liveBook · Manning

Relying party ID

As explained in Software Security for Developers

A relying party ID is the domain identifier that binds a WebAuthn credential and authentication ceremony to the intended service.

A relying party ID (rpId) is the expected domain that binds a WebAuthn credential and authentication ceremony to the intended service. The server verifies this value so a credential cannot be redirected to a malicious domain. section 15.3

Enforce the relying party ID alongside other authentication checks:

  • Match the authentication data’s rpId against the service’s expected domain, such as example.com. section 15.3
  • Reject mismatches because they can indicate phishing or a man-in-the-middle attempt. section 15.3
  • Treat rpId checking as complementary to challenge validation and signature verification. section 15.3

Domain mismatch

If a WebAuthn ceremony expects example.com but authentication data reports another relying party ID, the server rejects the attempt rather than trusting the signature alone. section 15.3

How Software Security for Developers covers it

How deep it goes
Explains server-side domain matching and its phishing rationale, but does not show detailed rpId implementation code.
Examples
Uses example.com as the expected domain and contrasts it with an authentication attempt reporting another relying party ID.
What it assumes
Assumes familiarity with WebAuthn authentication, credentials, challenges, and signatures.
What you can do after
Operate/configure WebAuthn authentication by enforcing the expected rpId on the server.
How it connects
Connects relying party ID with WebAuthn, challenge validation, signature verification, phishing, and man-in-the-middle attacks.

This explainer was generated by Manning's knowledge graph from the text of Software Security for Developers. The section links point to the parts of the book it draws on.