You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

twofactorsetupselection.php 1.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. ?>
  8. <div class="body-login-container update">
  9. <h2 class="two-factor-header"><?php p($l->t('Set up two-factor authentication')) ?></h2>
  10. <?php p($l->t('Enhanced security is enforced for your account. Choose which provider to set up:')) ?>
  11. <ul>
  12. <?php foreach ($_['providers'] as $provider): ?>
  13. <li>
  14. <a class="two-factor-provider"
  15. href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('core.TwoFactorChallenge.setupProvider',
  16. [
  17. 'providerId' => $provider->getId(),
  18. 'redirect_url' => $_['redirect_url'],
  19. ]
  20. )) ?>">
  21. <?php
  22. if ($provider instanceof \OCP\Authentication\TwoFactorAuth\IProvidesIcons) {
  23. $icon = $provider->getLightIcon();
  24. } else {
  25. $icon = image_path('core', 'actions/password-white.svg');
  26. }
  27. ?>
  28. <img src="<?php p($icon) ?>" alt="" />
  29. <div>
  30. <h3><?php p($provider->getDisplayName()) ?></h3>
  31. <p><?php p($provider->getDescription()) ?></p>
  32. </div>
  33. </a>
  34. </li>
  35. <?php endforeach; ?>
  36. </ul>
  37. <p><a class="two-factor-secondary" href="<?php print_unescaped($_['logout_url']); ?>">
  38. <?php p($l->t('Cancel login')) ?>
  39. </a></p>
  40. </div>