@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | * @return array list of Profiles of this IdP |
111 | 111 | */ |
112 | 112 | public function listProfiles(bool $activeOnly = FALSE) { |
113 | - $query = "SELECT profile_id FROM profile WHERE inst_id = $this->identifier" . ($activeOnly ? " AND showtime = 1" : ""); |
|
113 | + $query = "SELECT profile_id FROM profile WHERE inst_id = $this->identifier".($activeOnly ? " AND showtime = 1" : ""); |
|
114 | 114 | $allProfiles = $this->databaseHandle->exec($query); |
115 | 115 | $returnarray = []; |
116 | 116 | // SELECT -> resource, not boolean |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | $returnarray[] = $oneProfile; |
121 | 121 | } |
122 | 122 | |
123 | - $this->loggerInstance->debug(4, "listProfiles: " . print_r($returnarray, true)); |
|
123 | + $this->loggerInstance->debug(4, "listProfiles: ".print_r($returnarray, true)); |
|
124 | 124 | return $returnarray; |
125 | 125 | } |
126 | 126 | |
@@ -219,7 +219,7 @@ discard block |
||
219 | 219 | case AbstractProfile::PROFILETYPE_SILVERBULLET: |
220 | 220 | $theProfile = new ProfileSilverbullet($identifier, $this); |
221 | 221 | $theProfile->addSupportedEapMethod(new \core\common\EAP(\core\common\EAP::EAPTYPE_SILVERBULLET), 1); |
222 | - $theProfile->setRealm($this->identifier . "-" . $theProfile->identifier . "." . strtolower($this->federation) . strtolower(CONFIG_CONFASSISTANT['SILVERBULLET']['realm_suffix'])); |
|
222 | + $theProfile->setRealm($this->identifier."-".$theProfile->identifier.".".strtolower($this->federation).strtolower(CONFIG_CONFASSISTANT['SILVERBULLET']['realm_suffix'])); |
|
223 | 223 | return $theProfile; |
224 | 224 | default: |
225 | 225 | throw new Exception("This type of profile is unknown and can not be added."); |
@@ -336,7 +336,7 @@ discard block |
||
336 | 336 | */ |
337 | 337 | public function getExternalDBId() { |
338 | 338 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['name'] == "eduroam" && isset(CONFIG_CONFASSISTANT['CONSORTIUM']['deployment-voodoo']) && CONFIG_CONFASSISTANT['CONSORTIUM']['deployment-voodoo'] == "Operations Team") { // SW: APPROVED |
339 | - $idQuery = $this->databaseHandle->exec("SELECT external_db_id FROM institution WHERE inst_id = $this->identifier AND external_db_syncstate = " . self::EXTERNAL_DB_SYNCSTATE_SYNCED); |
|
339 | + $idQuery = $this->databaseHandle->exec("SELECT external_db_id FROM institution WHERE inst_id = $this->identifier AND external_db_syncstate = ".self::EXTERNAL_DB_SYNCSTATE_SYNCED); |
|
340 | 340 | // SELECT -> it's a resource, not a boolean |
341 | 341 | if (mysqli_num_rows(/** @scrutinizer ignore-type */ $idQuery) == 0) { |
342 | 342 | return FALSE; |
@@ -23,54 +23,54 @@ |
||
23 | 23 | this is just an include file for Gui class definition |
24 | 24 | */ |
25 | 25 | $Faq = [ |
26 | - [ |
|
26 | + [ |
|
27 | 27 | 'id'=>'idp_not_listed', |
28 | 28 | 'title'=>_("My organisation is not listed. Can't I just use any of the other ones?"), |
29 | 29 | 'text'=>_("No! The installers contain security settings which are specific to the organisation. If you are not from that organisation, your device will detect that you are about to send your username and credential to an unauthorised server and will abort the login. Using an installer from a different organisation is <i>guaranteed to not work</i>!") |
30 | - ], |
|
31 | - [ |
|
30 | + ], |
|
31 | + [ |
|
32 | 32 | 'id'=>'idp_not_listed', |
33 | 33 | 'title'=>_("What can I do to get my organisation listed?"), |
34 | 34 | 'text'=>sprintf(_("Contact %s administrators within your organisation and request that they add their organisation to the system. It will take at most one hour of their time to get things done."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
35 | 35 | ], |
36 | - [ |
|
36 | + [ |
|
37 | 37 | 'id'=>'device_not_listed', |
38 | 38 | 'title'=>sprintf(_("My device is not listed! Does that mean I can't do %s?"),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
39 | 39 | 'text'=>sprintf(_("No. The CAT tool can only support Operating Systems which can be automatically configured in some way. Many other devices can still be used with %s, but must be configured manually. Please contact your organisation to get help in setting up such a device."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
40 | - ], |
|
40 | + ], |
|
41 | 41 | |
42 | - [ |
|
42 | + [ |
|
43 | 43 | 'title'=>sprintf(_("I can connect to %s simply by providing username and password, what is the point of using an installer?"),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
44 | 44 | 'text'=>sprintf(_("When you are connecting from an unconfigured device your security is at risk. The very point of preconfiguration is to set up security, when this is done, your device will first confirm that it talks to the correct authentication server and will never send your password to an untrusted one.")) |
45 | 45 | ], |
46 | - [ |
|
46 | + [ |
|
47 | 47 | 'title'=>sprintf(_("Is it safe to use %s installers?"),CONFIG['APPEARANCE']['productname']), |
48 | 48 | 'text'=>sprintf(_("%s installers configure security settings on your device, therefore you should be sure that you are using genuine ones."),CONFIG['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['APPEARANCE']['productname'],CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']):""), |
49 | 49 | |
50 | 50 | ], |
51 | - [ |
|
51 | + [ |
|
52 | 52 | 'title'=>_("Windows 'SmartScreen' or 'Internet Explorer' tell me that the file is not commonly downloaded and possibly harmful. Should I be concerned?"), |
53 | 53 | '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>") |
54 | 54 | |
55 | 55 | ], |
56 | - [ |
|
56 | + [ |
|
57 | 57 | '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']), |
58 | - 'text'=>sprintf(_("There can be a number of different reasons. The network you see may not be a genuine %s one and your device silently drops the connection attempt; there may be something wrong with the configuration of the network; your account may have expired; there may be a connection problem with your home authentication server; you may have broken the regulations of the network you are using and have been refused access as a consequence. You should contact your organisation and report the problem, the administrators should be able to trace your connections."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
58 | + 'text'=>sprintf(_("There can be a number of different reasons. The network you see may not be a genuine %s one and your device silently drops the connection attempt; there may be something wrong with the configuration of the network; your account may have expired; there may be a connection problem with your home authentication server; you may have broken the regulations of the network you are using and have been refused access as a consequence. You should contact your organisation and report the problem, the administrators should be able to trace your connections."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
59 | 59 | ], |
60 | - [ |
|
60 | + [ |
|
61 | 61 | 'id'=>'contact', |
62 | 62 | 'title'=>sprintf(_("I have a question about this web site. Whom should I contact?")), |
63 | 63 | 'text'=>sprintf(_("You should send a mail to %s."),CONFIG['APPEARANCE']['support-contact']['display']) |
64 | - ], |
|
64 | + ], |
|
65 | 65 | ]; |
66 | 66 | |
67 | 67 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['name'] == "eduroam") { |
68 | 68 | $eduroamDb = new core\ExternalEduroamDBData(); |
69 | 69 | $SPs = $eduroamDb->allServiceProviders(); |
70 | - array_push($Faq, |
|
71 | - [ |
|
72 | - 'id'=>'what_is_'.CONFIG_CONFASSISTANT['CONSORTIUM']['name'], |
|
73 | - 'title'=>sprintf(_("What is this %s thing anyway?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
74 | - '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."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], count($SPs), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
75 | - ]); |
|
70 | + array_push($Faq, |
|
71 | + [ |
|
72 | + 'id'=>'what_is_'.CONFIG_CONFASSISTANT['CONSORTIUM']['name'], |
|
73 | + 'title'=>sprintf(_("What is this %s thing anyway?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
74 | + '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."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], count($SPs), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
75 | + ]); |
|
76 | 76 | } |
@@ -31,36 +31,36 @@ discard block |
||
31 | 31 | [ |
32 | 32 | 'id'=>'idp_not_listed', |
33 | 33 | 'title'=>_("What can I do to get my organisation listed?"), |
34 | - 'text'=>sprintf(_("Contact %s administrators within your organisation and request that they add their organisation to the system. It will take at most one hour of their time to get things done."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
34 | + 'text'=>sprintf(_("Contact %s administrators within your organisation and request that they add their organisation to the system. It will take at most one hour of their time to get things done."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
35 | 35 | ], |
36 | 36 | [ |
37 | 37 | 'id'=>'device_not_listed', |
38 | - 'title'=>sprintf(_("My device is not listed! Does that mean I can't do %s?"),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
39 | - 'text'=>sprintf(_("No. The CAT tool can only support Operating Systems which can be automatically configured in some way. Many other devices can still be used with %s, but must be configured manually. Please contact your organisation to get help in setting up such a device."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
38 | + 'title'=>sprintf(_("My device is not listed! Does that mean I can't do %s?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
39 | + 'text'=>sprintf(_("No. The CAT tool can only support Operating Systems which can be automatically configured in some way. Many other devices can still be used with %s, but must be configured manually. Please contact your organisation to get help in setting up such a device."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
40 | 40 | ], |
41 | 41 | |
42 | 42 | [ |
43 | - 'title'=>sprintf(_("I can connect to %s simply by providing username and password, what is the point of using an installer?"),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
43 | + 'title'=>sprintf(_("I can connect to %s simply by providing username and password, what is the point of using an installer?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
44 | 44 | 'text'=>sprintf(_("When you are connecting from an unconfigured device your security is at risk. The very point of preconfiguration is to set up security, when this is done, your device will first confirm that it talks to the correct authentication server and will never send your password to an untrusted one.")) |
45 | 45 | ], |
46 | 46 | [ |
47 | - 'title'=>sprintf(_("Is it safe to use %s installers?"),CONFIG['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['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['APPEARANCE']['productname'],CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']):""), |
|
47 | + 'title'=>sprintf(_("Is it safe to use %s installers?"), CONFIG['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['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['APPEARANCE']['productname'], CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']) : ""), |
|
49 | 49 | |
50 | 50 | ], |
51 | 51 | [ |
52 | 52 | 'title'=>_("Windows 'SmartScreen' or 'Internet Explorer' tell me that the file is not commonly downloaded and possibly harmful. Should I be concerned?"), |
53 | - '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 | + '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>") |
|
54 | 54 | |
55 | 55 | ], |
56 | 56 | [ |
57 | - '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']), |
|
58 | - 'text'=>sprintf(_("There can be a number of different reasons. The network you see may not be a genuine %s one and your device silently drops the connection attempt; there may be something wrong with the configuration of the network; your account may have expired; there may be a connection problem with your home authentication server; you may have broken the regulations of the network you are using and have been refused access as a consequence. You should contact your organisation and report the problem, the administrators should be able to trace your connections."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
57 | + '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']), |
|
58 | + 'text'=>sprintf(_("There can be a number of different reasons. The network you see may not be a genuine %s one and your device silently drops the connection attempt; there may be something wrong with the configuration of the network; your account may have expired; there may be a connection problem with your home authentication server; you may have broken the regulations of the network you are using and have been refused access as a consequence. You should contact your organisation and report the problem, the administrators should be able to trace your connections."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
59 | 59 | ], |
60 | 60 | [ |
61 | 61 | 'id'=>'contact', |
62 | 62 | 'title'=>sprintf(_("I have a question about this web site. Whom should I contact?")), |
63 | - 'text'=>sprintf(_("You should send a mail to %s."),CONFIG['APPEARANCE']['support-contact']['display']) |
|
63 | + 'text'=>sprintf(_("You should send a mail to %s."), CONFIG['APPEARANCE']['support-contact']['display']) |
|
64 | 64 | ], |
65 | 65 | ]; |
66 | 66 | |
@@ -71,6 +71,6 @@ discard block |
||
71 | 71 | [ |
72 | 72 | 'id'=>'what_is_'.CONFIG_CONFASSISTANT['CONSORTIUM']['name'], |
73 | 73 | 'title'=>sprintf(_("What is this %s thing anyway?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
74 | - '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."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], count($SPs), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
74 | + '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."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], count($SPs), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
75 | 75 | ]); |
76 | 76 | } |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | * @author Stefan Winter <[email protected]> |
28 | 28 | * @package UserGUI |
29 | 29 | */ |
30 | -require dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
30 | +require dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
31 | 31 | $API = new \core\UserAPI(); |
32 | 32 | $loggerInstance = new \core\common\Logging(); |
33 | 33 | $validator = new \web\lib\common\InputValidation(); |
@@ -76,5 +76,5 @@ discard block |
||
76 | 76 | if ($accountPageUrl === FALSE) { |
77 | 77 | throw new Exception("Unable to find our accountstatus.php page."); |
78 | 78 | } |
79 | - header("Location: ../accountstatus/accountstatus.php?token=" . $cleanToken . "&errorcode=GENERATOR_CONSUMED"); |
|
79 | + header("Location: ../accountstatus/accountstatus.php?token=".$cleanToken."&errorcode=GENERATOR_CONSUMED"); |
|
80 | 80 | } |
81 | 81 | \ No newline at end of file |
@@ -26,8 +26,8 @@ discard block |
||
26 | 26 | */ |
27 | 27 | ?> |
28 | 28 | <?php |
29 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
30 | -require_once dirname(dirname(dirname(__FILE__))) . "/core/phpqrcode.php"; |
|
29 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
30 | +require_once dirname(dirname(dirname(__FILE__)))."/core/phpqrcode.php"; |
|
31 | 31 | |
32 | 32 | |
33 | 33 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | } else { |
41 | 41 | $link = 'http://'; |
42 | 42 | } |
43 | -$link .= $_SERVER['SERVER_NAME'] . $_SERVER['SCRIPT_NAME']; |
|
43 | +$link .= $_SERVER['SERVER_NAME'].$_SERVER['SCRIPT_NAME']; |
|
44 | 44 | $link = htmlspecialchars($link); |
45 | 45 | |
46 | 46 | const QRCODE_PIXELS_PER_SYMBOL = 12; |
@@ -76,15 +76,15 @@ discard block |
||
76 | 76 | <div class='infobox' style='text-align:center;'> |
77 | 77 | <h2><?php echo sprintf(_("%s download area QR code"), $uiElements->nomenclatureInst); ?></h2> |
78 | 78 | <?php |
79 | - $idpLevelUrl = ( isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == "on" ? 'https://' : 'http://') . $_SERVER['SERVER_NAME'] . dirname(dirname($_SERVER['SCRIPT_NAME'])) . "?idp=" . $my_inst->identifier; |
|
79 | + $idpLevelUrl = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == "on" ? 'https://' : 'http://').$_SERVER['SERVER_NAME'].dirname(dirname($_SERVER['SCRIPT_NAME']))."?idp=".$my_inst->identifier; |
|
80 | 80 | // never NULL, because $filename is FALSE; but make Scrutinizer happy |
81 | 81 | $rawQr = QRcode::png($idpLevelUrl, FALSE, QR_ECLEVEL_Q, QRCODE_PIXELS_PER_SYMBOL); |
82 | 82 | if ($rawQr === NULL) { |
83 | 83 | throw new Exception("Something went seriously wrong during QR code generation!"); |
84 | 84 | } |
85 | - $uri = "data:image/png;base64," . base64_encode($uiElements->pngInjectConsortiumLogo($rawQr, QRCODE_PIXELS_PER_SYMBOL)); |
|
85 | + $uri = "data:image/png;base64,".base64_encode($uiElements->pngInjectConsortiumLogo($rawQr, QRCODE_PIXELS_PER_SYMBOL)); |
|
86 | 86 | $size = getimagesize($uri); |
87 | - echo "<img width='" . ($size[0] / 4) . "' height='" . ($size[1] / 4) . "' src='$uri' alt='QR-code'/>"; |
|
87 | + echo "<img width='".($size[0] / 4)."' height='".($size[1] / 4)."' src='$uri' alt='QR-code'/>"; |
|
88 | 88 | ?> |
89 | 89 | <br> |
90 | 90 | <?php echo "<a href='$idpLevelUrl'>$idpLevelUrl</a>"; ?> |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | </td> |
114 | 114 | <td> |
115 | 115 | <form action='edit_idp_result.php?inst_id=<?php echo $my_inst->identifier; ?>' method='post' accept-charset='UTF-8'> |
116 | - <button class='delete' type='submit' name='submitbutton' value='<?php echo web\lib\common\FormElements::BUTTON_DELETE; ?>' onclick="return confirm('<?php echo ( CONFIG_CONFASSISTANT['CONSORTIUM']['selfservice_registration'] === NULL ? sprintf(_("After deleting the %s, you can not recreate it yourself - you need a new invitation token from the %s administrator!"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed) . " " : "" ) . sprintf(_("Do you really want to delete your %s %s?"), $uiElements->nomenclatureInst, $my_inst->name); ?>')"><?php echo sprintf(_("Delete %s"), $uiElements->nomenclatureInst); ?></button> |
|
116 | + <button class='delete' type='submit' name='submitbutton' value='<?php echo web\lib\common\FormElements::BUTTON_DELETE; ?>' onclick="return confirm('<?php echo (CONFIG_CONFASSISTANT['CONSORTIUM']['selfservice_registration'] === NULL ? sprintf(_("After deleting the %s, you can not recreate it yourself - you need a new invitation token from the %s administrator!"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed)." " : "").sprintf(_("Do you really want to delete your %s %s?"), $uiElements->nomenclatureInst, $my_inst->name); ?>')"><?php echo sprintf(_("Delete %s"), $uiElements->nomenclatureInst); ?></button> |
|
117 | 117 | </form> |
118 | 118 | |
119 | 119 | </td> |
@@ -134,21 +134,21 @@ discard block |
||
134 | 134 | <?php |
135 | 135 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['DIAGNOSTICS'] !== NULL) { |
136 | 136 | echo "<tr> |
137 | - <td>" . _("Check another realm's reachability") . "</td> |
|
137 | + <td>" . _("Check another realm's reachability")."</td> |
|
138 | 138 | <td><form method='post' action='../diag/action_realmcheck.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'> |
139 | 139 | <input type='text' name='realm' id='realm'> |
140 | 140 | <input type='hidden' name='comefrom' id='comefrom' value='$link'/> |
141 | - <button type='submit'>" . _("Go!") . "</button> |
|
141 | + <button type='submit'>"._("Go!")."</button> |
|
142 | 142 | </form> |
143 | 143 | </td> |
144 | 144 | </tr>"; |
145 | 145 | } |
146 | 146 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['name'] == "eduroam") { // SW: APPROVED |
147 | 147 | echo "<tr> |
148 | - <td>" . sprintf(_("Check %s server status"), $uiElements->nomenclatureFed) . "</td> |
|
148 | + <td>" . sprintf(_("Check %s server status"), $uiElements->nomenclatureFed)."</td> |
|
149 | 149 | <td> |
150 | 150 | <form action='https://monitor.eduroam.org/mon_direct.php' accept-charset='UTF-8'> |
151 | - <button type='submit'>" . _("Go!") . "</button> |
|
151 | + <button type='submit'>" . _("Go!")."</button> |
|
152 | 152 | </form> |
153 | 153 | </td> |
154 | 154 | </tr>"; |
@@ -159,10 +159,10 @@ discard block |
||
159 | 159 | <?php |
160 | 160 | $profiles_for_this_idp = $my_inst->listProfiles(); |
161 | 161 | if (count($profiles_for_this_idp) == 0) { // no profiles yet. |
162 | - echo "<h2>" . sprintf(_("There are not yet any profiles for your %s."), $uiElements->nomenclatureInst) . "</h2>"; |
|
162 | + echo "<h2>".sprintf(_("There are not yet any profiles for your %s."), $uiElements->nomenclatureInst)."</h2>"; |
|
163 | 163 | } |
164 | 164 | if (count($profiles_for_this_idp) > 0) { // no profiles yet. |
165 | - echo "<h2>" . sprintf(_("Profiles for this %s"), $uiElements->nomenclatureInst) . "</h2>"; |
|
165 | + echo "<h2>".sprintf(_("Profiles for this %s"), $uiElements->nomenclatureInst)."</h2>"; |
|
166 | 166 | } |
167 | 167 | // if there is one profile and it is of type Silver Bullet, display a very |
168 | 168 | // simple widget with just a "Manage" button |
@@ -188,7 +188,7 @@ discard block |
||
188 | 188 | echo _("Information needed!"); |
189 | 189 | echo "<ul style='margin:1px'>"; |
190 | 190 | foreach ($completeness as $missing_attrib) { |
191 | - echo "<li>" . $uiElements->displayName($missing_attrib) . "</li>"; |
|
191 | + echo "<li>".$uiElements->displayName($missing_attrib)."</li>"; |
|
192 | 192 | } |
193 | 193 | echo "</ul>"; |
194 | 194 | echo "</div>"; |
@@ -202,7 +202,7 @@ discard block |
||
202 | 202 | if ($readonly === FALSE) { |
203 | 203 | ?> |
204 | 204 | <form action='edit_silverbullet.php?inst_id=<?php echo $my_inst->identifier; ?>&profile_id=<?php echo $profile_list->identifier; ?>' method='POST'> |
205 | - <button <?php echo ( is_array($completeness) ? "disabled" : "" ); ?> type='submit' name='sb_action' value='sb_edit'><?php echo _("Manage User Base"); ?></button> |
|
205 | + <button <?php echo (is_array($completeness) ? "disabled" : ""); ?> type='submit' name='sb_action' value='sb_edit'><?php echo _("Manage User Base"); ?></button> |
|
206 | 206 | </form> |
207 | 207 | <?php |
208 | 208 | } |
@@ -234,21 +234,21 @@ discard block |
||
234 | 234 | $has_overrides = TRUE; |
235 | 235 | } |
236 | 236 | } |
237 | - $buffer_eaptypediv = "<div style='margin-bottom:40px; float:left;'>" . _("<strong>EAP Types</strong> (in order of preference):") . "<br/>"; |
|
237 | + $buffer_eaptypediv = "<div style='margin-bottom:40px; float:left;'>"._("<strong>EAP Types</strong> (in order of preference):")."<br/>"; |
|
238 | 238 | $typelist = $profile_list->getEapMethodsinOrderOfPreference(); |
239 | 239 | $allcomplete = TRUE; |
240 | 240 | foreach ($typelist as $eaptype) { |
241 | 241 | $buffer_eaptypediv .= $eaptype->getPrintableRep(); |
242 | 242 | $completeness = $profile_list->isEapTypeDefinitionComplete($eaptype); |
243 | 243 | if ($completeness === true) { |
244 | - $buffer_eaptypediv .= " <div class='acceptable'>" . _("OK") . "</div>"; |
|
244 | + $buffer_eaptypediv .= " <div class='acceptable'>"._("OK")."</div>"; |
|
245 | 245 | } else { |
246 | 246 | $buffer_eaptypediv .= " <div class='notacceptable'>"; |
247 | 247 | $buffer_eaptypediv .= _("Information needed!"); |
248 | 248 | if (is_array($completeness)) { |
249 | 249 | $buffer_eaptypediv .= "<ul style='margin:1px'>"; |
250 | 250 | foreach ($completeness as $missing_attrib) { |
251 | - $buffer_eaptypediv .= "<li>" . $uiElements->displayName($missing_attrib) . "</li>"; |
|
251 | + $buffer_eaptypediv .= "<li>".$uiElements->displayName($missing_attrib)."</li>"; |
|
252 | 252 | } |
253 | 253 | $buffer_eaptypediv .= "</ul>"; |
254 | 254 | } |
@@ -260,12 +260,12 @@ discard block |
||
260 | 260 | foreach ($attribs as $attrib) { |
261 | 261 | if ($attrib['level'] == "Method" && !preg_match("/^internal:/", $attrib['name']) && !$justOnce) { |
262 | 262 | $justOnce = TRUE; |
263 | - $buffer_eaptypediv .= "<img src='../resources/images/icons/Letter-E-blue-icon.png' alt='" . _("Options on EAP Method/Device level are in effect.") . "'>"; |
|
263 | + $buffer_eaptypediv .= "<img src='../resources/images/icons/Letter-E-blue-icon.png' alt='"._("Options on EAP Method/Device level are in effect.")."'>"; |
|
264 | 264 | } |
265 | 265 | } |
266 | 266 | $buffer_eaptypediv .= "<br/>"; |
267 | 267 | } |
268 | - $buffer_headline = "<div style='padding-bottom:20px;'><h2 style='overflow:auto; display:inline; padding-bottom: 10px;'>" . sprintf(_("Profile: %s"), $profile_name) . "</h2>"; |
|
268 | + $buffer_headline = "<div style='padding-bottom:20px;'><h2 style='overflow:auto; display:inline; padding-bottom: 10px;'>".sprintf(_("Profile: %s"), $profile_name)."</h2>"; |
|
269 | 269 | |
270 | 270 | $buffer_headline .= "<span style='float:right;'>"; |
271 | 271 | $readiness = $profile_list->readinessLevel(); |
@@ -297,18 +297,18 @@ discard block |
||
297 | 297 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['DIAGNOSTICS'] == "LOCAL") { |
298 | 298 | $diagUrl = "../diag/"; |
299 | 299 | } else { |
300 | - $diagUrl = CONFIG['FUNCTIONALITY_LOCATIONS']['DIAGNOSTICS'] . "/diag/"; |
|
300 | + $diagUrl = CONFIG['FUNCTIONALITY_LOCATIONS']['DIAGNOSTICS']."/diag/"; |
|
301 | 301 | } |
302 | - echo "<form action='" . $diagUrl . "action_realmcheck.php?inst_id=$my_inst->identifier&profile_id=$profile_list->identifier' method='post' accept-charset='UTF-8'> |
|
302 | + echo "<form action='".$diagUrl."action_realmcheck.php?inst_id=$my_inst->identifier&profile_id=$profile_list->identifier' method='post' accept-charset='UTF-8'> |
|
303 | 303 | <input type='hidden' name='comefrom' id='comefrom-$profilecount' value='$link'/> |
304 | - <button type='submit' name='profile_action' value='check' " . ($has_realm ? "" : "disabled='disabled' title='" . _("The realm can only be checked if you configure the realm!") . "'") . "> |
|
305 | - " . _("Check realm reachability") . " |
|
304 | + <button type='submit' name='profile_action' value='check' ".($has_realm ? "" : "disabled='disabled' title='"._("The realm can only be checked if you configure the realm!")."'")."> |
|
305 | + " . _("Check realm reachability")." |
|
306 | 306 | </button> |
307 | 307 | </form>"; |
308 | 308 | } |
309 | 309 | echo "<form action='overview_installers.php?inst_id=$my_inst->identifier&profile_id=$profile_list->identifier' method='post' accept-charset='UTF-8'> |
310 | - <button type='submit' name='profile_action' value='check' " . ($has_eaptypes ? "" : "disabled='disabled' title='" . _("You have not fully configured any supported EAP types!") . "'") . "> |
|
311 | - " . _("Installer Fine-Tuning and Download") . " |
|
310 | + <button type='submit' name='profile_action' value='check' ".($has_eaptypes ? "" : "disabled='disabled' title='"._("You have not fully configured any supported EAP types!")."'")."> |
|
311 | + " . _("Installer Fine-Tuning and Download")." |
|
312 | 312 | </button> |
313 | 313 | </form> |
314 | 314 | </div>"; |
@@ -317,11 +317,11 @@ discard block |
||
317 | 317 | echo " <div class='buttongroupprofilebox' style='clear:both;'> |
318 | 318 | <form action='edit_profile.php?inst_id=$my_inst->identifier&profile_id=$profile_list->identifier' method='post' accept-charset='UTF-8'> |
319 | 319 | <hr/> |
320 | - <button type='submit' name='profile_action' value='edit'>" . _("Edit") . "</button> |
|
320 | + <button type='submit' name='profile_action' value='edit'>"._("Edit")."</button> |
|
321 | 321 | </form> |
322 | 322 | <form action='edit_profile_result.php?inst_id=$my_inst->identifier&profile_id=$profile_list->identifier' method='post' accept-charset='UTF-8'> |
323 | - <button class='delete' type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_DELETE . "' onclick=\"return confirm('" . sprintf(_("Do you really want to delete the profile %s?"), $profile_name) . "')\"> |
|
324 | - " . _("Delete") . " |
|
323 | + <button class='delete' type='submit' name='submitbutton' value='".web\lib\common\FormElements::BUTTON_DELETE."' onclick=\"return confirm('".sprintf(_("Do you really want to delete the profile %s?"), $profile_name)."')\"> |
|
324 | + " . _("Delete")." |
|
325 | 325 | </button> |
326 | 326 | </form> |
327 | 327 | </div>"; |
@@ -330,24 +330,24 @@ discard block |
||
330 | 330 | // dummy width to keep a little distance |
331 | 331 | echo "<div style='width:20px;'></div>"; |
332 | 332 | if ($readiness == core\AbstractProfile::READINESS_LEVEL_SHOWTIME) { |
333 | - echo "<div style='display: table-cell; text-align:center;'><p><strong>" . _("User Download Link") . "</strong></p>"; |
|
334 | - $displayurl = $idpLevelUrl . "&profile=" . $profile_list->identifier; |
|
335 | - $QRurl = $idpLevelUrl . "&profile=" . $profile_list->identifier; |
|
333 | + echo "<div style='display: table-cell; text-align:center;'><p><strong>"._("User Download Link")."</strong></p>"; |
|
334 | + $displayurl = $idpLevelUrl."&profile=".$profile_list->identifier; |
|
335 | + $QRurl = $idpLevelUrl."&profile=".$profile_list->identifier; |
|
336 | 336 | echo "<a href='$displayurl' style='white-space: nowrap; text-align: center;'>"; |
337 | 337 | $rawQr = QRcode::png($QRurl, FALSE, QR_ECLEVEL_Q, QRCODE_PIXELS_PER_SYMBOL); |
338 | 338 | if ($rawQr === NULL) { |
339 | 339 | throw new Exception("Something went seriously wrong during QR code generation!"); |
340 | 340 | } |
341 | - $uri = "data:image/png;base64," . base64_encode($uiElements->pngInjectConsortiumLogo($rawQr, QRCODE_PIXELS_PER_SYMBOL)); |
|
341 | + $uri = "data:image/png;base64,".base64_encode($uiElements->pngInjectConsortiumLogo($rawQr, QRCODE_PIXELS_PER_SYMBOL)); |
|
342 | 342 | $size = getimagesize($uri); |
343 | - echo "<img width='" . ($size[0] / 4) . "' height='" . ($size[1] / 4) . "' src='$uri' alt='QR-code'/>"; |
|
343 | + echo "<img width='".($size[0] / 4)."' height='".($size[1] / 4)."' src='$uri' alt='QR-code'/>"; |
|
344 | 344 | |
345 | 345 | //echo "<nobr>$displayurl</nobr></a>"; |
346 | 346 | echo "<p>$displayurl</p></a>"; |
347 | 347 | echo "</div>"; |
348 | 348 | // dummy width to keep a little distance |
349 | 349 | echo "<div style='width:20px;'></div>"; |
350 | - echo "<div style='display: table-cell; min-width:200px;'><p><strong>" . _("User Downloads") . "</strong></p><table>"; |
|
350 | + echo "<div style='display: table-cell; min-width:200px;'><p><strong>"._("User Downloads")."</strong></p><table>"; |
|
351 | 351 | $stats = $profile_list->getUserDownloadStats(); |
352 | 352 | foreach ($stats as $dev => $count) { |
353 | 353 | echo "<tr><td><strong>$dev</strong></td><td>$count</td></tr>"; |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | * <base_url>/copyright.php after deploying the software |
20 | 20 | */ |
21 | 21 | |
22 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
22 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
23 | 23 | |
24 | 24 | $Tests = [ |
25 | 25 | 'cat_base_url', |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | 'mailer', |
38 | 38 | ]; |
39 | 39 | |
40 | -if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_RADIUS'] == "LOCAL" ) { |
|
40 | +if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_RADIUS'] == "LOCAL") { |
|
41 | 41 | $Tests[] = 'makensis'; |
42 | 42 | $Tests[] = 'makensis=>NSISmodules'; |
43 | 43 | } |
@@ -71,10 +71,10 @@ discard block |
||
71 | 71 | $message = "Your configuration appears to be fine."; |
72 | 72 | break; |
73 | 73 | default: |
74 | - throw new Exception("The result code level " . $test->test_result['global'] . " is not defined!"); |
|
74 | + throw new Exception("The result code level ".$test->test_result['global']." is not defined!"); |
|
75 | 75 | } |
76 | 76 | $uiElements = new web\lib\admin\UIElements(); |
77 | - $out .= $uiElements->boxFlexible($test->test_result['global'], "<br><strong>Test Summary</strong><br>" . $message . "<br>See below for details<br><hr>"); |
|
77 | + $out .= $uiElements->boxFlexible($test->test_result['global'], "<br><strong>Test Summary</strong><br>".$message."<br>See below for details<br><hr>"); |
|
78 | 78 | foreach ($test->out as $testValue) { |
79 | 79 | foreach ($testValue as $o) { |
80 | 80 | $out .= $uiElements->boxFlexible($o['level'], $o['message']); |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | * <base_url>/copyright.php after deploying the software |
20 | 20 | */ |
21 | 21 | |
22 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
22 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
23 | 23 | |
24 | 24 | $auth = new \web\lib\admin\Authentication(); |
25 | 25 | $loggerInstance = new \core\common\Logging(); |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | $instId = $my_inst->identifier; |
35 | 35 | // delete the IdP and send user to enrollment |
36 | 36 | $my_inst->destroy(); |
37 | - $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP " . $instId); |
|
37 | + $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP ".$instId); |
|
38 | 38 | header("Location: overview_user.php"); |
39 | 39 | exit; |
40 | 40 | } |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | } |
51 | 51 | // flush all IdP attributes and send user to creation wizard |
52 | 52 | $my_inst->flushAttributes(); |
53 | - $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP starting over" . $instId); |
|
53 | + $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP starting over".$instId); |
|
54 | 54 | header("Location: edit_idp.php?inst_id=$instId&wizard=true"); |
55 | 55 | exit; |
56 | 56 | } |
@@ -72,17 +72,17 @@ discard block |
||
72 | 72 | } |
73 | 73 | |
74 | 74 | $inst_name = $my_inst->name; |
75 | -echo "<h1>" . sprintf(_("Submitted attributes for IdP '%s'"), $inst_name) . "</h1>"; |
|
75 | +echo "<h1>".sprintf(_("Submitted attributes for IdP '%s'"), $inst_name)."</h1>"; |
|
76 | 76 | echo "<table>"; |
77 | 77 | echo $optionParser->processSubmittedFields($my_inst, $_POST, $_FILES); |
78 | 78 | echo "</table>"; |
79 | 79 | |
80 | 80 | // delete cached logo, if present |
81 | -$dir = ROOT . '/web/downloads/logos/'; |
|
82 | -array_map('unlink', glob($dir . $my_inst->identifier . "_*.png")); |
|
81 | +$dir = ROOT.'/web/downloads/logos/'; |
|
82 | +array_map('unlink', glob($dir.$my_inst->identifier."_*.png")); |
|
83 | 83 | $loggerInstance->debug(4, "UNLINK from $dir\n"); |
84 | 84 | |
85 | -$loggerInstance->writeAudit($_SESSION['user'], "MOD", "IdP " . $my_inst->identifier . " - attributes changed"); |
|
85 | +$loggerInstance->writeAudit($_SESSION['user'], "MOD", "IdP ".$my_inst->identifier." - attributes changed"); |
|
86 | 86 | |
87 | 87 | // re-instantiate ourselves... profiles need fresh data |
88 | 88 | |
@@ -94,15 +94,15 @@ discard block |
||
94 | 94 | |
95 | 95 | if (isset(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) && count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0) { |
96 | 96 | foreach (CONFIG_CONFASSISTANT['CONSORTIUM']['ssid'] as $ssidname) { |
97 | - $ssids[] = $ssidname . " " . (isset(CONFIG_CONFASSISTANT['CONSORTIUM']['tkipsupport']) && CONFIG_CONFASSISTANT['CONSORTIUM']['tkipsupport'] === TRUE ? _("(WPA2/AES and WPA/TKIP)") : _("(WPA2/AES)") ); |
|
97 | + $ssids[] = $ssidname." ".(isset(CONFIG_CONFASSISTANT['CONSORTIUM']['tkipsupport']) && CONFIG_CONFASSISTANT['CONSORTIUM']['tkipsupport'] === TRUE ? _("(WPA2/AES and WPA/TKIP)") : _("(WPA2/AES)")); |
|
98 | 98 | } |
99 | 99 | } |
100 | 100 | |
101 | 101 | foreach ($my_inst->getAttributes("media:SSID_with_legacy") as $ssidname) { |
102 | - $ssids[] = $ssidname['value'] . " " . _("(WPA2/AES and WPA/TKIP)"); |
|
102 | + $ssids[] = $ssidname['value']." "._("(WPA2/AES and WPA/TKIP)"); |
|
103 | 103 | } |
104 | 104 | foreach ($my_inst->getAttributes("media:SSID") as $ssidname) { |
105 | - $ssids[] = $ssidname['value'] . " " . _("(WPA2/AES)"); |
|
105 | + $ssids[] = $ssidname['value']." "._("(WPA2/AES)"); |
|
106 | 106 | } |
107 | 107 | |
108 | 108 | echo "<table>"; |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | if (count($ssids) > 0) { |
111 | 111 | $printedlist = ""; |
112 | 112 | foreach ($ssids as $names) { |
113 | - $printedlist = $printedlist . "$names "; |
|
113 | + $printedlist = $printedlist."$names "; |
|
114 | 114 | } |
115 | 115 | echo $uiElements->boxOkay(sprintf(_("Your installers will configure the following SSIDs: <strong>%s</strong>"), $printedlist), _("SSIDs configured")); |
116 | 116 | } |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | // did we get an email address? then, show the silverbullet jumpstart button |
139 | 139 | // otherwise, issue a smartass comment |
140 | 140 | if (count($my_inst->getAttributes("support:email")) > 0) { |
141 | - echo "<form method='post' action='edit_silverbullet.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . sprintf(_("Continue to %s properties"), \core\ProfileSilverbullet::PRODUCTNAME) . "</button></form>"; |
|
141 | + echo "<form method='post' action='edit_silverbullet.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>".sprintf(_("Continue to %s properties"), \core\ProfileSilverbullet::PRODUCTNAME)."</button></form>"; |
|
142 | 142 | } else { |
143 | 143 | echo "<table>"; |
144 | 144 | echo $uiElements->boxError(sprintf(_("You did not submit an e-mail address. This is required for %s. Please go to the %s dashboard and edit your helpdesk settings to include a helpdesk e-mail address."), core\ProfileSilverbullet::PRODUCTNAME, $ui->nomenclatureInst), _("No support e-mail!")); |
@@ -146,9 +146,9 @@ discard block |
||
146 | 146 | } |
147 | 147 | } |
148 | 148 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_RADIUS'] == "LOCAL") { |
149 | - echo "<br/><form method='post' action='edit_profile.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . _("Continue to RADIUS/EAP profile definition") . "</button></form>"; |
|
149 | + echo "<br/><form method='post' action='edit_profile.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>"._("Continue to RADIUS/EAP profile definition")."</button></form>"; |
|
150 | 150 | } |
151 | 151 | } |
152 | -echo "<br/><form method='post' action='overview_idp.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . _("Continue to dashboard") . "</button></form>"; |
|
152 | +echo "<br/><form method='post' action='overview_idp.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>"._("Continue to dashboard")."</button></form>"; |
|
153 | 153 | |
154 | 154 | echo $deco->footer(); |
@@ -20,8 +20,8 @@ discard block |
||
20 | 20 | /* |
21 | 21 | * Class autoloader invocation, should be included prior to any other code at the entry points to the application |
22 | 22 | */ |
23 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
24 | -require_once dirname(dirname(dirname(__FILE__))) . "/core/phpqrcode.php"; |
|
23 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
24 | +require_once dirname(dirname(dirname(__FILE__)))."/core/phpqrcode.php"; |
|
25 | 25 | const QRCODE_PIXELS_PER_SYMBOL = 12; |
26 | 26 | |
27 | 27 | $auth = new \web\lib\admin\Authentication(); |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | $fed = new \core\Federation($inst->federation); |
56 | 56 | $allowSb = $fed->getAttributes("fed:silverbullet"); |
57 | 57 | if (count($allowSb) == 0) { |
58 | - throw new Exception("We were told to create a new SB profile, but this " . CONFIG_CONFASSISTANT['CONSORTIUM']['nomenclature_federation'] . " does not allow SB at all!"); |
|
58 | + throw new Exception("We were told to create a new SB profile, but this ".CONFIG_CONFASSISTANT['CONSORTIUM']['nomenclature_federation']." does not allow SB at all!"); |
|
59 | 59 | } |
60 | 60 | // okay, new SB profiles are allowed. |
61 | 61 | // but is there a support:email attribute on inst level? |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | // Create one. |
67 | 67 | $newProfile = $inst->newProfile(core\AbstractProfile::PROFILETYPE_SILVERBULLET); |
68 | 68 | // and modify the REQUEST_URI to add the new profile ID |
69 | - $_SERVER['REQUEST_URI'] = $_SERVER['REQUEST_URI'] . "&profile_id=" . $newProfile->identifier; |
|
69 | + $_SERVER['REQUEST_URI'] = $_SERVER['REQUEST_URI']."&profile_id=".$newProfile->identifier; |
|
70 | 70 | $_GET['profile_id'] = $newProfile->identifier; |
71 | 71 | $profile = $newProfile; |
72 | 72 | } else { |
@@ -134,7 +134,7 @@ discard block |
||
134 | 134 | break; |
135 | 135 | } |
136 | 136 | $properName = $validator->User($elements[0]); |
137 | - $properDate = new DateTime($elements[1] . " 00:00:00"); |
|
137 | + $properDate = new DateTime($elements[1]." 00:00:00"); |
|
138 | 138 | $numberOfActivations = $elements[2] ?? 1; |
139 | 139 | $number = $validator->integer($numberOfActivations); |
140 | 140 | if ($number === FALSE) { // invalid input received, default to sane |
@@ -227,18 +227,18 @@ discard block |
||
227 | 227 | // warn and ask for confirmation unless already confirmed |
228 | 228 | if (!isset($_POST['insecureconfirm']) || $_POST['insecureconfirm'] != "CONFIRM") { |
229 | 229 | echo $deco->pageheader(_("Insecure mail domain!"), "ADMIN-IDP-USERS"); |
230 | - echo "<p>" . sprintf(_("The mail domain of the mail address <strong>%s</strong> is not secure: some or all of the mail servers are not accepting encrypted connections (no consistent support for STARTTLS)."), $properEmail) . "</p>"; |
|
231 | - echo "<p>" . _("The invitation would need to be sent in cleartext across the internet, and can possibly be read and abused by anyone in transit.") . "</p>"; |
|
232 | - echo "<p>" . _("Do you want the system to send this mail anyway?") . "</p>"; |
|
230 | + echo "<p>".sprintf(_("The mail domain of the mail address <strong>%s</strong> is not secure: some or all of the mail servers are not accepting encrypted connections (no consistent support for STARTTLS)."), $properEmail)."</p>"; |
|
231 | + echo "<p>"._("The invitation would need to be sent in cleartext across the internet, and can possibly be read and abused by anyone in transit.")."</p>"; |
|
232 | + echo "<p>"._("Do you want the system to send this mail anyway?")."</p>"; |
|
233 | 233 | echo $formtext; |
234 | - echo "<button type='submit' class='delete'>" . _("DO NOT SEND") . "</button>"; |
|
234 | + echo "<button type='submit' class='delete'>"._("DO NOT SEND")."</button>"; |
|
235 | 235 | echo "</form>"; |
236 | 236 | echo $formtext; |
237 | - echo "<input type='hidden' name='command' value='" . \web\lib\common\FormElements::BUTTON_SENDINVITATIONMAILBYCAT . "'</>"; |
|
237 | + echo "<input type='hidden' name='command' value='".\web\lib\common\FormElements::BUTTON_SENDINVITATIONMAILBYCAT."'</>"; |
|
238 | 238 | echo "<input type='hidden' name='address' value='$properEmail'</>"; |
239 | - echo "<input type='hidden' name='token' value='" . $invitationObject->invitationTokenString . "'</>"; |
|
239 | + echo "<input type='hidden' name='token' value='".$invitationObject->invitationTokenString."'</>"; |
|
240 | 240 | echo "<input type='hidden' name='insecureconfirm' value='CONFIRM'/>"; |
241 | - echo "<button type='submit'>" . _("Send anyway.") . "</button>"; |
|
241 | + echo "<button type='submit'>"._("Send anyway.")."</button>"; |
|
242 | 242 | echo "</form>"; |
243 | 243 | echo $deco->footer(); |
244 | 244 | exit; |
@@ -288,7 +288,7 @@ discard block |
||
288 | 288 | $allUsers = $profile->listAllUsers(); |
289 | 289 | $activeUsers = $profile->listActiveUsers(); |
290 | 290 | |
291 | -echo $deco->defaultPagePrelude(_(sprintf(_('Managing %s users'), \core\ProfileSilverbullet::PRODUCTNAME ))); |
|
291 | +echo $deco->defaultPagePrelude(_(sprintf(_('Managing %s users'), \core\ProfileSilverbullet::PRODUCTNAME))); |
|
292 | 292 | ?> |
293 | 293 | <script src='js/option_expand.js' type='text/javascript'></script> |
294 | 294 | <script src='../external/jquery/jquery.js' type='text/javascript'></script> |
@@ -323,7 +323,7 @@ discard block |
||
323 | 323 | echo $deco->productHeader("ADMIN-IDP-USERS"); |
324 | 324 | ?> |
325 | 325 | <img src='../resources/images/icons/loading51.gif' id='spin' alt='loading...' style='position:absolute;left: 50%; top: 50%; transform: translate(-100px, -50px); display:none; z-index: 100;'> |
326 | - <?php echo $uiElements->instLevelInfoBoxes($inst);?> |
|
326 | + <?php echo $uiElements->instLevelInfoBoxes($inst); ?> |
|
327 | 327 | <div class='infobox'> |
328 | 328 | <h2><?php echo sprintf(_('Current %s users'), \core\ProfileSilverbullet::PRODUCTNAME); ?></h2> |
329 | 329 | <table> |
@@ -423,23 +423,23 @@ discard block |
||
423 | 423 | ?> |
424 | 424 | |
425 | 425 | <div class="sb-certificate-summary ca-summary" <?php echo $style; ?>> |
426 | - <div class="sb-certificate-details"><?php echo _("Device:") . " " . $display; ?> |
|
427 | - <br><?php echo _("Serial Number:") . " " . dechex($oneCert->serial); ?> |
|
428 | - <br><?php echo _("CN:") . " " . explode('@', $oneCert->username)[0] . "@…"; ?> |
|
429 | - <br><?php echo _("Expiry:") . " " . $oneCert->expiry; ?> |
|
430 | - <br><?php echo _("Issued:") . " " . $oneCert->issued; ?> |
|
426 | + <div class="sb-certificate-details"><?php echo _("Device:")." ".$display; ?> |
|
427 | + <br><?php echo _("Serial Number:")." ".dechex($oneCert->serial); ?> |
|
428 | + <br><?php echo _("CN:")." ".explode('@', $oneCert->username)[0]."@…"; ?> |
|
429 | + <br><?php echo _("Expiry:")." ".$oneCert->expiry; ?> |
|
430 | + <br><?php echo _("Issued:")." ".$oneCert->issued; ?> |
|
431 | 431 | </div> |
432 | 432 | <div style="text-align:right;padding-top: 5px; <?php echo $buttonStyle; ?>"> |
433 | 433 | <?php |
434 | 434 | if ($buttonText == "") { |
435 | 435 | echo "$formtext" |
436 | - . "<input type='hidden' name='certSerial' value='" . $oneCert->serial . "'/>" |
|
437 | - . "<input type='hidden' name='certAlgo' value='" . $oneCert->ca_type . "'/>" |
|
436 | + . "<input type='hidden' name='certSerial' value='".$oneCert->serial."'/>" |
|
437 | + . "<input type='hidden' name='certAlgo' value='".$oneCert->ca_type."'/>" |
|
438 | 438 | . "<button type='submit' " |
439 | 439 | . "name='command' " |
440 | - . "value='" . \web\lib\common\FormElements::BUTTON_REVOKECREDENTIAL . "' " |
|
440 | + . "value='".\web\lib\common\FormElements::BUTTON_REVOKECREDENTIAL."' " |
|
441 | 441 | . "class='delete' " |
442 | - . "onclick='return confirm(\"" . sprintf(_("The device in question will stop functioning with %s. The revocation cannot be undone. Are you sure you want to do this?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) . "\")'>" |
|
442 | + . "onclick='return confirm(\"".sprintf(_("The device in question will stop functioning with %s. The revocation cannot be undone. Are you sure you want to do this?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'])."\")'>" |
|
443 | 443 | . _("Revoke") |
444 | 444 | . "</button>" |
445 | 445 | . "</form>"; |
@@ -465,38 +465,38 @@ discard block |
||
465 | 465 | $tokenHtmlBuffer .= "<tr class='sb-certificate-row'><td></td>"; |
466 | 466 | $jsEncodedBody = str_replace('\n', '%0D%0A', str_replace('"', '', json_encode($invitationObject->invitationMailBody()))); |
467 | 467 | $tokenHtmlBuffer .= "<td>"; |
468 | - $tokenHtmlBuffer .= sprintf(_("The invitation token %s is ready for sending! Choose how to send it:"),"<input type='text' readonly='readonly' style='background-color:lightgrey;' size='60' value='" . $invitationObject->link() . "' name='token' class='identifiedtokenarea-" . $invitationObject->identifier . "'>(…)<br/>"); |
|
468 | + $tokenHtmlBuffer .= sprintf(_("The invitation token %s is ready for sending! Choose how to send it:"), "<input type='text' readonly='readonly' style='background-color:lightgrey;' size='60' value='".$invitationObject->link()."' name='token' class='identifiedtokenarea-".$invitationObject->identifier."'>(…)<br/>"); |
|
469 | 469 | $tokenHtmlBuffer .= "<table> |
470 | 470 | <tr><td style='vertical-align:bottom;'>"._("E-Mail:")."</td><td> |
471 | 471 | $formtext |
472 | - <input type='hidden' value='" . $invitationObject->invitationTokenString . "' name='token'><br/> |
|
472 | + <input type='hidden' value='".$invitationObject->invitationTokenString."' name='token'><br/> |
|
473 | 473 | <input type='text' name='address' id='address-$invitationObject->identifier'/> |
474 | - <button type='button' onclick='window.location=\"mailto:\"+document.getElementById(\"address-$invitationObject->identifier\").value+\"?subject=" . $invitationObject->invitationMailSubject() . "&body=$jsEncodedBody\"; return false;'>" . _("Local mail client") . "</button> |
|
475 | - <button type='submit' name='command' onclick='document.getElementById(\"spin\").style.display =\"block\"' value='" . \web\lib\common\FormElements::BUTTON_SENDINVITATIONMAILBYCAT . "'>"._("Send with CAT")."</button> |
|
474 | + <button type='button' onclick='window.location=\"mailto:\"+document.getElementById(\"address-$invitationObject->identifier\").value+\"?subject=".$invitationObject->invitationMailSubject()."&body=$jsEncodedBody\"; return false;'>"._("Local mail client")."</button> |
|
475 | + <button type='submit' name='command' onclick='document.getElementById(\"spin\").style.display =\"block\"' value='" . \web\lib\common\FormElements::BUTTON_SENDINVITATIONMAILBYCAT."'>"._("Send with CAT")."</button> |
|
476 | 476 | </form> |
477 | 477 | </td></tr> |
478 | 478 | <tr><td style='vertical-align:bottom;'>"._("SMS:")."</td><td> |
479 | 479 | $formtext |
480 | - <input type='hidden' value='" . $invitationObject->invitationTokenString . "' name='token'><br/> |
|
480 | + <input type='hidden' value='".$invitationObject->invitationTokenString."' name='token'><br/> |
|
481 | 481 | <input type='text' name='smsnumber' /> |
482 | - <button type='submit' name='command' value='" . \web\lib\common\FormElements::BUTTON_SENDINVITATIONSMS . "'>" . _("Send in SMS...") . "</button> |
|
482 | + <button type='submit' name='command' value='" . \web\lib\common\FormElements::BUTTON_SENDINVITATIONSMS."'>"._("Send in SMS...")."</button> |
|
483 | 483 | </form> |
484 | 484 | </td></tr> |
485 | 485 | <tr><td style='vertical-align:bottom;'>"._("Manual:")."</td><td> |
486 | - <button type='button' class='clipboardButton' onclick='clipboardCopy(" . $invitationObject->identifier . ");'>" . _("Copy to Clipboard") . "</button> |
|
486 | + <button type='button' class='clipboardButton' onclick='clipboardCopy(" . $invitationObject->identifier.");'>"._("Copy to Clipboard")."</button> |
|
487 | 487 | <form style='display:inline-block;' method='post' action='inc/displayQRcode.inc.php' onsubmit='popupQRWindow(this); return false;' accept-charset='UTF-8'> |
488 | - <input type='hidden' value='" . $invitationObject->invitationTokenString . "' name='token'><br/> |
|
489 | - <button type='submit'>" . _("Display QR code") . "</button> |
|
488 | + <input type='hidden' value='" . $invitationObject->invitationTokenString."' name='token'><br/> |
|
489 | + <button type='submit'>" . _("Display QR code")."</button> |
|
490 | 490 | </form> |
491 | 491 | </td></tr> |
492 | 492 | |
493 | 493 | </table> |
494 | 494 | </td>"; |
495 | - $tokenHtmlBuffer .= "<td>" . _("Expiry Date:") . " " . $invitationObject->expiry . " UTC<br>" . _("Activations remaining:") . " " . sprintf(_("%d of %d"), $invitationObject->activationsRemaining, $invitationObject->activationsTotal) . "</td>"; |
|
495 | + $tokenHtmlBuffer .= "<td>"._("Expiry Date:")." ".$invitationObject->expiry." UTC<br>"._("Activations remaining:")." ".sprintf(_("%d of %d"), $invitationObject->activationsRemaining, $invitationObject->activationsTotal)."</td>"; |
|
496 | 496 | $tokenHtmlBuffer .= "<td>" |
497 | 497 | . $formtext |
498 | - . "<input type='hidden' name='invitationtoken' value='" . $invitationObject->invitationTokenString . "'/>" |
|
499 | - . "<button type='submit' name='command' value='" . \web\lib\common\FormElements::BUTTON_REVOKEINVITATION . "' class='delete'>"._("Revoke"). "</button></form>" |
|
498 | + . "<input type='hidden' name='invitationtoken' value='".$invitationObject->invitationTokenString."'/>" |
|
499 | + . "<button type='submit' name='command' value='".\web\lib\common\FormElements::BUTTON_REVOKEINVITATION."' class='delete'>"._("Revoke")."</button></form>" |
|
500 | 500 | . "</td></tr>"; |
501 | 501 | break; |
502 | 502 | case core\SilverbulletInvitation::SB_TOKENSTATUS_EXPIRED: |
@@ -518,7 +518,7 @@ discard block |
||
518 | 518 | <span><input type="text" maxlength="19" class="sb-date-picker" name="userexpiry" value="<?php echo $profile->getUserExpiryDate($oneUserId); ?>"> (UTC)</span> |
519 | 519 | </div> |
520 | 520 | <input type="hidden" name="userid" value="<?php echo $oneUserId; ?>"/> |
521 | - <button type="submit" name="command" value="<?php echo \web\lib\common\FormElements::BUTTON_CHANGEUSEREXPIRY ?>"><?php echo _("Update");?></button> |
|
521 | + <button type="submit" name="command" value="<?php echo \web\lib\common\FormElements::BUTTON_CHANGEUSEREXPIRY ?>"><?php echo _("Update"); ?></button> |
|
522 | 522 | </form> |
523 | 523 | </td> |
524 | 524 | <td> |
@@ -526,13 +526,13 @@ discard block |
||
526 | 526 | <?php |
527 | 527 | if ($hasOnePendingInvite || count($validCerts) > 0) { |
528 | 528 | $deletionText = sprintf(_("All of the currently active devices will stop functioning with %s. This cannot be undone. While the user can be re-activated later, they will then need to be re-provisioned with new invitation tokens. Are you sure you want to do this?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']); |
529 | - echo $formtext . " |
|
529 | + echo $formtext." |
|
530 | 530 | <input type='hidden' name='userid' value='$oneUserId'/> |
531 | 531 | <button type='submit' " |
532 | 532 | . "name='command' " |
533 | - . "value='" . \web\lib\common\FormElements::BUTTON_DEACTIVATEUSER . "' " |
|
533 | + . "value='".\web\lib\common\FormElements::BUTTON_DEACTIVATEUSER."' " |
|
534 | 534 | . "class='delete' " |
535 | - . ( count($validCerts) > 0 ? "onclick='return confirm(\"".$deletionText."\")' " : "" ) |
|
535 | + . (count($validCerts) > 0 ? "onclick='return confirm(\"".$deletionText."\")' " : "") |
|
536 | 536 | . ">" |
537 | 537 | . _("Deactivate User") |
538 | 538 | . "</button> |
@@ -571,13 +571,13 @@ discard block |
||
571 | 571 | . ' If all accounts shown as active above are indeed still valid, please check the box below and push "Save".' |
572 | 572 | . ' If any of the accounts are stale, please deactivate them by pushing the corresponding button before doing this.'), CONFIG_CONFASSISTANT['SILVERBULLET']['gracetime'] ?? core\ProfileSilverbullet::SB_ACKNOWLEDGEMENT_REQUIRED_DAYS); |
573 | 573 | |
574 | - echo $formtext . "<div style='padding-bottom: 20px;'>" |
|
574 | + echo $formtext."<div style='padding-bottom: 20px;'>" |
|
575 | 575 | . " |
576 | 576 | <p>$acknowledgeText</p> |
577 | 577 | <input type='checkbox' name='acknowledge' value='true'> |
578 | - <label>" . sprintf(_("I have verified that all configured users are still eligible for %s."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) . "</label> |
|
578 | + <label>".sprintf(_("I have verified that all configured users are still eligible for %s."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'])."</label> |
|
579 | 579 | </div> |
580 | - <button type='submit' name='command' value='" . \web\lib\common\FormElements::BUTTON_ACKUSERELIGIBILITY . "'>"._("Save")."</button></form>"; |
|
580 | + <button type='submit' name='command' value='" . \web\lib\common\FormElements::BUTTON_ACKUSERELIGIBILITY."'>"._("Save")."</button></form>"; |
|
581 | 581 | } |
582 | 582 | ?> |
583 | 583 | </div> |
@@ -654,7 +654,7 @@ discard block |
||
654 | 654 | |
655 | 655 | <form action="overview_idp.php?inst_id=<?php echo $inst->identifier; ?>" method="POST"> |
656 | 656 | <p> |
657 | - <button type='submit' name='submitbutton' value="nomatter"><?php echo sprintf(_("Back to %s page"),$uiElements->nomenclatureInst);?></button> |
|
657 | + <button type='submit' name='submitbutton' value="nomatter"><?php echo sprintf(_("Back to %s page"), $uiElements->nomenclatureInst); ?></button> |
|
658 | 658 | </p> |
659 | 659 | </form> |
660 | 660 | <?php |
@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | |
22 | 22 | namespace core; |
23 | 23 | |
24 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
24 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
25 | 25 | |
26 | 26 | $instMgmt = new \core\UserManagement(); |
27 | 27 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | <?php echo $uiElements->infoblock($user->getAttributes(), "user", "User"); ?> |
52 | 52 | <tr> |
53 | 53 | <td> |
54 | -<?php echo "" . _("Unique Identifier") ?> |
|
54 | +<?php echo ""._("Unique Identifier") ?> |
|
55 | 55 | </td> |
56 | 56 | <td> |
57 | 57 | </td> |
@@ -64,14 +64,14 @@ discard block |
||
64 | 64 | <div> |
65 | 65 | <?php |
66 | 66 | if (CONFIG['DB']['USER']['readonly'] === FALSE) { |
67 | - echo "<a href='edit_user.php'><button>" . _("Edit User Details") . "</button></a>"; |
|
67 | + echo "<a href='edit_user.php'><button>"._("Edit User Details")."</button></a>"; |
|
68 | 68 | } |
69 | 69 | |
70 | 70 | if ($user->isFederationAdmin()) { |
71 | - echo "<form action='overview_federation.php' method='GET' accept-charset='UTF-8'><button type='submit'>" . sprintf(_('Click here for %s management tasks'), $uiElements->nomenclatureFed) . "</button></form>"; |
|
71 | + echo "<form action='overview_federation.php' method='GET' accept-charset='UTF-8'><button type='submit'>".sprintf(_('Click here for %s management tasks'), $uiElements->nomenclatureFed)."</button></form>"; |
|
72 | 72 | } |
73 | 73 | if ($user->isSuperadmin()) { |
74 | - echo "<form action='112365365321.php' method='GET' accept-charset='UTF-8'><button type='submit'>" . _('Click here to access the superadmin page') . "</button></form>"; |
|
74 | + echo "<form action='112365365321.php' method='GET' accept-charset='UTF-8'><button type='submit'>"._('Click here to access the superadmin page')."</button></form>"; |
|
75 | 75 | } |
76 | 76 | ?> |
77 | 77 | </div> |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
84 | 84 | $target = "https://wiki.geant.org/x/SSNwBg"; // Managed IdP manual |
85 | 85 | } |
86 | - $helptext = "<h3 style='display:inline;'>" . sprintf(_("(Need help? Refer to the <a href='%s'>%s administrator manual</a>)"), $target, $uiElements->nomenclatureInst) . "</h3>"; |
|
86 | + $helptext = "<h3 style='display:inline;'>".sprintf(_("(Need help? Refer to the <a href='%s'>%s administrator manual</a>)"), $target, $uiElements->nomenclatureInst)."</h3>"; |
|
87 | 87 | } else { |
88 | 88 | $helptext = ""; |
89 | 89 | } |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | // we need to run the Federation constructor |
93 | 93 | $cat = new \core\CAT; |
94 | 94 | /// first parameter: number of Identity Providers; second param is the literal configured term for 'Identity Provider' (you may or may not be able to add a plural suffix for your locale) |
95 | - echo "<h2>" . sprintf(ngettext("You are managing the following <span style='display:none'>%d </span>%s:", "You are managing the following <strong>%d</strong> %s:", sizeof($hasInst)), sizeof($hasInst), $uiElements->nomenclatureInst) . "</h2>"; |
|
95 | + echo "<h2>".sprintf(ngettext("You are managing the following <span style='display:none'>%d </span>%s:", "You are managing the following <strong>%d</strong> %s:", sizeof($hasInst)), sizeof($hasInst), $uiElements->nomenclatureInst)."</h2>"; |
|
96 | 96 | $instlist = []; |
97 | 97 | $my_idps = []; |
98 | 98 | $myFeds = []; |
@@ -114,10 +114,10 @@ discard block |
||
114 | 114 | $country[$key] = $row['country']; |
115 | 115 | $name[$key] = $row['name']; |
116 | 116 | } |
117 | - echo "<tr><th>" . sprintf(_("%s Name"), $uiElements->nomenclatureInst) . "</th><th>" . sprintf(_("Other admins of this %s"), $uiElements->nomenclatureInst) . "</th><th>" . ( CONFIG['DB']['INST']['readonly'] === FALSE ? _("Administrator Management") : "") . "</th></tr>"; |
|
117 | + echo "<tr><th>".sprintf(_("%s Name"), $uiElements->nomenclatureInst)."</th><th>".sprintf(_("Other admins of this %s"), $uiElements->nomenclatureInst)."</th><th>".(CONFIG['DB']['INST']['readonly'] === FALSE ? _("Administrator Management") : "")."</th></tr>"; |
|
118 | 118 | foreach ($myFeds as $fed_id => $fed_name) { |
119 | 119 | /// nomenclature 'fed', fed name, nomenclature 'inst' |
120 | - echo "<tr><td colspan='3'><strong>" . sprintf(_("%s %s: %s list"), $uiElements->nomenclatureFed, $fed_name, $uiElements->nomenclatureInst) . "</strong></td></tr>"; |
|
120 | + echo "<tr><td colspan='3'><strong>".sprintf(_("%s %s: %s list"), $uiElements->nomenclatureFed, $fed_name, $uiElements->nomenclatureInst)."</strong></td></tr>"; |
|
121 | 121 | |
122 | 122 | $fed_idps = $my_idps[$fed_id]; |
123 | 123 | asort($fed_idps); |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | $oneinst = $instlist[$index]; |
126 | 126 | $the_inst = $oneinst['object']; |
127 | 127 | |
128 | - echo "<tr><td><a href='overview_idp.php?inst_id=$the_inst->identifier'>" . $oneinst['name'] . "</a></td><td>"; |
|
128 | + echo "<tr><td><a href='overview_idp.php?inst_id=$the_inst->identifier'>".$oneinst['name']."</a></td><td>"; |
|
129 | 129 | echo "<input type='hidden' name='inst' value='$the_inst->identifier'>"; |
130 | 130 | $admins = $the_inst->listOwners(); |
131 | 131 | $blessedUser = FALSE; |
@@ -134,7 +134,7 @@ discard block |
||
134 | 134 | $coadmin = new \core\User($username['ID']); |
135 | 135 | $coadmin_name = $coadmin->getAttributes('user:realname'); |
136 | 136 | if (count($coadmin_name) > 0) { |
137 | - echo $coadmin_name[0]['value'] . "<br/>"; |
|
137 | + echo $coadmin_name[0]['value']."<br/>"; |
|
138 | 138 | unset($admins[$number]); |
139 | 139 | } |
140 | 140 | } else { // don't list self |
@@ -150,25 +150,25 @@ discard block |
||
150 | 150 | } |
151 | 151 | echo "</td><td>"; |
152 | 152 | if ($blessedUser && CONFIG['DB']['INST']['readonly'] === FALSE) { |
153 | - echo "<div style='white-space: nowrap;'><form method='post' action='inc/manageAdmins.inc.php?inst_id=" . $the_inst->identifier . "' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'><button type='submit'>" . _("Add/Remove Administrators") . "</button></form></div>"; |
|
153 | + echo "<div style='white-space: nowrap;'><form method='post' action='inc/manageAdmins.inc.php?inst_id=".$the_inst->identifier."' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'><button type='submit'>"._("Add/Remove Administrators")."</button></form></div>"; |
|
154 | 154 | } |
155 | 155 | echo "</td></tr>"; |
156 | 156 | } |
157 | 157 | } |
158 | 158 | echo "</table>"; |
159 | 159 | } else { |
160 | - echo "<h2>" . sprintf(_("You are not managing any %s."), $uiElements->nomenclatureInst) . "</h2>"; |
|
160 | + echo "<h2>".sprintf(_("You are not managing any %s."), $uiElements->nomenclatureInst)."</h2>"; |
|
161 | 161 | } |
162 | 162 | if (CONFIG['DB']['INST']['readonly'] === FALSE) { |
163 | 163 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['selfservice_registration'] === NULL) { |
164 | - echo "<p>" . sprintf(_("Please ask your %s administrator to invite you to become an %s administrator."), $uiElements->nomenclatureFed, $uiElements->nomenclatureInst) . "</p>"; |
|
164 | + echo "<p>".sprintf(_("Please ask your %s administrator to invite you to become an %s administrator."), $uiElements->nomenclatureFed, $uiElements->nomenclatureInst)."</p>"; |
|
165 | 165 | echo "<hr/> |
166 | 166 | <div style='white-space: nowrap;'> |
167 | 167 | <form action='action_enrollment.php' method='get' accept-charset='UTF-8'>" . |
168 | - sprintf(_("Did you receive an invitation token to manage an %s? Please paste it here:"), $uiElements->nomenclatureInst) . |
|
168 | + sprintf(_("Did you receive an invitation token to manage an %s? Please paste it here:"), $uiElements->nomenclatureInst). |
|
169 | 169 | " <input type='text' id='token' name='token'/> |
170 | 170 | <button type='submit'>" . |
171 | - _("Go!") . " |
|
171 | + _("Go!")." |
|
172 | 172 | </button> |
173 | 173 | </form> |
174 | 174 | </div>"; |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | <div style='white-space: nowrap;'> |
178 | 178 | <form action='action_enrollment.php' method='get'><button type='submit' accept-charset='UTF-8'> |
179 | 179 | <input type='hidden' id='token' name='token' value='SELF-REGISTER'/>" . |
180 | - sprintf(_("New %s Registration"), $uiElements->nomenclatureInst) . " |
|
180 | + sprintf(_("New %s Registration"), $uiElements->nomenclatureInst)." |
|
181 | 181 | </button> |
182 | 182 | </form> |
183 | 183 | </div>"; |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | * <base_url>/copyright.php after deploying the software |
20 | 20 | */ |
21 | 21 | |
22 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
22 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
23 | 23 | |
24 | 24 | $auth = new \web\lib\admin\Authentication(); |
25 | 25 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -94,12 +94,12 @@ discard block |
||
94 | 94 | </table> |
95 | 95 | </div> |
96 | 96 | <?php |
97 | - echo "<form enctype='multipart/form-data' action='edit_idp_result.php?inst_id=$my_inst->identifier" . ($wizardStyle ? "&wizard=true" : "") . "' method='post' accept-charset='UTF-8'> |
|
98 | - <input type='hidden' name='MAX_FILE_SIZE' value='" . CONFIG['MAX_UPLOAD_SIZE'] . "'>"; |
|
97 | + echo "<form enctype='multipart/form-data' action='edit_idp_result.php?inst_id=$my_inst->identifier".($wizardStyle ? "&wizard=true" : "")."' method='post' accept-charset='UTF-8'> |
|
98 | + <input type='hidden' name='MAX_FILE_SIZE' value='" . CONFIG['MAX_UPLOAD_SIZE']."'>"; |
|
99 | 99 | |
100 | 100 | if ($wizardStyle) { |
101 | - echo "<p>" . |
|
102 | - sprintf(_("Hello, newcomer. The %s is new to us. This wizard will ask you several questions about it, so that we can generate beautiful profiles for you in the end. All of the information below is optional, but it is important to fill out as many fields as possible for the benefit of your end users."), $uiElements->nomenclatureInst) . "</p>"; |
|
101 | + echo "<p>". |
|
102 | + sprintf(_("Hello, newcomer. The %s is new to us. This wizard will ask you several questions about it, so that we can generate beautiful profiles for you in the end. All of the information below is optional, but it is important to fill out as many fields as possible for the benefit of your end users."), $uiElements->nomenclatureInst)."</p>"; |
|
103 | 103 | } |
104 | 104 | $optionDisplay = new web\lib\admin\OptionDisplay($idpoptions, "IdP"); |
105 | 105 | ?> |
@@ -107,11 +107,11 @@ discard block |
||
107 | 107 | <legend><strong><?php echo _("General Information"); ?></strong></legend> |
108 | 108 | <?php |
109 | 109 | if ($wizardStyle) { |
110 | - echo "<p>" . |
|
111 | - _("Some properties are valid across all deployment profiles. This is the place where you can describe those properties in a fine-grained way. The solicited information is used as follows:") . "</p> |
|
110 | + echo "<p>". |
|
111 | + _("Some properties are valid across all deployment profiles. This is the place where you can describe those properties in a fine-grained way. The solicited information is used as follows:")."</p> |
|
112 | 112 | <ul> |
113 | - <li>" . _("<strong>Logo</strong>: When you submit a logo, we will embed this logo into all installers where a custom logo is possible. We accept any image format, but for best results, we suggest SVG. If you don't upload a logo, we will use the generic logo instead (see top-right corner of this page).") . "</li> |
|
114 | - <li>" . sprintf(_("<strong>Name</strong>: The %s may have names in multiple languages. It is recommended to always populate at least the 'default/other' language, as it is used as a fallback if the system does not have a name in the exact language the user requests a download in."),$uiElements->nomenclatureInst) . "</li>"; |
|
113 | + <li>" . _("<strong>Logo</strong>: When you submit a logo, we will embed this logo into all installers where a custom logo is possible. We accept any image format, but for best results, we suggest SVG. If you don't upload a logo, we will use the generic logo instead (see top-right corner of this page).")."</li> |
|
114 | + <li>" . sprintf(_("<strong>Name</strong>: The %s may have names in multiple languages. It is recommended to always populate at least the 'default/other' language, as it is used as a fallback if the system does not have a name in the exact language the user requests a download in."), $uiElements->nomenclatureInst)."</li>"; |
|
115 | 115 | echo "</ul>"; |
116 | 116 | } |
117 | 117 | echo $optionDisplay->prefilledOptionTable("general"); |
@@ -125,47 +125,47 @@ discard block |
||
125 | 125 | <legend><strong><?php echo _("Media Properties"); ?></strong></legend> |
126 | 126 | <?php |
127 | 127 | if ($wizardStyle) { |
128 | - echo "<p>" . |
|
129 | - sprintf(_("In this section, you define on which media %s should be configured on user devices."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) . "</p> |
|
128 | + echo "<p>". |
|
129 | + sprintf(_("In this section, you define on which media %s should be configured on user devices."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'])."</p> |
|
130 | 130 | <ul>"; |
131 | 131 | echo "<li>"; |
132 | - echo "<strong>" . ( count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0 ? _("Additional SSIDs:") : _("SSIDs:")) . " </strong>"; |
|
132 | + echo "<strong>".(count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0 ? _("Additional SSIDs:") : _("SSIDs:"))." </strong>"; |
|
133 | 133 | if (count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0) { |
134 | 134 | $ssidlist = ""; |
135 | 135 | foreach (CONFIG_CONFASSISTANT['CONSORTIUM']['ssid'] as $ssid) { |
136 | - $ssidlist .= ", '<strong>" . $ssid . "</strong>'"; |
|
136 | + $ssidlist .= ", '<strong>".$ssid."</strong>'"; |
|
137 | 137 | } |
138 | 138 | $ssidlist = substr($ssidlist, 2); |
139 | 139 | echo sprintf(ngettext("We will always configure this SSID for WPA2/AES: %s.", "We will always configure these SSIDs for WPA2/AES: %s.", count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid'])), $ssidlist); |
140 | 140 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['tkipsupport']) { |
141 | - echo " " . _("They will also be configured for WPA/TKIP if the device supports multiple encryption types."); |
|
141 | + echo " "._("They will also be configured for WPA/TKIP if the device supports multiple encryption types."); |
|
142 | 142 | } |
143 | - echo "<br/>" . sprintf(_("It is also possible to define custom additional SSIDs with the options '%s' and '%s' below."), $uiElements->displayName("media:SSID"), $uiElements->displayName("media:SSID_with_legacy")); |
|
143 | + echo "<br/>".sprintf(_("It is also possible to define custom additional SSIDs with the options '%s' and '%s' below."), $uiElements->displayName("media:SSID"), $uiElements->displayName("media:SSID_with_legacy")); |
|
144 | 144 | } else { |
145 | 145 | echo _("Please configure which SSIDs should be configured in the installers."); |
146 | 146 | } |
147 | - echo " " . _("By default, we will only configure the SSIDs with WPA2/AES encryption. By using the '(with WPA/TKIP)' option you can specify that we should include legacy support for WPA/TKIP where possible."); |
|
147 | + echo " "._("By default, we will only configure the SSIDs with WPA2/AES encryption. By using the '(with WPA/TKIP)' option you can specify that we should include legacy support for WPA/TKIP where possible."); |
|
148 | 148 | echo "</li>"; |
149 | 149 | |
150 | 150 | echo "<li>"; |
151 | - echo "<strong>" . ( count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0 ? _("Additional Hotspot 2.0 / Passpoint Consortia:") : _("Hotspot 2.0 / Passpoint Consortia:")) . " </strong>"; |
|
151 | + echo "<strong>".(count(CONFIG_CONFASSISTANT['CONSORTIUM']['ssid']) > 0 ? _("Additional Hotspot 2.0 / Passpoint Consortia:") : _("Hotspot 2.0 / Passpoint Consortia:"))." </strong>"; |
|
152 | 152 | if (count(CONFIG_CONFASSISTANT['CONSORTIUM']['interworking-consortium-oi']) > 0) { |
153 | 153 | $consortiumlist = ""; |
154 | 154 | foreach (CONFIG_CONFASSISTANT['CONSORTIUM']['interworking-consortium-oi'] as $oi) { |
155 | - $consortiumlist .= ", '<strong>" . $oi . "</strong>'"; |
|
155 | + $consortiumlist .= ", '<strong>".$oi."</strong>'"; |
|
156 | 156 | } |
157 | 157 | $consortiumlist = substr($consortiumlist, 2); |
158 | 158 | echo sprintf(ngettext("We will always configure this Consortium OI: %s.", "We will always configure these Consortium OIs: %s.", count(CONFIG_CONFASSISTANT['CONSORTIUM']['interworking-consortium-oi'])), $consortiumlist); |
159 | 159 | |
160 | - echo "<br/>" . sprintf(_("It is also possible to define custom additional OIs with the option '%s' below."), $uiElements->displayName("media:consortium_OI")); |
|
160 | + echo "<br/>".sprintf(_("It is also possible to define custom additional OIs with the option '%s' below."), $uiElements->displayName("media:consortium_OI")); |
|
161 | 161 | } else { |
162 | 162 | echo _("Please configure which Consortium OIs should be configured in the installers."); |
163 | 163 | } |
164 | 164 | echo "</li>"; |
165 | - echo "<li><strong>" . _("Support for wired IEEE 802.1X:") . " </strong>" |
|
166 | - . _("If you want to configure your users' devices with IEEE 802.1X support for wired ethernet, please check the corresponding box. Note that this makes the installation process a bit more difficult on some platforms (Windows: needs administrator privileges; Apple: attempting to install a profile with wired support on a device without an active wired ethernet card will fail).") . |
|
165 | + echo "<li><strong>"._("Support for wired IEEE 802.1X:")." </strong>" |
|
166 | + . _("If you want to configure your users' devices with IEEE 802.1X support for wired ethernet, please check the corresponding box. Note that this makes the installation process a bit more difficult on some platforms (Windows: needs administrator privileges; Apple: attempting to install a profile with wired support on a device without an active wired ethernet card will fail)."). |
|
167 | 167 | "</li>"; |
168 | - echo "<li><strong>" . _("Removal of bootstrap/onboarding SSIDs:") . " </strong>" |
|
168 | + echo "<li><strong>"._("Removal of bootstrap/onboarding SSIDs:")." </strong>" |
|
169 | 169 | . _("If you use a captive portal to distribute configurations, you may want to unconfigure/disable that SSID after the bootstrap process. With this option, the SSID will either be removed, or be defined as 'Only connect manually'.") |
170 | 170 | . "</li>"; |
171 | 171 | echo "</ul>"; |
@@ -181,16 +181,16 @@ discard block |
||
181 | 181 | echo "<p>"._("This section can be used to upload specific Terms of Use for your users and to display details of how your users can reach your local helpdesk.")."</p>"; |
182 | 182 | |
183 | 183 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_RADIUS'] == "LOCAL") { |
184 | - echo "<p>" . |
|
184 | + echo "<p>". |
|
185 | 185 | |
186 | - sprintf(_("Do you provide helpdesk services for your users? If so, it would be nice if you would tell us the pointers to this helpdesk."),$uiElements->nomenclatureInst) . "</p>" . |
|
187 | - "<p>" . |
|
188 | - _("If you enter a value here, it will be added to the installers for all your users, and will be displayed on the download page. If you operate separate helpdesks for different user groups (we call this 'profiles') specify per-profile helpdesk information later in this wizard. If you operate no help desk at all, just leave these fields empty.") . "</p>"; |
|
186 | + sprintf(_("Do you provide helpdesk services for your users? If so, it would be nice if you would tell us the pointers to this helpdesk."), $uiElements->nomenclatureInst)."</p>". |
|
187 | + "<p>". |
|
188 | + _("If you enter a value here, it will be added to the installers for all your users, and will be displayed on the download page. If you operate separate helpdesks for different user groups (we call this 'profiles') specify per-profile helpdesk information later in this wizard. If you operate no help desk at all, just leave these fields empty.")."</p>"; |
|
189 | 189 | if (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
190 | - echo "<p>" . sprintf(_("For %s deployments, providing at least a local e-mail contact is required."), core\ProfileSilverbullet::PRODUCTNAME) ." " . _("This is the contact point for your end users' level 1 support.") . "</p>"; |
|
190 | + echo "<p>".sprintf(_("For %s deployments, providing at least a local e-mail contact is required."), core\ProfileSilverbullet::PRODUCTNAME)." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
191 | 191 | } |
192 | 192 | } elseif (CONFIG['FUNCTIONALITY_LOCATIONS']['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
193 | - echo "<p>". _("Providing at least a local support e-mail contact is required.")." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
193 | + echo "<p>"._("Providing at least a local support e-mail contact is required.")." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
194 | 194 | } |
195 | 195 | |
196 | 196 | } |
@@ -200,8 +200,8 @@ discard block |
||
200 | 200 | <button type='button' class='newoption' onclick='getXML("support")'><?php echo _("Add new option"); ?></button></fieldset> |
201 | 201 | <?php |
202 | 202 | if ($wizardStyle) { |
203 | - echo "<p>" . sprintf(_("When you are sure that everything is correct, please click on %sContinue ...%s"), "<button type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_CONTINUE . "'>", "</button>") . "</p></form>"; |
|
203 | + echo "<p>".sprintf(_("When you are sure that everything is correct, please click on %sContinue ...%s"), "<button type='submit' name='submitbutton' value='".web\lib\common\FormElements::BUTTON_CONTINUE."'>", "</button>")."</p></form>"; |
|
204 | 204 | } else { |
205 | - echo "<div><button type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_SAVE . "'>" . _("Save data") . "</button> <button type='button' class='delete' name='abortbutton' value='abort' onclick='javascript:window.location = \"overview_idp.php?inst_id=$my_inst->identifier\"'>" . _("Discard changes") . "</button></div></form>"; |
|
205 | + echo "<div><button type='submit' name='submitbutton' value='".web\lib\common\FormElements::BUTTON_SAVE."'>"._("Save data")."</button> <button type='button' class='delete' name='abortbutton' value='abort' onclick='javascript:window.location = \"overview_idp.php?inst_id=$my_inst->identifier\"'>"._("Discard changes")."</button></div></form>"; |
|
206 | 206 | } |
207 | 207 | echo $deco->footer(); |