@@ -197,7 +197,6 @@ |
||
197 | 197 | * - RETVAL_NOTCONFIGURED; needs \config\Diagnostics::RADIUSTESTS['TLS-discoverytag'] |
198 | 198 | * - RETVAL_INVALID (at least one format error) |
199 | 199 | * - RETVAL_OK (all fine) |
200 | - |
|
201 | 200 | * @return int one of two RETVALs above |
202 | 201 | */ |
203 | 202 | public function relevantNAPTRcompliance() |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | case "core\User": |
140 | 140 | return $this->userName; |
141 | 141 | default: |
142 | - throw new Exception("Operating on a class where we don't know the relevant identifier in the DB - " . get_class($this) . "!"); |
|
142 | + throw new Exception("Operating on a class where we don't know the relevant identifier in the DB - ".get_class($this)."!"); |
|
143 | 143 | } |
144 | 144 | } |
145 | 145 | |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | */ |
178 | 178 | public function beginFlushAttributes($extracondition = "") |
179 | 179 | { |
180 | - $quotedIdentifier = (!is_int($this->getRelevantIdentifier()) ? "\"" : "") . $this->getRelevantIdentifier() . (!is_int($this->getRelevantIdentifier()) ? "\"" : ""); |
|
180 | + $quotedIdentifier = (!is_int($this->getRelevantIdentifier()) ? "\"" : "").$this->getRelevantIdentifier().(!is_int($this->getRelevantIdentifier()) ? "\"" : ""); |
|
181 | 181 | $this->databaseHandle->exec("DELETE FROM $this->entityOptionTable WHERE $this->entityIdColumn = $quotedIdentifier AND option_name NOT LIKE '%_file' $extracondition"); |
182 | 182 | $this->updateFreshness(); |
183 | 183 | $execFlush = $this->databaseHandle->exec("SELECT row FROM $this->entityOptionTable WHERE $this->entityIdColumn = $quotedIdentifier $extracondition"); |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | */ |
198 | 198 | public function commitFlushAttributes(array $tobedeleted) |
199 | 199 | { |
200 | - $quotedIdentifier = (!is_int($this->getRelevantIdentifier()) ? "\"" : "") . $this->getRelevantIdentifier() . (!is_int($this->getRelevantIdentifier()) ? "\"" : ""); |
|
200 | + $quotedIdentifier = (!is_int($this->getRelevantIdentifier()) ? "\"" : "").$this->getRelevantIdentifier().(!is_int($this->getRelevantIdentifier()) ? "\"" : ""); |
|
201 | 201 | foreach (array_keys($tobedeleted) as $row) { |
202 | 202 | $this->databaseHandle->exec("DELETE FROM $this->entityOptionTable WHERE $this->entityIdColumn = $quotedIdentifier AND row = $row"); |
203 | 203 | $this->updateFreshness(); |
@@ -226,7 +226,7 @@ discard block |
||
226 | 226 | { |
227 | 227 | $relevantId = $this->getRelevantIdentifier(); |
228 | 228 | $identifierType = (is_int($relevantId) ? "i" : "s"); |
229 | - $this->databaseHandle->exec("INSERT INTO $this->entityOptionTable ($this->entityIdColumn, option_name, option_lang, option_value) VALUES(?,?,?,?)", $identifierType . "sss", $relevantId, $attrName, $attrLang, $attrValue); |
|
229 | + $this->databaseHandle->exec("INSERT INTO $this->entityOptionTable ($this->entityIdColumn, option_name, option_lang, option_value) VALUES(?,?,?,?)", $identifierType."sss", $relevantId, $attrName, $attrLang, $attrValue); |
|
230 | 230 | $this->updateFreshness(); |
231 | 231 | } |
232 | 232 |
@@ -109,7 +109,6 @@ |
||
109 | 109 | * ["my.server.name"] => "my.server.name" |
110 | 110 | * ["foo.bar.de", "baz.bar.ge"] => "e" |
111 | 111 | * ["server1.example.com", "server2.example.com", "serverN.example.com"] => ".example.com" |
112 | - |
|
113 | 112 | * @return string |
114 | 113 | */ |
115 | 114 | public function longestNameSuffix() |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | protected function setSupportedEapMethods($eapArray) |
87 | 87 | { |
88 | 88 | $this->supportedEapMethods = $eapArray; |
89 | - $this->loggerInstance->debug(4, "This device (" . __CLASS__ . ") supports the following EAP methods: "); |
|
89 | + $this->loggerInstance->debug(4, "This device (".__CLASS__.") supports the following EAP methods: "); |
|
90 | 90 | $this->loggerInstance->debug(4, $this->supportedEapMethods); |
91 | 91 | } |
92 | 92 | |
@@ -460,7 +460,7 @@ discard block |
||
460 | 460 | return $baseName.$inst.'-'.$prof; |
461 | 461 | } |
462 | 462 | } |
463 | - return $baseName . $inst; |
|
463 | + return $baseName.$inst; |
|
464 | 464 | } |
465 | 465 | |
466 | 466 | /** |
@@ -590,7 +590,7 @@ discard block |
||
590 | 590 | // only add network blocks if their respective condition is met in this profile |
591 | 591 | if ($netDetails['condition'] === TRUE || (isset($this->attributes[$netDetails['condition']]) && $this->attributes[$netDetails['condition']] === TRUE)) { |
592 | 592 | $networks[$netName] = $netDetails; |
593 | - $this->loggerInstance->debug(5,$netName, "\nAdding network: "); |
|
593 | + $this->loggerInstance->debug(5, $netName, "\nAdding network: "); |
|
594 | 594 | } |
595 | 595 | } |
596 | 596 | // add locally defined SSIDs |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | private function inputValidationError($customtext) |
41 | 41 | { |
42 | 42 | \core\common\Entity::intoThePotatoes(); |
43 | - $retval = "<p>" . _("Input validation error: ") . $customtext . "</p>"; |
|
43 | + $retval = "<p>"._("Input validation error: ").$customtext."</p>"; |
|
44 | 44 | \core\common\Entity::outOfThePotatoes(); |
45 | 45 | return $retval; |
46 | 46 | } |
@@ -541,7 +541,7 @@ discard block |
||
541 | 541 | try { |
542 | 542 | $image->readImageBlob($binary); |
543 | 543 | } catch (\ImagickException $exception) { |
544 | - echo "Error" . $exception->getMessage(); |
|
544 | + echo "Error".$exception->getMessage(); |
|
545 | 545 | return FALSE; |
546 | 546 | } |
547 | 547 | // image survived the sanity check |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | */ |
27 | 27 | ?> |
28 | 28 | <?php |
29 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
29 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
30 | 30 | |
31 | 31 | $auth = new \web\lib\admin\Authentication(); |
32 | 32 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | // also send user back to the overview page |
73 | 73 | if (isset($_POST['requestcert']) && $_POST['requestcert'] == \web\lib\common\FormElements::BUTTON_SAVE) { |
74 | 74 | // basic sanity checks before we hand this over to openssl |
75 | - $sanitisedCsr = $validator->string($_POST['CSR'] ?? "" , TRUE); |
|
75 | + $sanitisedCsr = $validator->string($_POST['CSR'] ?? "", TRUE); |
|
76 | 76 | if (openssl_csr_get_public_key($sanitisedCsr) === FALSE) { |
77 | 77 | throw new Exception("Sorry: Unable to parse the submitted public key - no public key inside?"); |
78 | 78 | } |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | $fed = $validator->existingFederation($_POST['NRO-list']); |
87 | 87 | $country = strtoupper($fed->tld); |
88 | 88 | $DN[] = "C=$country"; |
89 | - $DN[] = "O=NRO of " . $cat->knownFederations[strtoupper($fed->tld)]; |
|
89 | + $DN[] = "O=NRO of ".$cat->knownFederations[strtoupper($fed->tld)]; |
|
90 | 90 | $DN[] = "CN=comes.from.eduroam.db"; |
91 | 91 | $policies[] = "eduroam IdP"; |
92 | 92 | $policies[] = "eduroam SP"; |
@@ -104,11 +104,11 @@ discard block |
||
104 | 104 | default: |
105 | 105 | throw new Exception("Sorry: Unknown level of issuance requested."); |
106 | 106 | } |
107 | - echo "<p>" . _("Requesting a certificate with the following properties"); |
|
107 | + echo "<p>"._("Requesting a certificate with the following properties"); |
|
108 | 108 | echo "<ul>"; |
109 | - echo "<li>" . _("Policy OIDs: ") . implode(", ", $policies) . "</li>"; |
|
110 | - echo "<li>" . _("Distinguished Name: ") . implode(", ", $DN) . "</li>"; |
|
111 | - echo "<li>" . _("Requester Contact Details: will come from eduroam DB (using stub 'Someone, <[email protected]>').") . "</li>"; |
|
109 | + echo "<li>"._("Policy OIDs: ").implode(", ", $policies)."</li>"; |
|
110 | + echo "<li>"._("Distinguished Name: ").implode(", ", $DN)."</li>"; |
|
111 | + echo "<li>"._("Requester Contact Details: will come from eduroam DB (using stub 'Someone, <[email protected]>').")."</li>"; |
|
112 | 112 | echo "</ul></p>"; |
113 | 113 | /* $ossl = proc_open("openssl req -subj '/".implode("/", $DN)."'", [ 0 => ["pipe", "r"], 1 => ["pipe", "w"], 2 => [ "file", "/tmp/voodoo-error", "a"] ], $pipes); |
114 | 114 | if (is_resource($ossl)) { |
@@ -121,13 +121,13 @@ discard block |
||
121 | 121 | throw new Exception("Calling openssl in a fancy way did not work."); |
122 | 122 | } |
123 | 123 | echo "<p>"._("This is the new CSR (return code was $retval)")."<pre>$newCsr</pre></p>"; */ |
124 | - $newCsrWithMeta = ["CSR" => /* $newCsr */ $_POST['CSR'], "USERNAME" => "Someone", "USERMAIL" => "[email protected]", "SUBJECT" => implode(",", $DN) ,"FED" => $country]; |
|
124 | + $newCsrWithMeta = ["CSR" => /* $newCsr */ $_POST['CSR'], "USERNAME" => "Someone", "USERMAIL" => "[email protected]", "SUBJECT" => implode(",", $DN), "FED" => $country]; |
|
125 | 125 | // our certs can be good for max 5 years |
126 | 126 | $fed->requestCertificate($newCsrWithMeta, 1825); |
127 | 127 | echo "<p>"._("The certificate was requested.")."</p>"; |
128 | 128 | ?> |
129 | 129 | <form action="overview_certificates.php" method="GET"> |
130 | - <button type="submit"><?php echo _("Back to Certificate Overview");?></button> |
|
130 | + <button type="submit"><?php echo _("Back to Certificate Overview"); ?></button> |
|
131 | 131 | </form> |
132 | 132 | <?php |
133 | 133 | echo $deco->footer(); |
@@ -136,14 +136,14 @@ discard block |
||
136 | 136 | |
137 | 137 | // if we did not get a SAVE button, display UI for a fresh request instead |
138 | 138 | ?> |
139 | - <h2><?php echo _("1. Certificate Holder Details");?></h2> |
|
139 | + <h2><?php echo _("1. Certificate Holder Details"); ?></h2> |
|
140 | 140 | <form action="action_req_certificate.php" method="POST"> |
141 | 141 | <input type="radio" name="LEVEL" id="NRO" value="NRO" checked><?php printf(_("Certificate for %s role"), $uiElements->nomenclatureFed); ?></input> |
142 | 142 | <?php |
143 | 143 | if (count($feds) == 1) { |
144 | 144 | $fedObject = new \core\Federation($feds[0]['value']); |
145 | - echo " <strong>" . $cat->knownFederations[$fedObject->tld] . "</strong>"; |
|
146 | - echo '<input type="hidden" name="NRO-list" id="NRO-list" value="' . $fedObject->tld . '"/>'; |
|
145 | + echo " <strong>".$cat->knownFederations[$fedObject->tld]."</strong>"; |
|
146 | + echo '<input type="hidden" name="NRO-list" id="NRO-list" value="'.$fedObject->tld.'"/>'; |
|
147 | 147 | } else { |
148 | 148 | ?> |
149 | 149 | <select name="NRO-list" id="NRO-list"> |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | <?php |
152 | 152 | foreach ($feds as $oneFed) { |
153 | 153 | $fedObject = new \core\Federation($oneFed['value']); |
154 | - echo '<option value="' . strtoupper($fedObject->tld) . '">' . $cat->knownFederations[$fedObject->tld] . "</option>"; |
|
154 | + echo '<option value="'.strtoupper($fedObject->tld).'">'.$cat->knownFederations[$fedObject->tld]."</option>"; |
|
155 | 155 | } |
156 | 156 | ?> |
157 | 157 | </select> |
@@ -171,15 +171,15 @@ discard block |
||
171 | 171 | } |
172 | 172 | } |
173 | 173 | foreach ($allIdPs as $id => $name) { |
174 | - echo '<option value="' . $id . '">' . $name . "</option>"; |
|
174 | + echo '<option value="'.$id.'">'.$name."</option>"; |
|
175 | 175 | } |
176 | 176 | ?> |
177 | 177 | </select> |
178 | 178 | <br/> |
179 | - <h2><?php echo _("2. CSR generation");?></h2> |
|
180 | - <p><?php echo _("One way to generate an acceptable certificate request is via this openssl one-liner:");?></p> |
|
179 | + <h2><?php echo _("2. CSR generation"); ?></h2> |
|
180 | + <p><?php echo _("One way to generate an acceptable certificate request is via this openssl one-liner:"); ?></p> |
|
181 | 181 | <p>openssl req -new -newkey rsa:4096 -out test.csr -keyout test.key -subj /DC=test/DC=test/DC=eduroam/C=XY/O=WillBeReplaced/CN=will.be.replaced</p> |
182 | - <h2><?php echo _("3. Submission");?></h2> |
|
182 | + <h2><?php echo _("3. Submission"); ?></h2> |
|
183 | 183 | <?php echo _("Please paste your CSR here:"); ?><br/><textarea name="CSR" id="CSR" rows="20" cols="85"/></textarea><br/> |
184 | 184 | <button type="submit" name="requestcert" id="requestcert" value="<?php echo \web\lib\common\FormElements::BUTTON_SAVE ?>"><?php echo _("Send request"); ?></button> |
185 | 185 | </form> |
@@ -131,7 +131,7 @@ discard block |
||
131 | 131 | return $this->counter; |
132 | 132 | } |
133 | 133 | |
134 | - $cachedNumber = @file_get_contents(ROOT . "/var/tmp/cachedSPNumber.serialised"); |
|
134 | + $cachedNumber = @file_get_contents(ROOT."/var/tmp/cachedSPNumber.serialised"); |
|
135 | 135 | if ($cachedNumber !== FALSE) { |
136 | 136 | $numberData = unserialize($cachedNumber); |
137 | 137 | $now = new \DateTime(); |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | } else { // data in cache is too old or doesn't exist. We really need to ask the database |
145 | 145 | $list = $this->listAllServiceProviders(); |
146 | 146 | $this->counter = count($list); |
147 | - file_put_contents(ROOT . "/var/tmp/cachedSPNumber.serialised", serialize(["number" => $this->counter, "timestamp" => new \DateTime()])); |
|
147 | + file_put_contents(ROOT."/var/tmp/cachedSPNumber.serialised", serialize(["number" => $this->counter, "timestamp" => new \DateTime()])); |
|
148 | 148 | return $this->counter; |
149 | 149 | } |
150 | 150 | } |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | $returnarray = []; |
176 | 176 | $query = "SELECT id_institution AS id, country, inst_realm as realmlist, name AS collapsed_name, contact AS collapsed_contact, type FROM view_active_institution WHERE country = ?"; |
177 | 177 | if ($eduroamDbType !== NULL) { |
178 | - $query .= " AND ( type = '" . ExternalEduroamDBData::TYPE_IDPSP . "' OR type = '" . $eduroamDbType . "')"; |
|
178 | + $query .= " AND ( type = '".ExternalEduroamDBData::TYPE_IDPSP."' OR type = '".$eduroamDbType."')"; |
|
179 | 179 | } |
180 | 180 | $externals = $this->db->exec($query, "s", $tld); |
181 | 181 | // was a SELECT query, so a resource and not a boolean |
@@ -45,11 +45,11 @@ discard block |
||
45 | 45 | ], |
46 | 46 | [ |
47 | 47 | 'title' => sprintf(_("Is it safe to use %s installers?"), \config\Master::APPEARANCE['productname']), |
48 | - 'text' => sprintf(_("%s installers configure security settings on your device, therefore you should be sure that you are using genuine ones."), \config\Master::APPEARANCE['productname']) . ' ' . ( isset(\config\ConfAssistant::CONSORTIUM['signer_name']) && \config\ConfAssistant::CONSORTIUM['signer_name'] != "" ? sprintf(_("This is why %s installers are digitally signed by %s. Watch out for a system message confirming this."), \config\Master::APPEARANCE['productname'], \config\ConfAssistant::CONSORTIUM['signer_name']) : ""), |
|
48 | + 'text' => sprintf(_("%s installers configure security settings on your device, therefore you should be sure that you are using genuine ones."), \config\Master::APPEARANCE['productname']).' '.(isset(\config\ConfAssistant::CONSORTIUM['signer_name']) && \config\ConfAssistant::CONSORTIUM['signer_name'] != "" ? sprintf(_("This is why %s installers are digitally signed by %s. Watch out for a system message confirming this."), \config\Master::APPEARANCE['productname'], \config\ConfAssistant::CONSORTIUM['signer_name']) : ""), |
|
49 | 49 | ], |
50 | 50 | [ |
51 | 51 | 'title' => _("Windows 'SmartScreen' or 'Internet Explorer' tell me that the file is not commonly downloaded and possibly harmful. Should I be concerned?"), |
52 | - 'text' => _("Contrary to what the name suggests, 'SmartScreen' isn't actually very smart. The warning merely means that the file has not yet been downloaded by enough users to make Microsoft consider it popular (which would strangely enough make it be considered 'safe'). This message alone is not a security problem.") . " " . (isset(\config\ConfAssistant::CONSORTIUM['signer_name']) && \config\ConfAssistant::CONSORTIUM['signer_name'] != "" ? sprintf(_("So long as the file is carrying a valid signature from %s, the download is safe."), \config\ConfAssistant::CONSORTIUM['signer_name']) . " " : "") . sprintf(_("Please see also Microsoft's FAQ regarding SmartScreen at %s."), "<a href='http://windows.microsoft.com/en-US/windows7/SmartScreen-Filter-frequently-asked-questions-IE9?SignedIn=1'>Microsoft FAQ</a>") |
|
52 | + 'text' => _("Contrary to what the name suggests, 'SmartScreen' isn't actually very smart. The warning merely means that the file has not yet been downloaded by enough users to make Microsoft consider it popular (which would strangely enough make it be considered 'safe'). This message alone is not a security problem.")." ".(isset(\config\ConfAssistant::CONSORTIUM['signer_name']) && \config\ConfAssistant::CONSORTIUM['signer_name'] != "" ? sprintf(_("So long as the file is carrying a valid signature from %s, the download is safe."), \config\ConfAssistant::CONSORTIUM['signer_name'])." " : "").sprintf(_("Please see also Microsoft's FAQ regarding SmartScreen at %s."), "<a href='http://windows.microsoft.com/en-US/windows7/SmartScreen-Filter-frequently-asked-questions-IE9?SignedIn=1'>Microsoft FAQ</a>") |
|
53 | 53 | ], |
54 | 54 | [ |
55 | 55 | 'title' => sprintf(_("I can see %s network and my device is configured but it does not connect, what can be the cause?"), \config\ConfAssistant::CONSORTIUM['display_name']), |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | $consortium = \config\ConfAssistant::CONSORTIUM['display_name']; |
69 | 69 | array_push($Faq, |
70 | 70 | [ |
71 | - 'id' => 'what_is_' . \config\ConfAssistant::CONSORTIUM['name'], |
|
71 | + 'id' => 'what_is_'.\config\ConfAssistant::CONSORTIUM['name'], |
|
72 | 72 | 'title' => sprintf(_("What is this %s thing anyway?"), $consortium), |
73 | 73 | 'text' => sprintf(_("%s is a global WiFi roaming consortium which gives members of education and research access to the internet <i>for free</i> on all %s hotspots on the planet. There are several million %s users already, enjoying free internet access on more than %d hotspots! Visit <a href='http://www.eduroam.org'>the %s homepage</a> or <a href='http://monitor.eduroam.org/map_service_loc.php'>the %s location map</a> for more details."), $consortium, $consortium, $consortium, $SPs, $consortium, $consortium) |
74 | 74 | ]); |
@@ -290,7 +290,7 @@ discard block |
||
290 | 290 | <table><tr> |
291 | 291 | <td class='icon_td'>"; |
292 | 292 | $out[] = "<img src='".$this->stateIcons[$this->globalLevelStatic]."' id='main_static_ico' class='icon'></td><td id='main_static_result'>". |
293 | - $this->globalInfo[$this->globalLevelStatic].' '. _("See the appropriate tab for details.").'</td> |
|
293 | + $this->globalInfo[$this->globalLevelStatic].' '._("See the appropriate tab for details.").'</td> |
|
294 | 294 | </tr></table>'; |
295 | 295 | if ($this->naptr > 0) { |
296 | 296 | $out[] = "<hr><strong>"._("Dynamic connectivity tests")."</strong> |
@@ -323,7 +323,7 @@ discard block |
||
323 | 323 | <td class='icon_td'><img src='".$this->stateIcons[$result->level]."' id='src".$hostindex."_img'></td> |
324 | 324 | <td id='src$hostindex' colspan=2> |
325 | 325 | "; |
326 | - $out[] = '<strong>'.($result->server ? $result->server : _("Connected to undetermined server")).'</strong><br/>'.sprintf (_("elapsed time: %sms."), $result->time_millisec).'<p>'.$result->message.'</p>'; |
|
326 | + $out[] = '<strong>'.($result->server ? $result->server : _("Connected to undetermined server")).'</strong><br/>'.sprintf(_("elapsed time: %sms."), $result->time_millisec).'<p>'.$result->message.'</p>'; |
|
327 | 327 | |
328 | 328 | if ($result->level > \core\common\Entity::L_OK && property_exists($result, 'cert_oddities')) { |
329 | 329 | foreach ($result->cert_oddities as $oddities) { |
@@ -408,7 +408,7 @@ discard block |
||
408 | 408 | } else { |
409 | 409 | $certdesc = '<br>'; |
410 | 410 | } |
411 | - $capathtest[] = '<div>'.($capath->message!='' ? $capath->message : _('Test failed')).'</div>'.$more; |
|
411 | + $capathtest[] = '<div>'.($capath->message != '' ? $capath->message : _('Test failed')).'</div>'.$more; |
|
412 | 412 | $capathtest[] = '</td> |
413 | 413 | </tr> |
414 | 414 | </table>'; |
@@ -434,7 +434,7 @@ discard block |
||
434 | 434 | $srefused = 0; |
435 | 435 | $cliinfo = ''; |
436 | 436 | $cliinfo .= '<li>'._('Client certificate').' <b>'.$ca->clientcertinfo->from. |
437 | - '</b>'.', '.$ca->clientcertinfo->message . |
|
437 | + '</b>'.', '.$ca->clientcertinfo->message. |
|
438 | 438 | '<br> (CA: '.$ca->clientcertinfo->issuer.')<ul>'; |
439 | 439 | foreach ($ca->certificate as $certificate) { |
440 | 440 | if ($certificate->returncode == \core\diag\RADIUSTests::RETVAL_CONNECTION_REFUSED) { |
@@ -494,7 +494,7 @@ discard block |
||
494 | 494 | } else { |
495 | 495 | $cliinfo = _('Test failed'); |
496 | 496 | $clientstest[] = "<table><tr><td class='icon_td' id='srcclient".$hostindex."_img'><img src='". |
497 | - $this->stateIcons[\core\common\Entity::L_WARN]."'></td>" . |
|
497 | + $this->stateIcons[\core\common\Entity::L_WARN]."'></td>". |
|
498 | 498 | "<td id='srcclient$hostindex'>$cliinfo</td></tr></table>"; |
499 | 499 | } |
500 | 500 | } else { |
@@ -146,12 +146,12 @@ discard block |
||
146 | 146 | $this->marshalObject($root, $eapIdp); |
147 | 147 | $dom = dom_import_simplexml($root)->ownerDocument; |
148 | 148 | //TODO schema validation makes sense so probably should be used |
149 | - if ($dom->schemaValidate(ROOT . '/devices/xml/eap-metadata.xsd') === FALSE) { |
|
149 | + if ($dom->schemaValidate(ROOT.'/devices/xml/eap-metadata.xsd') === FALSE) { |
|
150 | 150 | throw new Exception("Schema validation failed for eap-metadata"); |
151 | 151 | } |
152 | 152 | $dom->formatOutput = true; |
153 | - file_put_contents($this->installerBasename . '.eap-config', $dom->saveXML()); |
|
154 | - return($this->installerBasename . '.eap-config'); |
|
153 | + file_put_contents($this->installerBasename.'.eap-config', $dom->saveXML()); |
|
154 | + return($this->installerBasename.'.eap-config'); |
|
155 | 155 | } |
156 | 156 | |
157 | 157 | private const ATTRIBUTENAMES = [ |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | $this->loggerInstance->debug(4, "Missing class definition for $attrName\n"); |
178 | 178 | return([]); |
179 | 179 | } |
180 | - $className = "\devices\xml\\" . self::ATTRIBUTENAMES[$attrName]; |
|
180 | + $className = "\devices\xml\\".self::ATTRIBUTENAMES[$attrName]; |
|
181 | 181 | $objs = []; |
182 | 182 | if ($this->langScope === 'global') { |
183 | 183 | foreach ($attributeList['langs'] as $language => $value) { |
@@ -215,7 +215,7 @@ discard block |
||
215 | 215 | $displayname = new DisplayName(); |
216 | 216 | if (isset($profileNameLangs)) { |
217 | 217 | $langOrC = isset($profileNameLangs[$language]) ? $profileNameLangs[$language] : $profileNameLangs['C']; |
218 | - $value .= ' - ' . $langOrC; |
|
218 | + $value .= ' - '.$langOrC; |
|
219 | 219 | } |
220 | 220 | $displayname->setValue($value); |
221 | 221 | $displayname->setAttributes(['lang' => $language]); |
@@ -225,7 +225,7 @@ discard block |
||
225 | 225 | $displayname = new DisplayName(); |
226 | 226 | $value = $attr['general:instname'][0]; |
227 | 227 | if ($attr['internal:profile_count'][0] > 1) { |
228 | - $value .= ' - ' . $attr['profile:name'][0]; |
|
228 | + $value .= ' - '.$attr['profile:name'][0]; |
|
229 | 229 | } |
230 | 230 | $displayname->setValue($value); |
231 | 231 | $objs[] = $displayname; |
@@ -242,7 +242,7 @@ discard block |
||
242 | 242 | $attr = $this->attributes; |
243 | 243 | if (isset($attr['general:logo_file'][0])) { |
244 | 244 | $logoString = base64_encode($attr['general:logo_file'][0]); |
245 | - $logoMime = 'image/' . $attr['internal:logo_file'][0]['mime']; |
|
245 | + $logoMime = 'image/'.$attr['internal:logo_file'][0]['mime']; |
|
246 | 246 | $providerlogo = new ProviderLogo(); |
247 | 247 | $providerlogo->setAttributes(['mime' => $logoMime, 'encoding' => 'base64']); |
248 | 248 | $providerlogo->setValue($logoString); |
@@ -347,7 +347,7 @@ discard block |
||
347 | 347 | |
348 | 348 | if (isset($inner["METHOD"]) && $inner["METHOD"]) { |
349 | 349 | $innerauthmethod = new InnerAuthenticationMethod(); |
350 | - $typeOfInner = "\devices\xml\\" . ($inner["EAP"] ? 'EAPMethod' : 'NonEAPAuthMethod'); |
|
350 | + $typeOfInner = "\devices\xml\\".($inner["EAP"] ? 'EAPMethod' : 'NonEAPAuthMethod'); |
|
351 | 351 | $eapmethod = new $typeOfInner(); |
352 | 352 | $eaptype = new Type(); |
353 | 353 | $eaptype->setValue(abs($inner['METHOD'])); |