I have what may be a stupid question…

How is it your master password is both used to decrypt your vault and used to authenticate with bitwardens public servers to acquire a copy of your vault/view it in the web app, but bitwarden can’t use that password entry to decrypt the vault themselves?

(please correct me if I’m misunderstanding, as I use self-hosted vaultwarden for my server instead of the public ones)

  • Deebster@programming.dev
    link
    fedilink
    English
    arrow-up
    1
    ·
    9 months ago

    It’s a valid concern, because the truth is they could. Of course, they could also have some code in the app/plugin that sends your credentials to somewhere even if you’re self-hosting.

    Security always comes down to a trade-off between convenience and trust. In theory you could compile everything yourself after auditing the code, but that’s not realistic (and just moves the trust to your toolchain, OS, CPU microcode, etc).

    It’s a matter of trust that the code doesn’t have anything nefarious in on purpose, that the semi-fictional “many eyes” have caught any accidental bugs, and that their processes and security are good enough to stop bad actors from inserting malicious code.

    I’m assuming you already use 2FA where possible, and I personally keep my codes out of Bitwarden as a little extra defence in depth.

  • asudox@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    arrow-down
    1
    ·
    edit-2
    8 months ago

    The bitwarden servers do not store your password in plain text, but rather as a hash. The hashing algorithm they use hashes the password and outputs a digest. Hashing algorithms are by design not reversible and no hashing algorithm outputs the same hash (at least the audited ones). This can be used to check if the password is indeed the correct password without knowing the password itself. Upon authenticating, the server sends you the encrypted vault and the encrypted vault is decrypted using the same password locally on your computer. So nothing is sent in plain text nor received.

  • oktoberpaard@feddit.nl
    link
    fedilink
    English
    arrow-up
    0
    ·
    9 months ago

    For authentication your password doesn’t need to be stored on the server. Instead, they store a password hash, which is essentially the answer that you get when you put your password in some sort of irreversible mathematical expression. By comparing the hash derived from your password when you enter it, with the hash from the database, they can confirm that you used the correct password. The decryption of your vault uses a different method and can’t be done with the password hash that they have stored in the database.

    This is my best guess based on how hashing and encryption usually work, but I have no knowledge about the specific implementation of Bitwarden.