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

1666 Commits

Author SHA1 Message Date
Colton Hurst
d545912b67 [PM-22783] Add Feature Flag, Settings Toggle, and Services for Autotype MVP (#15262)
* [PM-22783] Add initial feature flag and settings toggle for autotype MVP

* [PM-22783] Undo Cargo.lock changes

* [PM-22783] Disable console.log block

* [PM-22783] Lint fix

* [PM-22783] Small updates

* [PM-22783] Build fix

* [PM-22783] Use combineLatest in updating the desktop autotype service

* [PM-22783] Check if the user is on Windows

* [PM-22783] Undo access selector html change, linting keeps removing this

* [PM-22783] Fix failing test

* [PM-22783] Update autotypeEnabled to be stored in service

* [PM-22783] Add todo comments

* [PM-22783] Add SlimConfigService and MainDesktopAutotypeService

* [PM-22783] Small fixes
2025-07-15 11:49:15 -04:00
Thomas Avery
4412dbb502 [PM-21883] Add back RemoveUnlockWithPin exemption (#15223) 2025-07-15 09:58:32 -05:00
Maciej Zieniuk
c6fd7b65e6 Feature flag for ForceUpdateKDFSettings (#15618) 2025-07-15 16:11:44 +02:00
Bernd Schoolmann
d1f0c40e2f [PM-23386] Fix fix usages of encrypt service (#15476)
* Fix incorrect usages of encrypt service

* Add docs

* Fix types
2025-07-15 11:56:19 +02:00
Bernd Schoolmann
8250e40c6c [PM-22271] Switch to SDK argon2 implementation, and drop other impls (#15401)
* Switch to SDK argon2 implementation

* Cleanup and update to the latest sdk

* Update package lock

* Remove copy patch

* Fix builds

* Fix test build

* Remove error

* Fix tests

* Fix build

* Run prettier

* Remove argon2 references

* Regenerate index.d.ts for desktop_native napi

* Replace mocked crypto function service type
2025-07-15 11:53:58 +02:00
Brandon Treston
4f84d6b0f6 fix bulk restore for unassigned items (#15533) 2025-07-14 15:50:13 -04:00
Justin Baur
ec7a2613cc [PM-23062] Fix extra signalr connections (#15432)
* Add `globalEnvironment$` property to `EnvironmentService`

* Update `ConfigService` to emit less and have higher quality fallbacks when no user config is available

* Remove debug code

* Fix strict null problems
2025-07-14 09:11:56 -04:00
Jared Snider
c9f642e491 feat(new SendPasswordService): [Auth/PM-23700] Create KM SendPasswordService (#15570)
* PM-23700 - SendPasswordService - create and test

* PM-23700 - SendPassword Service comment clean up

* PM-23700 - Use barrel file exports and register default service.

* PM-23700 - DefaultSendPasswordService - work with Bernd to deliver better service
2025-07-11 13:05:31 -04:00
SmithThe4th
3c6f763233 [PM-23306] "Show cards in autofill" is defaulting to on when the setting is enabled (#15534)
* disable card autofill

* Fixed dependency issues
2025-07-11 12:50:31 -04:00
Jason Ng
bf50160a47 [PM-19562] remove flag pm-18520-desktop-cipher-forms (#15524)
* removing the desktop flag and replacing the route in desktop app routing. removing code from old desktop
2025-07-10 15:30:23 -04:00
Todd Martin
c5be837b51 chore(feature-flag) [PM-22604] Remove 2FA persistence feature flag
* Removed flag.

* Fixed tests to no longer reference flag.

* Fixed test.

* Removed duplicate test class.

* Moved files into folders for yubikey and authenticator

* Removed TwoFactorAuthEmailComponentService since it is no longer needed

* Removed export

* Fixed export
2025-07-10 15:00:49 -04:00
Alex Morask
a53b1e9ffb [PM-21881] Manage payment details outside of checkout (#15458)
* Add billable-entity

* Add payment types

* Add billing.client

* Update stripe.service

* Add payment method components

* Add address.pipe

* Add billing address components

* Add account credit components

* Add component index

* Add feature flag

* Re-work organization warnings code

* Add organization-payment-details.component

* Backfill translations

* Set up organization FF routing

* Add account-payment-details.component

* Set up account FF routing

* Add provider-payment-details.component

* Set up provider FF routing

* Use inline component templates for re-usable payment components

* Remove errant rebase file

* Removed public accessibility modifier

* Fix failing test
2025-07-10 08:32:40 -05:00
Patrick-Pimentel-Bitwarden
1f60bcdcc0 feat(change-password): [PM-18720] (#5319) Change Password Implementation for Non Dialog Cases (#15319)
* feat(change-password-component): Change Password Update [18720] - Very close to complete.

* fix(policy-enforcement): [PM-21085] Fix Bug with Policy Enforcement - Removed temp code to force the state I need to verify correctness.

* fix(policy-enforcement): [PM-21085] Fix Bug with Policy Enforcement - Recover account working with change password component.

* fix(policy-enforcement): [PM-21085] Fix Bug with Policy Enforcement - Made code more dry.

* fix(change-password-component): Change Password Update [18720] - Updates to routing and the extension. Extension is still a wip.

* fix(change-password-component): Change Password Update [18720] - Extension routing changes.

* feat(change-password-component): Change Password Update [18720] - More extension work

* feat(change-password-component): Change Password Update [18720] - Pausing work for now while we wait for product to hear back.

* feat(change-password-component): Change Password Update [18720] - Removed duplicated anon layouts.

* feat(change-password-component): Change Password Update [18720] - Tidied up code.

* feat(change-password-component): Change Password Update [18720] - Small fixes to the styling

* feat(change-password-component): Change Password Update [18720] - Adding more content for the routing.

* feat(change-password-component): Change Password Update [18720] - Removed circular loop for now.

* feat(change-password-component): Change Password Update [18720] - Made comments regarding the change password routing complexities with change-password and auth guard.

* feat(change-password-component): Change Password Update [18720] - Undid some changes because they will be conflicts later on.

* feat(change-password-component): Change Password Update [18720] - Small directive change.

* feat(change-password-component): Change Password Update [18720] - Small changes and added some clarification on where I'm blocked

* feat(change-password-component): Change Password Update [18720] - Org invite is seemingly working, found one bug to iron out.

* refactor(change-password-component): Change Password Update [18720] - Fixed up policy service to be made more clear.

* docs(change-password-component): Change Password Update [18720] - Updated documentation.

* refactor(change-password-component): Change Password Update [18720] - Routing changes and policy service changes.

* fix(change-password-component): Change Password Update [18720] - Wrapping up changes.

* feat(change-password-component): Change Password Update [18720] - Should be working fully

* feat(change-password-component): Change Password Update [18720] - Found a bug, working on password policy being present on login.

* feat(change-password-component): Change Password Update [18720] - Turned on auth guard on other clients for change-password route.

* feat(change-password-component): Change Password Update [18720] - Committing intermediate changes.

* feat(change-password-component): Change Password Update [18720] - The master password policy endpoint has been added! Should be working. Testing now.

* feat(change-password-component): Change Password Update [18720] - Minor fixes.

* feat(change-password-component): Change Password Update [18720] - Undid naming change.

* feat(change-password-component): Change Password Update [18720] - Removed comment.

* feat(change-password-component): Change Password Update [18720] - Removed unneeded code.

* fix(change-password-component): Change Password Update [18720] - Took org invite state out of service and made it accessible.

* fix(change-password-component): Change Password Update [18720] - Small changes.

* fix(change-password-component): Change Password Update [18720] - Split up org invite service into client specific implementations and have them injected into clients properly

* feat(change-password-component): Change Password Update [18720] - Stopping work and going to switch to a new branch to pare down some of the solutions that were made to get this over the finish line

* feat(change-password-component): Change Password Update [18720] - Started to remove functionality in the login.component and the password login strategy.

* feat(change-password-component): Change Password Update [18720] - Removed more unneded changes.

* feat(change-password-component): Change Password Update [18720] - Change password clearing state working properly.

* fix(change-password-component): Change Password Update [18720] - Added docs and moved web implementation.

* comments(change-password-component): Change Password Update [18720] - Added more notes.

* test(change-password-component): Change Password Update [18720] - Added in tests for policy service.

* comment(change-password-component): Change Password Update [18720] - Updated doc with correct ticket number.

* comment(change-password-component): Change Password Update [18720] - Fixed doc.

* test(change-password-component): Change Password Update [18720] - Fixed tests.

* test(change-password-component): Change Password Update [18720] - Fixed linting errors. Have more tests to fix.

* test(change-password-component): Change Password Update [18720] - Added back in ignore for typesafety.

* fix(change-password-component): Change Password Update [18720] - Fixed other type issues.

* test(change-password-component): Change Password Update [18720] - Fixed tests.

* test(change-password-component): Change Password Update [18720] - Fixed more tests.

* test(change-password-component): Change Password Update [18720] - Fixed tiny duplicate code.

* fix(change-password-component): Change Password Update [18720] - Fixed desktop component.

* fix(change-password-component): Change Password Update [18720] - Removed unused code

* fix(change-password-component): Change Password Update [18720] - Fixed locales.

* fix(change-password-component): Change Password Update [18720] - Removed tracing.

* fix(change-password-component): Change Password Update [18720] - Removed duplicative services module entry.

* fix(change-password-component): Change Password Update [18720] - Added comment.

* fix(change-password-component): Change Password Update [18720] - Fixed unneeded call in two factor to get user id.

* fix(change-password-component): Change Password Update [18720] - Fixed a couple of tiny things.

* fix(change-password-component): Change Password Update [18720] - Added comment for later fix.

* fix(change-password-component): Change Password Update [18720] - Fixed linting error.

* PM-18720 - AuthGuard - move call to get isChangePasswordFlagOn down after other conditions for efficiency.

* PM-18720 - PasswordLoginStrategy tests - test new feature flagged combine org invite policies logic for weak password evaluation.

* PM-18720 - CLI - fix dep issue

* PM-18720 - ChangePasswordComp - extract change password warning up out of input password component

* PM-18720 - InputPassword - remove unused dependency.

* PM-18720 - ChangePasswordComp - add callout dep

* PM-18720 - Revert all anon-layout changes

* PM-18720 - Anon Layout - finish reverting changes.

* PM-18720 - WIP move of change password out of libs/auth

* PM-18720 - Clean up remaining imports from moving change password out of libs/auth

* PM-18720 - Add change-password barrel file for better import grouping

* PM-18720 - Change Password comp - restore maxWidth

* PM-18720 - After merge, fix errors

* PM-18720 - Desktop - fix api service import

* PM-18720 - NDV - fix routing.

* PM-18720 - Change Password Comp - add logout service todo

* PM-18720 - PasswordSettings - per feedback, component is already feature flagged behind PM16117_ChangeExistingPasswordRefactor so we can just delete the replaced callout (new text is in change-password comp)

* PM-18720 - Routing Modules - properly flag new component behind feature flag.

* PM-18720 - SSO Login Strategy - fix config service import since it is now in shared deps from main merge.

* PM-18720 - Fix SSO login strategy tests

* PM-18720 - Default Policy Service - address AC PR feedback

---------

Co-authored-by: Jared Snider <jsnider@bitwarden.com>
Co-authored-by: Jared Snider <116684653+JaredSnider-Bitwarden@users.noreply.github.com>
2025-07-10 09:08:25 -04:00
Andreas Coroiu
90b7197279 [PM-20210] Expand badge API (#14801)
* feat: scaffold new badge service structure

* feat: add state override

* feat: add priority-based override

* feat: implement state clearing

* feat: add docs to badge service functions

* feat: add support for setting icon

* feat: implement unsetting

* feat: implement setting text

* feat: add support for setting background

* fix: default icon

* feat: clean up old update-badge

* feat: save state using StateProvider

* feat: migrate auth status badge updating

* feat: migrate autofill badge updating

* fix: auto set to default values

* chore: woops, clean up copy-pasta

* fix: lint and types

* chore: nit updates from PR review

* feat: remove ability to send in arbitrary icons

* feat: move init to separate function

* fix: wrong import

* fix: typing issues

* fix: try again to fix typing issues

* feat: scaffold tests for new tabId-specific states

* feat: add diffence util function

* feat: add support for limiting state to tabId

* feat: re-implement autofill badge updater to only update when a tab actually changes

* feat[wip]: always set all tabs when changing the general state

* feat[wip]: implement general states for mutliple open tabs

* feat[wip]: implement fully working multi-tab functionality

* feat: optimize api calls

* feat: adjust storage

* chore: clean up old code

* chore: remove unused log service

* chore: minor tweaks

* fix: types

* fix: race condition causing wrong icon on startup

The service assumes that the first emission from the state will be an empty one and discards it
(techincally it just doesn't act on it because pairwise requires a minimum two emissions). This
caused issues when a service is able to update the state before the observable got a change to
properly initialize. To fix this we simply force an empty emission before anything else,
that way we will always react to the emission from the state provider (because that would end up
being the second emission). We then use distinctUntilChanged to avoid unecessarily acting on
an empty state.
2025-07-09 15:38:33 -04:00
SmithThe4th
b62f6c7eb5 Fixed from json conversion for encyrpted key (#15536) 2025-07-09 13:24:58 -04:00
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
✨ Audrey ✨
d5e7f3bd04 [PM-23514] add send access storage location (#15523) 2025-07-08 16:02:14 -04: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
Jordan Aasen
0b1545264b [PM-23181] - User can access card items in their personal vault if they belong to another org (#15462)
* hide personal vault cards if any org has enabled restricted card item

* fix comment
2025-07-07 13:56:34 -04:00
SmithThe4th
4d9516cd96 [PM-22812] Attachments get corrupted when downgrading from cipherkeys (#15324)
* Map decrypted key returned from SDK to client

* Updated sdk dependency
2025-07-07 13:48:05 -04:00
Oscar Hinton
71bef25a96 Resolve breaking changes in the SDK (#15472) 2025-07-07 11:49:29 -04:00
Nick Krantz
b54c40ff00 Refactor PendingSecurityTasks to RefreshSecurityTasks (#15021)
- Allows for more general use case of security task notifications
2025-07-07 09:26:34 -05:00
Jason Ng
c7fc9b88fc [PM-23197] update cipherService to return decCiphers (#15433)
* update cipherService to return decCiphers, update input to use signal, refactor observable, update spec
2025-07-03 17:35:50 -04:00
cyprain-okeke
2d897e8cea Fix the failing billing steps (#15459) 2025-07-03 18:07:51 +01: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
SmithThe4th
522acf5718 Fixed date conversion issue when importing (#15434) 2025-07-03 11:12:08 -04:00
Nick Krantz
ab4af7deed [PM-22179] Redirect user to /setup-extension (#15375)
* add end user feature flag

* add initial setup extension component and route

* redirect users from registration completion to the setup extension page

* add `hideIcon` to anon layout for web
- matches implementation on the browser.

* integrate with anon layout for extension wrapper

* add initial loading state

* conditionally redirect the user upon initialization

* redirect the user to the vault if the extension is installed

* add initial copy for setup-extension page

* add confirmation dialog for skipping the extension installation

* add success state for setup extension page

* only show loggedin toast when end user activation is not enabled.

* add image alt

* lower threshold for polling extension

* close the dialog when linking to the vault

* update party colors

* use the platform specific registration service to to only forward the web registrations to `/setup-extension`

* call `super` rather than `/vault` directly, it could change in the future
2025-07-03 06:14:25 -05:00
cd-bitwarden
cef6a5e8d0 [SM-1273] Adding enums for additional event logs for secrets (#15274)
* Adding enums for additional event logs for secrets

* updating messages

* Updating messages to be consistent for logs
2025-07-03 10:49:39 +02:00
rr-bw
cc65f5efc6 feat(set-initial-password): [Auth/PM-18784] SetInitialPasswordComponent Handle TDE Offboarding (#14861)
This PR makes it so that `SetInitialPasswordComponent` handles the TDE offboarding flow where an org user now needs to set an initial master password.

Feature flag: `PM16117_SetInitialPasswordRefactor`
2025-07-02 07:23:45 -07:00
Addison Beck
5497063e7e refactor(state): point storage imports to @bitwarden/storage-core (#15414)
This change updates every import of StorageServiceProvider,
AbstractStorageService, and ObservableStorageService throughout the common
state code (including spec files) to pull from the new
@bitwarden/storage-core package instead of their old relative paths. The cuts
out one of the issues that needs to be resolved before state can hold its own
as a library without importing common.
2025-07-01 19:23:34 -04:00
Daniel García
586d91e816 Redact SignalR token from logs (#15402) 2025-07-01 22:02:57 +02:00
Justin Baur
172623e050 [PM-20247] Initialize user-core library (#15029)
* Initialize user-core library

* Run `npm install`

* Fix patched generator bug
2025-07-01 15:59:11 -04:00
Anders Åberg
5eca3a5916 [PM-18809] Passkey: use ArrayBuffer instead of Uint8Array (#15092)
* Passkey: use ArrayBuffer instead of Uint8Array to conform WebAuthn spec

* ArrayBufferView generics was too modern for this project

* Correctly update the types from Uint8arrays to ArrayBuffers

* Fixed broken tests + bugs

* Removed arrayBufferViewToArrayBuffer as it's not needed in this invocation paths

---------

Co-authored-by: ozraru <ozraru@raru.work>
Co-authored-by: Todd Martin <106564991+trmartin4@users.noreply.github.com>
2025-07-01 21:00:13 +02:00
Justin Baur
4cb80b4a03 Platform logging lib (#15338)
* Add Platform Logging Lib

* Move console log spec and test util back into libs/common

* Fix ConsoleLogServer re-export

* Fix types error
2025-07-01 13:47:02 -04:00
Addison Beck
782dc930ad refactor(storage-test-utils): cut a new library for storage test tools (#15259)
* refactor(platform): generate a storage-test-utils library

* refactor(storage-test-utils): move FakeStorageService out of common
2025-06-30 13:56:26 -04:00
SmithThe4th
ea5224da25 Properly converted date strings during imports and provided default values (#15398) 2025-06-30 13:04:01 -04:00
Jared McCannon
64f8073fdf Removed feature flag for OptimizeNestedTraverseTypescript and vnext methods related to it. (#15314) 2025-06-27 13:13:21 -05:00
Nick Krantz
cb36b96855 [PM-22178] Add WebBrowserInteractionService (#15261)
* add `WebBrowserInteractionService` and check for the extension observable

* update checkForExtension to use observables rather than window timeouts

* add open extension to WebBrowserInteractionService

* add at-risk-passwords to `PopupPageUrls`

* refactor `PopupPageUrls` to `ExtensionPageUrls`

* add test for passing a page

* refactor `Default` to `Index`

* clean up complete/next issue using `race`

* refactor page to url

* continue listening for messages from the extension after subscribed

* mark risk passwords a deprecated

* remove takeUntilDestroyed

* add back `takeUntilDestroyed` for internal `messages`

* removed null filter - unneeded

* add tap to send message for extension installation

* add check for accepted urls to prevent any bad actors from opening the extension
2025-06-27 12:55:20 -05: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
SmithThe4th
bfb71a3405 [PM-22996] Failed to decrypt ciphers: TypeError: this.uriChecksum is null (#15355) 2025-06-27 09:59:38 -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
Daniel James Smith
28e799f2bb Removing unused feature flag "item-share" (#15327)
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
2025-06-26 08:17:15 -04:00
Andreas Coroiu
71d4f989b7 [PM-18042] Build request response structure (#15163)
* feat: add support for discover command

* feat: make client public to allow RPC

* feat: update SDK
2025-06-26 14:01:31 +02:00
Todd Martin
473ab3a1f7 feat(feature-flags): Add Device-Identifier header to unauthenticated requests
* Added header to unauthenticated requests

* Added comment
2025-06-26 07:27:50 -04:00
Justin Baur
7d2b97b1df [PM-22573] Don't call server on existing subscription (#15154)
* Don't put subscription to our server when it's existing

* Only update server when subscription-user associations change

---------

Co-authored-by: Matt Gibson <mgibson@bitwarden.com>
2025-06-25 21:42:06 -04:00
Brandon Treston
012ce25e49 add encrypted collection name to confirmUser request (#15156) 2025-06-24 09:34:48 -04:00
Brandon Treston
1c237a3753 [PM-20633] rename personal ownership (#15228)
* sensible renames

* renames

* clean up comments
2025-06-24 09:31:40 -04:00
Rui Tomé
fa23a905e0 [PM-22442] Refactor ApiService: Remove unused methods for collection user management (#15208) 2025-06-24 10:21:35 +01:00
Addison Beck
95841eb078 refactor(storage-core): move storage files out of @bitwarden/common (#15076)
* refactor(platform): generate @bitwarden/storage-core boilerplate

* refactor(storage-core): move storage files out of @bitwarden/common

* chore(naming): rename AbstractStorageService to StorageService
2025-06-23 16:00:54 -04:00
rr-bw
5bd4d1691e refactor(auth-guard): [PM-22822] Update AuthGuard to explicitly handle each forceSetPasswordReason (#15252)
Update the `authGuard` to explicitly handle each `ForceSetPasswordReason`
2025-06-23 11:45:27 -07:00