Add HTTP basic authentication (#996)

* add http basic auth

* add feature check for basic auth process

* fix http basic auth build for unsupported platforms (W800, W600)

* fix includes in http_basic_auth

* fix basic auth invocations when unavailable

* add http basic auth allow checks to http_fns

* remove unnecessary checks

* add my_strnicmp export

* silence warning

* update web password config ui

* update submodules

* add base64 lib to boufallo.mk for BL602

* add safe mode http basic auth bypass flag

* fix bl602 build with http auth bypass flag

* disable shared led driver

---------

Co-authored-by: Tester23 <openshwprojects@gmail.com>
This commit is contained in:
Lubomir Kaplan
2023-12-13 15:19:11 +01:00
committed by GitHub
parent 8b7594e3de
commit 95c30dd800
18 changed files with 320 additions and 23 deletions

View File

@ -105,9 +105,9 @@ static int http_rest_post_cmd(http_request_t* request);
void init_rest() {
HTTP_RegisterCallback("/api/", HTTP_GET, http_rest_get);
HTTP_RegisterCallback("/api/", HTTP_POST, http_rest_post);
HTTP_RegisterCallback("/app", HTTP_GET, http_rest_app);
HTTP_RegisterCallback("/api/", HTTP_GET, http_rest_get, 1);
HTTP_RegisterCallback("/api/", HTTP_POST, http_rest_post, 1);
HTTP_RegisterCallback("/app", HTTP_GET, http_rest_app, 1);
}
/* Extracts string token value into outBuffer (128 char). Returns true if the operation was successful. */