@@ -68,13 +68,12 @@ |
||
| 68 | 68 | |
| 69 | 69 | <?php |
| 70 | 70 | /** |
| 71 | - * The OS object holds operating system descriptions |
|
| 72 | - * @param name is the main title |
|
| 73 | - * @param subtitle - the subtitle |
|
| 74 | - * @param path - the path to the scriin-dump image |
|
| 75 | - * @param signed - if true show information that the module is signed |
|
| 76 | - |
|
| 77 | -*/ |
|
| 71 | + * The OS object holds operating system descriptions |
|
| 72 | + * @param name is the main title |
|
| 73 | + * @param subtitle - the subtitle |
|
| 74 | + * @param path - the path to the scriin-dump image |
|
| 75 | + * @param signed - if true show information that the module is signed |
|
| 76 | + */ |
|
| 78 | 77 | ?> |
| 79 | 78 | |
| 80 | 79 | function OS(name, subtitle, path, signed) { |
@@ -23,7 +23,7 @@ |
||
| 23 | 23 | core\ProfileSilverbullet::triggerNewOCSPStatement($serialRow->serial_number); |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | - /* |
|
| 26 | + /* |
|
| 27 | 27 | * and then writes all recently updated statements to a temporary directory. The |
| 28 | 28 | * calling script ocsp_update.sh should then scp all the files to their |
| 29 | 29 | * destination. |
@@ -156,8 +156,8 @@ |
||
| 156 | 156 | // replace namespace separators with directory separators |
| 157 | 157 | // in the relative class name, append with .php |
| 158 | 158 | $file = $base_dir |
| 159 | - . str_replace('\\', '/', $relative_class) |
|
| 160 | - . '.php'; |
|
| 159 | + . str_replace('\\', '/', $relative_class) |
|
| 160 | + . '.php'; |
|
| 161 | 161 | |
| 162 | 162 | // if the mapped file exists, require it |
| 163 | 163 | if ($this->requireFile($file)) { |
@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | if (isset($Cache[$entry])) { |
| 42 | 42 | continue; |
| 43 | 43 | } |
| 44 | - \core\common\Entity::rrmdir($downloads . '/' . $entry); |
|
| 44 | + \core\common\Entity::rrmdir($downloads . '/' . $entry); |
|
| 45 | 45 | print "$entry\n"; |
| 46 | 46 | } |
| 47 | 47 | closedir($handle); |
@@ -56,7 +56,7 @@ discard block |
||
| 56 | 56 | if ($ftime < 3600) { |
| 57 | 57 | continue; |
| 58 | 58 | } |
| 59 | - \core\common\Entity::rrmdir($downloads . '/' . $entry); |
|
| 59 | + \core\common\Entity::rrmdir($downloads . '/' . $entry); |
|
| 60 | 60 | print "$entry\n"; |
| 61 | 61 | } |
| 62 | 62 | closedir($handle); |
@@ -11,15 +11,15 @@ |
||
| 11 | 11 | namespace devices\redirect_dev; |
| 12 | 12 | |
| 13 | 13 | class Device_RedirectDev extends \core\DeviceConfig { |
| 14 | - /** |
|
| 15 | - * Constructs a Device object. |
|
| 16 | - * |
|
| 17 | - * @final not to be redefined |
|
| 18 | - */ |
|
| 14 | + /** |
|
| 15 | + * Constructs a Device object. |
|
| 16 | + * |
|
| 17 | + * @final not to be redefined |
|
| 18 | + */ |
|
| 19 | 19 | final public function __construct() { |
| 20 | 20 | parent::__construct(); |
| 21 | - $this->setSupportedEapMethods([\core\common\EAP::EAPTYPE_NONE]); |
|
| 22 | - $this->loggerInstance->debug(4,"RedirectEx called"); |
|
| 21 | + $this->setSupportedEapMethods([\core\common\EAP::EAPTYPE_NONE]); |
|
| 22 | + $this->loggerInstance->debug(4,"RedirectEx called"); |
|
| 23 | 23 | } |
| 24 | 24 | public function writeDeviceInfo() { |
| 25 | 25 | $out = "<p>"; |
@@ -246,11 +246,11 @@ discard block |
||
| 246 | 246 | } |
| 247 | 247 | |
| 248 | 248 | /** |
| 249 | - * This function parses a X.509 cert and returns all certificatePolicies OIDs |
|
| 250 | - * |
|
| 251 | - * @param array $cert (returned from openssl_x509_parse) |
|
| 252 | - * @return array of OIDs |
|
| 253 | - */ |
|
| 249 | + * This function parses a X.509 cert and returns all certificatePolicies OIDs |
|
| 250 | + * |
|
| 251 | + * @param array $cert (returned from openssl_x509_parse) |
|
| 252 | + * @return array of OIDs |
|
| 253 | + */ |
|
| 254 | 254 | private function propertyCheckPolicy($cert) { |
| 255 | 255 | $oids = []; |
| 256 | 256 | if ($cert['extensions']['certificatePolicies']) { |
@@ -263,11 +263,11 @@ discard block |
||
| 263 | 263 | return $oids; |
| 264 | 264 | } |
| 265 | 265 | /** |
| 266 | - * This function parses a X.509 cert and returns the value of $field |
|
| 267 | - * |
|
| 268 | - * @param array $cert (returned from openssl_x509_parse) |
|
| 269 | - * @return string value of the issuer field or '' |
|
| 270 | - */ |
|
| 266 | + * This function parses a X.509 cert and returns the value of $field |
|
| 267 | + * |
|
| 268 | + * @param array $cert (returned from openssl_x509_parse) |
|
| 269 | + * @return string value of the issuer field or '' |
|
| 270 | + */ |
|
| 271 | 271 | private function getCertificateIssuer($cert) { |
| 272 | 272 | $issuer = ''; |
| 273 | 273 | foreach ($cert['issuer'] as $key => $val) { |
@@ -88,7 +88,7 @@ |
||
| 88 | 88 | 'server_suffix' => '.hosted.eduroam.org', |
| 89 | 89 | 'gracetime' => 90, |
| 90 | 90 | 'CA' => ["type" => "embedded"], # OCSP URL needs to be configured in openssl.cnf |
| 91 | - # 'CA' => ["type" => "DFN", "SOAP_API_ENDPOINT" => "http://no.idea.where/"], |
|
| 91 | + # 'CA' => ["type" => "DFN", "SOAP_API_ENDPOINT" => "http://no.idea.where/"], |
|
| 92 | 92 | |
| 93 | 93 | ], |
| 94 | 94 | /** |
@@ -77,90 +77,90 @@ |
||
| 77 | 77 | } |
| 78 | 78 | |
| 79 | 79 | switch ($operationMode) { |
| 80 | - case OPERATION_MODE_EDIT: |
|
| 81 | - $idp = $validator->IdP($_GET['inst_id']); |
|
| 82 | - // editing IdPs is done from within the popup. When we're done, send the |
|
| 83 | - // user back to the popup (append the result of the operation later) |
|
| 84 | - $redirect_destination = "manageAdmins.inc.php?inst_id=" . $idp->identifier . "&"; |
|
| 85 | - $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 86 | - // is the user admin of this IdP? |
|
| 87 | - $is_owner = FALSE; |
|
| 88 | - $owners = $idp->owner(); |
|
| 89 | - foreach ($owners as $oneowner) { |
|
| 90 | - if ($oneowner['ID'] == $_SESSION['user'] && $oneowner['LEVEL'] == "FED") { |
|
| 91 | - $is_owner = TRUE; |
|
| 80 | + case OPERATION_MODE_EDIT: |
|
| 81 | + $idp = $validator->IdP($_GET['inst_id']); |
|
| 82 | + // editing IdPs is done from within the popup. When we're done, send the |
|
| 83 | + // user back to the popup (append the result of the operation later) |
|
| 84 | + $redirect_destination = "manageAdmins.inc.php?inst_id=" . $idp->identifier . "&"; |
|
| 85 | + $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 86 | + // is the user admin of this IdP? |
|
| 87 | + $is_owner = FALSE; |
|
| 88 | + $owners = $idp->owner(); |
|
| 89 | + foreach ($owners as $oneowner) { |
|
| 90 | + if ($oneowner['ID'] == $_SESSION['user'] && $oneowner['LEVEL'] == "FED") { |
|
| 91 | + $is_owner = TRUE; |
|
| 92 | + } |
|
| 93 | + } |
|
| 94 | + // check if he is (also) federation admin for the federation this IdP is in. His invitations have more blessing then. |
|
| 95 | + $fedadmin = $userObject->isFederationAdmin($idp->federation); |
|
| 96 | + // check if he is either one, if not, complain |
|
| 97 | + if (!$is_owner && !$fedadmin) { |
|
| 98 | + echo "<p>" . sprintf(_("Something's wrong... you are a %s admin, but not for the %s the requested %s belongs to!"), $uiElements->nomenclature_fed, $uiElements->nomenclature_fed, $uiElements->nomenclature_inst) . "</p>"; |
|
| 99 | + exit(1); |
|
| 92 | 100 | } |
| 93 | - } |
|
| 94 | - // check if he is (also) federation admin for the federation this IdP is in. His invitations have more blessing then. |
|
| 95 | - $fedadmin = $userObject->isFederationAdmin($idp->federation); |
|
| 96 | - // check if he is either one, if not, complain |
|
| 97 | - if (!$is_owner && !$fedadmin) { |
|
| 98 | - echo "<p>" . sprintf(_("Something's wrong... you are a %s admin, but not for the %s the requested %s belongs to!"), $uiElements->nomenclature_fed, $uiElements->nomenclature_fed, $uiElements->nomenclature_inst) . "</p>"; |
|
| 99 | - exit(1); |
|
| 100 | - } |
|
| 101 | 101 | |
| 102 | - $prettyprintname = $idp->name; |
|
| 103 | - $newtoken = $mgmt->createToken($fedadmin, $mailaddress, $idp); |
|
| 104 | - $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP " . $idp->identifier . " - Token created for " . $mailaddress); |
|
| 105 | - $introtext = sprintf(_("a %s of the %s %s \"%s\" has invited you to manage the %s together with him."), $uiElements->nomenclature_fed, CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_inst, $prettyprintname, $uiElements->nomenclature_inst) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 106 | - break; |
|
| 107 | - case OPERATION_MODE_NEWUNLINKED: |
|
| 108 | - $redirect_destination = "../overview_federation.php?"; |
|
| 109 | - $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 110 | - // run an input check and conversion of the raw inputs... just in case |
|
| 111 | - $newinstname = $validator->string($_POST['name']); |
|
| 112 | - $newcountry = $validator->string($_POST['country']); |
|
| 113 | - $new_idp_authorized_fedadmin = $userObject->isFederationAdmin($newcountry); |
|
| 114 | - if ($new_idp_authorized_fedadmin !== TRUE) { |
|
| 115 | - throw new Exception("Something's wrong... you want to create a new " . $uiElements->nomenclature_inst . ", but are not a " . $uiElements->nomenclature_fed . " admin for the " . $uiElements->nomenclature_fed . " it should be in!"); |
|
| 116 | - } |
|
| 117 | - $federation = $validator->Federation($newcountry); |
|
| 118 | - $prettyprintname = $newinstname; |
|
| 119 | - $introtext = sprintf(_("a %s %s has invited you to manage the future %s \"%s\" (%s)."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_fed, $uiElements->nomenclature_inst, $prettyprintname, $newcountry) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 120 | - // send the user back to his federation overview page, append the result of the operation later |
|
| 121 | - // do the token creation magic |
|
| 122 | - $newtoken = $mgmt->createToken(TRUE, $mailaddress, $newinstname, 0, $newcountry); |
|
| 123 | - $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP FUTURE - Token created for " . $mailaddress); |
|
| 124 | - break; |
|
| 125 | - case OPERATION_MODE_NEWFROMDB: |
|
| 126 | - $redirect_destination = "../overview_federation.php?"; |
|
| 127 | - $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 128 | - // a real external DB entry was submitted and all the required parameters are there |
|
| 129 | - $newexternalid = $validator->string($_POST['externals']); |
|
| 130 | - $extinfo = $catInstance->getExternalDBEntityDetails($newexternalid); |
|
| 131 | - $new_idp_authorized_fedadmin = $userObject->isFederationAdmin($extinfo['country']); |
|
| 132 | - if ($new_idp_authorized_fedadmin !== TRUE) { |
|
| 133 | - throw new Exception("Something's wrong... you want to create a new " . $uiElements->nomenclature_inst . ", but are not a " . $uiElements->nomenclature_fed . " admin for the " . $uiElements->nomenclature_fed . " it should be in!"); |
|
| 134 | - } |
|
| 135 | - $federation = $validator->Federation($extinfo['country']); |
|
| 136 | - $newcountry = $extinfo['country']; |
|
| 137 | - // see if the inst name is defined in the currently set language; if not, pick its English name; if N/A, pick the last in the list |
|
| 138 | - $prettyprintname = ""; |
|
| 139 | - foreach ($extinfo['names'] as $lang => $name) { |
|
| 140 | - if ($lang == $languageInstance->getLang()) { |
|
| 141 | - $prettyprintname = $name; |
|
| 102 | + $prettyprintname = $idp->name; |
|
| 103 | + $newtoken = $mgmt->createToken($fedadmin, $mailaddress, $idp); |
|
| 104 | + $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP " . $idp->identifier . " - Token created for " . $mailaddress); |
|
| 105 | + $introtext = sprintf(_("a %s of the %s %s \"%s\" has invited you to manage the %s together with him."), $uiElements->nomenclature_fed, CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_inst, $prettyprintname, $uiElements->nomenclature_inst) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 106 | + break; |
|
| 107 | + case OPERATION_MODE_NEWUNLINKED: |
|
| 108 | + $redirect_destination = "../overview_federation.php?"; |
|
| 109 | + $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 110 | + // run an input check and conversion of the raw inputs... just in case |
|
| 111 | + $newinstname = $validator->string($_POST['name']); |
|
| 112 | + $newcountry = $validator->string($_POST['country']); |
|
| 113 | + $new_idp_authorized_fedadmin = $userObject->isFederationAdmin($newcountry); |
|
| 114 | + if ($new_idp_authorized_fedadmin !== TRUE) { |
|
| 115 | + throw new Exception("Something's wrong... you want to create a new " . $uiElements->nomenclature_inst . ", but are not a " . $uiElements->nomenclature_fed . " admin for the " . $uiElements->nomenclature_fed . " it should be in!"); |
|
| 142 | 116 | } |
| 143 | - } |
|
| 144 | - if ($prettyprintname == "" && isset($extinfo['names']['en'])) { |
|
| 145 | - $prettyprintname = $extinfo['names']['en']; |
|
| 146 | - } |
|
| 147 | - if ($prettyprintname == "") { |
|
| 148 | - foreach ($extinfo['names'] as $name) { |
|
| 149 | - $prettyprintname = $name; |
|
| 117 | + $federation = $validator->Federation($newcountry); |
|
| 118 | + $prettyprintname = $newinstname; |
|
| 119 | + $introtext = sprintf(_("a %s %s has invited you to manage the future %s \"%s\" (%s)."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_fed, $uiElements->nomenclature_inst, $prettyprintname, $newcountry) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 120 | + // send the user back to his federation overview page, append the result of the operation later |
|
| 121 | + // do the token creation magic |
|
| 122 | + $newtoken = $mgmt->createToken(TRUE, $mailaddress, $newinstname, 0, $newcountry); |
|
| 123 | + $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP FUTURE - Token created for " . $mailaddress); |
|
| 124 | + break; |
|
| 125 | + case OPERATION_MODE_NEWFROMDB: |
|
| 126 | + $redirect_destination = "../overview_federation.php?"; |
|
| 127 | + $mailaddress = abortOnBogusMail($newmailaddress, $redirect_destination); |
|
| 128 | + // a real external DB entry was submitted and all the required parameters are there |
|
| 129 | + $newexternalid = $validator->string($_POST['externals']); |
|
| 130 | + $extinfo = $catInstance->getExternalDBEntityDetails($newexternalid); |
|
| 131 | + $new_idp_authorized_fedadmin = $userObject->isFederationAdmin($extinfo['country']); |
|
| 132 | + if ($new_idp_authorized_fedadmin !== TRUE) { |
|
| 133 | + throw new Exception("Something's wrong... you want to create a new " . $uiElements->nomenclature_inst . ", but are not a " . $uiElements->nomenclature_fed . " admin for the " . $uiElements->nomenclature_fed . " it should be in!"); |
|
| 150 | 134 | } |
| 151 | - } |
|
| 152 | - // fill the rest of the text |
|
| 153 | - $introtext = sprintf(_("a %s %s has invited you to manage the %s \"%s\"."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_fed, $uiElements->nomenclature_inst, $prettyprintname) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 154 | - // do the token creation magic |
|
| 155 | - $newtoken = $mgmt->createToken(TRUE, $mailaddress, $prettyprintname, $newexternalid); |
|
| 156 | - $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP FUTURE - Token created for " . $mailaddress); |
|
| 157 | - break; |
|
| 158 | - default: // includes OPERATION_MODE_INVALID |
|
| 159 | - $wrongcontent = print_r($_POST, TRUE); |
|
| 160 | - echo "<pre>Wrong parameters in POST: |
|
| 135 | + $federation = $validator->Federation($extinfo['country']); |
|
| 136 | + $newcountry = $extinfo['country']; |
|
| 137 | + // see if the inst name is defined in the currently set language; if not, pick its English name; if N/A, pick the last in the list |
|
| 138 | + $prettyprintname = ""; |
|
| 139 | + foreach ($extinfo['names'] as $lang => $name) { |
|
| 140 | + if ($lang == $languageInstance->getLang()) { |
|
| 141 | + $prettyprintname = $name; |
|
| 142 | + } |
|
| 143 | + } |
|
| 144 | + if ($prettyprintname == "" && isset($extinfo['names']['en'])) { |
|
| 145 | + $prettyprintname = $extinfo['names']['en']; |
|
| 146 | + } |
|
| 147 | + if ($prettyprintname == "") { |
|
| 148 | + foreach ($extinfo['names'] as $name) { |
|
| 149 | + $prettyprintname = $name; |
|
| 150 | + } |
|
| 151 | + } |
|
| 152 | + // fill the rest of the text |
|
| 153 | + $introtext = sprintf(_("a %s %s has invited you to manage the %s \"%s\"."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $uiElements->nomenclature_fed, $uiElements->nomenclature_inst, $prettyprintname) . " " . sprintf(_("This invitation is valid for 24 hours from now, i.e. until %s."), strftime("%x %X", time() + 86400)); |
|
| 154 | + // do the token creation magic |
|
| 155 | + $newtoken = $mgmt->createToken(TRUE, $mailaddress, $prettyprintname, $newexternalid); |
|
| 156 | + $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP FUTURE - Token created for " . $mailaddress); |
|
| 157 | + break; |
|
| 158 | + default: // includes OPERATION_MODE_INVALID |
|
| 159 | + $wrongcontent = print_r($_POST, TRUE); |
|
| 160 | + echo "<pre>Wrong parameters in POST: |
|
| 161 | 161 | " . htmlspecialchars($wrongcontent) . " |
| 162 | 162 | </pre>"; |
| 163 | - exit(1); |
|
| 163 | + exit(1); |
|
| 164 | 164 | } |
| 165 | 165 | // are we on https? |
| 166 | 166 | $proto = "http://"; |
@@ -59,10 +59,10 @@ discard block |
||
| 59 | 59 | */ |
| 60 | 60 | |
| 61 | 61 | public static $Options=[ |
| 62 | - 'sign'=>0, |
|
| 63 | - 'no_cache'=>0, |
|
| 64 | - 'hidden'=>0, |
|
| 65 | - 'redirect'=>0, |
|
| 62 | + 'sign'=>0, |
|
| 63 | + 'no_cache'=>0, |
|
| 64 | + 'hidden'=>0, |
|
| 65 | + 'redirect'=>0, |
|
| 66 | 66 | ]; |
| 67 | 67 | |
| 68 | 68 | /** |
@@ -100,75 +100,75 @@ discard block |
||
| 100 | 100 | |
| 101 | 101 | public static function listDevices() { |
| 102 | 102 | return [ |
| 103 | - 'w10'=>[ |
|
| 104 | - 'group' => "microsoft", |
|
| 105 | - 'display'=>_("MS Windows 10"), |
|
| 106 | - 'match'=>'Windows NT 10', |
|
| 107 | - 'directory'=>'ms', |
|
| 108 | - 'module'=>'W10', |
|
| 109 | - 'signer'=>'ms_windows_sign', |
|
| 103 | + 'w10'=>[ |
|
| 104 | + 'group' => "microsoft", |
|
| 105 | + 'display'=>_("MS Windows 10"), |
|
| 106 | + 'match'=>'Windows NT 10', |
|
| 107 | + 'directory'=>'ms', |
|
| 108 | + 'module'=>'W10', |
|
| 109 | + 'signer'=>'ms_windows_sign', |
|
| 110 | 110 | 'options'=>[ |
| 111 | - 'sign'=>1, |
|
| 112 | - 'device_id'=>'W10', |
|
| 113 | - 'mime'=>'application/x-dosexec', |
|
| 114 | - ], |
|
| 115 | - ], |
|
| 111 | + 'sign'=>1, |
|
| 112 | + 'device_id'=>'W10', |
|
| 113 | + 'mime'=>'application/x-dosexec', |
|
| 114 | + ], |
|
| 115 | + ], |
|
| 116 | 116 | |
| 117 | - 'w8'=>[ |
|
| 118 | - 'group' => "microsoft", |
|
| 119 | - 'display'=>_("MS Windows 8, 8.1"), |
|
| 120 | - 'match'=>'Windows NT 6[._][23]', |
|
| 121 | - 'directory'=>'ms', |
|
| 122 | - 'module'=>'W8', |
|
| 123 | - 'signer'=>'ms_windows_sign', |
|
| 117 | + 'w8'=>[ |
|
| 118 | + 'group' => "microsoft", |
|
| 119 | + 'display'=>_("MS Windows 8, 8.1"), |
|
| 120 | + 'match'=>'Windows NT 6[._][23]', |
|
| 121 | + 'directory'=>'ms', |
|
| 122 | + 'module'=>'W8', |
|
| 123 | + 'signer'=>'ms_windows_sign', |
|
| 124 | 124 | 'options'=>[ |
| 125 | - 'sign'=>1, |
|
| 126 | - 'device_id'=>'W8', |
|
| 127 | - 'mime'=>'application/x-dosexec', |
|
| 128 | - ], |
|
| 129 | - ], |
|
| 125 | + 'sign'=>1, |
|
| 126 | + 'device_id'=>'W8', |
|
| 127 | + 'mime'=>'application/x-dosexec', |
|
| 128 | + ], |
|
| 129 | + ], |
|
| 130 | 130 | |
| 131 | - 'w7'=>[ |
|
| 132 | - 'group' => "microsoft", |
|
| 133 | - 'display'=>_("MS Windows 7"), |
|
| 134 | - 'match'=>'Windows NT 6[._]1', |
|
| 135 | - 'directory'=>'ms', |
|
| 136 | - 'module'=>'Vista7', |
|
| 137 | - 'signer'=>'ms_windows_sign', |
|
| 131 | + 'w7'=>[ |
|
| 132 | + 'group' => "microsoft", |
|
| 133 | + 'display'=>_("MS Windows 7"), |
|
| 134 | + 'match'=>'Windows NT 6[._]1', |
|
| 135 | + 'directory'=>'ms', |
|
| 136 | + 'module'=>'Vista7', |
|
| 137 | + 'signer'=>'ms_windows_sign', |
|
| 138 | 138 | 'options'=>[ |
| 139 | - 'sign'=>1, |
|
| 140 | - 'device_id'=>'W7', |
|
| 141 | - 'mime'=>'application/x-dosexec', |
|
| 142 | - ], |
|
| 143 | - ], |
|
| 139 | + 'sign'=>1, |
|
| 140 | + 'device_id'=>'W7', |
|
| 141 | + 'mime'=>'application/x-dosexec', |
|
| 142 | + ], |
|
| 143 | + ], |
|
| 144 | 144 | |
| 145 | - 'vista'=>[ |
|
| 146 | - 'group' => "microsoft", |
|
| 147 | - 'display'=>_("MS Windows Vista"), |
|
| 148 | - 'match'=>'Windows NT 6[._]0', |
|
| 149 | - 'directory'=>'ms', |
|
| 150 | - 'module'=>'Vista7', |
|
| 151 | - 'signer'=>'ms_windows_sign', |
|
| 145 | + 'vista'=>[ |
|
| 146 | + 'group' => "microsoft", |
|
| 147 | + 'display'=>_("MS Windows Vista"), |
|
| 148 | + 'match'=>'Windows NT 6[._]0', |
|
| 149 | + 'directory'=>'ms', |
|
| 150 | + 'module'=>'Vista7', |
|
| 151 | + 'signer'=>'ms_windows_sign', |
|
| 152 | 152 | 'options'=>[ |
| 153 | - 'sign'=>1, |
|
| 154 | - 'device_id'=>'Vista', |
|
| 155 | - 'mime'=>'application/x-dosexec', |
|
| 156 | - ], |
|
| 157 | - ], |
|
| 153 | + 'sign'=>1, |
|
| 154 | + 'device_id'=>'Vista', |
|
| 155 | + 'mime'=>'application/x-dosexec', |
|
| 156 | + ], |
|
| 157 | + ], |
|
| 158 | 158 | |
| 159 | - 'win-rt'=>[ |
|
| 159 | + 'win-rt'=>[ |
|
| 160 | 160 | 'group' => "microsoft", |
| 161 | 161 | 'display'=>_("Windows RT"), |
| 162 | 162 | 'directory'=>'redirect_dev', |
| 163 | 163 | 'module'=>'RedirectDev', |
| 164 | 164 | 'options'=>[ |
| 165 | - 'hidden'=>0, |
|
| 166 | - 'redirect'=>1, |
|
| 167 | - ], |
|
| 168 | - ], |
|
| 165 | + 'hidden'=>0, |
|
| 166 | + 'redirect'=>1, |
|
| 167 | + ], |
|
| 168 | + ], |
|
| 169 | 169 | |
| 170 | 170 | |
| 171 | - 'apple_sierra'=>array( |
|
| 171 | + 'apple_sierra'=>array( |
|
| 172 | 172 | 'group' => "apple", |
| 173 | 173 | 'display'=>_("Apple macOS Sierra"), |
| 174 | 174 | 'match'=>'Mac OS X 10[._]12', |
@@ -176,14 +176,14 @@ discard block |
||
| 176 | 176 | 'module'=>'mobileconfig_os_x', |
| 177 | 177 | 'signer'=>'mobileconfig_sign', |
| 178 | 178 | 'options'=>array( |
| 179 | - 'sign'=>1, |
|
| 180 | - 'device_id'=>'OS_X', |
|
| 181 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 182 | - ), |
|
| 179 | + 'sign'=>1, |
|
| 180 | + 'device_id'=>'OS_X', |
|
| 181 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 182 | + ), |
|
| 183 | 183 | ), |
| 184 | 184 | |
| 185 | 185 | |
| 186 | - 'apple_el_cap'=>[ |
|
| 186 | + 'apple_el_cap'=>[ |
|
| 187 | 187 | 'group' => "apple", |
| 188 | 188 | 'display'=>_("Apple OS X El Capitan"), |
| 189 | 189 | 'match'=>'Mac OS X 10[._]11', |
@@ -191,13 +191,13 @@ discard block |
||
| 191 | 191 | 'module'=>'mobileconfig_os_x', |
| 192 | 192 | 'signer'=>'mobileconfig_sign', |
| 193 | 193 | 'options'=>array( |
| 194 | - 'sign'=>1, |
|
| 195 | - 'device_id'=>'OS_X', |
|
| 196 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 197 | - ), |
|
| 194 | + 'sign'=>1, |
|
| 195 | + 'device_id'=>'OS_X', |
|
| 196 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 197 | + ), |
|
| 198 | 198 | ], |
| 199 | 199 | |
| 200 | - 'apple_yos'=>[ |
|
| 200 | + 'apple_yos'=>[ |
|
| 201 | 201 | 'group' => "apple", |
| 202 | 202 | 'display'=>_("Apple OS X Yosemite"), |
| 203 | 203 | 'match'=>'Mac OS X 10[._]10', |
@@ -205,13 +205,13 @@ discard block |
||
| 205 | 205 | 'module'=>'mobileconfig_os_x', |
| 206 | 206 | 'signer'=>'mobileconfig_sign', |
| 207 | 207 | 'options'=>[ |
| 208 | - 'sign'=>1, |
|
| 209 | - 'device_id'=>'OS_X', |
|
| 210 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 211 | - ], |
|
| 208 | + 'sign'=>1, |
|
| 209 | + 'device_id'=>'OS_X', |
|
| 210 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 211 | + ], |
|
| 212 | 212 | ], |
| 213 | 213 | |
| 214 | - 'apple_mav'=>[ |
|
| 214 | + 'apple_mav'=>[ |
|
| 215 | 215 | 'group' => "apple", |
| 216 | 216 | 'display'=>_("Apple OS X Mavericks"), |
| 217 | 217 | 'match'=>'Mac OS X 10[._]9', |
@@ -219,13 +219,13 @@ discard block |
||
| 219 | 219 | 'module'=>'mobileconfig_os_x', |
| 220 | 220 | 'signer'=>'mobileconfig_sign', |
| 221 | 221 | 'options'=>[ |
| 222 | - 'sign'=>1, |
|
| 223 | - 'device_id'=>'OS_X', |
|
| 224 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 225 | - ], |
|
| 222 | + 'sign'=>1, |
|
| 223 | + 'device_id'=>'OS_X', |
|
| 224 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 225 | + ], |
|
| 226 | 226 | ], |
| 227 | 227 | |
| 228 | - 'apple_m_lion'=>[ |
|
| 228 | + 'apple_m_lion'=>[ |
|
| 229 | 229 | 'group' => "apple", |
| 230 | 230 | 'display'=>_("Apple OS X Mountain Lion"), |
| 231 | 231 | 'match'=>'Mac OS X 10[._]8', |
@@ -233,13 +233,13 @@ discard block |
||
| 233 | 233 | 'module'=>'mobileconfig_os_x', |
| 234 | 234 | 'signer'=>'mobileconfig_sign', |
| 235 | 235 | 'options'=>[ |
| 236 | - 'sign'=>1, |
|
| 237 | - 'device_id'=>'OS_X', |
|
| 238 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 239 | - ], |
|
| 236 | + 'sign'=>1, |
|
| 237 | + 'device_id'=>'OS_X', |
|
| 238 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 239 | + ], |
|
| 240 | 240 | ], |
| 241 | 241 | |
| 242 | - 'apple_lion'=>[ |
|
| 242 | + 'apple_lion'=>[ |
|
| 243 | 243 | 'group' => "apple", |
| 244 | 244 | 'display'=>_("Apple OS X Lion"), |
| 245 | 245 | 'match'=>'Mac OS X 10[._]7', |
@@ -247,13 +247,13 @@ discard block |
||
| 247 | 247 | 'module'=>'mobileconfig_os_x', |
| 248 | 248 | 'signer'=>'mobileconfig_sign', |
| 249 | 249 | 'options'=>[ |
| 250 | - 'sign'=>1, |
|
| 251 | - 'device_id'=>'OS_X', |
|
| 252 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 253 | - ], |
|
| 250 | + 'sign'=>1, |
|
| 251 | + 'device_id'=>'OS_X', |
|
| 252 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 253 | + ], |
|
| 254 | 254 | ], |
| 255 | 255 | |
| 256 | - 'mobileconfig'=>[ |
|
| 256 | + 'mobileconfig'=>[ |
|
| 257 | 257 | 'group' => "apple", |
| 258 | 258 | 'display'=>_("Apple iOS mobile devices"), |
| 259 | 259 | 'match'=>'(iPad|iPhone|iPod);.*OS ([7-9]|1[0-5])_', |
@@ -261,13 +261,13 @@ discard block |
||
| 261 | 261 | 'module'=>'mobileconfig_ios', |
| 262 | 262 | 'signer'=>'mobileconfig_sign', |
| 263 | 263 | 'options'=>[ |
| 264 | - 'sign'=>1, |
|
| 265 | - 'device_id'=>'iOS', |
|
| 266 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 267 | - ], |
|
| 264 | + 'sign'=>1, |
|
| 265 | + 'device_id'=>'iOS', |
|
| 266 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 267 | + ], |
|
| 268 | 268 | ], |
| 269 | 269 | |
| 270 | - 'mobileconfig-56'=>[ |
|
| 270 | + 'mobileconfig-56'=>[ |
|
| 271 | 271 | 'group' => "apple", |
| 272 | 272 | 'display'=>_("Apple iOS mobile devices (iOS 5 and 6)"), |
| 273 | 273 | 'match'=>'(iPad|iPhone|iPod);.*OS [56]_', |
@@ -275,132 +275,132 @@ discard block |
||
| 275 | 275 | 'module'=>'mobileconfig_ios_56', |
| 276 | 276 | 'signer'=>'mobileconfig_sign', |
| 277 | 277 | 'options'=>[ |
| 278 | - 'sign'=>1, |
|
| 279 | - 'device_id'=>'iOS', |
|
| 280 | - 'mime'=>'application/x-apple-aspen-config', |
|
| 281 | - ], |
|
| 278 | + 'sign'=>1, |
|
| 279 | + 'device_id'=>'iOS', |
|
| 280 | + 'mime'=>'application/x-apple-aspen-config', |
|
| 281 | + ], |
|
| 282 | 282 | ], |
| 283 | 283 | |
| 284 | 284 | |
| 285 | - 'linux'=>[ |
|
| 286 | - 'group' => "linux", |
|
| 287 | - 'display'=>_("Linux"), |
|
| 288 | - 'match'=>'Linux(?!.*Android)', |
|
| 289 | - 'directory'=>'linux', |
|
| 290 | - 'module' => 'Linux', |
|
| 291 | - 'options'=>[ |
|
| 292 | - 'mime'=>'application/x-sh', |
|
| 293 | - ], |
|
| 294 | - ], |
|
| 285 | + 'linux'=>[ |
|
| 286 | + 'group' => "linux", |
|
| 287 | + 'display'=>_("Linux"), |
|
| 288 | + 'match'=>'Linux(?!.*Android)', |
|
| 289 | + 'directory'=>'linux', |
|
| 290 | + 'module' => 'Linux', |
|
| 291 | + 'options'=>[ |
|
| 292 | + 'mime'=>'application/x-sh', |
|
| 293 | + ], |
|
| 294 | + ], |
|
| 295 | 295 | |
| 296 | - 'chromeos'=>[ |
|
| 296 | + 'chromeos'=>[ |
|
| 297 | 297 | 'group' => "chrome", |
| 298 | 298 | 'display'=>_("Chrome OS"), |
| 299 | 299 | 'match'=>'CrOS', |
| 300 | 300 | 'directory'=>'chromebook', |
| 301 | 301 | 'module'=>'chromebook', |
| 302 | 302 | 'options'=>[ |
| 303 | - 'mime'=>'application/x-onc', |
|
| 304 | - 'message'=>sprintf(_("After downloading the file, open the Chrome browser and browse to this URL: <a href='chrome://net-internals/#chromeos'>chrome://net-internals/#chromeos</a>. Then, use the 'Import ONC file' button. The import is silent; the new network definitions will be added to the preferred networks.")), |
|
| 305 | - ], |
|
| 306 | - ], |
|
| 303 | + 'mime'=>'application/x-onc', |
|
| 304 | + 'message'=>sprintf(_("After downloading the file, open the Chrome browser and browse to this URL: <a href='chrome://net-internals/#chromeos'>chrome://net-internals/#chromeos</a>. Then, use the 'Import ONC file' button. The import is silent; the new network definitions will be added to the preferred networks.")), |
|
| 305 | + ], |
|
| 306 | + ], |
|
| 307 | 307 | |
| 308 | - 'android_marshmallow'=>[ |
|
| 308 | + 'android_marshmallow'=>[ |
|
| 309 | 309 | 'group' => "android", |
| 310 | 310 | 'display'=>_("Android 6.0 Marshmallow"), |
| 311 | - 'match'=>'Android 6\.[0-9]', |
|
| 311 | + 'match'=>'Android 6\.[0-9]', |
|
| 312 | 312 | 'directory'=>'xml', |
| 313 | 313 | 'module'=>'Lollipop', |
| 314 | 314 | 'options'=>[ |
| 315 | - 'mime'=>'application/eap-config', |
|
| 316 | - 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 315 | + 'mime'=>'application/eap-config', |
|
| 316 | + 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 317 | 317 | "eduroamCAT", |
| 318 | 318 | "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>", |
| 319 | 319 | "<a target='_blank' href='unbeknownst'>Amazon Appstore</a>", |
| 320 | 320 | "<a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"), |
| 321 | - ], |
|
| 322 | - ], |
|
| 321 | + ], |
|
| 322 | + ], |
|
| 323 | 323 | |
| 324 | - 'android_lollipop'=>[ |
|
| 324 | + 'android_lollipop'=>[ |
|
| 325 | 325 | 'group' => "android", |
| 326 | 326 | 'display'=>_("Android 5.0 Lollipop"), |
| 327 | - 'match'=>'Android 5\.[0-9]', |
|
| 327 | + 'match'=>'Android 5\.[0-9]', |
|
| 328 | 328 | 'directory'=>'xml', |
| 329 | 329 | 'module'=>'Lollipop', |
| 330 | 330 | 'options'=>[ |
| 331 | - 'mime'=>'application/eap-config', |
|
| 332 | - 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 331 | + 'mime'=>'application/eap-config', |
|
| 332 | + 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 333 | 333 | "eduroamCAT", |
| 334 | 334 | "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>", |
| 335 | 335 | "<a target='_blank' href='unbeknownst'>Amazon Appstore</a>", |
| 336 | 336 | "<a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"), |
| 337 | - ], |
|
| 338 | - ], |
|
| 337 | + ], |
|
| 338 | + ], |
|
| 339 | 339 | |
| 340 | - 'android_kitkat'=>[ |
|
| 340 | + 'android_kitkat'=>[ |
|
| 341 | 341 | 'group' => "android", |
| 342 | 342 | 'display'=>_("Android 4.4 KitKat"), |
| 343 | - 'match'=>'Android 4\.[4-9]', |
|
| 343 | + 'match'=>'Android 4\.[4-9]', |
|
| 344 | 344 | 'directory'=>'xml', |
| 345 | 345 | 'module'=>'KitKat', |
| 346 | 346 | 'options'=>[ |
| 347 | - 'mime'=>'application/eap-config', |
|
| 348 | - 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 347 | + 'mime'=>'application/eap-config', |
|
| 348 | + 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 349 | 349 | "eduroamCAT", |
| 350 | 350 | "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>", |
| 351 | 351 | "<a target='_blank' href='unbeknownst'>Amazon Appstore</a>", |
| 352 | 352 | "<a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"), |
| 353 | - ], |
|
| 354 | - ], |
|
| 353 | + ], |
|
| 354 | + ], |
|
| 355 | 355 | |
| 356 | 356 | |
| 357 | - 'android_43'=>[ |
|
| 357 | + 'android_43'=>[ |
|
| 358 | 358 | 'group' => "android", |
| 359 | 359 | 'display'=>_("Android 4.3"), |
| 360 | - 'match'=>'Android 4\.3', |
|
| 360 | + 'match'=>'Android 4\.3', |
|
| 361 | 361 | 'directory'=>'xml', |
| 362 | 362 | 'module'=>'KitKat', |
| 363 | 363 | 'options'=>[ |
| 364 | - 'mime'=>'application/eap-config', |
|
| 365 | - 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 364 | + 'mime'=>'application/eap-config', |
|
| 365 | + 'message'=>sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from %s, %s and %s, and will use the configuration file downloaded from CAT to create all necessary settings."), |
|
| 366 | 366 | "eduroamCAT", |
| 367 | 367 | "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>", |
| 368 | 368 | "<a target='_blank' href='unbeknownst'>Amazon Appstore</a>", |
| 369 | 369 | "<a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"), |
| 370 | - ], |
|
| 371 | - ], |
|
| 370 | + ], |
|
| 371 | + ], |
|
| 372 | 372 | |
| 373 | - 'android_legacy'=>[ |
|
| 374 | - 'group' => "android", |
|
| 375 | - 'display'=>_("Android"), |
|
| 376 | - 'match'=>'Android', |
|
| 377 | - 'directory'=>'redirect_dev', |
|
| 378 | - 'module'=>'RedirectDev', |
|
| 379 | - 'options'=>[ |
|
| 380 | - 'redirect'=>1, |
|
| 381 | - ], |
|
| 382 | - ], |
|
| 373 | + 'android_legacy'=>[ |
|
| 374 | + 'group' => "android", |
|
| 375 | + 'display'=>_("Android"), |
|
| 376 | + 'match'=>'Android', |
|
| 377 | + 'directory'=>'redirect_dev', |
|
| 378 | + 'module'=>'RedirectDev', |
|
| 379 | + 'options'=>[ |
|
| 380 | + 'redirect'=>1, |
|
| 381 | + ], |
|
| 382 | + ], |
|
| 383 | 383 | |
| 384 | - 'eap-config'=>[ |
|
| 384 | + 'eap-config'=>[ |
|
| 385 | 385 | 'group' => "eap-config", |
| 386 | 386 | 'display'=>_("EAP config"), |
| 387 | 387 | 'directory'=>'xml', |
| 388 | 388 | 'module'=>'XML_ALL', |
| 389 | 389 | 'options'=>[ |
| 390 | - 'mime'=>'application/eap-config', |
|
| 391 | - 'message'=>sprintf(_("This option provides a generic EAP config XML file, which can be consumed by dedicated applications like eduroamCAT for Android and Linux platforms. This is still an experimental feature.")), |
|
| 392 | - ], |
|
| 390 | + 'mime'=>'application/eap-config', |
|
| 391 | + 'message'=>sprintf(_("This option provides a generic EAP config XML file, which can be consumed by dedicated applications like eduroamCAT for Android and Linux platforms. This is still an experimental feature.")), |
|
| 392 | + ], |
|
| 393 | 393 | ], |
| 394 | 394 | |
| 395 | - 'test'=>[ |
|
| 395 | + 'test'=>[ |
|
| 396 | 396 | 'group' => "other", |
| 397 | 397 | 'display'=>_("Test"), |
| 398 | 398 | 'directory'=>'test_module', |
| 399 | 399 | 'module'=>'TestModule', |
| 400 | 400 | 'options'=>[ |
| 401 | - 'hidden'=>1, |
|
| 402 | - ], |
|
| 403 | - ], |
|
| 401 | + 'hidden'=>1, |
|
| 402 | + ], |
|
| 403 | + ], |
|
| 404 | 404 | |
| 405 | 405 | |
| 406 | 406 | /* |