{% extends "base.html" %} {% from "components/page-header.html" import page_header %} {% from "components/components/button/macro.njk" import usaButton %} {% from "components/components/back-link/macro.njk" import usaBackLink %} {% from "components/table.html" import edit_field, mapping_table, row, field, row_heading %} {% from "components/webauthn-api-check.html" import webauthn_api_check %} {% from "components/components/error-message/macro.njk" import usaErrorMessage %} {% set page_title = 'Security keys' %} {% set credentials = current_user.webauthn_credentials %} {% block extra_javascripts_before_body %} {{ webauthn_api_check() }} {% endblock %} {% block per_page_title %} {{ page_title }} {% endblock %} {% block backLink %} {{ usaBackLink({ "href": url_for('.user_profile') }) }} {% endblock %} {% block maincolumn_content %} {% set webauthn_button %} {{ usaButton({ "element": "button", "text": "Register a key", "classes": "govuk-button--secondary webauthn__api-required", "attributes": { "data-module": "register-security-key", "data-csrf-token": csrf_token(), } }) }} {{ usaErrorMessage({ "classes": "webauthn__api-missing", "text": "Your browser does not support security keys. Try signing in to Notify using a different browser." }) }} {{ usaErrorMessage({ "classes": "webauthn__no-js", "text": "JavaScript is not available for this page. Security keys need JavaScript to work." }) }} {% endset %}
Check you have the right key and try again. ' + 'If this does not work, ' + 'contact us." + '
' ), "attributes": { "aria-live": "polite", "tabindex": '-1' } }) }} {% if credentials %}Security keys are an alternative way of signing in to Notify, instead of getting a code in a text message
You can buy any key that’s compatible with the WebAuthn standard.
{{ webauthn_button }}