@@ -187,8 +187,8 @@ |
||
| 187 | 187 | $ret = []; |
| 188 | 188 | foreach ($this->certificates as $cert) { |
| 189 | 189 | /* Construct a PEM formatted certificate */ |
| 190 | - $pemCert = "-----BEGIN CERTIFICATE-----\n". |
|
| 191 | - chunk_split($cert, 64). |
|
| 190 | + $pemCert = "-----BEGIN CERTIFICATE-----\n" . |
|
| 191 | + chunk_split($cert, 64) . |
|
| 192 | 192 | "-----END CERTIFICATE-----\n"; |
| 193 | 193 | |
| 194 | 194 | /* Extract the public key from the certificate for validation. */ |
@@ -98,7 +98,7 @@ |
||
| 98 | 98 | { |
| 99 | 99 | if ($this->count() !== 1) { |
| 100 | 100 | throw new RuntimeException(sprintf( |
| 101 | - __CLASS__.'::'.__METHOD__.' requires that the collection has exactly one element, ' |
|
| 101 | + __CLASS__ . '::' . __METHOD__ . ' requires that the collection has exactly one element, ' |
|
| 102 | 102 | . '"%d" elements found', |
| 103 | 103 | $this->count() |
| 104 | 104 | )); |
@@ -290,7 +290,7 @@ |
||
| 290 | 290 | if ($this->encryptedNameId === null) { |
| 291 | 291 | $this->nameId->toXML($root); |
| 292 | 292 | } else { |
| 293 | - $eid = $root->ownerDocument->createElementNS(Constants::NS_SAML, 'saml:'.'EncryptedID'); |
|
| 293 | + $eid = $root->ownerDocument->createElementNS(Constants::NS_SAML, 'saml:' . 'EncryptedID'); |
|
| 294 | 294 | $root->appendChild($eid); |
| 295 | 295 | $eid->appendChild($root->ownerDocument->importNode($this->encryptedNameId, true)); |
| 296 | 296 | } |
@@ -36,8 +36,8 @@ |
||
| 36 | 36 | return sprintf( |
| 37 | 37 | '%s%s%s', |
| 38 | 38 | $this->truncateStatus($responseStatus['Code']), |
| 39 | - $responseStatus['SubCode'] ? '/'.$this->truncateStatus($responseStatus['SubCode']) : '', |
|
| 40 | - $responseStatus['Message'] ? ' '.$responseStatus['Message'] : '' |
|
| 39 | + $responseStatus['SubCode'] ? '/' . $this->truncateStatus($responseStatus['SubCode']) : '', |
|
| 40 | + $responseStatus['Message'] ? ' ' . $responseStatus['Message'] : '' |
|
| 41 | 41 | ); |
| 42 | 42 | } |
| 43 | 43 | |
@@ -64,7 +64,7 @@ |
||
| 64 | 64 | $this->GeolocationHint = Utils::extractStrings($xml, Common::NS, 'GeolocationHint'); |
| 65 | 65 | |
| 66 | 66 | /** @var \DOMElement $node */ |
| 67 | - foreach (Utils::xpQuery($xml, "./*[namespace-uri()!='".Common::NS."']") as $node) { |
|
| 67 | + foreach (Utils::xpQuery($xml, "./*[namespace-uri()!='" . Common::NS . "']") as $node) { |
|
| 68 | 68 | $this->children[] = new Chunk($node); |
| 69 | 69 | } |
| 70 | 70 | } |
@@ -135,7 +135,7 @@ |
||
| 135 | 135 | if (strpos($keyword, "+") !== false) { |
| 136 | 136 | throw new \Exception('Keywords may not contain a "+" character.'); |
| 137 | 137 | } |
| 138 | - $value .= str_replace(' ', '+', $keyword).' '; |
|
| 138 | + $value .= str_replace(' ', '+', $keyword) . ' '; |
|
| 139 | 139 | } |
| 140 | 140 | $value = rtrim($value); |
| 141 | 141 | $e->appendChild($doc->createTextNode($value)); |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | } |
| 46 | 46 | |
| 47 | 47 | if (!$xml->hasAttribute('index')) { |
| 48 | - throw new \Exception('Missing index on '.$xml->tagName); |
|
| 48 | + throw new \Exception('Missing index on ' . $xml->tagName); |
|
| 49 | 49 | } |
| 50 | 50 | $this->index = intval($xml->getAttribute('index')); |
| 51 | 51 | |
@@ -120,7 +120,7 @@ discard block |
||
| 120 | 120 | */ |
| 121 | 121 | private static function getStringElements(\DOMElement $parent, string $name) : array |
| 122 | 122 | { |
| 123 | - $e = Utils::xpQuery($parent, './saml_metadata:'.$name); |
|
| 123 | + $e = Utils::xpQuery($parent, './saml_metadata:' . $name); |
|
| 124 | 124 | |
| 125 | 125 | $ret = []; |
| 126 | 126 | foreach ($e as $i) { |
@@ -146,7 +146,7 @@ discard block |
||
| 146 | 146 | return null; |
| 147 | 147 | } |
| 148 | 148 | if (count($e) > 1) { |
| 149 | - throw new \Exception('More than one '.$name.' in '.$parent->tagName); |
|
| 149 | + throw new \Exception('More than one ' . $name . ' in ' . $parent->tagName); |
|
| 150 | 150 | } |
| 151 | 151 | |
| 152 | 152 | return $e[0]; |
@@ -108,7 +108,7 @@ |
||
| 108 | 108 | } |
| 109 | 109 | |
| 110 | 110 | if (!$xml->hasAttribute('protocolSupportEnumeration')) { |
| 111 | - throw new \Exception('Missing protocolSupportEnumeration attribute on '.$xml->localName); |
|
| 111 | + throw new \Exception('Missing protocolSupportEnumeration attribute on ' . $xml->localName); |
|
| 112 | 112 | } |
| 113 | 113 | $this->protocolSupportEnumeration = preg_split('/[\s]+/', $xml->getAttribute('protocolSupportEnumeration')); |
| 114 | 114 | |