Problem/Motivation
We have unofficially had validateRequest() as a method to be used for implementing validation outside of a login form.
We have mixed use documentation on implementations on if this will be a string or an integer. For this to be useful we should have this standardized, string would be the most practical as it can be cast to an integer if needed (the TOTP/HOTP modules use a library that expects a string) and allows more complex methods to be developed such as binary data being sent as base64 encoded text, which could be useful for solutions such as perhaps U2F/FIDO.
Steps to reproduce
N/A
Proposed resolution
Add validateRequest(string $code): bool to TfaValidationInterface.
Remaining tasks
Patch and CR.
User interface changes
None
API changes
Add new method that must be implemented to TfaValidationInterface
Data model changes
None
Issue fork tfa-3386585
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
cmlaraComment #5
cmlara