verifyJWS(_:as:)

Verify a JWS with the x5c header parameter against the trusted root certificates.

X5CVerifier.swift:93
func verifyJWS<Payload>(_ token: String, as _: Payload.Type = Payload.self) async throws -> Payload where Payload : JWTPayload

Parameters

token

The JWS to verify.

payload

The type to decode from the token payload.

Returns

The decoded payload, if verified.