1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-06 00:13:28 +00:00
Commit Graph

608 Commits

Author SHA1 Message Date
Thomas Avery
09fb74679d [PM-21912] Require userID for KeyService's hasUserKey (#14890)
* Update keyService hasUserKey to require userId and remove unused/duplicate methods

* Update lock component consumer

* Update send commands to pass in userId

* update SSO login to pass in userID

* Update bw serve to pass in userID

* remove unneeded method from electron-key.service
2025-07-09 11:53:16 -05:00
Jared Snider
b9f930a609 fix(tde-offboarding): Auth/PM-19165 - Handle TDE offboarding on an untrusted device with warning message (#15430)
When a user logs in via SSO after their org has offboarded from TDE, we now show them a helpful error message stating that they must either login on a Trusted device, or ask their admin to assign them a password.

Feature flag: `PM16117_SetInitialPasswordRefactor`
2025-07-08 09:58:03 -07:00
renovate[bot]
aadb8853b1 [deps] Vault: Update @koa/multer to v4 (#15502)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Nick Krantz <125900171+nick-livefront@users.noreply.github.com>
2025-07-08 09:19:52 -05:00
Todd Martin
d1c6b334b1 feat(DuckDuckGo): [PM-9388] Add new device type for DuckDuckGo browser
* Add new device type for DuckDuckGo browser

* Added feature support property for sync domains

* Added new features

* Added isDuckDuckGo() to CLI

* Addressed PR feedback.

* Renamed new property

* Fixed rename that missed CLI.
2025-07-03 11:27:28 -04:00
Github Actions
3ae5e063a7 Bumped client version(s) 2025-07-01 17:11:29 +00:00
SmithThe4th
4bfcc9d076 [PM-23008] Error when attempting to export vault (#15397)
* moved restrictedItemTypesService creation before export service is created

* Fixed cliRestrictedItemTypesService arrangement
2025-06-30 15:32:19 +00:00
Jordan Aasen
62750a06ec [PM-36] - [Tech Debt] Move SearchService to libs/common/vault (#15251)
* wip - migrate search service to vault

* fix import
2025-06-27 08:16:59 -07:00
Justin Baur
4c2475a515 [PM-22343] Bump non-cli to Node 22 (#15058)
* Bump non-cli to Node 22

* Fix working-directory

* Lets see what breaks

* Maybe this works
2025-06-26 18:05:37 -04:00
Ike
7c9e95271d [PM -20329] browser auth approval client api service (#15161)
* feat: Create methods for calling GET auth-request/pending endpoint.

* feat: update banner service on web, and desktop vault

* test: updated banner test to use auth request services

* fix: DI fixes

* feat: add RequestDeviceId to AuthRequestResponse

* fix: add Browser Approvals feature flags to desktop vault and web vault banner service

* test: fix tests for feature flag
2025-06-26 11:13:06 -04:00
Andreas Coroiu
556ec500ff [PM-12416] Fix cli signing issues (#15132)
* Add macOS notarization and signing steps to CI workflow

* Fix

* Fix path

* Test logic changes for signing

* Test logic

* feat: remove runtime hardening option

* feat: try using entitlements instead

* try removing unsigned memory entitlement

* fix: revert changes, unsigned memory required

---------

Co-authored-by: Michal Checinski <mchecinski@bitwarden.com>
Co-authored-by: Vince Grassia <593223+vgrassia@users.noreply.github.com>
2025-06-24 09:36:14 +02:00
SmithThe4th
e291e2df0a [PM-21451] [Vault] [CLI] Changes to Enforce "Remove card item type policy" (#15187)
* Created new service to get restricted types for the CLI

* Created service for cli to get restricted types

* Utilized restriction service in commands

* Renamed function

* Refactored service and made it simpler to check when a cipher type is restricted or not

* Moved service to common so it can be utilized on the cli

* Refactored service to use restricted type service

* Removed userId passing from commands

* Exclude restrict types from export

* Added missing dependency

* Added missing dependency

* Added missing dependency

* Added service utils commit from desktop PR

* refactored to use reusable function

* updated reference

* updated reference

* Fixed merge conflicts

* Refactired services to use isCipherRestricted

* Refactored restricted item types service

* Updated services to use the reafctored item types service
2025-06-23 09:04:56 -07:00
Github Actions
437706917c Bumped client version(s) 2025-06-16 13:05:45 +00:00
renovate[bot]
b6f402faa8 [deps] Vault: Update form-data to v4.0.2 (#14468)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: cd-bitwarden <106776772+cd-bitwarden@users.noreply.github.com>
Co-authored-by: SmithThe4th <gsmith@bitwarden.com>
2025-06-13 09:41:23 -07:00
Thomas Avery
90b07728d7 [PM-22133] Require userID for clearStoredUserKey (#14973) 2025-06-10 17:28:50 -05:00
Rui Tomé
b5bddd0b06 [PM-17154] Limit item deletion feature flag removal (#15094)
* Refactor components to remove limitItemDeletion feature flag usage

This commit simplifies the logic in various components by removing the limitItemDeletion feature flag. The conditions for displaying restore and delete actions are now based solely on the cipher's permissions, enhancing code clarity and maintainability.

* Refactor cipher deletion logic to remove the feature flag and collection ID dependency

This commit updates the cipher deletion logic across multiple components and services by removing the unnecessary dependency on collection IDs. The `canDeleteCipher$` method now solely relies on the cipher's permissions, simplifying the code and improving maintainability.

* Remove LimitItemDeletion feature flag from feature-flag enum and default values

* Remove configService from ServiceContainer and MainBackground constructor parameters

* Remove configService from RestoreCommand instantiation in OssServeConfigurator and VaultProgram classes
2025-06-10 09:57:34 +01:00
Oscar Hinton
18573bdc48 [PM-22250] Bump open (#15011)
Upgrade open to latest version.
2025-06-06 12:06:14 +02:00
Todd Martin
2c404d35d4 fix(2fa): Update CLI to send email regardless of number of methods 2025-06-05 15:55:55 -04:00
Bernd Schoolmann
23ec6bacc9 [PM-20225] Prevent legacy users without userkey from logging in (#14267)
* Prevent legacy users without userkey from logging in

* Remove further web-migration code for legacy users

* Add i18n for legacy user error message

* Update comment

* Remove migrate legacy component

* Remove i18n messages

* Remove migrate legacy encryption reference
2025-06-02 23:56:29 +02:00
Addison Beck
26caeb3083 Implement and extend tsconfig.base across projects (#14554)
* Implement and extend tsconfig.base across projects

* fixup! Merge remote-tracking branch 'origin/main' into rename-tsconfig

* fix: import tsconfig.base from components

* fix: skip typechecking node modules

* fixing tests

* fix the tests for real

* undo accidentally change
2025-06-02 20:38:17 +00:00
Oscar Hinton
85cef971c6 Add semver as dependency (#15005) 2025-05-30 15:31:11 +02:00
Oscar Hinton
5423ab3268 [PM-21934] Upgrade to eslint 9 (#14754)
Upgrades to Eslint v9. Since this is a major version there were breaking changes, but since we've previously migrated to flat configs in #12806 those were minimal.
2025-05-27 13:13:15 -04:00
renovate[bot]
0f9f6a1c5d [deps] Tools: Update papaparse to v5.5.3 (#14966)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel James Smith <2670567+djsmith85@users.noreply.github.com>
2025-05-27 18:58:56 +02:00
Thomas Avery
bd29397fd8 [PM-21611] Require userId on KeyService clear methods (#14788) 2025-05-22 13:55:26 -05:00
SmithThe4th
46a0b709fe [PM-21644] Cannot retrieve attachment from bw serve (#14806)
* Modified saveAttachmenttofIle to implement callback attachment content decryption

* renamed parameter
2025-05-22 09:15:30 -04:00
Bernd Schoolmann
d93f547cfb [PM-21001] Move platform code to new encrypt service interface (#14544)
* Move platform code to new encrypt service interface

* Fix tests

* Fix tests

* Fix cli build
2025-05-20 19:45:40 +02:00
renovate[bot]
b09b22a47b [deps] AC: Update core-js to v3.42.0 (#14476)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Brandon Treston <btreston@bitwarden.com>
2025-05-19 10:09:33 -04:00
Maciej Zieniuk
239556b55f [PM-18017] Show key connector domain in remove password page (#14695)
* Passed in userId on RemovePasswordComponent.

* Added userId on other references to KeyConnectorService methods

* remove password component refactor, test coverage, enabled strict

* explicit user id provided to key connector service

* redirect to / instead when user not logged in or not managing organization

* key connector service explicit user id

* key connector service no longer requires account service

* key connector service missing null type

* cli convert to key connector unit tests

* remove unnecessary SyncService

* error toast not showing on ErrorResponse

* bad import due to merge conflict

* bad import due to merge conflict

* missing loading in remove password component for browser extension

* error handling in remove password component

* organization observable race condition in key-connector

* usesKeyConnector always returns boolean

* unit test coverage

* key connector reactive

* reactive key connector service

* introducing convertAccountRequired$

* cli build fix

* moving message sending side effect to sync

* key connector service unit tests

* fix unit tests

* move key connector components to KM team ownership

* new unit tests in wrong place

* key connector domain shown in remove password component

* type safety improvements

* convert to key connector command localization

* key connector domain in convert to key connector command

* convert to key connector command unit tests with prompt assert

* organization name placement change in the remove password component

* unit test update

* key connector url required to be provided when migrating user

* unit tests in wrong place after KM code ownership move

* infinite page reload

* failing unit tests

* failing unit tests

---------

Co-authored-by: Todd Martin <tmartin@bitwarden.com>
2025-05-19 08:58:51 -04:00
Github Actions
a82eb8c22b Bumped client version(s) 2025-05-19 10:40:05 +00:00
Maciej Zieniuk
e73f902aee [PM-18576] Fix missing user id on remove password (#13777)
* Passed in userId on RemovePasswordComponent.

* Added userId on other references to KeyConnectorService methods

* remove password component refactor, test coverage, enabled strict

* explicit user id provided to key connector service

* redirect to / instead when user not logged in or not managing organization

* key connector service explicit user id

* key connector service no longer requires account service

* key connector service missing null type

* cli convert to key connector unit tests

* remove unnecessary SyncService

* error toast not showing on ErrorResponse

* bad import due to merge conflict

* bad import due to merge conflict

* missing loading in remove password component for browser extension

* error handling in remove password component

* organization observable race condition in key-connector

* usesKeyConnector always returns boolean

* unit test coverage

* key connector reactive

* reactive key connector service

* introducing convertAccountRequired$

* cli build fix

* moving message sending side effect to sync

* key connector service unit tests

* fix unit tests

* unit tests in wrong place after KM code ownership move

* infinite page reload

* failing unit tests

* failing unit tests

---------

Co-authored-by: Todd Martin <tmartin@bitwarden.com>
2025-05-19 08:51:46 +02:00
SmithThe4th
ad3121f535 [PM-12423] Migrate Cipher Decryption to Use SDK (#14206)
* Created mappings for client domain object to SDK

* Add abstract decrypt observable

* Added todo for future consideration

* Added implementation to cipher service

* Added adapter and unit tests

* Created cipher encryption abstraction and service

* Register cipher encryption service

* Added tests for the cipher encryption service

* changed signature

* Updated feature flag name

* added new function to be used for decrypting ciphers

* Added new encryptedKey field

* added new function to be used for decrypting ciphers

* Manually set fields

* Added encrypted key in attachment view

* Fixed test

* Updated references to use decrypt with feature flag

* Added dependency

* updated package.json

* lint fix

* fixed tests

* Fixed small mapping issues

* Fixed test

* Added function to decrypt fido2 key value

* Added function to decrypt fido2 key value and updated test

* updated to use sdk function without prociding the key

* updated localdata sdk type change

* decrypt attachment content using sdk

* Fixed dependency issues

* updated package.json

* Refactored service to handle getting decrypted buffer using the legacy and sdk implementations

* updated services and component to use refactored version

* Updated decryptCiphersWithSdk to use decryptManyLegacy for batch decryption, ensuring the SDK is only called once per batch

* Fixed merge conflicts

* Fixed merge conflicts

* Fixed merge conflicts

* Fixed lint issues

* Moved getDecryptedAttachmentBuffer to cipher service

* Moved getDecryptedAttachmentBuffer to cipher service

* ensure CipherView properties are null instead of undefined

* Fixed test

* ensure AttachmentView properties are null instead of undefined

* Linked ticket in comment

* removed unused orgKey
2025-05-14 07:30:01 -07:00
Oscar Hinton
9a7089594e [PM-19878] Add core-js to cli (#14696)
* Add core-js to cli

* Add core-js to bit-cli
2025-05-13 16:59:56 +02:00
Todd Martin
4c68f61d47 feat(CLI-SSO-Login): [Auth/PM-21116] CLI - SSO Login - Add SSO Org Identifier option (#14605)
* Add --identifier option for SSO on CLI

* Add option for identifier

* Moved auto-submit after the setting of client arguments

* Adjusted comment

* Changed to pass in as SSO option

* Renamed to orgSsoIdentifier for clarity

* Added more changes to orgSsoIdentifier.
2025-05-13 10:58:48 -04:00
renovate[bot]
9af7963609 [deps] Vault: Update @koa/multer to v3.1.0 (#14495)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Nick Krantz <125900171+nick-livefront@users.noreply.github.com>
2025-05-12 14:58:48 -05:00
renovate[bot]
7d01c42e37 [deps] Vault: Update multer to v1.4.5-lts.2 (#14469)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: SmithThe4th <gsmith@bitwarden.com>
2025-05-12 15:42:21 -04:00
Justin Baur
1b756df749 [PM-14484] ApiService showing html in error message (#14658)
* Make ApiService more testable

* Add ApiService tests

* Switch to only reading text/plain content
2025-05-09 20:21:25 -04:00
Todd Martin
4191bb9533 chore(captcha): [PM-15162] Remove handling of captcha enforcement and bypass token
* Removed captcha references.

* Removed connectors from webpack

* Fixed extra parameter.

* Resolve merge conflicts.

* Fixed extra argument.

* Fixed failing tests.

* Fixed failing test.

* Accessibility cookie cleanup

* Cleaned up accessibility component.

* Deleted old registration endpoint

* Remove unused register request object.

* Fixed merge error that changed font family.

* Fixed formatting from merge.

* Linting
2025-05-09 10:44:11 -04:00
Alec Rippberger
3030eb7552 [PM-19212] Consolidate password set routing to AuthGuard using ForceSetPasswordReason (#14356)
* Consolidates component routing, removing routing to update-temp-password from components. All routing to update-temp-password should happen in the AuthGuard now.

---------

Co-authored-by: Jared Snider <jsnider@bitwarden.com>
Co-authored-by: Todd Martin <tmartin@bitwarden.com>
2025-05-08 11:24:52 -05:00
Bernd Schoolmann
744c1b1b49 [PM-21001] Move vault code to new encrypt service interface (#14546)
* Move vault code to new encrypt service interface

* Fix tests
2025-05-06 21:24:53 +00:00
Brandon Treston
fd43222938 [PM-19383] admins unable to download attachments (#14363)
* add admin support for downloading attachments

* fix delete and upload

* fix delete admin to return a response

* fix upload

* add missing param

* use getCipherAdmin

* fix cli
2025-05-05 13:36:49 -04:00
Matt Bishop
8090586b52 Fix some references to master (#14578)
* Fix some references to master

* Fix broken links
2025-05-01 07:18:09 -07:00
Thomas Avery
d43e4757df [PM-7604] Require target UserID for KdfConfigService (#14380)
* Require userId for KdfConfigService

* Update auth team callers

* Update tools team callers
2025-04-29 17:25:27 -05:00
renovate[bot]
438f90c987 [deps] Autofill: Update tldts to v7 (#14510)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-29 12:20:29 -04:00
Bernd Schoolmann
fd0db40f79 [PM-20492] Refactor symmetric keys - remove key buffer representation, migrate consumers to .toEncoded() (#14371)
* Refactor encrypt service to expose key wrapping

* Fix build

* Undo ts strict removal

* Fix wrong method being used to encrypt key material

* Rename parameters and remove todo

* Add summary to encrypt

* Update libs/common/src/key-management/crypto/services/encrypt.service.implementation.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Update libs/common/src/key-management/crypto/services/encrypt.service.implementation.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Update libs/common/src/key-management/crypto/services/encrypt.service.implementation.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Update libs/common/src/key-management/crypto/services/encrypt.service.implementation.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Update libs/common/src/key-management/crypto/abstractions/encrypt.service.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Update libs/common/src/key-management/crypto/services/encrypt.service.implementation.ts

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>

* Add tests for unhappy paths

* Add test coverage

* Add links

* Remove direct buffer access

* Fix build on cli

---------

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>
2025-04-25 19:26:39 +02:00
Todd Martin
26273ca072 Update copyright year to 2025 (#14364)
Co-authored-by: Daniel James Smith <2670567+djsmith85@users.noreply.github.com>
2025-04-24 13:46:20 -04:00
renovate[bot]
f521afa3ae [deps] Tools: Update jsdom to v26.1.0 (#14397)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel James Smith <2670567+djsmith85@users.noreply.github.com>
2025-04-24 14:39:31 +02:00
Github Actions
1b6f75806d Bumped client version(s) 2025-04-21 14:22:41 +00:00
Maciej Zieniuk
4da03821ce move key connector components to KM team ownership (#14008) 2025-04-18 08:23:52 -07:00
Daniel James Smith
170f97da8e [PM-20333] Remove "export-attachments" feature flag (#14310)
* Remove usage of export-attachments feature flag

* Remove export-attachments feature flag definition

* Update export.command documentation

---------

Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
2025-04-17 08:58:16 -04:00
renovate[bot]
c4c9db5121 [deps] Vault: Update koa to v2.16.1 [SECURITY] (#14197)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-17 08:49:07 -04:00
aj-bw
c7259b4cb1 BRE-536/Add-ARM-targz-builds-for-desktop-and-cli (#14270)
* Test ARM64 build

* Remove sudo

* Change to public preview runner

* Change cache key for architectures

* Test

* Test

* Test

* remove x86 musl target - troubleshooting build error

* native module troubleshooting

* remove cross-platform for testing

* attempt to resolve cross-platform issue

* support more arm64 build types

* fix missed amd to arm update

* missing dependency during env setup

* lxd troubleshooting

* install lxd with snap instead

* electron-builder debug

* simplified script for testing

* testing

* 22.04 to 20.04

* try ubuntu 24.04 runner

* add dist script

* update build command

* troubleshoot 24.04 compatibility

* remove lxd before merging main

* add comment, bump arm runner down to 22.04

* revert to tar.gz support only for this PR

* testing cli arm builds

* fix build target designation

* adjust runner designation

* runner name typo

* not needed currently

* adjust build.js logic and call in workflow

* address styling feedback and unnecessary rust toolchain call

* simplify build cli os matrix

* revert x86 linux builds to cross-platform command for build.js

---------

Co-authored-by: Vince Grassia <593223+vgrassia@users.noreply.github.com>
2025-04-17 08:21:24 -04:00