summaryrefslogtreecommitdiff
path: root/libraries/ESP_Async_WebServer/src/WebAuthentication.h
diff options
context:
space:
mode:
authorschererleander <leander@schererleander.de>2026-01-20 08:34:54 +0100
committerschererleander <leander@schererleander.de>2026-01-20 08:34:54 +0100
commit85ea4e995a75abe061f6fc375ea0481084dddd43 (patch)
tree7eb5d57653ecd8f041aeac4e68d7d554c1168681 /libraries/ESP_Async_WebServer/src/WebAuthentication.h
initial commitHEADmain
Diffstat (limited to 'libraries/ESP_Async_WebServer/src/WebAuthentication.h')
-rw-r--r--libraries/ESP_Async_WebServer/src/WebAuthentication.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/libraries/ESP_Async_WebServer/src/WebAuthentication.h b/libraries/ESP_Async_WebServer/src/WebAuthentication.h
new file mode 100644
index 0000000..1711821
--- /dev/null
+++ b/libraries/ESP_Async_WebServer/src/WebAuthentication.h
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: LGPL-3.0-or-later
+// Copyright 2016-2025 Hristo Gochkov, Mathieu Carbou, Emil Muratov
+
+#ifndef WEB_AUTHENTICATION_H_
+#define WEB_AUTHENTICATION_H_
+
+#include "Arduino.h"
+
+bool checkBasicAuthentication(const char *header, const char *username, const char *password);
+
+bool checkDigestAuthentication(
+ const char *header, const char *method, const char *username, const char *password, const char *realm, bool passwordIsHash, const char *nonce,
+ const char *opaque, const char *uri
+);
+
+// for storing hashed versions on the device that can be authenticated against
+String generateDigestHash(const char *username, const char *password, const char *realm);
+
+String generateBasicHash(const char *username, const char *password);
+
+String genRandomMD5();
+
+#endif