mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2023-10-10 13:36:59 +02:00
Fix: prevent downgrade of authorization
This commit is contained in:
parent
f764202561
commit
826f94d507
@ -71,11 +71,12 @@ void JsonAPI::initialize(void)
|
||||
_authorized = !_authManager->isLocalAuthRequired();
|
||||
|
||||
// admin access is allowed, when the connection is local and the option for local admin isn't set. Con: All local connections get full access
|
||||
// authorization is also granted for api based on admin result. Pro: Admin should have full access.
|
||||
if(_localConnection)
|
||||
{
|
||||
_userAuthorized = !_authManager->isLocalAdminAuthRequired();
|
||||
_authorized = _userAuthorized;
|
||||
// just in positive direction
|
||||
if(_userAuthorized)
|
||||
_authorized = true;
|
||||
}
|
||||
|
||||
// setup auth interface
|
||||
|
Loading…
x
Reference in New Issue
Block a user