Explorar o código

feat(webauthn): perfer creation of a client-side discoverable credential

Tianzhi Jin hai 10 meses
pai
achega
b65373db7e
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      internal/ui/webauthn.go

+ 2 - 0
internal/ui/webauthn.go

@@ -105,6 +105,8 @@ func (h *handler) beginRegistration(w http.ResponseWriter, r *http.Request) {
 			nil,
 		},
 		webauthn.WithExclusions(credsDescriptors),
+		webauthn.WithResidentKeyRequirement(protocol.ResidentKeyRequirementPreferred),
+		webauthn.WithExtensions(protocol.AuthenticationExtensions{"credProps": true}),
 	)
 
 	if err != nil {