The next generation of the Teknik Services. Written in ASP.NET. https://www.teknik.io/
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.

TwoFactorCheck.cshtml 2.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. @model Teknik.Areas.Users.ViewModels.TwoFactorViewModel
  2. @using Teknik.Helpers
  3. <script>
  4. var confirmAuthCodeURL = '@Url.SubRouteUrl("user", "User.Action", new { action = "ConfirmAuthenticatorCode" })';
  5. </script>
  6. @Scripts.Render("~/bundles/checkAuthCode")
  7. <div class="container">
  8. <div class="row">
  9. <div class="col-md-12">
  10. <div class="text-center">
  11. <h1>Two-factor authentication</h1>
  12. <div class="col-md-4 col-md-offset-4">
  13. <div class="panel panel-default">
  14. <div class="panel-body">
  15. <div class="row">
  16. <div class="col-sm-12 text-center">
  17. <div id="authCheckStatus"></div>
  18. </div>
  19. </div>
  20. <form role="form" id="twoFactorCheckForm" action="##" method="post" accept-charset="UTF-8">
  21. <input name="ReturnUrl" id="ReturnUrl" type="hidden" value="@Model.ReturnUrl" />
  22. <input name="RememberMe" id="RememberMe" type="hidden" value="@Model.RememberMe" />
  23. <div class="form-group text-left">
  24. <label for="update_website">Authentication code</label>
  25. <input type="text" class="form-control" id="Code" name="Code" data-val-required="The Authentication Code is required." data-val="true" />
  26. </div>
  27. @if (Model.AllowTrustedDevice)
  28. {
  29. <div class="checkbox">
  30. <label>
  31. <input id="RememberDevice" type="checkbox" value="true" name="RememberDevice" /><input name="RememberDevice" type="hidden" value="false"> Remember Device
  32. </label>
  33. </div>
  34. <small>Set this device as a trusted device. It is not advised to trust a public computer.</small>
  35. <br />
  36. <br />
  37. }
  38. <div class="form-group">
  39. <button class="btn btn-primary btn-block" id="verifyCodeSubmit" type="button" name="verifyCodeSubmit">Verify</button>
  40. </div>
  41. </form>
  42. <p class="text-left">Open the two-factor authentication app on your device to view your authentication code and verify your identity.</p>
  43. </div>
  44. </div>
  45. </div>
  46. </div>
  47. </div>
  48. </div>
  49. </div>