TOTP algorithm parameter (SHA256/SHA512) appears ignored — generates SHA1 codes only
Summary
Bitwarden documentation and prior discussions indicate support for SHA256/SHA512 in TOTP.
However, in practice, Bitwarden appears to generate SHA1-based codes regardless of the
algorithm parameter in otpauth:// URIs.
This results in authentication failures for services that require SHA256 (e.g. Australian Government myGov, error RFM 177).
This issue relates to the integrated TOTP functionality within the Bitwarden Password Manager (not the standalone Bitwarden Authenticator app).
Expected Behaviour
Bitwarden should:
- Parse the
algorithmparameter inotpauth://URIs - Generate TOTP codes using:
- SHA1 (default)
- SHA256
- SHA512
- Behave in accordance with RFC 6238
Actual Behaviour
- Bitwarden generates TOTP codes consistent with SHA1
- Codes match other SHA1-based authenticators (e.g. Bitwarden and Microsoft Authenticator fallback)
- Codes do not match SHA256-generated values
- Services requiring SHA256 reject the codes
Reproduction Steps
- Add a TOTP entry using the following URI:
otpauth://totp/Test:sha256@example.com?secret=JBSWY3DPEHPK3PXP&issuer=Test&algorithm=SHA256&digits=6&period=30
- Generate a code in Bitwarden
- Generate a code using a SHA256-compatible tool for the same secret and timestamp
Verified Test Case (RFC 6238)
Using:
- Secret:
JBSWY3DPEHPK3PXP - Time:
59
Expected:
- SHA1:
94287082 - SHA256:
46119246
Bitwarden produces the SHA1 value.
Real-world Impact
This is not theoretical — it blocks use of Bitwarden for MFA on services requiring SHA256, including:
- Australian Government myGov (returns an error indicating the authenticator is not compatible with SHA256)
Prior Discussion
There is an older thread indicating support was planned/implemented:
https://community.bitwarden.com/t/support-totp-auth-parameters/37
However, current behaviour suggests that algorithm=SHA256 is either ignored or not functioning correctly.
Key Observation
If SHA256 were correctly implemented, Bitwarden should generate a different code than SHA1 for the same secret and timestamp. Currently, it does not.
Request
- Confirm whether SHA256/SHA512 TOTP is fully supported
- If supported, investigate why the
algorithmparameter appears to be ignored - If not supported, implement full RFC 6238 support for SHA256/SHA512
Environment
- Bitwarden browser extension (Chrome)
- Latest version (as of 2026)
- Reproduced across multiple authenticators for comparison