I'm starting to learn about the FIDO2 standard, and I'm wondering if this scenario is possible...
- Victim visits a credential harvesting page and enters their credentials
- Credential harvesting backend opens a connection to the legitimate login page and submits the stolen credentials
- Legitimate website presents a FIDO2 challenge
- The credential harvesting website presents the same challenge to the victim's web browser
- The victim signs the challenge and sends the challenge response to the credential harvesting site
- The attacker sends the challenge response to the legitimate website and authenticates as the victim
This answer on the Information Security Stack Exchange claims it is not possible, but I don't fully understand why. If a key pair is generated for for use only for a specific domain (enforced by the browser), the private key must be stored on a hardware key (such as a Yubikey)? Is that correct? What is the limit to the number of keys that can be stored, and what happens when that limit is reached?