mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-12 18:59:51 +03:00
merge #2108
This commit is contained in:
22
src/ESP32React/AuthenticationService.h
Normal file
22
src/ESP32React/AuthenticationService.h
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef AuthenticationService_H_
|
||||
#define AuthenticationService_H_
|
||||
|
||||
#include "SecurityManager.h"
|
||||
|
||||
#include <ESPAsyncWebServer.h>
|
||||
|
||||
#define VERIFY_AUTHORIZATION_PATH "/rest/verifyAuthorization"
|
||||
#define SIGN_IN_PATH "/rest/signIn"
|
||||
|
||||
class AuthenticationService {
|
||||
public:
|
||||
AuthenticationService(AsyncWebServer * server, SecurityManager * securityManager);
|
||||
|
||||
private:
|
||||
SecurityManager * _securityManager;
|
||||
|
||||
void signIn(AsyncWebServerRequest * request, JsonVariant json);
|
||||
void verifyAuthorization(AsyncWebServerRequest * request);
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user