diff options
author | RaindropsSys <raindrops@equestria.dev> | 2023-11-08 20:59:42 +0100 |
---|---|---|
committer | RaindropsSys <raindrops@equestria.dev> | 2023-11-08 20:59:42 +0100 |
commit | b83a38434156038bc02db74cb93fa8460d0f2f32 (patch) | |
tree | 5229c62153ad640f164ff3d4a837bd8345305e02 /oauth/callback-native | |
parent | 4755889793a36a1f33282ee4759445bef1eb2bb2 (diff) | |
download | mist-b83a38434156038bc02db74cb93fa8460d0f2f32.tar.gz mist-b83a38434156038bc02db74cb93fa8460d0f2f32.tar.bz2 mist-b83a38434156038bc02db74cb93fa8460d0f2f32.zip |
Updated 16 files, added 3 files, deleted android/app/release/app-release.apk.zip and renamed android/app/release/app-release.apk (automated)
Diffstat (limited to 'oauth/callback-native')
-rw-r--r-- | oauth/callback-native/index.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/oauth/callback-native/index.php b/oauth/callback-native/index.php index c289957..5095734 100644 --- a/oauth/callback-native/index.php +++ b/oauth/callback-native/index.php @@ -38,7 +38,9 @@ if (isset($result["access_token"])) { $result = $result_orig = curl_exec($crl); $result = json_decode($result, true); - if (!in_array($result["id"], $app["allowed"])) { + $isAllowed = in_array("5fe2cdf1-cff8-470e-a54a-ad1c713b0387", array_map(function ($i) { return $i["id"]; }, $result["transitiveGroups"])); + + if (!$isAllowed) { header("HTTP/1.1 403 Forbidden"); die("Not allowed to log in to this application. This will be reported."); } |