2022-10-13 19:44:16 +02:00
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include <ESPAsyncWebServer.h>
|
2024-01-20 02:00:22 +01:00
|
|
|
#include <TaskSchedulerDeclarations.h>
|
2022-10-13 19:44:16 +02:00
|
|
|
|
|
|
|
|
class WebApiSecurityClass {
|
|
|
|
|
public:
|
2024-01-20 02:00:22 +01:00
|
|
|
void init(AsyncWebServer& server, Scheduler& scheduler);
|
2022-10-13 19:44:16 +02:00
|
|
|
|
|
|
|
|
private:
|
2022-11-22 23:32:52 +01:00
|
|
|
void onSecurityGet(AsyncWebServerRequest* request);
|
|
|
|
|
void onSecurityPost(AsyncWebServerRequest* request);
|
2022-10-13 19:44:16 +02:00
|
|
|
|
2022-11-03 21:00:13 +01:00
|
|
|
void onAuthenticateGet(AsyncWebServerRequest* request);
|
2024-01-20 02:00:22 +01:00
|
|
|
};
|