Skip to content
Snippets Groups Projects
  1. Jan 12, 2023
  2. Jan 10, 2023
  3. Jan 09, 2023
    • Daniel García's avatar
      Merge pull request #3065 from BlackDex/future-clippy-fixes · 367e1ce2
      Daniel García authored
      Resolve uninlined_format_args clippy warnings
      367e1ce2
    • BlackDex's avatar
      Resolve uninlined_format_args clippy warnings · 7390f343
      BlackDex authored
      The upcomming release of Rust 1.67.0 will warn on `uninlined_format_args`.
      This PR resolves that by inlining all these items.
      It also looks nicer.
      7390f343
    • Daniel García's avatar
    • Daniel García's avatar
      Merge branch 'BlackDex-update-libraries' · 5399ee82
      Daniel García authored
      5399ee82
    • pjsier's avatar
    • BlackDex's avatar
      Resolve uninlined_format_args clippy warnings · 912ad645
      BlackDex authored
      The upcomming release of Rust 1.67.0 will warn on `uninlined_format_args`.
      This PR resolves that by inlining all these items.
      It also looks nicer.
      912ad645
    • BlackDex's avatar
      Fix failing large note imports · 00855ee3
      BlackDex authored
      When importing to Vaultwarden (or Bitwarden) notes larger then 10_000
      encrypted characters are invalid. This because it for one isn't
      compatible with Bitwarden. And some clients tend to break on very large
      notes.
      
      We already added a check for this limit when adding a single cipher, but
      this caused issues during import, and could cause a partial imported
      vault. Bitwarden does some validations before actually running it
      through the import process and generates a special error message which
      helps the user indicate which items are invalid during the import.
      
      This PR adds that validation check and returns the same kind of error.
      Fixes #3048
      00855ee3
    • pjsier's avatar
    • pjsier's avatar
    • BlackDex's avatar
      Resolve uninlined_format_args clippy warnings · a263aaa4
      BlackDex authored
      The upcomming release of Rust 1.67.0 will warn on `uninlined_format_args`.
      This PR resolves that by inlining all these items.
      It also looks nicer.
      a263aaa4
    • Rychart Redwerkz's avatar
      Remove `shrink-to-fit=no` · 0a20ba00
      Rychart Redwerkz authored
      This was a workaroud needed for iOS versions before 9.3 and is not part of the recommended viewport meta tag anymore.
      https://www.scottohara.me/blog/2018/12/11/shrink-to-fit.html
      0a20ba00
    • Jeremy Lin's avatar
      Change `text/plain` API responses to `application/json` · 6541600a
      Jeremy Lin authored
      Recent versions of the Bitwarden clients (see bitwarden/clients#3574)
      won't parse non-JSON responses. The most noticeable consequence is that
      `/api/accounts/revision-date` responses won't be parsed, leading to
      `/api/sync` always being called, even when it's not necessary.
      6541600a
    • Daniel García's avatar
      Merge branch 'BlackDex-issue-3048' · 525979d5
      Daniel García authored
      525979d5
    • pjsier's avatar
    • pjsier's avatar
    • BlackDex's avatar
      Resolve uninlined_format_args clippy warnings · e935989f
      BlackDex authored
      The upcomming release of Rust 1.67.0 will warn on `uninlined_format_args`.
      This PR resolves that by inlining all these items.
      It also looks nicer.
      e935989f
    • Rychart Redwerkz's avatar
      Remove `shrink-to-fit=no` · 25c401f6
      Rychart Redwerkz authored
      This was a workaroud needed for iOS versions before 9.3 and is not part of the recommended viewport meta tag anymore.
      https://www.scottohara.me/blog/2018/12/11/shrink-to-fit.html
      25c401f6
    • Jeremy Lin's avatar
      Change `text/plain` API responses to `application/json` · 18b72da6
      Jeremy Lin authored
      Recent versions of the Bitwarden clients (see bitwarden/clients#3574)
      won't parse non-JSON responses. The most noticeable consequence is that
      `/api/accounts/revision-date` responses won't be parsed, leading to
      `/api/sync` always being called, even when it's not necessary.
      18b72da6
    • Daniel García's avatar
      e8e6c899
    • pjsier's avatar
    • Rychart Redwerkz's avatar
      Remove `shrink-to-fit=no` · da9605f2
      Rychart Redwerkz authored
      This was a workaroud needed for iOS versions before 9.3 and is not part of the recommended viewport meta tag anymore.
      https://www.scottohara.me/blog/2018/12/11/shrink-to-fit.html
      da9605f2
    • pjsier's avatar
    • Jeremy Lin's avatar
      Change `text/plain` API responses to `application/json` · b67c5b77
      Jeremy Lin authored
      Recent versions of the Bitwarden clients (see bitwarden/clients#3574)
      won't parse non-JSON responses. The most noticeable consequence is that
      `/api/accounts/revision-date` responses won't be parsed, leading to
      `/api/sync` always being called, even when it's not necessary.
      b67c5b77
    • BlackDex's avatar
      Resolve uninlined_format_args clippy warnings · d30878c4
      BlackDex authored
      The upcomming release of Rust 1.67.0 will warn on `uninlined_format_args`.
      This PR resolves that by inlining all these items.
      It also looks nicer.
      d30878c4
    • BlackDex's avatar
      Fix failing large note imports · 6be26f0a
      BlackDex authored
      When importing to Vaultwarden (or Bitwarden) notes larger then 10_000
      encrypted characters are invalid. This because it for one isn't
      compatible with Bitwarden. And some clients tend to break on very large
      notes.
      
      We already added a check for this limit when adding a single cipher, but
      this caused issues during import, and could cause a partial imported
      vault. Bitwarden does some validations before actually running it
      through the import process and generates a special error message which
      helps the user indicate which items are invalid during the import.
      
      This PR adds that validation check and returns the same kind of error.
      Fixes #3048
      6be26f0a
    • Daniel García's avatar
      Merge branch 'stapelkai-main' · 34a6bfae
      Daniel García authored
      34a6bfae
    • Jeremy Lin's avatar
      Change `text/plain` API responses to `application/json` · 1c8749eb
      Jeremy Lin authored
      Recent versions of the Bitwarden clients (see bitwarden/clients#3574)
      won't parse non-JSON responses. The most noticeable consequence is that
      `/api/accounts/revision-date` responses won't be parsed, leading to
      `/api/sync` always being called, even when it's not necessary.
      1c8749eb
    • Andrés Maldonado's avatar
      Percent-encode org_name in links · 1198c36a
      Andrés Maldonado authored
      If org_name contains spaces, the generated link will not work in some email clients unless it is percent-encoded
      1198c36a
    • BlackDex's avatar
      Optimize config loading messages · 41e6c1a3
      BlackDex authored
      As kinda discussed here #3090, the messages regarding loading the
      configuration files is a bit strange or unclear. There have been some
      other reports regarding this in the past, but wasn't that big a of a
      deal.
      
      But to make the whole process it bit more nice, this PR adjusts the way
      it reports issues and some small changes to the messages to make it all
      a bit more clear.
      
      - Do not report a missing `.env` file, but only send a message when using one.
      - Exit instead of Panic, a panic causes a stacktrace, which isn't needed
        here. I'm using a exit code 255 here so it is different to the other
        exit's we use.
      - Exit on more issues, since if we continue, it could cause
        configuration issues if the user thinks all is fine.
      - Use the actual env file used in the messages instead of `.env`.
      - Added a **INFO** message when loading the `config.json`.
        This makes it consistent with the info message for loading the env file.
      
      Resolves #3090
      41e6c1a3
    • BlackDex's avatar
      Update WebSocket Notifications · 0042c3e4
      BlackDex authored
      Previously the websocket notifications were using `app_id` as the
      `ContextId`. This was incorrect and should have been the device_uuid
      from the client device executing the request. The clients will ignore
      the websocket request if the uuid matches. This also fixes some issues
      with the Desktop client which is able to modify attachments within the
      same screen and causes an issue when saving the attachment afterwards.
      
      Also changed the way to handle removed attachments, since that causes an
      error saving the vault cipher afterwards, complaining about a missing
      attachment. Bitwarden ignores this, and continues with the remaining
      attachments (if any). This also fixes #2591 .
      
      Further some more websocket notifications have been added to some other
      functions which enhance the user experience.
      
      - Logout users when deauthed, changed password, rotated keys
      - Trigger OrgSyncKeys on user confirm and removal
      - Added some extra to the send feature
      
      Also renamed UpdateTypes to match Bitwarden naming.
      0042c3e4
    • pjsier's avatar
    • BlackDex's avatar
      Validate YUBICO_SERVER string (#3003) · 6867d23c
      BlackDex authored
      If the `YUBICO_SERVER` is defined to an empty string, the whole yubikey
      implementation doesn't work anymore.
      
      This PR adds a check for this variable that it at least starts with `https://`.
      
      Resolves #3003
      6867d23c
    • BlackDex's avatar
      Removed unsafe-inline JS from CSP and other fixes · de26af0c
      BlackDex authored
      - Removed `unsafe-inline` for javascript from CSP.
        The admin interface now uses files instead of inline javascript.
      - Modified javascript to work not being inline.
      - Run eslint over javascript and fixed some items.
      - Added a `to_json` Handlebars helper.
        Used at the diagnostics page.
      - Changed `AdminTemplateData` struct to be smaller.
        The `config` was always added, but only used at one page.
        Same goes for `can_backup` and `version`.
      - Also inlined CSS.
        We can't remove the `unsafe-inline` from css, because that seems to
        break the web-vault currently. That might need some further checks.
        But for now the 404 page and all the admin pages are clear of inline scripts and styles.
      de26af0c
    • Alex Martel's avatar
      Remove patched multer-rs · 3f223a75
      Alex Martel authored
      3f223a75
    • Daniel García's avatar
      Merge branch 'jjlin-json-response' · 23f5a62d
      Daniel García authored
      23f5a62d
    • Andrés Maldonado's avatar
      Percent-encode org_name in links · 81e2054f
      Andrés Maldonado authored
      If org_name contains spaces, the generated link will not work in some email clients unless it is percent-encoded
      81e2054f
    • BlackDex's avatar
      Optimize config loading messages · f9337eff
      BlackDex authored
      As kinda discussed here #3090, the messages regarding loading the
      configuration files is a bit strange or unclear. There have been some
      other reports regarding this in the past, but wasn't that big a of a
      deal.
      
      But to make the whole process it bit more nice, this PR adjusts the way
      it reports issues and some small changes to the messages to make it all
      a bit more clear.
      
      - Do not report a missing `.env` file, but only send a message when using one.
      - Exit instead of Panic, a panic causes a stacktrace, which isn't needed
        here. I'm using a exit code 255 here so it is different to the other
        exit's we use.
      - Exit on more issues, since if we continue, it could cause
        configuration issues if the user thinks all is fine.
      - Use the actual env file used in the messages instead of `.env`.
      - Added a **INFO** message when loading the `config.json`.
        This makes it consistent with the info message for loading the env file.
      
      Resolves #3090
      f9337eff
    • BlackDex's avatar
      Update WebSocket Notifications · 2972904e
      BlackDex authored
      Previously the websocket notifications were using `app_id` as the
      `ContextId`. This was incorrect and should have been the device_uuid
      from the client device executing the request. The clients will ignore
      the websocket request if the uuid matches. This also fixes some issues
      with the Desktop client which is able to modify attachments within the
      same screen and causes an issue when saving the attachment afterwards.
      
      Also changed the way to handle removed attachments, since that causes an
      error saving the vault cipher afterwards, complaining about a missing
      attachment. Bitwarden ignores this, and continues with the remaining
      attachments (if any). This also fixes #2591 .
      
      Further some more websocket notifications have been added to some other
      functions which enhance the user experience.
      
      - Logout users when deauthed, changed password, rotated keys
      - Trigger OrgSyncKeys on user confirm and removal
      - Added some extra to the send feature
      
      Also renamed UpdateTypes to match Bitwarden naming.
      2972904e
Loading