Merge branch 'main' of https://git.ranaze.com/null/promiscuity into main
Deploy Promiscuity Character API / deploy (push) Has been cancelled
k8s smoke test / test (push) Has been cancelled
Deploy Promiscuity Auth API / deploy (push) Has been cancelled

This commit is contained in:
2026-01-07 17:32:29 -06:00
171 changed files with 5673 additions and 188 deletions
+17
View File
@@ -0,0 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Bcrypt.Net-Next" Version="4.0.3" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="8.0.8" />
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="8.0.8" />
<PackageReference Include="MongoDB.Driver" Version="3.4.3" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.5.0" />
</ItemGroup>
</Project>
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ActiveDebugProfile>https</ActiveDebugProfile>
</PropertyGroup>
</Project>
+6
View File
@@ -0,0 +1,6 @@
@AuthApi_HostAddress = http://localhost:5279
GET {{AuthApi_HostAddress}}/weatherforecast/
Accept: application/json
###
@@ -0,0 +1,113 @@
using AuthApi.Models;
using AuthApi.Services;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Microsoft.IdentityModel.Tokens;
using System.IdentityModel.Tokens.Jwt;
using System.Security.Claims;
using System.Text;
namespace AuthApi.Controllers;
[ApiController]
[Route("api/[controller]")]
public class AuthController : ControllerBase
{
private readonly UserService _users;
private readonly IConfiguration _cfg;
private readonly BlacklistService _blacklist;
public AuthController(UserService users, IConfiguration cfg, BlacklistService blacklist)
{
_users = users; _cfg = cfg; _blacklist = blacklist;
}
[HttpPost("register")]
public async Task<IActionResult> Register([FromBody] RegisterRequest req)
{
if (string.IsNullOrWhiteSpace(req.Username) || string.IsNullOrWhiteSpace(req.Password))
return BadRequest("Username and password required");
if (await _users.GetByUsernameAsync(req.Username) != null)
return BadRequest("User already exists");
var hash = BCrypt.Net.BCrypt.HashPassword(req.Password);
var user = new User { Username = req.Username, PasswordHash = hash, Role = "USER", Email = req.Email };
await _users.CreateAsync(user);
return Ok("User created");
}
[HttpPost("login")]
public async Task<IActionResult> Login([FromBody] LoginRequest req)
{
var user = await _users.GetByUsernameAsync(req.Username);
if (user == null || !BCrypt.Net.BCrypt.Verify(req.Password, user.PasswordHash))
return Unauthorized();
var (accessToken, jti, expUtc) = GenerateJwtToken(user);
user.RefreshToken = Guid.NewGuid().ToString("N");
user.RefreshTokenExpiry = DateTime.UtcNow.AddDays(7);
await _users.UpdateAsync(user);
return Ok(new { accessToken, refreshToken = user.RefreshToken, user.Username, user.Role, jti, exp = expUtc });
}
[HttpPost("refresh")]
public async Task<IActionResult> Refresh([FromBody] RefreshRequest req)
{
var user = await _users.GetByUsernameAsync(req.Username);
if (user == null || user.RefreshToken != req.RefreshToken || user.RefreshTokenExpiry < DateTime.UtcNow)
return Unauthorized("Invalid or expired refresh token");
var (accessToken, _, expUtc) = GenerateJwtToken(user);
return Ok(new { accessToken, exp = expUtc });
}
[HttpPost("logout")]
[Authorize(Roles = "USER,SUPER")]
public async Task<IActionResult> Logout()
{
var token = HttpContext.Request.Headers["Authorization"].FirstOrDefault()?.Replace("Bearer ", "");
if (string.IsNullOrWhiteSpace(token)) return BadRequest("Token missing");
var jwt = new JwtSecurityTokenHandler().ReadJwtToken(token);
await _blacklist.AddToBlacklistAsync(jwt.Id, jwt.ValidTo);
return Ok("Logged out.");
}
[HttpPost("role")]
[Authorize(Roles = "SUPER")]
public async Task<IActionResult> ChangeUserRole([FromBody] ChangeRoleRequest req)
{
if (req.NewRole is not ("USER" or "SUPER")) return BadRequest("Role must be 'USER' or 'SUPER'");
var user = await _users.GetByUsernameAsync(req.Username);
if (user is null) return NotFound("User not found");
user.Role = req.NewRole;
await _users.UpdateAsync(user);
return Ok($"{req.Username}'s role updated to {req.NewRole}");
}
[HttpGet("users")]
[Authorize(Roles = "SUPER")]
public async Task<IActionResult> GetAllUsers() => Ok(await _users.GetAllAsync());
private (string token, string jti, DateTime expUtc) GenerateJwtToken(User user)
{
var key = Encoding.UTF8.GetBytes(_cfg["Jwt:Key"]!);
var issuer = _cfg["Jwt:Issuer"] ?? "GameAuthApi";
var audience = _cfg["Jwt:Audience"] ?? issuer;
var creds = new SigningCredentials(new SymmetricSecurityKey(key), SecurityAlgorithms.HmacSha256);
var jti = Guid.NewGuid().ToString("N");
var claims = new[]
{
new Claim(ClaimTypes.Name, user.Username),
new Claim(ClaimTypes.NameIdentifier, user.Id),
new Claim(ClaimTypes.Role, user.Role),
new Claim(JwtRegisteredClaimNames.Jti, jti)
};
var exp = DateTime.UtcNow.AddMinutes(15);
var token = new JwtSecurityToken(issuer, audience, claims, expires: exp, signingCredentials: creds);
return (new JwtSecurityTokenHandler().WriteToken(token), jti, exp);
}
}
+21
View File
@@ -0,0 +1,21 @@
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
# Copy project file first to take advantage of Docker layer caching
COPY ["AuthApi.csproj", "./"]
RUN dotnet restore "AuthApi.csproj"
# Copy the remaining source and publish
COPY . .
RUN dotnet publish "AuthApi.csproj" -c Release -o /app/publish /p:UseAppHost=false
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS final
WORKDIR /app
COPY --from=build /app/publish .
ENV ASPNETCORE_URLS=http://+:8080 \
ASPNETCORE_ENVIRONMENT=Production
EXPOSE 8080
ENTRYPOINT ["dotnet", "AuthApi.dll"]
+6
View File
@@ -0,0 +1,6 @@
namespace AuthApi.Models;
public class RegisterRequest { public string Username { get; set; } = ""; public string Password { get; set; } = ""; public string? Email { get; set; } }
public class LoginRequest { public string Username { get; set; } = ""; public string Password { get; set; } = ""; }
public class ChangeRoleRequest { public string Username { get; set; } = ""; public string NewRole { get; set; } = ""; }
public class RefreshRequest { public string Username { get; set; } = ""; public string RefreshToken { get; set; } = ""; }
+16
View File
@@ -0,0 +1,16 @@
using MongoDB.Bson;
using MongoDB.Bson.Serialization.Attributes;
namespace AuthApi.Models;
public class User
{
[BsonId] [BsonRepresentation(BsonType.ObjectId)]
public string Id { get; set; } = default!;
public string Username { get; set; } = default!;
public string PasswordHash { get; set; } = default!;
public string Role { get; set; } = "USER";
public string? Email { get; set; }
public string? RefreshToken { get; set; }
public DateTime? RefreshTokenExpiry { get; set; }
}
+86
View File
@@ -0,0 +1,86 @@
using AuthApi.Services;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.IdentityModel.Tokens;
using Microsoft.OpenApi.Models;
using System.Security.Claims;
using System.Text;
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddControllers();
// DI
builder.Services.AddSingleton<UserService>();
builder.Services.AddSingleton<BlacklistService>();
// Swagger + JWT auth in Swagger
builder.Services.AddEndpointsApiExplorer();
builder.Services.AddSwaggerGen(c =>
{
c.SwaggerDoc("v1", new OpenApiInfo { Title = "Auth API", Version = "v1" });
c.AddSecurityDefinition("bearerAuth", new OpenApiSecurityScheme
{
Type = SecuritySchemeType.Http,
Scheme = "bearer",
BearerFormat = "JWT",
Description = "Paste your access token here (no 'Bearer ' prefix needed)."
});
c.AddSecurityRequirement(new OpenApiSecurityRequirement
{
{
new OpenApiSecurityScheme
{
Reference = new OpenApiReference
{ Type = ReferenceType.SecurityScheme, Id = "bearerAuth" }
},
Array.Empty<string>()
}
});
});
// AuthN/JWT
var cfg = builder.Configuration;
var jwtKey = cfg["Jwt:Key"] ?? throw new Exception("Jwt:Key missing");
var issuer = cfg["Jwt:Issuer"] ?? "GameAuthApi";
var aud = cfg["Jwt:Audience"] ?? issuer;
builder.Services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddJwtBearer(o =>
{
o.TokenValidationParameters = new TokenValidationParameters
{
ValidateIssuer = true, ValidIssuer = issuer,
ValidateAudience = true, ValidAudience = aud,
ValidateIssuerSigningKey = true,
IssuerSigningKey = new SymmetricSecurityKey(Encoding.UTF8.GetBytes(jwtKey)),
ValidateLifetime = true,
ClockSkew = TimeSpan.FromSeconds(30)
};
o.Events = new JwtBearerEvents
{
OnTokenValidated = async ctx =>
{
var jti = ctx.Principal?.FindFirstValue(System.IdentityModel.Tokens.Jwt.JwtRegisteredClaimNames.Jti);
if (!string.IsNullOrEmpty(jti))
{
var bl = ctx.HttpContext.RequestServices.GetRequiredService<BlacklistService>();
if (await bl.IsBlacklistedAsync(jti)) ctx.Fail("Token revoked");
}
}
};
});
builder.Services.AddAuthorization();
var app = builder.Build();
app.MapGet("/healthz", () => Results.Ok("ok"));
app.UseSwagger();
app.UseSwaggerUI(o =>
{
o.SwaggerEndpoint("/swagger/v1/swagger.json", "Auth API v1");
o.RoutePrefix = "swagger";
});
app.UseAuthentication();
app.UseAuthorization();
app.MapControllers();
app.Run();
@@ -0,0 +1,23 @@
{
"$schema": "https://json.schemastore.org/launchsettings.json",
"profiles": {
"http": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": false,
"applicationUrl": "http://localhost:5279",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"https": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": false,
"applicationUrl": "https://localhost:7295;http://localhost:5279",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}
@@ -0,0 +1,36 @@
using MongoDB.Bson.Serialization.Attributes;
using MongoDB.Driver;
namespace AuthApi.Services;
public class BlacklistedToken
{
[BsonId] public string Jti { get; set; } = default!;
public DateTime ExpiresAt { get; set; }
}
public class BlacklistService
{
private readonly IMongoCollection<BlacklistedToken> _col;
public BlacklistService(IConfiguration cfg)
{
var cs = cfg["MongoDB:ConnectionString"] ?? "mongodb://127.0.0.1:27017";
var dbName = cfg["MongoDB:DatabaseName"] ?? "GameDb";
var client = new MongoClient(cs);
var db = client.GetDatabase(dbName);
_col = db.GetCollection<BlacklistedToken>("BlacklistedTokens");
// TTL index so revocations expire automatically
var keys = Builders<BlacklistedToken>.IndexKeys.Ascending(x => x.ExpiresAt);
_col.Indexes.CreateOne(new CreateIndexModel<BlacklistedToken>(keys, new CreateIndexOptions { ExpireAfter = TimeSpan.Zero }));
}
public Task AddToBlacklistAsync(string jti, DateTime expiresAt) =>
_col.ReplaceOneAsync(x => x.Jti == jti,
new BlacklistedToken { Jti = jti, ExpiresAt = expiresAt },
new ReplaceOptions { IsUpsert = true });
public Task<bool> IsBlacklistedAsync(string jti) =>
_col.Find(x => x.Jti == jti).AnyAsync();
}
@@ -0,0 +1,32 @@
using AuthApi.Models;
using MongoDB.Driver;
namespace AuthApi.Services;
public class UserService
{
private readonly IMongoCollection<User> _col;
public UserService(IConfiguration cfg)
{
var cs = cfg["MongoDB:ConnectionString"] ?? "mongodb://127.0.0.1:27017";
var dbName = cfg["MongoDB:DatabaseName"] ?? "GameDb";
var client = new MongoClient(cs);
var db = client.GetDatabase(dbName);
_col = db.GetCollection<User>("Users");
var keys = Builders<User>.IndexKeys.Ascending(u => u.Username);
_col.Indexes.CreateOne(new CreateIndexModel<User>(keys, new CreateIndexOptions { Unique = true }));
}
public Task<User?> GetByUsernameAsync(string username) =>
_col.Find(u => u.Username == username).FirstOrDefaultAsync();
public Task CreateAsync(User user) => _col.InsertOneAsync(user);
public Task UpdateAsync(User user) =>
_col.ReplaceOneAsync(u => u.Id == user.Id, user);
public Task<List<User>> GetAllAsync() =>
_col.Find(FilterDefinition<User>.Empty).ToListAsync();
}
@@ -0,0 +1,8 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
}
}
+7
View File
@@ -0,0 +1,7 @@
{
"Kestrel": { "Endpoints": { "Http": { "Url": "http://0.0.0.0:5000" } } },
"MongoDB": { "ConnectionString": "mongodb://192.168.86.50:27017", "DatabaseName": "promiscuity" },
"Jwt": { "Key": "SuperUltraSecureJwtKeyWithAtLeast32Chars!!", "Issuer": "promiscuity", "Audience": "promiscuity-auth-api" },
"Logging": { "LogLevel": { "Default": "Information" } },
"AllowedHosts": "*"
}
@@ -0,0 +1,476 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v8.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v8.0": {
"AuthApi/1.0.0": {
"dependencies": {
"BCrypt.Net-Next": "4.0.3",
"Microsoft.AspNetCore.Authentication.JwtBearer": "8.0.8",
"Microsoft.AspNetCore.OpenApi": "8.0.8",
"MongoDB.Driver": "3.4.3",
"Swashbuckle.AspNetCore": "6.5.0"
},
"runtime": {
"AuthApi.dll": {}
}
},
"BCrypt.Net-Next/4.0.3": {
"runtime": {
"lib/net6.0/BCrypt.Net-Next.dll": {
"assemblyVersion": "4.0.3.0",
"fileVersion": "4.0.3.0"
}
}
},
"DnsClient/1.6.1": {
"dependencies": {
"Microsoft.Win32.Registry": "5.0.0"
},
"runtime": {
"lib/net5.0/DnsClient.dll": {
"assemblyVersion": "1.6.1.0",
"fileVersion": "1.6.1.0"
}
}
},
"Microsoft.AspNetCore.Authentication.JwtBearer/8.0.8": {
"dependencies": {
"Microsoft.IdentityModel.Protocols.OpenIdConnect": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.AspNetCore.Authentication.JwtBearer.dll": {
"assemblyVersion": "8.0.8.0",
"fileVersion": "8.0.824.36908"
}
}
},
"Microsoft.AspNetCore.OpenApi/8.0.8": {
"dependencies": {
"Microsoft.OpenApi": "1.4.3"
},
"runtime": {
"lib/net8.0/Microsoft.AspNetCore.OpenApi.dll": {
"assemblyVersion": "8.0.8.0",
"fileVersion": "8.0.824.36908"
}
}
},
"Microsoft.Extensions.ApiDescription.Server/6.0.5": {},
"Microsoft.Extensions.Logging.Abstractions/2.0.0": {},
"Microsoft.IdentityModel.Abstractions/7.1.2": {
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.Abstractions.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.IdentityModel.JsonWebTokens/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.Tokens": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.JsonWebTokens.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.IdentityModel.Logging/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.Abstractions": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.Logging.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.IdentityModel.Protocols/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.Logging": "7.1.2",
"Microsoft.IdentityModel.Tokens": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.Protocols.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.IdentityModel.Protocols.OpenIdConnect/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.Protocols": "7.1.2",
"System.IdentityModel.Tokens.Jwt": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.IdentityModel.Tokens/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.Logging": "7.1.2"
},
"runtime": {
"lib/net8.0/Microsoft.IdentityModel.Tokens.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"Microsoft.NETCore.Platforms/5.0.0": {},
"Microsoft.OpenApi/1.4.3": {
"runtime": {
"lib/netstandard2.0/Microsoft.OpenApi.dll": {
"assemblyVersion": "1.4.3.0",
"fileVersion": "1.4.3.0"
}
}
},
"Microsoft.Win32.Registry/5.0.0": {
"dependencies": {
"System.Security.AccessControl": "5.0.0",
"System.Security.Principal.Windows": "5.0.0"
}
},
"MongoDB.Bson/3.4.3": {
"dependencies": {
"System.Memory": "4.5.5",
"System.Runtime.CompilerServices.Unsafe": "5.0.0"
},
"runtime": {
"lib/net6.0/MongoDB.Bson.dll": {
"assemblyVersion": "3.4.3.0",
"fileVersion": "3.4.3.0"
}
}
},
"MongoDB.Driver/3.4.3": {
"dependencies": {
"DnsClient": "1.6.1",
"Microsoft.Extensions.Logging.Abstractions": "2.0.0",
"MongoDB.Bson": "3.4.3",
"SharpCompress": "0.30.1",
"Snappier": "1.0.0",
"System.Buffers": "4.5.1",
"ZstdSharp.Port": "0.7.3"
},
"runtime": {
"lib/net6.0/MongoDB.Driver.dll": {
"assemblyVersion": "3.4.3.0",
"fileVersion": "3.4.3.0"
}
}
},
"SharpCompress/0.30.1": {
"runtime": {
"lib/net5.0/SharpCompress.dll": {
"assemblyVersion": "0.30.1.0",
"fileVersion": "0.30.1.0"
}
}
},
"Snappier/1.0.0": {
"runtime": {
"lib/net5.0/Snappier.dll": {
"assemblyVersion": "1.0.0.0",
"fileVersion": "1.0.0.0"
}
}
},
"Swashbuckle.AspNetCore/6.5.0": {
"dependencies": {
"Microsoft.Extensions.ApiDescription.Server": "6.0.5",
"Swashbuckle.AspNetCore.Swagger": "6.5.0",
"Swashbuckle.AspNetCore.SwaggerGen": "6.5.0",
"Swashbuckle.AspNetCore.SwaggerUI": "6.5.0"
}
},
"Swashbuckle.AspNetCore.Swagger/6.5.0": {
"dependencies": {
"Microsoft.OpenApi": "1.4.3"
},
"runtime": {
"lib/net7.0/Swashbuckle.AspNetCore.Swagger.dll": {
"assemblyVersion": "6.5.0.0",
"fileVersion": "6.5.0.0"
}
}
},
"Swashbuckle.AspNetCore.SwaggerGen/6.5.0": {
"dependencies": {
"Swashbuckle.AspNetCore.Swagger": "6.5.0"
},
"runtime": {
"lib/net7.0/Swashbuckle.AspNetCore.SwaggerGen.dll": {
"assemblyVersion": "6.5.0.0",
"fileVersion": "6.5.0.0"
}
}
},
"Swashbuckle.AspNetCore.SwaggerUI/6.5.0": {
"runtime": {
"lib/net7.0/Swashbuckle.AspNetCore.SwaggerUI.dll": {
"assemblyVersion": "6.5.0.0",
"fileVersion": "6.5.0.0"
}
}
},
"System.Buffers/4.5.1": {},
"System.IdentityModel.Tokens.Jwt/7.1.2": {
"dependencies": {
"Microsoft.IdentityModel.JsonWebTokens": "7.1.2",
"Microsoft.IdentityModel.Tokens": "7.1.2"
},
"runtime": {
"lib/net8.0/System.IdentityModel.Tokens.Jwt.dll": {
"assemblyVersion": "7.1.2.0",
"fileVersion": "7.1.2.41121"
}
}
},
"System.Memory/4.5.5": {},
"System.Runtime.CompilerServices.Unsafe/5.0.0": {},
"System.Security.AccessControl/5.0.0": {
"dependencies": {
"Microsoft.NETCore.Platforms": "5.0.0",
"System.Security.Principal.Windows": "5.0.0"
}
},
"System.Security.Principal.Windows/5.0.0": {},
"ZstdSharp.Port/0.7.3": {
"runtime": {
"lib/net7.0/ZstdSharp.dll": {
"assemblyVersion": "0.7.3.0",
"fileVersion": "0.7.3.0"
}
}
}
}
},
"libraries": {
"AuthApi/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"BCrypt.Net-Next/4.0.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-W+U9WvmZQgi5cX6FS5GDtDoPzUCV4LkBLkywq/kRZhuDwcbavOzcDAr3LXJFqHUi952Yj3LEYoWW0jbEUQChsA==",
"path": "bcrypt.net-next/4.0.3",
"hashPath": "bcrypt.net-next.4.0.3.nupkg.sha512"
},
"DnsClient/1.6.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-4H/f2uYJOZ+YObZjpY9ABrKZI+JNw3uizp6oMzTXwDw6F+2qIPhpRl/1t68O/6e98+vqNiYGu+lswmwdYUy3gg==",
"path": "dnsclient/1.6.1",
"hashPath": "dnsclient.1.6.1.nupkg.sha512"
},
"Microsoft.AspNetCore.Authentication.JwtBearer/8.0.8": {
"type": "package",
"serviceable": true,
"sha512": "sha512-J145j2LgD4kkkNkrf5DW/pKzithZRKN5EFY+KAO3SqweMyDfv4cgKgtOIsv2bhrOLGqPJixuZkZte7LfK1seYQ==",
"path": "microsoft.aspnetcore.authentication.jwtbearer/8.0.8",
"hashPath": "microsoft.aspnetcore.authentication.jwtbearer.8.0.8.nupkg.sha512"
},
"Microsoft.AspNetCore.OpenApi/8.0.8": {
"type": "package",
"serviceable": true,
"sha512": "sha512-wNHhohqP8rmsQ4UhKbd6jZMD6l+2Q/+DvRBT0Cgqeuglr13aF6sSJWicZKCIhZAUXzuhkdwtHVc95MlPlFk0dA==",
"path": "microsoft.aspnetcore.openapi/8.0.8",
"hashPath": "microsoft.aspnetcore.openapi.8.0.8.nupkg.sha512"
},
"Microsoft.Extensions.ApiDescription.Server/6.0.5": {
"type": "package",
"serviceable": true,
"sha512": "sha512-Ckb5EDBUNJdFWyajfXzUIMRkhf52fHZOQuuZg/oiu8y7zDCVwD0iHhew6MnThjHmevanpxL3f5ci2TtHQEN6bw==",
"path": "microsoft.extensions.apidescription.server/6.0.5",
"hashPath": "microsoft.extensions.apidescription.server.6.0.5.nupkg.sha512"
},
"Microsoft.Extensions.Logging.Abstractions/2.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-6ZCllUYGFukkymSTx3Yr0G/ajRxoNJp7/FqSxSB4fGISST54ifBhgu4Nc0ItGi3i6DqwuNd8SUyObmiC++AO2Q==",
"path": "microsoft.extensions.logging.abstractions/2.0.0",
"hashPath": "microsoft.extensions.logging.abstractions.2.0.0.nupkg.sha512"
},
"Microsoft.IdentityModel.Abstractions/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-33eTIA2uO/L9utJjZWbKsMSVsQf7F8vtd6q5mQX7ZJzNvCpci5fleD6AeANGlbbb7WX7XKxq9+Dkb5e3GNDrmQ==",
"path": "microsoft.identitymodel.abstractions/7.1.2",
"hashPath": "microsoft.identitymodel.abstractions.7.1.2.nupkg.sha512"
},
"Microsoft.IdentityModel.JsonWebTokens/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-cloLGeZolXbCJhJBc5OC05uhrdhdPL6MWHuVUnkkUvPDeK7HkwThBaLZ1XjBQVk9YhxXE2OvHXnKi0PLleXxDg==",
"path": "microsoft.identitymodel.jsonwebtokens/7.1.2",
"hashPath": "microsoft.identitymodel.jsonwebtokens.7.1.2.nupkg.sha512"
},
"Microsoft.IdentityModel.Logging/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-YCxBt2EeJP8fcXk9desChkWI+0vFqFLvBwrz5hBMsoh0KJE6BC66DnzkdzkJNqMltLromc52dkdT206jJ38cTw==",
"path": "microsoft.identitymodel.logging/7.1.2",
"hashPath": "microsoft.identitymodel.logging.7.1.2.nupkg.sha512"
},
"Microsoft.IdentityModel.Protocols/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-SydLwMRFx6EHPWJ+N6+MVaoArN1Htt92b935O3RUWPY1yUF63zEjvd3lBu79eWdZUwedP8TN2I5V9T3nackvIQ==",
"path": "microsoft.identitymodel.protocols/7.1.2",
"hashPath": "microsoft.identitymodel.protocols.7.1.2.nupkg.sha512"
},
"Microsoft.IdentityModel.Protocols.OpenIdConnect/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-6lHQoLXhnMQ42mGrfDkzbIOR3rzKM1W1tgTeMPLgLCqwwGw0d96xFi/UiX/fYsu7d6cD5MJiL3+4HuI8VU+sVQ==",
"path": "microsoft.identitymodel.protocols.openidconnect/7.1.2",
"hashPath": "microsoft.identitymodel.protocols.openidconnect.7.1.2.nupkg.sha512"
},
"Microsoft.IdentityModel.Tokens/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-oICJMqr3aNEDZOwnH5SK49bR6Z4aX0zEAnOLuhloumOSuqnNq+GWBdQyrgILnlcT5xj09xKCP/7Y7gJYB+ls/g==",
"path": "microsoft.identitymodel.tokens/7.1.2",
"hashPath": "microsoft.identitymodel.tokens.7.1.2.nupkg.sha512"
},
"Microsoft.NETCore.Platforms/5.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-VyPlqzH2wavqquTcYpkIIAQ6WdenuKoFN0BdYBbCWsclXacSOHNQn66Gt4z5NBqEYW0FAPm5rlvki9ZiCij5xQ==",
"path": "microsoft.netcore.platforms/5.0.0",
"hashPath": "microsoft.netcore.platforms.5.0.0.nupkg.sha512"
},
"Microsoft.OpenApi/1.4.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-rURwggB+QZYcSVbDr7HSdhw/FELvMlriW10OeOzjPT7pstefMo7IThhtNtDudxbXhW+lj0NfX72Ka5EDsG8x6w==",
"path": "microsoft.openapi/1.4.3",
"hashPath": "microsoft.openapi.1.4.3.nupkg.sha512"
},
"Microsoft.Win32.Registry/5.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-dDoKi0PnDz31yAyETfRntsLArTlVAVzUzCIvvEDsDsucrl33Dl8pIJG06ePTJTI3tGpeyHS9Cq7Foc/s4EeKcg==",
"path": "microsoft.win32.registry/5.0.0",
"hashPath": "microsoft.win32.registry.5.0.0.nupkg.sha512"
},
"MongoDB.Bson/3.4.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ZB2nCdlWtmDGItkDFh2E2kfYlXaItG414t9Np7CZhpftLypemYnxtdI52H+0b8RPqoUJD7bUvrf598sDTJd5iA==",
"path": "mongodb.bson/3.4.3",
"hashPath": "mongodb.bson.3.4.3.nupkg.sha512"
},
"MongoDB.Driver/3.4.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-yE6XQiDoFwTH4Xq/STJCbzsz+74RuzCXU45g9gaWFlLyy95xG8utuj+e64uXSbONtzabbp1O/8vfA3/HJXL6Pg==",
"path": "mongodb.driver/3.4.3",
"hashPath": "mongodb.driver.3.4.3.nupkg.sha512"
},
"SharpCompress/0.30.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-XqD4TpfyYGa7QTPzaGlMVbcecKnXy4YmYLDWrU+JIj7IuRNl7DH2END+Ll7ekWIY8o3dAMWLFDE1xdhfIWD1nw==",
"path": "sharpcompress/0.30.1",
"hashPath": "sharpcompress.0.30.1.nupkg.sha512"
},
"Snappier/1.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-rFtK2KEI9hIe8gtx3a0YDXdHOpedIf9wYCEYtBEmtlyiWVX3XlCNV03JrmmAi/Cdfn7dxK+k0sjjcLv4fpHnqA==",
"path": "snappier/1.0.0",
"hashPath": "snappier.1.0.0.nupkg.sha512"
},
"Swashbuckle.AspNetCore/6.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-FK05XokgjgwlCI6wCT+D4/abtQkL1X1/B9Oas6uIwHFmYrIO9WUD5aLC9IzMs9GnHfUXOtXZ2S43gN1mhs5+aA==",
"path": "swashbuckle.aspnetcore/6.5.0",
"hashPath": "swashbuckle.aspnetcore.6.5.0.nupkg.sha512"
},
"Swashbuckle.AspNetCore.Swagger/6.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-XWmCmqyFmoItXKFsQSwQbEAsjDKcxlNf1l+/Ki42hcb6LjKL8m5Db69OTvz5vLonMSRntYO1XLqz0OP+n3vKnA==",
"path": "swashbuckle.aspnetcore.swagger/6.5.0",
"hashPath": "swashbuckle.aspnetcore.swagger.6.5.0.nupkg.sha512"
},
"Swashbuckle.AspNetCore.SwaggerGen/6.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-Y/qW8Qdg9OEs7V013tt+94OdPxbRdbhcEbw4NiwGvf4YBcfhL/y7qp/Mjv/cENsQ2L3NqJ2AOu94weBy/h4KvA==",
"path": "swashbuckle.aspnetcore.swaggergen/6.5.0",
"hashPath": "swashbuckle.aspnetcore.swaggergen.6.5.0.nupkg.sha512"
},
"Swashbuckle.AspNetCore.SwaggerUI/6.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-OvbvxX+wL8skxTBttcBsVxdh73Fag4xwqEU2edh4JMn7Ws/xJHnY/JB1e9RoCb6XpDxUF3hD9A0Z1lEUx40Pfw==",
"path": "swashbuckle.aspnetcore.swaggerui/6.5.0",
"hashPath": "swashbuckle.aspnetcore.swaggerui.6.5.0.nupkg.sha512"
},
"System.Buffers/4.5.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-Rw7ijyl1qqRS0YQD/WycNst8hUUMgrMH4FCn1nNm27M4VxchZ1js3fVjQaANHO5f3sN4isvP4a+Met9Y4YomAg==",
"path": "system.buffers/4.5.1",
"hashPath": "system.buffers.4.5.1.nupkg.sha512"
},
"System.IdentityModel.Tokens.Jwt/7.1.2": {
"type": "package",
"serviceable": true,
"sha512": "sha512-Thhbe1peAmtSBFaV/ohtykXiZSOkx59Da44hvtWfIMFofDA3M3LaVyjstACf2rKGn4dEDR2cUpRAZ0Xs/zB+7Q==",
"path": "system.identitymodel.tokens.jwt/7.1.2",
"hashPath": "system.identitymodel.tokens.jwt.7.1.2.nupkg.sha512"
},
"System.Memory/4.5.5": {
"type": "package",
"serviceable": true,
"sha512": "sha512-XIWiDvKPXaTveaB7HVganDlOCRoj03l+jrwNvcge/t8vhGYKvqV+dMv6G4SAX2NoNmN0wZfVPTAlFwZcZvVOUw==",
"path": "system.memory/4.5.5",
"hashPath": "system.memory.4.5.5.nupkg.sha512"
},
"System.Runtime.CompilerServices.Unsafe/5.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ZD9TMpsmYJLrxbbmdvhwt9YEgG5WntEnZ/d1eH8JBX9LBp+Ju8BSBhUGbZMNVHHomWo2KVImJhTDl2hIgw/6MA==",
"path": "system.runtime.compilerservices.unsafe/5.0.0",
"hashPath": "system.runtime.compilerservices.unsafe.5.0.0.nupkg.sha512"
},
"System.Security.AccessControl/5.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-dagJ1mHZO3Ani8GH0PHpPEe/oYO+rVdbQjvjJkBRNQkX4t0r1iaeGn8+/ybkSLEan3/slM0t59SVdHzuHf2jmw==",
"path": "system.security.accesscontrol/5.0.0",
"hashPath": "system.security.accesscontrol.5.0.0.nupkg.sha512"
},
"System.Security.Principal.Windows/5.0.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-t0MGLukB5WAVU9bO3MGzvlGnyJPgUlcwerXn1kzBRjwLKixT96XV0Uza41W49gVd8zEMFu9vQEFlv0IOrytICA==",
"path": "system.security.principal.windows/5.0.0",
"hashPath": "system.security.principal.windows.5.0.0.nupkg.sha512"
},
"ZstdSharp.Port/0.7.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-U9Ix4l4cl58Kzz1rJzj5hoVTjmbx1qGMwzAcbv1j/d3NzrFaESIurQyg+ow4mivCgkE3S413y+U9k4WdnEIkRA==",
"path": "zstdsharp.port/0.7.3",
"hashPath": "zstdsharp.port.0.7.3.nupkg.sha512"
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,19 @@
{
"runtimeOptions": {
"tfm": "net8.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "8.0.0"
},
{
"name": "Microsoft.AspNetCore.App",
"version": "8.0.0"
}
],
"configProperties": {
"System.GC.Server": true,
"System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,8 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
}
}
@@ -0,0 +1,7 @@
{
"Kestrel": { "Endpoints": { "Http": { "Url": "http://0.0.0.0:5000" } } },
"MongoDB": { "ConnectionString": "mongodb://192.168.86.50:27017", "DatabaseName": "promiscuity" },
"Jwt": { "Key": "SuperUltraSecureJwtKeyWithAtLeast32Chars!!", "Issuer": "promiscuity", "Audience": "promiscuity-auth-api" },
"Logging": { "LogLevel": { "Default": "Information" } },
"AllowedHosts": "*"
}
+28
View File
@@ -0,0 +1,28 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: promiscuity-auth
labels:
app: promiscuity-auth
spec:
replicas: 2
selector:
matchLabels:
app: promiscuity-auth
template:
metadata:
labels:
app: promiscuity-auth
spec:
containers:
- name: promiscuity-auth
image: promiscuity-auth:latest
imagePullPolicy: IfNotPresent
ports:
- containerPort: 8080
readinessProbe:
httpGet:
path: /healthz
port: 8080
initialDelaySeconds: 5
periodSeconds: 10
+15
View File
@@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
name: promiscuity-auth
labels:
app: promiscuity-auth
spec:
selector:
app: promiscuity-auth
type: NodePort
ports:
- name: http
port: 80 # cluster port
targetPort: 5000 # container port
nodePort: 30080 # same external port you've been using
@@ -0,0 +1,88 @@
{
"format": 1,
"restore": {
"C:\\Users\\hz-vm\\Desktop\\micro-services\\AuthApi\\AuthApi.csproj": {}
},
"projects": {
"C:\\Users\\hz-vm\\Desktop\\micro-services\\AuthApi\\AuthApi.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\hz-vm\\Desktop\\micro-services\\AuthApi\\AuthApi.csproj",
"projectName": "AuthApi",
"projectPath": "C:\\Users\\hz-vm\\Desktop\\micro-services\\AuthApi\\AuthApi.csproj",
"packagesPath": "C:\\Users\\hz-vm\\.nuget\\packages\\",
"outputPath": "C:\\Users\\hz-vm\\Desktop\\micro-services\\AuthApi\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\hz-vm\\AppData\\Roaming\\NuGet\\NuGet.Config"
],
"originalTargetFrameworks": [
"net9.0"
],
"sources": {
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net9.0": {
"targetAlias": "net9.0",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
},
"restoreAuditProperties": {
"enableAudit": "true",
"auditLevel": "low",
"auditMode": "direct"
},
"SdkAnalysisLevel": "9.0.200"
},
"frameworks": {
"net9.0": {
"targetAlias": "net9.0",
"dependencies": {
"Bcrypt.Net-Next": {
"target": "Package",
"version": "[4.0.3, )"
},
"Microsoft.AspNetCore.Authentication.JwtBearer": {
"target": "Package",
"version": "[9.0.8, )"
},
"Microsoft.AspNetCore.OpenApi": {
"target": "Package",
"version": "[9.0.4, )"
},
"MongoDB.Driver": {
"target": "Package",
"version": "[3.4.3, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48",
"net481"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.AspNetCore.App": {
"privateAssets": "none"
},
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\9.0.203/PortableRuntimeIdentifierGraph.json"
}
}
}
}
}
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\hz-vm\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.13.2</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\hz-vm\.nuget\packages\" />
</ItemGroup>
</Project>
@@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />
@@ -0,0 +1,94 @@
{
"format": 1,
"restore": {
"Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\AuthApi.csproj": {}
},
"projects": {
"Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\AuthApi.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\AuthApi.csproj",
"projectName": "AuthApi",
"projectPath": "Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\AuthApi.csproj",
"packagesPath": "C:\\Users\\hz\\.nuget\\packages\\",
"outputPath": "Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\hz\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"net8.0"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"C:\\Program Files\\dotnet\\library-packs": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net8.0": {
"targetAlias": "net8.0",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
},
"restoreAuditProperties": {
"enableAudit": "true",
"auditLevel": "low",
"auditMode": "direct"
}
},
"frameworks": {
"net8.0": {
"targetAlias": "net8.0",
"dependencies": {
"Bcrypt.Net-Next": {
"target": "Package",
"version": "[4.0.3, )"
},
"Microsoft.AspNetCore.Authentication.JwtBearer": {
"target": "Package",
"version": "[8.0.8, )"
},
"Microsoft.AspNetCore.OpenApi": {
"target": "Package",
"version": "[8.0.8, )"
},
"MongoDB.Driver": {
"target": "Package",
"version": "[3.4.3, )"
},
"Swashbuckle.AspNetCore": {
"target": "Package",
"version": "[6.5.0, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48",
"net481"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.AspNetCore.App": {
"privateAssets": "none"
},
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.400/PortableRuntimeIdentifierGraph.json"
}
}
}
}
}
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\hz\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.11.0</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\hz\.nuget\packages\" />
</ItemGroup>
<ImportGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<Import Project="$(NuGetPackageRoot)microsoft.extensions.apidescription.server\6.0.5\build\Microsoft.Extensions.ApiDescription.Server.props" Condition="Exists('$(NuGetPackageRoot)microsoft.extensions.apidescription.server\6.0.5\build\Microsoft.Extensions.ApiDescription.Server.props')" />
<Import Project="$(NuGetPackageRoot)swashbuckle.aspnetcore\6.5.0\build\Swashbuckle.AspNetCore.props" Condition="Exists('$(NuGetPackageRoot)swashbuckle.aspnetcore\6.5.0\build\Swashbuckle.AspNetCore.props')" />
</ImportGroup>
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<PkgMicrosoft_Extensions_ApiDescription_Server Condition=" '$(PkgMicrosoft_Extensions_ApiDescription_Server)' == '' ">C:\Users\hz\.nuget\packages\microsoft.extensions.apidescription.server\6.0.5</PkgMicrosoft_Extensions_ApiDescription_Server>
</PropertyGroup>
</Project>
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ImportGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<Import Project="$(NuGetPackageRoot)microsoft.extensions.apidescription.server\6.0.5\build\Microsoft.Extensions.ApiDescription.Server.targets" Condition="Exists('$(NuGetPackageRoot)microsoft.extensions.apidescription.server\6.0.5\build\Microsoft.Extensions.ApiDescription.Server.targets')" />
</ImportGroup>
</Project>
@@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")]
@@ -0,0 +1,102 @@
[
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "Login",
"RelativePath": "api/Auth/login",
"HttpMethod": "POST",
"IsController": true,
"Order": 0,
"Parameters": [
{
"Name": "req",
"Type": "AuthApi.Models.LoginRequest",
"IsRequired": true
}
],
"ReturnTypes": []
},
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "Logout",
"RelativePath": "api/Auth/logout",
"HttpMethod": "POST",
"IsController": true,
"Order": 0,
"Parameters": [],
"ReturnTypes": []
},
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "Refresh",
"RelativePath": "api/Auth/refresh",
"HttpMethod": "POST",
"IsController": true,
"Order": 0,
"Parameters": [
{
"Name": "req",
"Type": "AuthApi.Models.RefreshRequest",
"IsRequired": true
}
],
"ReturnTypes": []
},
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "Register",
"RelativePath": "api/Auth/register",
"HttpMethod": "POST",
"IsController": true,
"Order": 0,
"Parameters": [
{
"Name": "req",
"Type": "AuthApi.Models.RegisterRequest",
"IsRequired": true
}
],
"ReturnTypes": []
},
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "ChangeUserRole",
"RelativePath": "api/Auth/role",
"HttpMethod": "POST",
"IsController": true,
"Order": 0,
"Parameters": [
{
"Name": "req",
"Type": "AuthApi.Models.ChangeRoleRequest",
"IsRequired": true
}
],
"ReturnTypes": []
},
{
"ContainingType": "AuthApi.Controllers.AuthController",
"Method": "GetAllUsers",
"RelativePath": "api/Auth/users",
"HttpMethod": "GET",
"IsController": true,
"Order": 0,
"Parameters": [],
"ReturnTypes": []
},
{
"ContainingType": "Program\u002B\u003C\u003Ec",
"Method": "\u003C\u003CMain\u003E$\u003Eb__0_2",
"RelativePath": "healthz",
"HttpMethod": "GET",
"IsController": false,
"Order": 0,
"Parameters": [],
"ReturnTypes": [
{
"Type": "System.Void",
"MediaTypes": [],
"StatusCode": 200
}
]
}
]
@@ -0,0 +1,23 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("AuthApi")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+9a56091e8e5e471606d25b9bf0f7f03190f6cbf5")]
[assembly: System.Reflection.AssemblyProductAttribute("AuthApi")]
[assembly: System.Reflection.AssemblyTitleAttribute("AuthApi")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Generated by the MSBuild WriteCodeFragment class.
@@ -0,0 +1 @@
a91a0b2722e979e6c11baa13ff8d8df94508dbebb6818a92f2b91e9d1d22c45b
@@ -0,0 +1,19 @@
is_global = true
build_property.TargetFramework = net8.0
build_property.TargetPlatformMinVersion =
build_property.UsingMicrosoftNETSdkWeb = true
build_property.ProjectTypeGuids =
build_property.InvariantGlobalization =
build_property.PlatformNeutralAssembly =
build_property.EnforceExtendedAnalyzerRules =
build_property._SupportedPlatformList = Linux,macOS,Windows
build_property.RootNamespace = AuthApi
build_property.RootNamespace = AuthApi
build_property.ProjectDir = Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\
build_property.EnableComHosting =
build_property.EnableGeneratedComInterfaceComImportInterop =
build_property.RazorLangVersion = 8.0
build_property.SupportLocalizedComponentNames =
build_property.GenerateRazorMetadataSourceChecksumAttributes =
build_property.MSBuildProjectDirectory = Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi
build_property._RazorSourceGeneratorDebug =
@@ -0,0 +1,17 @@
// <auto-generated/>
global using global::Microsoft.AspNetCore.Builder;
global using global::Microsoft.AspNetCore.Hosting;
global using global::Microsoft.AspNetCore.Http;
global using global::Microsoft.AspNetCore.Routing;
global using global::Microsoft.Extensions.Configuration;
global using global::Microsoft.Extensions.DependencyInjection;
global using global::Microsoft.Extensions.Hosting;
global using global::Microsoft.Extensions.Logging;
global using global::System;
global using global::System.Collections.Generic;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Net.Http.Json;
global using global::System.Threading;
global using global::System.Threading.Tasks;
@@ -0,0 +1,18 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: Microsoft.AspNetCore.Mvc.ApplicationParts.ApplicationPartAttribute("Microsoft.AspNetCore.OpenApi")]
[assembly: Microsoft.AspNetCore.Mvc.ApplicationParts.ApplicationPartAttribute("Swashbuckle.AspNetCore.SwaggerGen")]
// Generated by the MSBuild WriteCodeFragment class.
@@ -0,0 +1 @@
da46c012b6fe4f51885a4732442769de4be5f6593e91ea2c8a2d100926d7757f
@@ -0,0 +1,48 @@
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\appsettings.Development.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\appsettings.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\AuthApi.exe
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\AuthApi.deps.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\AuthApi.runtimeconfig.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\AuthApi.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\AuthApi.pdb
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\BCrypt.Net-Next.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\DnsClient.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.AspNetCore.Authentication.JwtBearer.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.AspNetCore.OpenApi.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.Abstractions.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.JsonWebTokens.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.Logging.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.Protocols.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.Protocols.OpenIdConnect.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.IdentityModel.Tokens.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Microsoft.OpenApi.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\MongoDB.Bson.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\MongoDB.Driver.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\SharpCompress.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Snappier.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Swashbuckle.AspNetCore.Swagger.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Swashbuckle.AspNetCore.SwaggerGen.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\Swashbuckle.AspNetCore.SwaggerUI.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\System.IdentityModel.Tokens.Jwt.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\bin\Debug\net8.0\ZstdSharp.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.csproj.AssemblyReference.cache
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.GeneratedMSBuildEditorConfig.editorconfig
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.AssemblyInfoInputs.cache
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.AssemblyInfo.cs
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.csproj.CoreCompileInputs.cache
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.MvcApplicationPartsAssemblyInfo.cs
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.MvcApplicationPartsAssemblyInfo.cache
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets.build.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets.development.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets\msbuild.AuthApi.Microsoft.AspNetCore.StaticWebAssets.props
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets\msbuild.build.AuthApi.props
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets\msbuild.buildMultiTargeting.AuthApi.props
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets\msbuild.buildTransitive.AuthApi.props
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\staticwebassets.pack.json
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\scopedcss\bundle\AuthApi.styles.css
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.csproj.Up2Date
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\refint\AuthApi.dll
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.pdb
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\AuthApi.genruntimeconfig.cache
Z:\Godot\Godot_v4.5-stable_mono_win64\repos\promiscuity\microservices\AuthApi\obj\Debug\net8.0\ref\AuthApi.dll
Binary file not shown.
@@ -0,0 +1 @@
e30fb922132cef9c79d05bc731999650beba7b92a3bd5e1cb012089dc4a23683
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,11 @@
{
"Version": 1,
"Hash": "C408O5kacdHemLwWaRw7LibnFg3O/FwJs0BPfvRzuIw=",
"Source": "AuthApi",
"BasePath": "_content/AuthApi",
"Mode": "Default",
"ManifestType": "Build",
"ReferencedProjectsConfiguration": [],
"DiscoveryPatterns": [],
"Assets": []
}
@@ -0,0 +1,3 @@
<Project>
<Import Project="Microsoft.AspNetCore.StaticWebAssets.props" />
</Project>
@@ -0,0 +1,3 @@
<Project>
<Import Project="..\build\AuthApi.props" />
</Project>
@@ -0,0 +1,3 @@
<Project>
<Import Project="..\buildMultiTargeting\AuthApi.props" />
</Project>
@@ -0,0 +1,17 @@
// <auto-generated/>
global using global::Microsoft.AspNetCore.Builder;
global using global::Microsoft.AspNetCore.Hosting;
global using global::Microsoft.AspNetCore.Http;
global using global::Microsoft.AspNetCore.Routing;
global using global::Microsoft.Extensions.Configuration;
global using global::Microsoft.Extensions.DependencyInjection;
global using global::Microsoft.Extensions.Hosting;
global using global::Microsoft.Extensions.Logging;
global using global::System;
global using global::System.Collections.Generic;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Net.Http.Json;
global using global::System.Threading;
global using global::System.Threading.Tasks;
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,39 @@
{
"version": 2,
"dgSpecHash": "l8awjmVG4Bo=",
"success": true,
"projectFilePath": "Z:\\Godot\\Godot_v4.5-stable_mono_win64\\repos\\promiscuity\\microservices\\AuthApi\\AuthApi.csproj",
"expectedPackageFiles": [
"C:\\Users\\hz\\.nuget\\packages\\bcrypt.net-next\\4.0.3\\bcrypt.net-next.4.0.3.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\dnsclient\\1.6.1\\dnsclient.1.6.1.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.aspnetcore.authentication.jwtbearer\\8.0.8\\microsoft.aspnetcore.authentication.jwtbearer.8.0.8.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.aspnetcore.openapi\\8.0.8\\microsoft.aspnetcore.openapi.8.0.8.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.extensions.apidescription.server\\6.0.5\\microsoft.extensions.apidescription.server.6.0.5.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.extensions.logging.abstractions\\2.0.0\\microsoft.extensions.logging.abstractions.2.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.abstractions\\7.1.2\\microsoft.identitymodel.abstractions.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.jsonwebtokens\\7.1.2\\microsoft.identitymodel.jsonwebtokens.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.logging\\7.1.2\\microsoft.identitymodel.logging.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.protocols\\7.1.2\\microsoft.identitymodel.protocols.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.protocols.openidconnect\\7.1.2\\microsoft.identitymodel.protocols.openidconnect.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.identitymodel.tokens\\7.1.2\\microsoft.identitymodel.tokens.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.netcore.platforms\\5.0.0\\microsoft.netcore.platforms.5.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.openapi\\1.4.3\\microsoft.openapi.1.4.3.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\microsoft.win32.registry\\5.0.0\\microsoft.win32.registry.5.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\mongodb.bson\\3.4.3\\mongodb.bson.3.4.3.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\mongodb.driver\\3.4.3\\mongodb.driver.3.4.3.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\sharpcompress\\0.30.1\\sharpcompress.0.30.1.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\snappier\\1.0.0\\snappier.1.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\swashbuckle.aspnetcore\\6.5.0\\swashbuckle.aspnetcore.6.5.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\swashbuckle.aspnetcore.swagger\\6.5.0\\swashbuckle.aspnetcore.swagger.6.5.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\swashbuckle.aspnetcore.swaggergen\\6.5.0\\swashbuckle.aspnetcore.swaggergen.6.5.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\swashbuckle.aspnetcore.swaggerui\\6.5.0\\swashbuckle.aspnetcore.swaggerui.6.5.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.buffers\\4.5.1\\system.buffers.4.5.1.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.identitymodel.tokens.jwt\\7.1.2\\system.identitymodel.tokens.jwt.7.1.2.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.memory\\4.5.5\\system.memory.4.5.5.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.runtime.compilerservices.unsafe\\5.0.0\\system.runtime.compilerservices.unsafe.5.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.security.accesscontrol\\5.0.0\\system.security.accesscontrol.5.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\system.security.principal.windows\\5.0.0\\system.security.principal.windows.5.0.0.nupkg.sha512",
"C:\\Users\\hz\\.nuget\\packages\\zstdsharp.port\\0.7.3\\zstdsharp.port.0.7.3.nupkg.sha512"
],
"logs": []
}