mirror of
https://github.com/hmaxnl/DotBased.git
synced 2025-05-15 23:07:54 +02:00
[WIP] Working schemes
This commit is contained in:
parent
edf8891ddc
commit
05b95c6050
|
@ -1,16 +1,24 @@
|
|||
using System.Text.Json;
|
||||
using Microsoft.AspNetCore.Authentication;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace DotBased.AspNet.Authority.Controllers;
|
||||
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
[Microsoft.AspNetCore.Mvc.Route("[controller]")]
|
||||
public class AuthorityController : ControllerBase
|
||||
{
|
||||
[Inject]
|
||||
public IAuthenticationService AuthenticationService { get; set; }
|
||||
|
||||
[HttpGet("auth/login")]
|
||||
public async Task<ActionResult> LoginFromSchemeAsync([FromQuery(Name = "s")] string scheme)
|
||||
[AllowAnonymous]
|
||||
public async Task<ActionResult> LoginFromSchemeAsync([FromQuery(Name = "s")] string? scheme)
|
||||
{
|
||||
return BadRequest();
|
||||
var authResult = await HttpContext.AuthenticateAsync();
|
||||
return Ok();
|
||||
}
|
||||
|
||||
[HttpGet("auth/logout")]
|
||||
|
|
Loading…
Reference in New Issue
Block a user