TsgcWSAPIServer_WebAuthnPropiedades › WebAuthnOptions

WebAuthnOptions Propiedad

Configuración del Relying Party: RPName, RPID, Origins, algoritmos admitidos, formatos de Attestation, verificación de usuario, Timeout y AuthenticatorSelection.

Sintaxis

property WebAuthnOptions: TsgcWSWebAuthnServer_Options read FWebAuthnOptions write SetWebAuthnOptions;

Valor Predeterminado

RelyingParty (RPID) vacío — debe establecerse con el nombre DNS del servidor. Algoritmos: ES256 + RS256. Todos los formatos de atestación habilitados. AllowCrossOrigins: false. AllowCredentials: false. ExcludeCredentials: false.

Observaciones

Configuración principal de parte de confianza WebAuthn (FIDO2) utilizada tanto para el registro de credenciales (navigator.credentials.create()) como para la autenticación (navigator.credentials.get()). RelyingParty es obligatorio y debe coincidir con el nombre DNS del servidor (por ejemplo www.test.com). Se pueden configurar Origins y TopOrigins adicionales cuando las solicitudes provengan de dominios adicionales o iframes incrustados, y AllowCrossOrigins habilita los flujos de iframes de origen cruzado. El conjunto Algorithms controla qué algoritmos de firma COSE se aceptan (ES256, ES384, ES512, RS256, RS384, RS512, PS256, PS384, PS512, RS1, EdDSA); de forma predeterminada solo están habilitados ES256 y RS256. Los formatos de atestación (None, Packed, TPM, AndroidKey, Apple, FidoU2F) pueden habilitarse o deshabilitarse individualmente. AllowCredentials / ExcludeCredentials / Limit controlan qué IDs de credencial se envían al cliente durante la autenticación y el registro.

Ejemplo

oWebAuthn.WebAuthnOptions.RelyingParty := 'www.test.com';
oWebAuthn.WebAuthnOptions.Origins.Add('https://login.test.com');
oWebAuthn.WebAuthnOptions.Algorithms.ES256 := True;
oWebAuthn.WebAuthnOptions.Algorithms.RS256 := True;
oWebAuthn.WebAuthnOptions.Attestation.NoneAttestation := True;
oWebAuthn.WebAuthnOptions.Attestation.PackedAttestation := True;
oWebAuthn.WebAuthnOptions.Credentials.ExcludeCredentials := True;
oWebAuthn.WebAuthnOptions.Credentials.Limit := 10;

Volver a Propiedades