mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-23 19:27:13 +02:00
parent
6533143e80
commit
c7060e40ff
3 changed files with 11 additions and 6 deletions
|
@ -130,11 +130,13 @@ class Web {
|
|||
bool prot;
|
||||
prot = mProtected;
|
||||
if(!prot) {
|
||||
uint8_t ip[4];
|
||||
ah::ip2Arr(ip, request->client()->remoteIP().toString().c_str());
|
||||
for(uint8_t i = 0; i < 4; i++) {
|
||||
if(mLoginIp[i] != ip[i])
|
||||
prot = true;
|
||||
if(strlen(mConfig->sys.adminPwd) > 0) {
|
||||
uint8_t ip[4];
|
||||
ah::ip2Arr(ip, request->client()->remoteIP().toString().c_str());
|
||||
for(uint8_t i = 0; i < 4; i++) {
|
||||
if(mLoginIp[i] != ip[i])
|
||||
prot = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue