|
9 | 9 | <div id="user-saml-save-indicator" class="msg success inlineblock" style="display: none;">Saved</div> |
10 | 10 |
|
11 | 11 | <div id="user-saml-settings"> |
12 | | - <ul> |
13 | | - <li><a href="#user-saml-sp"><?php p($l->t('Service Provider Data')) ?></a></li> |
14 | | - <li><a href="#user-saml-idp"><?php p($l->t('Identity Provider Data')) ?></a></li> |
15 | | - <li><a href="#user-saml-security"><?php p($l->t('Security settings')) ?></a></li> |
16 | | - <li><a href="#user-saml-general"><?php p($l->t('General')) ?></a></li> |
17 | | - </ul> |
18 | | - <div id="user-saml-sp"> |
19 | | - <p><?php print_unescaped($l->t('If your Service Provider should use certificates you can optionally specify them here.')) ?></p> |
20 | | - <?php foreach($_['sp'] as $key => $text): ?> |
21 | | - <textarea name="<?php p($key) ?>" placeholder="<?php p($text) ?>"><?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'sp-'.$key, '')) ?></textarea> |
22 | | - <?php endforeach; ?> |
23 | | - </div> |
24 | | - <div id="user-saml-idp"> |
25 | | - <p><?php print_unescaped($l->t('Configure your IdP settings here, all yellow input fields are required, others optional.')) ?></p> |
26 | | - <input name="entityId" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-entityId', '')) ?>" type="text" class="required" placeholder="<?php p($l->t('Identifier of the IdP entity (must be a URI)')) ?>"/> |
27 | | - <input name="singleSignOnService.url" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-singleSignOnService.url', '')) ?>" type="text" class="required" placeholder="<?php p($l->t('URL Target of the IdP where the SP will send the Authentication Request Message')) ?>"/> |
28 | | - <input name="singleLogoutService.url" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-singleLogoutService.url', '')) ?>" type="text" placeholder="<?php p($l->t('URL Location of the IdP where the SP will send the SLO Request')) ?>"/> |
29 | | - <textarea name="x509cert" placeholder="<?php p($l->t('Public X.509 certificate of the IdP')) ?>"><?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-x509cert', '')) ?></textarea> |
30 | | - </div> |
31 | | - <div id="user-saml-security"> |
32 | | - <p><?php print_unescaped($l->t('For increased security we recommend enabling the following settings if supported by your environment.')) ?></p> |
33 | | - |
34 | | - <h3><?php p($l->t('Signatures and encryption offered')) ?></h3> |
35 | | - <?php foreach($_['security-offer'] as $key => $text): ?> |
36 | | - <input type="checkbox" id="user-saml-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'security-'.$key, '0')) ?>"> |
37 | | - <label for="user-saml-<?php p($key)?>"><?php p($text) ?></label><br/> |
38 | | - <?php endforeach; ?> |
39 | | - <h3><?php p($l->t('Signatures and encryption required')) ?></h3> |
40 | | - <?php foreach($_['security-required'] as $key => $text): ?> |
41 | | - <input type="checkbox" id="user-saml-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'security-'.$key, '0')) ?>"> |
42 | | - <label for="user-saml-<?php p($key)?>"><?php p($text) ?></label><br/> |
43 | | - <?php endforeach; ?> |
44 | | - </div> |
45 | 12 | <div id="user-saml-general"> |
| 13 | + <h3><?php p($l->t('General')) ?></h3> |
46 | 14 | <?php foreach($_['general'] as $key => $attribute): ?> |
47 | 15 | <?php if($attribute['type'] === 'checkbox'): ?> |
48 | | - <input type="checkbox" id="user-saml-general-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'general-'.$key, '0')) ?>"> |
49 | | - <label for="user-saml-general-<?php p($key)?>"><?php p($attribute['text']) ?></label><br/> |
| 16 | + <p> |
| 17 | + <input type="checkbox" id="user-saml-general-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'general-'.$key, '0')) ?>"> |
| 18 | + <label for="user-saml-general-<?php p($key)?>"><?php p($attribute['text']) ?></label><br/> |
| 19 | + </p> |
50 | 20 | <?php elseif($attribute['type'] === 'line'): ?> |
51 | | - <input name="<?php p($key) ?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'general-'.$key, '')) ?>" type="text" <?php if(isset($attribute['required']) && $attribute['required'] === true): ?>class="required"<?php endif;?> placeholder="<?php p($attribute['text']) ?>"/> |
| 21 | + <p> |
| 22 | + <input name="<?php p($key) ?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'general-'.$key, '')) ?>" type="text" <?php if(isset($attribute['required']) && $attribute['required'] === true): ?>class="required"<?php endif;?> placeholder="<?php p($attribute['text']) ?>"/> |
| 23 | + </p> |
52 | 24 | <?php endif; ?> |
53 | 25 | <?php endforeach; ?> |
54 | 26 |
|
55 | 27 | <!-- FIXME: Add "Disable timeout from SAML" switch (checked by default)--> |
56 | 28 | </div> |
| 29 | + <div id="user-saml-sp"> |
| 30 | + <h3><?php p($l->t('Service Provider Data')) ?></h3> |
| 31 | + <p> |
| 32 | + <?php print_unescaped($l->t('If your Service Provider should use certificates you can optionally specify them here.')) ?> |
| 33 | + <span class="toggle"><?php p($l->t('Show Service Provider settings ...')) ?></span> |
| 34 | + </p> |
| 35 | + |
| 36 | + <div class="hidden"> |
| 37 | + <?php foreach($_['sp'] as $key => $text): ?> |
| 38 | + <p> |
| 39 | + <textarea name="<?php p($key) ?>" placeholder="<?php p($text) ?>"><?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'sp-'.$key, '')) ?></textarea> |
| 40 | + </p> |
| 41 | + <?php endforeach; ?> |
| 42 | + </div> |
| 43 | + </div> |
| 44 | + <div id="user-saml-idp"> |
| 45 | + <h3><?php p($l->t('Identity Provider Data')) ?></h3> |
| 46 | + <p> |
| 47 | + <?php print_unescaped($l->t('Configure your IdP settings here.')) ?> |
| 48 | + </p> |
| 49 | + |
| 50 | + <p><input name="entityId" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-entityId', '')) ?>" type="text" class="required" placeholder="<?php p($l->t('Identifier of the IdP entity (must be a URI)')) ?>"/></p> |
| 51 | + <p><input name="singleSignOnService.url" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-singleSignOnService.url', '')) ?>" type="text" class="required" placeholder="<?php p($l->t('URL Target of the IdP where the SP will send the Authentication Request Message')) ?>"/></p> |
| 52 | + <p><span class="toggle"><?php p($l->t('Show optional Identity Provider settings ...')) ?></span></p> |
| 53 | + <div class="hidden"> |
| 54 | + <p><input name="singleLogoutService.url" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-singleLogoutService.url', '')) ?>" type="text" placeholder="<?php p($l->t('URL Location of the IdP where the SP will send the SLO Request')) ?>"/></p> |
| 55 | + <p><textarea name="x509cert" placeholder="<?php p($l->t('Public X.509 certificate of the IdP')) ?>"><?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'idp-x509cert', '')) ?></textarea></p> |
| 56 | + </div> |
| 57 | + </div> |
| 58 | + <div id="user-saml-security"> |
| 59 | + <h3><?php p($l->t('Security settings')) ?></h3> |
| 60 | + <p> |
| 61 | + <?php print_unescaped($l->t('For increased security we recommend enabling the following settings if supported by your environment.')) ?> |
| 62 | + <span class="toggle"><?php p($l->t('Show security settings ...')) ?></span> |
| 63 | + </p> |
| 64 | + <div class="indent hidden"> |
| 65 | + <h4><?php p($l->t('Signatures and encryption offered')) ?></h4> |
| 66 | + <?php foreach($_['security-offer'] as $key => $text): ?> |
| 67 | + <p> |
| 68 | + <input type="checkbox" id="user-saml-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'security-'.$key, '0')) ?>" class="checkbox"> |
| 69 | + <label for="user-saml-<?php p($key)?>"><?php p($text) ?></label><br/> |
| 70 | + </p> |
| 71 | + <?php endforeach; ?> |
| 72 | + <h4><?php p($l->t('Signatures and encryption required')) ?></h4> |
| 73 | + <?php foreach($_['security-required'] as $key => $text): ?> |
| 74 | + <p> |
| 75 | + <input type="checkbox" id="user-saml-<?php p($key)?>" name="<?php p($key)?>" value="<?php p(\OC::$server->getConfig()->getAppValue('user_saml', 'security-'.$key, '0')) ?>" class="checkbox"> |
| 76 | + <label for="user-saml-<?php p($key)?>"><?php p($text) ?></label> |
| 77 | + </p> |
| 78 | + <?php endforeach; ?> |
| 79 | + </div> |
| 80 | + </div> |
57 | 81 |
|
58 | 82 | <a href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('user_saml.SAML.getMetadata')) ?>" class="button"><?php p($l->t('Download metadata XML')) ?></a> |
59 | 83 | <!-- FIXME: Add test settings --> |
|
0 commit comments