Cannot delete entries from browser extension or client applications #4355

Closed
opened 2026-03-07 19:41:47 -06:00 by GiteaMirror · 5 comments
Owner

Originally created by @sgissi on GitHub (Jun 1, 2020).

Subject of the issue

Cannot delete entries from browser extension or client applications. Works fine from web vault.

Your environment

  • Bitwarden_rs version: bitwardenrs/server-postgresql:1.14.2
  • Install method: Kubernetes (official docker image for postgresql)
  • Clients used: Works - Web Vault. Does not work - Linux client version 1.18.0, Firefox extension version 1.44.2
  • Reverse proxy and version: Traefik 2.2.1
  • Version of mysql/postgresql: PostgreSQL 11.7.0

Steps to reproduce

Run bitwarden_rs server, create one entry, connect using client or web extension and delete the entry. Entry will remain, server will show a 404 error:
[2020-06-01 21:33:53][request][INFO] PUT /api/ciphers//delete
[2020-06-01 21:33:53][response][INFO] 404 Not Found

When using the Web Vault it uses the DELETE verb:
[2020-06-01 22:24:55][request][INFO] DELETE /api/ciphers/
[2020-06-01 22:24:55][response][INFO] DELETE /api/ciphers/ (delete_cipher) => 200 OK

Relevant commit

The root of the issue is that the path "put /ciphers/<uuid>/delete" is not recognized by the server. This commit fixes the issue while implementing soft delete. If that commit isn't ready for release, a simple fix is to add the relevant functions in src/api/core/ciphers.rs (plus adding them into routes() of course):

#[put("/ciphers/<uuid>/delete")]
fn delete_cipher_put(uuid: String, headers: Headers, conn: DbConn, nt: Notify) -> EmptyResult {
    _delete_cipher_by_uuid(&uuid, &headers, &conn, &nt)
}

#[put("/ciphers/<uuid>/delete-admin")]
fn delete_cipher_put_admin(uuid: String, headers: Headers, conn: DbConn, nt: Notify) -> EmptyResult {
    _delete_cipher_by_uuid(&uuid, &headers, &conn, &nt)
}

Is it possible to get a 2.14.3 released with either fix? Happy to submit PR against 2.14.2 if needed.

Originally created by @sgissi on GitHub (Jun 1, 2020). ### Subject of the issue Cannot delete entries from browser extension or client applications. Works fine from web vault. ### Your environment * Bitwarden_rs version: bitwardenrs/server-postgresql:1.14.2 * Install method: Kubernetes (official docker image for postgresql) * Clients used: **Works** - Web Vault. **Does not work** - Linux client version 1.18.0, Firefox extension version 1.44.2 * Reverse proxy and version: Traefik 2.2.1 * Version of mysql/postgresql: PostgreSQL 11.7.0 ### Steps to reproduce Run bitwarden_rs server, create one entry, connect using client or web extension and delete the entry. Entry will remain, server will show a 404 error: [2020-06-01 21:33:53][request][INFO] PUT /api/ciphers/<redacted UUID>/delete [2020-06-01 21:33:53][response][INFO] 404 Not Found When using the Web Vault it uses the DELETE verb: [2020-06-01 22:24:55][request][INFO] DELETE /api/ciphers/<redacted UUID> [2020-06-01 22:24:55][response][INFO] DELETE /api/ciphers/<uuid> (delete_cipher) => 200 OK ### Relevant commit The root of the issue is that the path "put /ciphers/\<uuid\>/delete" is not recognized by the server. This [commit](https://github.com/dani-garcia/bitwarden_rs/commit/e3b00b59a7db760848f6b357fc4328081574aeac) fixes the issue while implementing soft delete. If that commit isn't ready for release, a simple fix is to add the relevant functions in src/api/core/ciphers.rs (plus adding them into routes() of course): ``` #[put("/ciphers/<uuid>/delete")] fn delete_cipher_put(uuid: String, headers: Headers, conn: DbConn, nt: Notify) -> EmptyResult { _delete_cipher_by_uuid(&uuid, &headers, &conn, &nt) } #[put("/ciphers/<uuid>/delete-admin")] fn delete_cipher_put_admin(uuid: String, headers: Headers, conn: DbConn, nt: Notify) -> EmptyResult { _delete_cipher_by_uuid(&uuid, &headers, &conn, &nt) } ``` Is it possible to get a 2.14.3 released with either fix? Happy to submit PR against 2.14.2 if needed.
Author
Owner

@sgissi commented on GitHub (Jun 1, 2020):

Forgot to mention, 1.18 was released a few days ago, all my clients got updated automatically and created the issue: https://github.com/bitwarden/desktop/releases/tag/v1.18.0

@sgissi commented on GitHub (Jun 1, 2020): Forgot to mention, 1.18 was released a few days ago, all my clients got updated automatically and created the issue: https://github.com/bitwarden/desktop/releases/tag/v1.18.0
Author
Owner

@BlackDex commented on GitHub (Jun 2, 2020):

I just did a quick test, but i do not have any issues with this either with the Firefox Extension or the Desktop application.

What i do find strange is that you have an extra / there, which seem to cause an issue.

[2020-06-01 21:33:53][request][INFO] PUT /api/ciphers//delete

@BlackDex commented on GitHub (Jun 2, 2020): I just did a quick test, but i do not have any issues with this either with the Firefox Extension or the Desktop application. What i do find strange is that you have an extra / there, which seem to cause an issue. > [2020-06-01 21:33:53][request][INFO] PUT /api/ciphers//delete
Author
Owner

@dani-garcia commented on GitHub (Jun 2, 2020):

He's using the numbered releases, and the latest release didn't contain the soft delete functionality, I've made a new release now containing that and the new admin page, it will still take some hours to build still.

The missing id in that request is weird, maybe @sgissi just censored it himself though.

@dani-garcia commented on GitHub (Jun 2, 2020): He's using the numbered releases, and the latest release didn't contain the soft delete functionality, I've made a new release now containing that and the new admin page, it will still take some hours to build still. The missing id in that request is weird, maybe @sgissi just censored it himself though.
Author
Owner

@sgissi commented on GitHub (Jun 2, 2020):

Thank you both. Actually I replaced with <redacted> but Github didn't like the <> signs and removed it, my mistake. In retrospect, it is really just UUID, not a secret, no need to redact really. I'm using numbered releases indeed, I'll test the new images and let you know.

@sgissi commented on GitHub (Jun 2, 2020): Thank you both. Actually I replaced with \<redacted\> but Github didn't like the \<\> signs and removed it, my mistake. In retrospect, it is really just UUID, not a secret, no need to redact really. I'm using numbered releases indeed, I'll test the new images and let you know.
Author
Owner

@sgissi commented on GitHub (Jun 3, 2020):

Just tested the new release and it worked great out of the box, thanks a lot!

@sgissi commented on GitHub (Jun 3, 2020): Just tested the new release and it worked great out of the box, thanks a lot!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vaultwarden#4355