How do you choose between Argon2id and bcrypt?

    6 min read
    ByPaula CKraftwire Software
    Illustration for How do you choose between Argon2id and bcrypt?

    Sources

    1. cheatsheetseries.owasp.org › Password_Storage_Cheat_Sheet.html
    2. rfc-editor.org › rfc9106

    Frequently asked questions

    How should I test optimal bcrypt cost factors?
    Measure verification time and memory use on representative authentication servers under expected concurrent load. Review the results against your security baseline and service requirements, then record the approved configuration. Use synthetic credentials for these tests and ask a security reviewer to assess the chosen settings before deployment.
    How should I inspect bcrypt password length handling?
    Check how the server library handles encoded password bytes and inputs beyond its documented boundary. Ask the security owner to approve the algorithm choice and migration plan before changing the password policy. Test rejected inputs and the proposed migration using synthetic passwords, and keep those test results with the review.
    How should I review Argon2id client resource limits?
    First identify whether the operation is server-side login verification or client-side vault key derivation. Measure the appropriate hardware separately and review memory, iteration and parallelism settings as a set. Do not select parallelism solely from a device’s thread count or transfer a server configuration to a browser without a protocol and resource review.
    How should I prepare upgrading password hashes?
    After successful verification of an existing password, derive the new representation with the approved configuration and replace the active legacy record. Do not retain extra legacy-hash copies for convenience. Define a reset procedure for inactive accounts and review backup retention separately; never log the submitted password or derived secret.
    How should I choose key derivation parameters?
    Start from current guidance for the specific use case and the library you have selected. Benchmark synthetic credentials on representative hardware, then have the security owner approve the parameters and operational limits. Keep password storage and encryption-key derivation requirements separate; do not collect users’ passwords for an entropy survey.
    How should I record algorithm validation logs?
    Record the library version, algorithm identifier, approved settings and test outcome using synthetic credentials. Use the verification API to test correct and incorrect passwords. Keep passwords, encryption keys and derived secrets out of application logs, telemetry and examples shared in issue trackers.

    Start writing with true privacy

    Get Started Free

    Related reading