mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-05-15 22:22:27 +00:00
Refactor deserialization and authentication (#550)
* Refactor deserialization and more * Refactor authentication flow * Fix unit tests * Make deserialization better
This commit is contained in:
parent
505b5eb03b
commit
b3a00da554
48 changed files with 575 additions and 589 deletions
|
@ -1,28 +1,14 @@
|
|||
using LBPUnion.ProjectLighthouse.PlayerData;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers;
|
||||
|
||||
[ApiController]
|
||||
[Authorize]
|
||||
[Route("LITTLEBIGPLANETPS3_XML/")]
|
||||
[Produces("text/xml")]
|
||||
public class DeveloperController : Controller
|
||||
{
|
||||
|
||||
private readonly Database database;
|
||||
|
||||
public DeveloperController(Database database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
||||
[HttpGet("developer_videos")]
|
||||
public async Task<IActionResult> DeveloperVideos()
|
||||
{
|
||||
GameToken? token = await this.database.GameTokenFromRequest(this.Request);
|
||||
|
||||
if (token == null) return this.StatusCode(403, "");
|
||||
|
||||
return this.Ok("<videos></videos>");
|
||||
}
|
||||
public IActionResult DeveloperVideos() => this.Ok("<videos></videos>");
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue