mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-22 18:57:12 +02:00
0.8.78
* try to finalize API token protection
This commit is contained in:
parent
15349520d2
commit
8b2db4abfa
6 changed files with 39 additions and 49 deletions
|
@ -227,7 +227,7 @@ class Web {
|
|||
}
|
||||
|
||||
void checkProtection(AsyncWebServerRequest *request) {
|
||||
if(mApp->isProtected(request->client()->remoteIP().toString().c_str())) {
|
||||
if(mApp->isProtected(request->client()->remoteIP().toString().c_str(), true)) {
|
||||
checkRedirect(request);
|
||||
return;
|
||||
}
|
||||
|
@ -314,7 +314,7 @@ class Web {
|
|||
|
||||
if (request->args() > 0) {
|
||||
if (String(request->arg("pwd")) == String(mConfig->sys.adminPwd)) {
|
||||
mApp->unlock(request->client()->remoteIP().toString().c_str());
|
||||
mApp->unlock(request->client()->remoteIP().toString().c_str(), true);
|
||||
request->redirect("/");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue