Skip to content

Commit

Permalink
Fix default value configuration for public dashboard authentication
Browse files Browse the repository at this point in the history
(cherry picked from commit 83782dc)
  • Loading branch information
rootpd committed Jan 29, 2025
1 parent 91328e2 commit b27eed5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Beam/config/dashboard.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php

return [
'username' => env('DASHBOARD_USERNAME', ''),
'password' => env('DASHBOARD_PASSWORD', ''),
'username' => env('DASHBOARD_USERNAME'),
'password' => env('DASHBOARD_PASSWORD'),
// TODO temporarily support 2 passwords, remove later after authentication is done
'username2' => env('DASHBOARD_USERNAME2', ''),
'password2' => env('DASHBOARD_PASSWORD2', ''),
'username2' => env('DASHBOARD_USERNAME2'),
'password2' => env('DASHBOARD_PASSWORD2'),
];
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ public function handle($request, Closure $next)
config('dashboard.username') => config('dashboard.password'),
config('dashboard.username2') => config('dashboard.password2'),
];
unset($credentials[null]);
unset($credentials['']);

if (array_key_exists($request->getUser(), $credentials)
&& $credentials[$request->getUser()] === $request->getPassword()) {
Expand Down
3 changes: 3 additions & 0 deletions changelogs/CHANGELOG-v3.10.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
## [3.10] - 2024-10-25

- [3.10.1][Beam]: Fixed default value configuration for public dashboard authentication.


### [Beam]

- [Tracker] Fixed Tracker not publishing messages to pub/sub due to prematurely closed client. remp/remp#1384
Expand Down

0 comments on commit b27eed5

Please sign in to comment.