1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-01-23 21:31:29 +01:00
Commit Graph

1956 Commits

Author SHA1 Message Date
Matt Gibson
6ef3e9a076
[PM-16831] TS Strict crypto function service (#12737)
* strict types in crypto function services

* Improve aesDecrypt types
2025-01-09 18:58:22 -05:00
Bernd Schoolmann
8cabb36c99
[PM-16699] Add decrypt trace for decrypt failures (#12749)
* Improve decrypt failure logging

* Rename decryptcontext to decrypttrace

* Improve docs

* Revert changes to decrypt logic

* Revert keyservice decryption logic change

* Undo one more change to decrypt logic
2025-01-09 20:23:55 +01:00
Thomas Avery
8cfa30acb5
[PM-16889] Add KM lib to tailwind configs (#12783)
Add KM lib to tailwind configs
2025-01-09 13:07:26 -06:00
1fexd
a872f67523
fix: Don't try to load icon for .onion/.i2p URIs (#9125)
Co-authored-by: Bernd Schoolmann <mail@quexten.com>
Co-authored-by: Jason Ng <jng@bitwarden.com>
2025-01-09 13:23:17 -05:00
✨ Audrey ✨
f1c3c690a7
remove circular dependency from @bitwarden/generator-core (#12785) 2025-01-09 13:18:45 -05:00
Jared McCannon
3550a904dc
[PM-13764] - Update Collection Settings (#12734)
* Updating org when collection settings change.
2025-01-09 10:32:21 -06:00
Bernd Schoolmann
67a59b6072
[PM-15584] Fix autoprompt safari process reload (#12352)
* Move ownership of biometrics to key-management

* Move biometrics ipc ownership to km

* Move further files to km; split off preload / ipc to km

* Fix linting

* Fix linting

* Fix tests

* Extract biometric messaging service

* Fix tests

* Update .github/CODEOWNERS

Co-authored-by: Maciej Zieniuk <167752252+mzieniukbw@users.noreply.github.com>

* Update .github/CODEOWNERS

Co-authored-by: Maciej Zieniuk <167752252+mzieniukbw@users.noreply.github.com>

* Change ownership of native messaging to key-management

* Initial refactor

* Initial refactor

* Continued refactor

* Continued refactor

* Add message for when biometric unlock is not configured in desktop app

* Clean up lock component

* Clean up lock component html

* Fix build

* Fix status for windows and linux

* Continue refactor

* Refactor browser

* Fix unlock on extensions and add message enums

* Implement safari and fix setup

* Fix cli and web

* Make tests pass

* Add backward compatibility

* Fix version incompatibility

* Clean up auto-bio-prompt on desktop

* Fix biometric auto prompt on browser

* Fix tests

* Remove logging

* Add null in return type of unlockwithbiometricsforuser

* Move biometrics to libs/key-management

* Add README to capital whitelist

* Update package-lock.json

* Move km to key-management

* Move km to key-management

* Fix build for cli

* Import fixes

* Apply prettier fix

* Fix test

* Import fixes

* Import fixes

* Update libs/key-management/README.md

Co-authored-by: Maciej Zieniuk <167752252+mzieniukbw@users.noreply.github.com>

* Update libs/key-management/package.json

Co-authored-by: Maciej Zieniuk <167752252+mzieniukbw@users.noreply.github.com>

* Update lock file

* Change imports to top level km package

* Change import order

* Fix cli build

* Remove debug logging

* Fix user not showing in "notenabledinconnecteddesktopapp" helptext

* Document autoprompt and enable it on manual account switch

* Fix build

* Fix unlock on windows

* Rename duckduckgo message handler service

* Fix merge conflicts

* Fix codeowners

* Fix biometric message handler naming

* Update codeowners for renamed message handler service

* Fix cli build error

* Fix browser build errors

* Fix tests and update lock components

* Fix linking

* Fix build error

* Fix build error

* Fix build error

* Fix build error

* Fix logging message

* Fix conflicts

* Add jsdoc to biometric status enum

* Add jsdoc to biometric commands

* Remove unused initialization code

* Fix incorrectly checked setup-required status in desktop settings component

* Extract process reload when required

* Remvoe cryptoservice reference

* Remove commented out tests

* Improve tests

* Fix build

* Fix tests

* Fix biometric unlock

* Fix errors from prior merge

* Re-add tests

* Update lock component tests

* Add tests for process reload for biometric ipc unlock

* Fix autoprompt happening when it should not

* Fix lock v2

* Fix lint

* Update apps/browser/src/auth/popup/settings/account-security.component.ts

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

* Update apps/desktop/src/app/accounts/settings.component.ts

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

* Update apps/desktop/src/key-management/biometrics/main-biometrics.service.ts

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

* Update libs/key-management/src/biometrics/biometric.service.ts

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

* Update libs/key-management/src/biometrics/biometrics-status.ts

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

* Update apps/browser/src/background/nativeMessaging.background.ts

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

* Update apps/desktop/src/key-management/biometrics/main-biometrics.service.ts

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

* Cleanup

* Remove unavailabilityReason from UI

* Fix autoprompt safari process reload

* Apply changes according to feedback

* Adjust PR according to feedback

* Address feedback

* Fix account settings biometrics setting

* Fix build

* Cleanup

* Fix incorrect merge

* Allow disabling biometrics in browser while desktop app is disconnected

---------

Co-authored-by: Maciej Zieniuk <167752252+mzieniukbw@users.noreply.github.com>
Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>
2025-01-09 13:01:49 +01:00
Jordan Aasen
a3e876eb8f
fixed icon width (#12721) 2025-01-08 16:19:51 -08:00
Thomas Avery
bb61b3df3a
[PM-15940] Add regen to SSO login (#12643)
* Add loginSuccessHandlerService to SSO login component

* Update regen service to handle SSO login
2025-01-08 16:41:02 -06:00
Shane Melton
d72dd2ea76
[PM-16098] Improved cipher decryption error handling (#12468)
* [PM-16098] Add decryptionFailure flag to CipherView

* [PM-16098] Add failedToDecryptCiphers$ observable to CipherService

* [PM-16098] Introduce decryption-failure-dialog.component

* [PM-16098] Disable cipher rows for the Web Vault

* [PM-16098] Show decryption error dialog on vault load or when attempting to view/edit a corrupted cipher

* [PM-16098] Browser - Show decryption error dialog on vault load or when attempting to view/edit a corrupted cipher

* [PM-16098] Desktop - Show decryption error dialog on vault load or when attempting to view a corrupted cipher. Remove edit/clone context menu options and footer actions.

* [PM-16098] Add CS link to decryption failure dialog

* [PM-16098] Return cipherViews and move filtering of isDeleted to consumers

* [PM-16098] Throw an error when retrieving cipher data for key rotation when a decryption failure is present

* [PM-16098] Properly filter out deleted, corrupted ciphers when showing dialog within the Vault

* [PM-16098] Show the decryption error dialog when attempting to view a cipher in trash and disable the restore option

* [PM-16098] Exclude failed to decrypt ciphers from getAllDecrypted method and cipherViews$ observable

* [PM-16098] Avoid re-sorting remainingCiphers$ as it was redundant

* [PM-16098] Update tests

* [PM-16098] Prevent opening view dialog in AC for corrupted ciphers

* [PM-16098] Remove withLatestFrom operator that was causing race conditions when navigating away from the individual vault

* [PM-16098] Ensure decryption error dialog is only shown once on Desktop when switching accounts
2025-01-08 08:42:46 -08:00
Tom
8bb080cf93
Removing testing tabs and the learn more link (#12481) 2025-01-08 16:09:05 +01:00
Bernd Schoolmann
bb2961f4ca
[PM-10413] ssh keygen on web and browser (#12176)
* Move desktop to sdk ssh-key generation

* Add ssh keygen support on web and browser

* Move ssh keygen on all clients behind feature flag

* Update package lock

* Fix linting

* Fix build

* Fix build

* Remove rand_chacha

* Move libc to linux-only target

* Remove async-streams dep

* Make generateSshKey private

* Remove async from generate ssh key

* Update cargo lock

* Fix sdk init for ssh key generation

* Update index.d.ts

* Fix build on browser

* Fix build

* Fix build by updating libc dependency
2025-01-08 16:01:23 +01:00
Oscar Hinton
3949aae8e3
[PM-16838] Fix bad imports for shared and platform code (#12743)
Imports containing /src/ are forbidden.
2025-01-08 14:29:26 +01:00
Bernd Schoolmann
72121cda94
[PM-10741] Refactor biometrics interface & add dynamic status (#10973) 2025-01-08 10:46:00 +01:00
Jason Ng
5cb31f37e9
[PM-16824] update new device verification notice page one so learn more link opens in browser from desktop (#12731) 2025-01-07 15:10:42 -05:00
Alec Rippberger
f99a3c4162
feat(web): [PM-1214] add device management screen
Adds a device management tab under settings -> security that allows users to:
- View and manage their account's connected devices
- Remove/deactivate devices
- See device details like platform, last login, and trust status
- Sort and filter device list with virtual scrolling

Resolves PM-1214
2025-01-07 13:29:36 -06:00
cyprain-okeke
02556c1416
Changes to restart cancelled org (#12730) 2025-01-07 20:09:37 +01:00
Jonathan Prusik
966e8d3fb8
[PM-16667] Followup clarifying work (#12665)
* clean up readability

* fix ts-strict violations

* fix consistency with uncertain cases in isCardExpired
2025-01-07 13:48:18 -05:00
Oscar Hinton
9ca3d0653d
Fix strict typescript for Component Library stories (#12423)
Fixing some low hanging fruits for moving CL to strict typescript.

This primarily removes the types from args since TS infers them differently. We previously needed them since storybook would use any for args but now provides proper typings
2025-01-07 17:28:35 +01:00
Thomas Avery
c0d3fe15d1
[PM-11528] Move Lock to KM ownership (#12407)
* update code owners

* Move lock component v2 to KM

* Add @bitwarden/key-management/angular to tsconfigs

* Move lock component service to KM

* Move lock component v1 to KM

* Update imports

* Move into @bitwarden/key-management

* Revert "Move into @bitwarden/key-management"

This reverts commit b7514fb8c2.

* Add to tsconfig.libs
2025-01-07 16:47:51 +01:00
Conner Turnbull
91d6963074
[PM-14366] Deprecated active user state from billing state service (#12273)
* Updated billing state provider to not rely on ActiveUserStateProvider

* Updated usages

* Resolved browser build

* Resolved web build

* Resolved CLI build

* resolved desktop build

* Update apps/cli/src/tools/send/commands/create.command.ts

Co-authored-by:  Audrey  <ajensen@bitwarden.com>

* Move subscription visibility logic from component to service

* Resolved unit test failures. Using existing userIds where present

* Simplified activeUserId access

* Resolved typescript strict errors

* Resolved broken unit test

* Resolved ts strict error

---------

Co-authored-by:  Audrey  <ajensen@bitwarden.com>
2025-01-07 10:25:26 -05:00
Jared Snider
1075d7a798
PM-16685 - Web - Fix locking (#12722) 2025-01-06 18:56:21 -05:00
Jonathan Prusik
15faf52f57
[PM-13115] Allow users to disable extension content script injections by domain (#11826)
* add disabledInteractionsUris state to the domain settings service

* add routes and ui for user disabledInteractionsUris state management

* use disabled URIs service state as a preemptive conditon to injecting content scripts

* move disabled domains navigation button from account security settings to autofill settings

* update disabled domain terminology to blocked domain terminology

* update copy

* handle blocked domains initializing with null value

* add dismissable banner to the vault view when the active autofill tab is on the blocked domains list

* add autofill blocked domain indicators to autofill suggestions section header

* add BlockBrowserInjectionsByDomain feature flag and put feature behind it

* update router config to new style

* update tests and cleanup

* use full-width-notice slot for domain script injection blocked banner

* convert thrown error on content script injection block to a warning and early return

* simplify and enspeeden state resolution for blockedInteractionsUris

* refactor feature flag state fetching and update tests

* document domain settings service

* remove vault component presentational updates
2025-01-06 17:10:34 -05:00
Jordan Aasen
ddc817689a
[PM-13365] - don't display totp capture when in popout (#12645)
* don't display totp capture when in popout

* add canCaptureTotp method

* dry up logic

* add unit tests

* fix failing tests

* add missing mock to cipher-form story
2025-01-06 13:52:42 -08:00
Jason Ng
5a46991e4e
[PM-16696] New Device Verification Notice Learn More (#12715)
* add learn more link to new device verification notification page one
2025-01-06 16:08:29 -05:00
Alec Rippberger
26f086368b
fix(auth): [PM-15987] improve email/master password entry back/forward navigation
- Fix back button behavior in Safari to reliably return to email entry screen
- Enable browser forward button after navigating back to email entry
- Move email validation to input event instead of blur
- Add continueClicked function to differentiate user clicks vs browser navigation
- Add email verification gate to SSO route
- Enhance master password validation logic
- Fix strict typing errors

Resolves PM-15987
2025-01-06 11:01:56 -08:00
Daniel James Smith
ec21e8db59
Add missing credit card number pipe (#12508)
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
2025-01-06 17:44:36 +01:00
Kyle Spearrin
05d373d070
turn off autocomplete for browser search input (#12679) 2025-01-03 14:51:54 -05:00
Victoria League
c07454342d
[PM-16675] Prevent scrollbar from appearing on each send item (#12666) 2025-01-03 09:41:18 -05:00
SmithThe4th
10c8a2101a
[PM-12049] Remove usage of ActiveUserState from folder service (#11880)
* Migrated folder service from using active user state to single user state

Added extra test cases for encrypted folder and decrypted folders

Updated derived state to use decrypt with key

* Update callers in the web

* Update callers in the browser

* Update callers in libs

* Update callers in cli

* Fixed test

* Fixed folder state test

* Fixed test

* removed duplicate activeUserId

* Added takewhile operator to only make calls when userId is present

* Simplified to accept a single user id instead of an observable

* Required userid to be passed from notification service

* [PM-15635] Folders not working on desktop (#12333)

* Added folders memory state definition

* added decrypted folders state

* Refactored service to remove derived state

* removed combinedstate and added clear decrypted folders to methods

* Fixed test

* Fixed issue with editing folder on the desktop app

* Fixed test

* Changed state name

* fixed ts strict issue

* fixed ts strict issue

* fixed ts strict issue

* removed unnecessasry null encrypteed folder check

* Handle null folderdata

* [PM-16197] "Items with No Folder" shows as a folder to edit name and delete (#12470)

* Force redcryption anytime encryption state changes

* Fixed text file

* revert changes

* create new object with nofolder instead of modifying exisiting object

* Fixed failing test

* switched to use memory-large-object

* Fixed ts sctrict issue

---------

Co-authored-by: Matt Bishop <mbishop@bitwarden.com>
Co-authored-by: bnagawiecki <107435978+bnagawiecki@users.noreply.github.com>
2025-01-02 17:16:33 -05:00
Nick Krantz
cf9bc7c455
Vault Strict Typing cleanup (#12512)
* remove strict types from `NewDeviceVerificationNotice`
- Add null default value for class properties
- Enforce that the userId is passed
- noticeState$ can return null

* remove strict types from `CopyCipherFieldService`
- refactor title to be a string rather than null

* remove strict types from `PasswordRepromptComponent`
- add guard to exit early on submit but also solves removing null/undefined from typing

* use bang to ensure required input

* remove strict types from `CopyCipherFieldDirective`
- add bang for required types
- add default values for null types

* add bang for constant variables in cipher form stories

* remove strict types from `DeleteAttachmentComponent`
- add bang for required types
- refactor title to be an empty string

* fix tests
2025-01-02 15:37:48 -06:00
Alex Morask
15cc4ff1eb
[PM-14461] Update organization state after subscription update (#12222)
* Update organization state after subscription update

* QA: Fix SM trial seat adjustment
2025-01-02 15:37:09 -05:00
Jonas Hendrickx
c724b0d974
[PM-13999] show estimated tax for taxable countries (#12245) 2025-01-02 20:28:04 +01:00
Jonathan Prusik
e47b5a15fd
[PM-16667] Fix flaky card expiry tests (#12659)
* fix improper date month subtraction

* fix mishandling of 0 month value
2025-01-02 14:09:57 -05:00
Jason Ng
75f75dc0f8
[PM-8214] adding tabIndex for screen reader (#12602)
* update new device components to use liveannouncer so users are notified of the pages header, and add tabindex to remind me later btn
2024-12-31 15:33:41 -05:00
cyprain-okeke
899b16966a
[PM-15814]Alert owners of reseller-managed orgs to renewal events (#12607)
* Changes for the reseller alert

* Resolve the null error

* Refactor the reseller service

* Fix the a failing test due to null date

* Fix the No overload matches error

* Resolve the null error

* Resolve the null error

* Resolve the null error

* Change the date format

* Remove unwanted comment

* Refactor changes

* Add the feature flag
2024-12-31 18:06:45 +01:00
Jason Ng
894dd2c896
[PM-16507] update new device verification notice state definition (#12608) 2024-12-30 19:24:31 -05:00
Victoria League
a95427eee0
[CL-524] Ignore flaky elements in Chromatic tests (#12561) 2024-12-30 16:42:53 -05:00
Victoria League
6539f06654
[CL-135] Fix import statement for standalone component (#12589) 2024-12-30 14:46:29 -05:00
Victoria League
1f4972fcb8
[PM-16102] Prevent item action height overflow (#12588) 2024-12-30 09:10:42 -05:00
Kyle Spearrin
f434334a88
[PM-16428] Option for primary click action to autofill on Vault view (#12557)
* add option for primary click action to autofill

* setting option string

* autofill setting for click items to autofill

* fix showQuickCopyActions

* apply setting
2024-12-27 08:51:17 -05:00
Victoria League
395258d63e
[PM-16102] Add min width on interactive badges (#12514) 2024-12-23 12:08:52 -05:00
Victoria League
64166a9354
[PM-16102] Increase clickable area for bit-item actions (#12450) 2024-12-20 14:03:50 -05:00
rr-bw
d209da4c94
feat(auth): [PM-9674] Remove Deprecated LockComponents (#12453)
This PR deletes the legacy lock components from the Angular clients and also removes feature flag control from the routing. The lock component will now be based entirely on the new, recently refreshed LockComponent in libs/auth/angular.
2024-12-20 10:23:03 -08:00
Nick Krantz
6ad35e0871
Vault Refactor: Clean up some strict types (#12357)
* update cipher-view to account for strict type checking

* update view-identity-sections to account for strict type checking

* update read-only-cipher-card to account for strict type checking

* remove unused card import

* remove unused card import

* update additional-options to account for strict type checking
2024-12-20 10:16:34 -06:00
Nick Krantz
b27a1a5337
[PM-12998] View Cipher: Color Password (#12354)
* show color password for visible passwords in vault view

- The password input will be visually hidden
- Adds tests for the login credentials component

* formatting
2024-12-20 09:44:36 -06:00
Andreas Coroiu
1d335bb164
[PM-16262] Make getEnvironment observable and use it in SdkService (#12501)
* feat: re-implement getEnvironment as an observable

* feat: deprecate `getEnvironment`

* fix: use correct environment function in SdkService

* fix: test
2024-12-20 15:20:23 +01:00
Oscar Hinton
8caadacfbc
[PM-16217] Remove wasm timeout (#12476)
Remove the WASM timeout logic and supported$.
2024-12-20 13:54:52 +01:00
Nick Krantz
e129e90faa
[PM-14347][PM-14348] New Device Verification Logic (#12451)
* add account created date to the account information

* set permanent dismissal flag when the user selects that they can access their email

* update the logic of device verification notice

* add service to cache the profile creation date to avoid calling the API multiple times

* update step one logic for new device verification + add tests

* update step two logic for new device verification + add tests
- remove remind me later link for permanent logic

* migrate 2FA check to use the profile property rather than hitting the API directly.

The API for 2FA providers is only available on web so it didn't work for browser & native.

* remove unneeded account related changes

- profile creation is used from other sources

* remove obsolete test

* store the profile id within the vault service

* remove unused map

* store the associated profile id so account for profile switching in the extension

* add comment for temporary service and ticket number to remove

* formatting

* move up logic for feature flags
2024-12-19 09:55:39 -06:00
Nick Krantz
0f3803ac91
[PM-11442] Emergency Cipher Viewing (#12054)
* force viewOnly to be true for emergency access

* add input to hide password history, applicable when the view is used from emergency view

* add extension refresh version of the emergency view dialog

* allow emergency access to view password history

- `ViewPasswordHistoryService` accepts a cipher id or CipherView. When a CipherView is included, the history component no longer has to fetch the cipher.

* remove unused comments

* Add fixme comment for removing non-extension refresh code

* refactor password history component to accept a full cipher view

- Remove the option to pass in only an id
2024-12-19 09:42:37 -06:00