webauthn-policy-passwordless.html 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. <!--
  2. ~ Copyright 2019 Red Hat, Inc. and/or its affiliates
  3. ~ and other contributors as indicated by the @author tags.
  4. ~
  5. ~ Licensed under the Apache License, Version 2.0 (the "License");
  6. ~ you may not use this file except in compliance with the License.
  7. ~ You may obtain a copy of the License at
  8. ~
  9. ~ http://www.apache.org/licenses/LICENSE-2.0
  10. ~
  11. ~ Unless required by applicable law or agreed to in writing, software
  12. ~ distributed under the License is distributed on an "AS IS" BASIS,
  13. ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. ~ See the License for the specific language governing permissions and
  15. ~ limitations under the License.
  16. ~
  17. -->
  18. <div class="col-sm-9 col-md-10 col-sm-push-3 col-md-push-2">
  19. <h1>{{:: 'authentication' | translate}}</h1>
  20. <span data-ng-init="redirectIfWebAuthnDisabled()"></span>
  21. <kc-tabs-authentication></kc-tabs-authentication>
  22. <form class="form-horizontal" name="realmForm" novalidate kc-read-only="!access.manageRealm">
  23. <div class="form-group">
  24. <label for="name" class="col-md-2 control-label"><span class="required">*</span> {{:: 'webauthn-rp-entity-name' | translate}}</label>
  25. <div class="col-md-2">
  26. <div>
  27. <input id="name" type="text" ng-model="realm.webAuthnPolicyPasswordlessRpEntityName" class="form-control">
  28. </div>
  29. </div>
  30. <kc-tooltip>{{:: 'webauthn-rp-entity-name.tooltip' | translate}}</kc-tooltip>
  31. </div>
  32. <div class="form-group">
  33. <label for="sigalg" class="col-md-2 control-label">{{:: 'webauthn-signature-algorithms' | translate}}</label>
  34. <div class="col-md-2">
  35. <div>
  36. <select id="sigalg" ng-model="realm.webAuthnPolicyPasswordlessSignatureAlgorithms" class="form-control" multiple>
  37. <option value="ES256">ES256</option>
  38. <option value="ES384">ES384</option>
  39. <option value="ES512">ES512</option>
  40. <option value="RS256">RS256</option>
  41. <option value="RS384">RS384</option>
  42. <option value="RS512">RS512</option>
  43. <option value="RS1">RS1</option>
  44. </select>
  45. </div>
  46. </div>
  47. <kc-tooltip>{{:: 'webauthn-signature-algorithms.tooltip' | translate}}</kc-tooltip>
  48. </div>
  49. <div class="form-group">
  50. <label for="rpid" class="col-md-2 control-label">{{:: 'webauthn-rp-id' | translate}}</label>
  51. <div class="col-md-2">
  52. <div>
  53. <input id="rpid" type="text" ng-model="realm.webAuthnPolicyPasswordlessRpId" class="form-control">
  54. </div>
  55. </div>
  56. <kc-tooltip>{{:: 'webauthn-rp-id.tooltip' | translate}}</kc-tooltip>
  57. </div>
  58. <div class="form-group">
  59. <label for="attpref" class="col-md-2 control-label">{{:: 'webauthn-attestation-conveyance-preference' | translate}}</label>
  60. <div class="col-md-2">
  61. <div>
  62. <select id="attpref" ng-model="realm.webAuthnPolicyPasswordlessAttestationConveyancePreference" class="form-control">
  63. <option value="not specified"></option>
  64. <option value="none">none</option>
  65. <option value="indirect">indirect</option>
  66. <option value="direct">direct</option>
  67. </select>
  68. </div>
  69. </div>
  70. <kc-tooltip>{{:: 'webauthn-attestation-conveyance-preference.tooltip' | translate}}</kc-tooltip>
  71. </div>
  72. <div class="form-group">
  73. <label for="authnatt" class="col-md-2 control-label">{{:: 'webauthn-authenticator-attachment' | translate}}</label>
  74. <div class="col-md-2">
  75. <div>
  76. <select id="authnatt" ng-model="realm.webAuthnPolicyPasswordlessAuthenticatorAttachment" class="form-control">
  77. <option value="not specified"></option>
  78. <option value="platform">platform</option>
  79. <option value="cross-platform">cross-platform</option>
  80. </select>
  81. </div>
  82. </div>
  83. <kc-tooltip>{{:: 'webauthn-authenticator-attachment.tooltip' | translate}}</kc-tooltip>
  84. </div>
  85. <div class="form-group">
  86. <label for="reqresident" class="col-md-2 control-label">{{:: 'webauthn-require-resident-key' | translate}}</label>
  87. <div class="col-md-2">
  88. <div>
  89. <select id="reqresident" ng-model="realm.webAuthnPolicyPasswordlessRequireResidentKey" class="form-control">
  90. <option value="not specified"></option>
  91. <option value="Yes">Yes</option>
  92. <option value="No">No</option>
  93. </select>
  94. </div>
  95. </div>
  96. <kc-tooltip>{{:: 'webauthn-require-resident-key.tooltip' | translate}}</kc-tooltip>
  97. </div>
  98. <div class="form-group">
  99. <label for="usrverify" class="col-md-2 control-label">{{:: 'webauthn-user-verification-requirement' | translate}}</label>
  100. <div class="col-md-2">
  101. <div>
  102. <select id="usrverify" ng-model="realm.webAuthnPolicyPasswordlessUserVerificationRequirement" class="form-control">
  103. <option value="not specified"></option>
  104. <option value="required">required</option>
  105. <option value="preferred">preferred</option>
  106. <option value="discouraged">discouraged</option>
  107. </select>
  108. </div>
  109. </div>
  110. <kc-tooltip>{{:: 'webauthn-user-verification-requirement.tooltip' | translate}}</kc-tooltip>
  111. </div>
  112. <div class="form-group">
  113. <label for="timeout" class="col-md-2 control-label">{{:: 'webauthn-create-timeout' | translate}}</label>
  114. <div class="col-md-2">
  115. <div>
  116. <input id="timeout" type="number" min="0" max="31536" ng-model="realm.webAuthnPolicyPasswordlessCreateTimeout" class="form-control"/>
  117. </div>
  118. </div>
  119. <kc-tooltip>{{:: 'webauthn-create-timeout.tooltip' | translate}}</kc-tooltip>
  120. </div>
  121. <div class="form-group">
  122. <label for="avoidsame" class="col-md-2 control-label">{{:: 'webauthn-avoid-same-authenticator-register' | translate}}</label>
  123. <div class="col-md-2">
  124. <div>
  125. <input id="avoidsame" ng-model="realm.webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister" onoffswitch on-text="{{:: 'onText' | translate}}" off-text="{{:: 'offText' | translate}}"/>
  126. </div>
  127. </div>
  128. <kc-tooltip>{{:: 'webauthn-avoid-same-authenticator-register.tooltip' | translate}}</kc-tooltip>
  129. </div>
  130. <div class="form-group">
  131. <label for="type" class="col-md-2 control-label">{{:: 'webauthn-acceptable-aaguids' | translate}}</label>
  132. <div class="col-sm-4">
  133. <div class="input-group" ng-repeat="(i, acceptableAaguid) in realm.webAuthnPolicyPasswordlessAcceptableAaguids track by $index">
  134. <input class="form-control webauthn-acceptable-aaguid" ng-model="realm.webAuthnPolicyPasswordlessAcceptableAaguids[i]">
  135. <div class="input-group-btn">
  136. <button class="btn btn-default" type="button" data-ng-click="deleteAcceptableAaguid($index)">
  137. <span class="fa fa-minus"></span>
  138. </button>
  139. </div>
  140. </div>
  141. <div class = "input-group">
  142. <input class="form-control" ng-model="newAcceptableAaguid" id="newAcceptableAaguid">
  143. <div class="input-group-btn">
  144. <button class="btn btn-default" type="button" data-ng-click="newAcceptableAaguid.length > 0 && addAcceptableAaguid()">
  145. <span class="fa fa-plus"></span>
  146. </button>
  147. </div>
  148. </div>
  149. </div>
  150. <kc-tooltip>{{:: 'webauthn-acceptable-aaguids.tooltip' | translate}}</kc-tooltip>
  151. </div>
  152. <div class="form-group" data-ng-show="access.manageRealm">
  153. <div class="col-md-10 col-md-offset-2">
  154. <button kc-save data-ng-disabled="!changed">{{:: 'save' | translate}}</button>
  155. <button kc-reset data-ng-disabled="!changed">{{:: 'cancel' | translate}}</button>
  156. </div>
  157. </div>
  158. </form>
  159. </div>
  160. <kc-menu></kc-menu>