@@ -170,7 +170,7 @@ |
||
170 | 170 | |
171 | 171 | if ($response === false) { |
172 | 172 | $errorCode = $radius->getErrorCode(); |
173 | - switch($errorCode) { |
|
173 | + switch ($errorCode) { |
|
174 | 174 | case $radius::TYPE_ACCESS_REJECT: |
175 | 175 | throw new \SimpleSAML\Error\Error('WRONGUSERPASS'); |
176 | 176 | case $radius::TYPE_ACCESS_CHALLENGE: |
@@ -197,15 +197,15 @@ |
||
197 | 197 | * therefore done now. |
198 | 198 | */ |
199 | 199 | return $attributes; |
200 | - } else { |
|
201 | - foreach ($radius->getReceivedAttributes() as $content) { |
|
202 | - if ($content[0] == 26) { // is a Vendor-Specific attribute |
|
203 | - $vsa = $radius->decodeVendorSpecificContent($content[1]); |
|
204 | - if ($vsa[0][0] === $this->vendor && $vsa[0][1] === $this->vendorType) { // matches configured Vendor and Type |
|
205 | - $decomposed = explode("=", $vsa[0][2], 2); // SAML attributes expected in a URN=value, so split at first = |
|
206 | - $attributes[$decomposed[0]][] = $decomposed[1]; |
|
207 | - } |
|
208 | - } |
|
200 | + } else { |
|
201 | + foreach ($radius->getReceivedAttributes() as $content) { |
|
202 | + if ($content[0] == 26) { // is a Vendor-Specific attribute |
|
203 | + $vsa = $radius->decodeVendorSpecificContent($content[1]); |
|
204 | + if ($vsa[0][0] === $this->vendor && $vsa[0][1] === $this->vendorType) { // matches configured Vendor and Type |
|
205 | + $decomposed = explode("=", $vsa[0][2], 2); // SAML attributes expected in a URN=value, so split at first = |
|
206 | + $attributes[$decomposed[0]][] = $decomposed[1]; |
|
207 | + } |
|
208 | + } |
|
209 | 209 | } |
210 | 210 | } |
211 | 211 | } |