Update AuthController routes; add Test endpoint

Refactored route attributes for Login and Status actions to use nameof() for improved maintainability. Added a new Test GET endpoint that returns a simple OK response.
This commit is contained in:
2026-03-13 13:02:01 +01:00
parent 7926d3d93f
commit cfc74276ae

View File

@@ -29,7 +29,7 @@ public class AuthController : ControllerBase
/// Triggers the NTLM handshake and returns authenticated user info.
/// </summary>
[Authorize]
[HttpGet("login")]
[HttpGet(nameof(Login))]
public IActionResult Login()
{
var identity = User.Identity;
@@ -93,7 +93,7 @@ public class AuthController : ControllerBase
}
[Authorize]
[HttpGet("status")]
[HttpGet(nameof(Status))]
public IActionResult Status()
{
return Ok(new
@@ -102,4 +102,7 @@ public class AuthController : ControllerBase
User.Identity?.AuthenticationType
});
}
[HttpGet(nameof(Test))]
public IActionResult Test() => Ok();
}