]>
BookStack Code Mirror - bookstack/commitdiff
projects
/
bookstack
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
050d69e
)
Added reason, if existing, into SAML acs error
author
Dan Brown
<redacted>
Tue, 20 Sep 2022 11:52:44 +0000
(12:52 +0100)
committer
Dan Brown
<redacted>
Tue, 20 Sep 2022 11:52:44 +0000
(12:52 +0100)
Closes #3731
app/Auth/Access/Saml2Service.php
patch
|
blob
|
history
diff --git
a/app/Auth/Access/Saml2Service.php
b/app/Auth/Access/Saml2Service.php
index f5d0cd7ccf57ee61fd863c8a85f5f9144d71db75..b0bf39995e63f0b050aabf67d4cd8af05abadebc 100644
(file)
--- a/
app/Auth/Access/Saml2Service.php
+++ b/
app/Auth/Access/Saml2Service.php
@@
-109,9
+109,10
@@
class Saml2Service
$errors = $toolkit->getErrors();
if (!empty($errors)) {
- throw new Error(
- 'Invalid ACS Response: ' . implode(', ', $errors)
- );
+ $reason = $toolkit->getLastErrorReason();
+ $message = 'Invalid ACS Response; Errors: ' . implode(', ', $errors);
+ $message .= $reason ? "; Reason: {$reason}" : '';
+ throw new Error($message);
}
if (!$toolkit->isAuthenticated()) {