Passed
Branch master (9cc8ee)
by Tim
02:36
created
lib/IdP/ADFS.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
             $metadata = MetaDataStorageHandler::getMetadataHandler();
33 33
             $spMetadata = $metadata->getMetaDataConfig($issuer, 'adfs-sp-remote');
34 34
 
35
-            Logger::info('ADFS - IdP.prp: Incoming Authentication request: ' . $issuer . ' id ' . $requestid);
35
+            Logger::info('ADFS - IdP.prp: Incoming Authentication request: '.$issuer.' id '.$requestid);
36 36
         } catch (\Exception $exception) {
37 37
             throw new Error\Error('PROCESSAUTHNREQUEST', $exception);
38 38
         }
@@ -347,7 +347,7 @@  discard block
 block discarded – undo
347 347
         $spEntityId = $spMetadata['entityid'];
348 348
         $spMetadata = Configuration::loadFromArray(
349 349
             $spMetadata,
350
-            '$metadata[' . var_export($spEntityId, true) . ']'
350
+            '$metadata['.var_export($spEntityId, true).']'
351 351
         );
352 352
 
353 353
         $attributes = $state['Attributes'];
@@ -367,7 +367,7 @@  discard block
 block discarded – undo
367 367
         $idpEntityId = $idpMetadata->getString('entityid');
368 368
 
369 369
         $idp->addAssociation([
370
-            'id' => 'adfs:' . $spEntityId,
370
+            'id' => 'adfs:'.$spEntityId,
371 371
             'Handler' => ADFS::class,
372 372
             'adfs:entityID' => $spEntityId,
373 373
         ]);
@@ -390,7 +390,7 @@  discard block
 block discarded – undo
390 390
         $wresult = ADFS::signResponse($response, $privateKeyFile, $certificateFile, $algo, $passphrase);
391 391
 
392 392
         $wctx = $state['adfs:wctx'];
393
-        $wreply = $state['adfs:wreply'] ? : $spMetadata->getValue('prp');
393
+        $wreply = $state['adfs:wreply'] ?: $spMetadata->getValue('prp');
394 394
         ADFS::postResponse($wreply, $wresult, $wctx);
395 395
     }
396 396
 
@@ -448,8 +448,8 @@  discard block
 block discarded – undo
448 448
         $metadata = MetaDataStorageHandler::getMetadataHandler();
449 449
         $spMetadata = $metadata->getMetaDataConfig($association['adfs:entityID'], 'adfs-sp-remote');
450 450
         $returnTo = Module::getModuleURL(
451
-            'adfs/idp/prp.php?assocId=' . urlencode($association["id"]) . '&relayState=' . urlencode($relayState)
451
+            'adfs/idp/prp.php?assocId='.urlencode($association["id"]).'&relayState='.urlencode($relayState)
452 452
         );
453
-        return $spMetadata->getValue('prp') . '?wa=wsignoutcleanup1.0&wreply=' . urlencode($returnTo);
453
+        return $spMetadata->getValue('prp').'?wa=wsignoutcleanup1.0&wreply='.urlencode($returnTo);
454 454
     }
455 455
 }
Please login to merge, or discard this patch.
lib/Controller/AdfsController.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
                 ];
117 117
             }
118 118
 
119
-            $adfs_service_location = Module::getModuleURL('adfs') . '/idp/prp.php';
119
+            $adfs_service_location = Module::getModuleURL('adfs').'/idp/prp.php';
120 120
             $metaArray = [
121 121
                 'metadata-set'        => 'adfs-idp-remote',
122 122
                 'entityid'            => $idpentityid,
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
                 $metaArray['RegistrationInfo'] = $idpmeta->getArray('RegistrationInfo');
179 179
             }
180 180
 
181
-            $metaflat = '$metadata[' . var_export($idpentityid, true) . '] = ' . var_export($metaArray, true) . ';';
181
+            $metaflat = '$metadata['.var_export($idpentityid, true).'] = '.var_export($metaArray, true).';';
182 182
 
183 183
             $metaBuilder = new Metadata\SAMLBuilder($idpentityid);
184 184
             $metaBuilder->addSecurityTokenServiceType($metaArray);
@@ -208,8 +208,8 @@  discard block
 block discarded – undo
208 208
                 $certdata = [];
209 209
                 foreach (array_keys($availableCerts) as $availableCert) {
210 210
                     $certdata[$availableCert]['name'] = $availableCert;
211
-                    $certdata[$availableCert]['url'] = Module::getModuleURL('saml/idp/certs.php') .
212
-                        '/' . $availableCert;
211
+                    $certdata[$availableCert]['url'] = Module::getModuleURL('saml/idp/certs.php').
212
+                        '/'.$availableCert;
213 213
 
214 214
                     $certdata[$availableCert]['comment'] = '';
215 215
                 }
@@ -250,18 +250,18 @@  discard block
 block discarded – undo
250 250
         Logger::info('ADFS - IdP.prp: Accessing ADFS IdP endpoint prp');
251 251
 
252 252
         $idpEntityId = $this->metadata->getMetaDataCurrentEntityID('adfs-idp-hosted');
253
-        $idp = IdP::getById('adfs:' . $idpEntityId);
253
+        $idp = IdP::getById('adfs:'.$idpEntityId);
254 254
 
255 255
         if (isset($_GET['wa'])) {
256 256
             if ($_GET['wa'] === 'wsignout1.0') {
257 257
                 return new StreamedResponse(
258
-                    function () use ($idp) {
258
+                    function() use ($idp) {
259 259
                         ADFS::receiveLogoutMessage($idp);
260 260
                     }
261 261
                 );
262 262
             } elseif ($_GET['wa'] === 'wsignin1.0') {
263 263
                 return new StreamedResponse(
264
-                    function () use ($idp) {
264
+                    function() use ($idp) {
265 265
                         ADFS::receiveAuthnRequest($idp);
266 266
                     }
267 267
                 );
@@ -274,7 +274,7 @@  discard block
 block discarded – undo
274 274
             $logoutError = null; // null on success, or an instance of a \SimpleSAML\Error\Exception on failure.
275 275
 
276 276
             return new StreamedResponse(
277
-                function () use ($idp, $assocId, $relayState, $logoutError) {
277
+                function() use ($idp, $assocId, $relayState, $logoutError) {
278 278
                     $idp->handleLogoutResponse($assocId, $relayState, $logoutError);
279 279
                 }
280 280
             );
Please login to merge, or discard this patch.