refactor(PlaceholderAuthController): Update auf Login nur über Body und ohne Cookie
This commit is contained in:
parent
753eb18b71
commit
c3f5d90b6a
@ -1,44 +1,24 @@
|
|||||||
using Microsoft.AspNetCore.Authentication.Cookies;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using Microsoft.AspNetCore.Authentication;
|
|
||||||
using System.Security.Claims;
|
|
||||||
using Microsoft.AspNetCore.Mvc;
|
|
||||||
using DigitalData.UserManager.Application.Contracts;
|
|
||||||
using DigitalData.UserManager.Application.DTOs.User;
|
|
||||||
using Microsoft.AspNetCore.Authorization;
|
using Microsoft.AspNetCore.Authorization;
|
||||||
using DigitalData.UserManager.Application;
|
|
||||||
using DigitalData.Core.Abstractions.Application;
|
|
||||||
using WorkFlow.API.Models;
|
using WorkFlow.API.Models;
|
||||||
using WorkFlow.API.Attributes;
|
using WorkFlow.API.Attributes;
|
||||||
|
|
||||||
namespace WorkFlow.API.Controllers
|
namespace WorkFlow.API.Controllers;
|
||||||
|
|
||||||
|
//TODO: implement up-to-date AuthController in UserManager
|
||||||
|
[APIKeyAuth]
|
||||||
|
[Route("Auth")]
|
||||||
|
[ApiController]
|
||||||
|
[Tags("Auth")]
|
||||||
|
public class PlaceholderAuthController : ControllerBase
|
||||||
{
|
{
|
||||||
//TODO: implement up-to-date AuthController in UserManager
|
|
||||||
[APIKeyAuth]
|
|
||||||
[Route("Auth")]
|
|
||||||
[ApiController]
|
|
||||||
public class PlaceholderAuthController : ControllerBase
|
|
||||||
{
|
|
||||||
[HttpPost("login")]
|
|
||||||
[AllowAnonymous]
|
|
||||||
public IActionResult Login([FromForm] Login login)
|
|
||||||
{
|
|
||||||
throw new NotImplementedException();
|
|
||||||
}
|
|
||||||
|
|
||||||
[HttpPost("logout")]
|
|
||||||
public IActionResult Logout()
|
|
||||||
{
|
|
||||||
throw new NotImplementedException();
|
|
||||||
}
|
|
||||||
|
|
||||||
[HttpPost]
|
[HttpPost]
|
||||||
public IActionResult CreateTokenViaBody([FromBody] Login login, [FromQuery] bool cookie = false)
|
public IActionResult CreateTokenViaBody([FromBody] Login login)
|
||||||
{
|
{
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
}
|
}
|
||||||
|
|
||||||
[HttpGet("check")]
|
[HttpGet("check")]
|
||||||
[Authorize]
|
[Authorize]
|
||||||
public IActionResult Check() => Ok();
|
public IActionResult Check() => throw new NotImplementedException();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user