Replaced env() with config() to check environment variables
Made the app.php description for 'REQUIRE_SAML' a bit more... descriptive.
This commit is contained in:
parent
a6116a1b15
commit
6898119891
2 changed files with 7 additions and 5 deletions
|
@ -76,7 +76,7 @@ class LoginController extends Controller
|
|||
|
||||
//If the environment is set to ALWAYS require SAML, go straight to the SAML route.
|
||||
//We don't need to check other settings, as this should override those.
|
||||
if((env("REQUIRE_SAML", false)))
|
||||
if(config('REQUIRE_SAML'))
|
||||
{
|
||||
return redirect()->route('saml.login');
|
||||
}
|
||||
|
@ -209,7 +209,7 @@ class LoginController extends Controller
|
|||
public function login(Request $request)
|
||||
{
|
||||
//If the environment is set to ALWAYS require SAML, return access denied
|
||||
if((env("REQUIRE_SAML", false)))
|
||||
if(config('REQUIRE_SAML'))
|
||||
{
|
||||
return view('errors.403');
|
||||
}
|
||||
|
|
|
@ -255,9 +255,11 @@ return [
|
|||
| Require SAML Login
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Disable the ability to login via form login, and require all logins to
|
||||
| process via SAML login. (If you are not using SAML, this option should
|
||||
| be left alone.)
|
||||
| Disable the ability to login via form login, and disables the 'nosaml'
|
||||
| workaround. It requires all logins to process via SAML login.
|
||||
| (This is for high security setups. If your SAML configuration is not
|
||||
| working, this option should be set to false. This option is not needed
|
||||
| to successfully configure SAML authentication.)
|
||||
|
|
||||
*/
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue