1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-17 02:34:47 +02:00
Commit Graph

1066 Commits

Author SHA1 Message Date
Bitwarden DevOps
3c2d3669c5
Bumped web version to (#8772) 2024-04-16 19:26:30 +00:00
Carlos Gonçalves
06acdefa91
[PM-5273] Migrate state in CipherService (#8314)
* PM-5273 Initial migration work for localData

* PM-5273 Encrypted and Decrypted ciphers migration to state provider

* pm-5273 Update references

* pm5273 Ensure prototype on cipher

* PM-5273 Add CipherId

* PM-5273 Remove migrated methods and updated references

* pm-5273 Fix versions

* PM-5273 Added missing options

* Conflict resolution

* Revert "Conflict resolution"

This reverts commit 0c0c2039ed.

* PM-5273 Fix PR comments

* Pm-5273 Fix comments

* PM-5273 Changed decryptedCiphers to use ActiveUserState

* PM-5273 Fix tests

* PM-5273 Fix pr comments
2024-04-16 17:37:03 +01:00
Carlos Gonçalves
62ed7e5abc
[PM-2170] Update collections component (#6794)
* PM-2170 Updated Collections to use Component Library

* PM-2170 Removed some extra space

* PM-2170 Fix typo

* PM-2170 Refresh vault when saving

* PM-2170 Fix PR comments

* PM-2170 Refactor to use CollectionsDialogResult to fix lint error

* PM-2170 Refactor subtitle

* PM-4788 Fix dismiss of modal

* PM-2170 Fix PR comments
2024-04-16 15:47:12 +01:00
github-actions[bot]
ffcf660ff5
Autosync the updated translations (#8741)
Co-authored-by: bitwarden-devops-bot <106330231+bitwarden-devops-bot@users.noreply.github.com>
2024-04-15 17:55:41 +00:00
github-actions[bot]
c8f03a0d46
Autosync the updated translations (#8626)
Co-authored-by: bitwarden-devops-bot <106330231+bitwarden-devops-bot@users.noreply.github.com>
2024-04-15 08:55:30 +00:00
Shane Melton
2e8d1a2061
[AC-2431] New collection dialog bug (#8648)
* [AC-2431] Add null check for convertToPermission helper

* [AC-2431] Only attempt to convertToPermission if collectionId has a value
2024-04-12 16:51:20 +01:00
Conner Turnbull
b914260705
[AC-2319] remove the owned by business checkbox business name (#8674)
* Removed business name from organization create/upgrade flows, and org info page

* Prefilling the logged in user's email to the billing email when creating an organization
2024-04-12 10:17:38 -04:00
Thomas Rittson
d026087bfd
[AC-2443] Update unassigned items banner text for self-hosted (#8719)
* Update banner text for self-hosted environments

* Fix tests

* Fix web vault wording

* Actually fix web vault wording
2024-04-12 06:57:17 -05:00
Addison Beck
bf11b90c43
Use UserVerificationDialogComponent for account recovery enrollment (#8632) 2024-04-12 06:38:53 -05:00
Addison Beck
ab83a367dd
Address review feedback on UnassignedBannerService (#8680)
* Introduce `UnassignedItemsBannerApiService`

* Delete `WebUnassignedItemsBannerService`
2024-04-10 16:13:41 -05:00
Alex Morask
4c2afb4121
Add tax information to provider setup component when FF is on. (#8616) 2024-04-10 14:10:47 -04:00
Thomas Rittson
be362988b0
[AC-2436] Show unassigned items banner in web (#8655)
* Boostrap basic banner, show for all admins

* Remove UI banner, fix method calls

* Invert showBanner -> hideBanner

* Add api call

* Minor tweaks and wording

* Change to active user state

* Add tests

* Fix mixed up names

* Simplify logic

* Add feature flag

* Do not clear on logout

* Update apps/web/src/locales/en/messages.json

---------

Co-authored-by: Addison Beck <github@addisonbeck.com>
2024-04-10 11:52:13 -05:00
SmithThe4th
2bce6c538c
[PM-6194] Refactor injection of services in browser services module (#8380)
* refactored injector of services on the browser service module

* refactored the search and popup serach service to use state provider

* renamed back to default

* removed token service that was readded during merge conflict

* Updated search service construction on the cli

* updated to use user key definition

* Reafctored all components that refernce issearchable

* removed commented variable

* added uncommited code to remove dependencies not needed anymore

* added uncommited code to remove dependencies not needed anymore
2024-04-10 14:02:46 +01:00
Jake Fink
9d10825dbd
[PM-5362] Add MP Service (attempt #2) (#8619)
* create mp and kdf service

* update mp service interface to not rely on active user

* rename observable methods

* update crypto service with new MP service

* add master password service to login strategies
- make fake service for easier testing
- fix crypto service tests

* update auth service and finish strategies

* auth request refactors

* more service refactors and constructor updates

* setMasterKey refactors

* remove master key methods from crypto service

* remove master key and hash from state service

* missed fixes

* create migrations and fix references

* fix master key imports

* default force set password reason to none

* add password reset reason observable factory to service

* remove kdf changes and migrate only disk data

* update migration number

* fix sync service deps

* use disk for force set password state

* fix desktop migration

* fix sso test

* fix tests

* fix more tests

* fix even more tests

* fix even more tests

* fix cli

* remove kdf service abstraction

* add missing deps for browser

* fix merge conflicts

* clear reset password reason on lock or logout

* fix tests

* fix other tests

* add jsdocs to abstraction

* use state provider in crypto service

* inverse master password service factory

* add clearOn to master password service

* add parameter validation to master password service

* add component level userId

* add missed userId

* migrate key hash

* fix login strategy service

* delete crypto master key from account

* migrate master key encrypted user key

* rename key hash to master key hash

* use mp service for getMasterKeyEncryptedUserKey

* fix tests

* fix user key decryption logic

* add clear methods to mp service

* fix circular dep and encryption issue

* fix test

* remove extra account service call

* use EncString in state provider

* fix tests

* return to using encrypted string for serialization
2024-04-09 20:50:20 -04:00
Conner Turnbull
18ae698f8d
SM changes (#8531) 2024-04-08 14:42:49 -04:00
Vincent Salucci
0c291bf79b
[AC-2086] Limit admin access - Collection Modal (#8335)
* feat: add view collection string, update button text, refs AC-2086

* feat: remove canEdit from Restricted Collection Access component, refs AC-2086

* feat: add view collection clicked flow, refs AC-2086

* fix: revert accidental svg icon changes, refs AC-2086

* feat: add input for access selector to hide multi select, refs AC-2086

* feat: apply readonly/disabled changes to access dialog, refs AC-2086

* fix: messages file conflict, refs AC-2086

* feat: apply disabled state to access selector, refs AC-2086

* fix: formatting, refs AC-2086

* fix: permission mode read only relocate, refs AC-2086

* fix: conform readonly casing, refs AC-2086
2024-04-08 13:24:27 -05:00
Oscar Hinton
7064b595da
[SM-1031] Remove SecretsManager & showDDG compile flags (#8610)
Remove old compile flags which should no longer be required, and may even cause issues. secretsManager: false hides the app switcher which is now used for more than just secrets manager.
2024-04-08 17:46:24 +02:00
Oscar Hinton
5c30be2927
Increase max-old-space for bit:dev:watch (#8628) 2024-04-08 17:38:24 +02:00
Bitwarden DevOps
5f1a3acc17
Bumped web version to (#8642) 2024-04-08 15:26:10 +00:00
Thomas Rittson
26226c4090
[AC-2356] Use safeProvider in web core services module (#8521)
* Also add tests
* Exclude type (compile-time) tests from jest config
2024-04-08 07:59:12 +10:00
Addison Beck
2ff990edd2
Update policy service to clear its own state (#8564) 2024-04-05 13:10:24 -05:00
Shane Melton
cbf48decec
[PM-7292] Fix viewing/editing unassigned ciphers for admins (#8627)
* [PM-7292] Introduce canEditUnassignedCiphers helper

* [PM-7292] Use new canEditUnassignedCiphers helper

* [PM-7292] Remove duplicate canUseAdminCollections helper
2024-04-05 08:23:50 -07:00
Victoria League
09169cac71
[CL-254] Rename 500 colors to 600 to prep for UI redesign (#8623)
* [CL-254] Rename 500 colors to 600 to prep for UI redesign

---------

Co-authored-by: Will Martin <contact@willmartian.com>
2024-04-05 10:58:32 -04:00
Colton Hurst
fb51aa570d
SM-1159: Rename Service Accounts to Machine Accounts (#8444)
* SM-1159: Rename service accounts to machine accounts. Visible text only.

* SM-1159: Second round of adding service to machine account renames

* SM-1159: Change title

* SM-1159: Fix typo

* SM-1159: Add more keys

* SM-1159: Reordered keys

* SM-1159: Keys update
2024-04-05 10:52:21 -04:00
Alex Morask
9f8f93ef97
Resolved subscription page problem for free org (#8622) 2024-04-05 09:23:12 -04:00
Jake Fink
775c8a1bbe
Revert "[PM-5362]Create MP Service for state provider migration (#7623)" (#8617)
This reverts commit b1abfb0a5c.
2024-04-04 16:17:09 +00:00
Oscar Hinton
bf2f570b61
[PM-7057] Add dev tool for toggling width in web vault (#8447)
Add a dev tool for toggling the web vault width. This allows developers and designers to experiment with how the vault currently behaves with responsiveness and ensure new functionality looks good.
2024-04-04 16:40:21 +02:00
Jake Fink
b1abfb0a5c
[PM-5362]Create MP Service for state provider migration (#7623)
* create mp and kdf service

* update mp service interface to not rely on active user

* rename observable methods

* update crypto service with new MP service

* add master password service to login strategies
- make fake service for easier testing
- fix crypto service tests

* update auth service and finish strategies

* auth request refactors

* more service refactors and constructor updates

* setMasterKey refactors

* remove master key methods from crypto service

* remove master key and hash from state service

* missed fixes

* create migrations and fix references

* fix master key imports

* default force set password reason to none

* add password reset reason observable factory to service

* remove kdf changes and migrate only disk data

* update migration number

* fix sync service deps

* use disk for force set password state

* fix desktop migration

* fix sso test

* fix tests

* fix more tests

* fix even more tests

* fix even more tests

* fix cli

* remove kdf service abstraction

* add missing deps for browser

* fix merge conflicts

* clear reset password reason on lock or logout

* fix tests

* fix other tests

* add jsdocs to abstraction

* use state provider in crypto service

* inverse master password service factory

* add clearOn to master password service

* add parameter validation to master password service

* add component level userId

* add missed userId

* migrate key hash

* fix login strategy service

* delete crypto master key from account

* migrate master key encrypted user key

* rename key hash to master key hash

* use mp service for getMasterKeyEncryptedUserKey

* fix tests
2024-04-04 14:22:41 +00:00
Thomas Rittson
32981ce30d
[AC-2320] Update canEditAnyCollection logic for Flexible Collections v1 (#8394)
* also update calling locations to use canEditAllCiphers where applicable
2024-04-04 13:48:41 +10:00
Oscar Hinton
23c89bda74
[PM-6975] Replace purchasedPremium broadcast message with observables (#8421)
In https://github.com/bitwarden/clients/pull/8133 the premium state changed to
be derived from observables, which means we can get rid of the `purchasePremium`
messages that are sent and instead rely directly on the observable to distribute
the state.
2024-04-03 15:51:55 -05:00
Rui Tomé
ff3ff89e20
[AC-1913] Update OrganizationLayoutComponent to use PolicyService to check if the user has the SingleOrg policy and use the value to hide the 'New Org' button (#8349) 2024-04-03 15:51:21 +01:00
Ariful Alam
7ea717aa5d
Use nullValidator to accept No folder while moving (#5645)
Co-authored-by: Daniel James Smith <2670567+djsmith85@users.noreply.github.com>
2024-04-02 16:35:23 -04:00
Will Martin
165f9c460a
remove unused OrganizationBillingTabComponent (#8435)
Co-authored-by: cyprain-okeke <108260115+cyprain-okeke@users.noreply.github.com>
2024-04-02 20:00:08 +00:00
Vincent Salucci
2f3e37d713
[SM-889] FIX - bulk activate SM members (#8375)
* fix: add accessSecretsManager property and filter checked users, refs SM-889

* fix: load members list on bulk sm complete, refs SM-889
2024-04-02 14:58:54 -05:00
Alex Morask
7df3304a25
[AC-1759] Update subscription status section (#8578)
* Resolve subscription status confusion

* Add feature flag
2024-04-02 13:53:13 -04:00
rr-bw
f79d159277
[PM-5500] Implement StateProvider in RouterService (#8119)
* implement StateProvider in RouterService

* Remove 'export'

Co-authored-by: Andreas Coroiu <acoroiu@bitwarden.com>

* Skip parameter

Co-authored-by: Andreas Coroiu <acoroiu@bitwarden.com>

---------

Co-authored-by: Andreas Coroiu <acoroiu@bitwarden.com>
2024-04-02 10:16:42 -07:00
Tom
a6e178f1e6
[PM-5574] sends state provider (#8373)
* Adding the key definitions and tests and initial send state service

* Adding the abstraction and implementing

* Planning comments

* Everything but fixing the send tests

* Moving send tests over to the state provider

* jslib needed name refactor

* removing get/set encrypted sends from web vault state service

* browser send state service factory

* Fixing conflicts

* Removing send service from services module and fixing send service observable

* Commenting the migrator to be clear on why only encrypted

* No need for service factories in browser

* browser send service is no longer needed

* Key def test cases to use toStrictEqual

* Running prettier

* Creating send test data to avoid code duplication

* Adding state provider and account service to send in cli

* Fixing the send service test cases

* Fixing state definition keys

* Moving to observables and implementing encryption service

* Fixing key def tests

* The cli was using the deprecated get method

* The observables init doesn't need to happen in constructor

* Missed commented out code

* If enc key is null get user key

* Service factory fix
2024-04-02 12:39:06 -04:00
cyprain-okeke
9956f020e7
[AC-1911] Clients: Create components to manage client organization seat allocation (#8505)
* implementing the clients changes

* resolve pr comments on message.json

* moved the method to billing-api.service

* move the request and response files to billing folder

* remove the adding existing orgs

* resolve the routing issue

* resolving the pr comments

* code owner changes

* fix the assignedseat

* resolve the warning message

* resolve the error on update

* passing the right id

* resolve the unassign value

* removed unused logservice

* Adding the loader on submit button
2024-04-02 17:04:02 +01:00
Alex Morask
22cca018f8
Don't let users who can't edit sub reactivate sub pending cancelation (#8433) 2024-04-02 09:28:36 -04:00
Jared Snider
c202c93378
Auth/PM-5268 - DeviceTrustCryptoService state provider migration (#7882)
* PM-5268 - Add DEVICE_TRUST_DISK to state definitions

* PM-5268 - DeviceTrustCryptoService - Get most of state provider refactor done - WIP - commented out stuff for now.

* PM-5268 - DeviceTrustCryptoServiceStateProviderMigrator - WIP - got first draft of migrator in place and working on tests. Rollback tests are failing for some reason TBD.

* PM-5268 - more WIP on device trust crypto service migrator tests

* PM-5268 - DeviceTrustCryptoServiceStateProviderMigrator - Refactor based on call with platform

* PM-5268 - DeviceTrustCryptoServiceStateProviderMigrator - tests passing

* PM-5268 - Update DeviceTrustCryptoService to convert over to state providers + update all service instantiations / dependencies to ensure state provider is passed in or injected.

* PM-5268 - Register new migration

* PM-5268 - Temporarily remove device trust crypto service from migrator to ease merge conflicts as there are 6 more migrators before I can apply mine in main.

* PM-5268 - Update migration numbers of DeviceTrustCryptoServiceStateProviderMigrator based on latest migrations from main.

* PM-5268 - (1) Export new KeyDefinitions from DeviceTrustCryptoService for use in test suite (2) Update DeviceTrustCryptoService test file to use state provider.

* PM-5268 - Fix DeviceTrustCryptoServiceStateProviderMigrator tests to use proper versions

* PM-5268 - Actually fix all instances of DeviceTrustCryptoServiceStateProviderMigrator test failures

* PM-5268 - Clean up state service, account, and login strategy of all migrated references

* PM-5268 - Account - finish cleaning up device key

* PM-5268 - StateService - clean up last reference to device key

* PM-5268 - Remove even more device key refs. *facepalm*

* PM-5268 - Finish resolving merge conflicts by incrementing migration version from 22 to 23

* PM-5268 - bump migration versions

* PM-5268 - DeviceTrustCryptoService - Implement secure storage functionality for getDeviceKey and setDeviceKey (to achieve feature parity with the ElectronStateService implementation prior to the state provider migration). Tests to follow shortly.

* PM-5268 - DeviceTrustCryptoService tests - getDeviceKey now tested with all new secure storage scenarios. SetDeviceKey tests to follow.

* PM-5268 - DeviceTrustCryptoService tests - test all setDeviceKey scenarios with state provider & secure storage

* PM-5268 - Update DeviceTrustCryptoService deps to actually use secure storage svc on platforms that support it.

* PM-5268 - Bump migration version due to merge conflicts.

* PM-5268 - Bump migration version

* PM-5268 - tweak jsdocs to be single line per PR feedback

* PM-5268 - DeviceTrustCryptoSvc - improve debuggability.

* PM-5268 - Remove state service as a dependency on the device trust crypto service (woo!)

* PM-5268 - Update migration test json to correctly reflect reality.

* PM-5268 - DeviceTrustCryptoSvc - getDeviceKey - add throw error for active user id missing.

* PM-5268 - Fix tests

* PM-5268 - WIP start on adding user id to every method on device trust crypto service.

* PM-5268 - Update lock comp dependencies across clients

* PM-5268 - Update login via auth request deps across clients to add acct service.

* PM-5268 - UserKeyRotationSvc - add acct service to get active acct id for call to rotateDevicesTrust and then update tests.

* PM-5268 - WIP on trying to fix device trust crypto svc tests.

* PM-5268 - More WIP device trust crypto svc tests passing

* PM-5268 - Device Trust crypto service - get all tests passing

* PM-5268 - DeviceTrustCryptoService.getDeviceKey - fix secure storage b64 to symmetric crypto key conversion

* PM-5268 - Add more tests and update test names

* PM-5268 - rename state to indicate it was disk local

* PM-5268 - DeviceTrustCryptoService - save symmetric key in JSON format

* PM-5268 - Fix lock comp tests by adding acct service dep

* PM-5268 - Update set device key tests to pass

* PM-5268 - Bump migration versions again

* PM-5268 - Fix user key rotation svc tests

* PM-5268 - Update web jest config to allow use of common spec in user-key-rotation-svc tests

* PM-5268 - Bump migration version

* PM-5268 - Per PR feedback, save off user id

* PM-5268 - bump migration version

* PM-5268 - Per PR feedback, remove unnecessary await.

* PM-5268 - Bump migration verson
2024-04-01 16:02:58 -04:00
rr-bw
2e51d96416
[PM-5264] Implement StateProvider in LoginEmailService (#7662)
* setup StateProvider in LoginService

* replace implementations

* replace implementation

* remove stateService

* change storage location for web to 'disk-local'

* implement migrate() method of Migrator

* add RememberedEmailMigrator to migrate.ts

* add rollback

* add tests

* replace implementation

* replace implementation

* add StateProvider to Desktop services

* rename LoginService to RememberEmailService

* update state definition

* rename file

* rename to storedEmail

* rename service to EmailService to avoid confusion

* add jsdocs

* refactor login.component.ts

* fix typos

* fix test

* rename to LoginEmailService

* update factory

* more renaming

* remove duplicate logic and rename method

* convert storedEmail to observable

* refactor to remove setStoredEmail() method

* move service to libs/auth/common

* address floating promises

* remove comment

* remove unnecessary deps in service registration
2024-03-30 11:00:27 -07:00
SmithThe4th
3a830789ba
[PM-5884] Allow deletion of passkey from edit view - clients (#8500)
* add remove button for passkeys during edit

* added live region to announce when a passkey is removed

* removed announce passkey removed by SR

* removed unused variable
2024-03-29 10:06:50 -04:00
aj-rosado
813dd97fed
Removing clientSideOnlyVerification on UserVerificationDialogComponent on web export.component (#8545) 2024-03-29 13:08:41 +00:00
Ike
3d19e3489c
[PM-5269] Key Connector state migration (#8327)
* key connector migration initial

* migrator complete

* fix dependencies

* finalized tests

* fix deps and sync main

* clean up definition file

* fixing tests

* fixed tests

* fixing CLI, Browser, Desktop builds

* fixed factory options

* reverting exports

* implemented UserKeyDefinition clearOn

* Update KeyConnector MIgration

* updated migrator and tests to match profile object

* removed unused service and updated clear

* dep fix

* dep fixes

* clear usesKeyConnector on logout
2024-03-28 12:50:24 -04:00
Jake Fink
bd6b3266d4
move auth request notification to service (#8451)
- cleanup hanging promises
2024-03-28 09:34:21 -04:00
github-actions[bot]
ddae908d86
Autosync the updated translations (#8524)
Co-authored-by: bitwarden-devops-bot <106330231+bitwarden-devops-bot@users.noreply.github.com>
2024-03-28 11:06:25 +00:00
Thomas Rittson
5cb2e99b2f
[AC-1724] Remove BulkCollectionAccess feature flag (#8502) 2024-03-28 08:08:28 +10:00
Matt Gibson
62ad39e697
Ps/pm 5965/better config polling (#8325)
* Create tracker that can await until expected observables are received.

* Test dates are almost equal

* Remove unused class method

* Allow for updating active account in accout service fake

* Correct observable tracker behavior

Clarify documentation

* Transition config service to state provider

Updates the config fetching behavior to be lazy and ensure that any emitted value has been updated if older than a configurable value (statically compiled).

If desired, config fetching can be ensured fresh through an async.

* Update calls to config service in DI and bootstrapping

* Migrate account server configs

* Fix global config fetching

* Test migration rollback

* Adhere to implementation naming convention

* Adhere to abstract class naming convention

* Complete config abstraction rename

* Remove unnecessary cli config service

* Fix builds

* Validate observable does not complete

* Use token service to determine authed or unauthed config pull

* Remove superfluous factory config

* Name describe blocks after the thing they test

* Remove implementation documentation

Unfortunately the experience when linking to external documentation is quite poor. Instead of following the link and retrieving docs, you get a link that can be clicked to take you out of context to the docs. No link _does_ retrieve docs, but lacks indication in the implementation that documentation exists at all.

On the balance, removing the link is the better experience.

* Fix storybook
2024-03-27 10:03:09 -07:00
Daniel James Smith
64d6f6fef3
Move export.component from @bitwarden/angular to @bitwarden/vault-export-ui (#8514)
Move export.component
Export from @bitwarden/vault-export-ui
Fix imports on browser, desktop and web

Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
2024-03-27 17:02:56 +00:00
Jason Ng
7f55833974
[AC-2285] Edit Unassigned Ciphers in AC Bug (#8410)
* check if cipher is unassigned and call the proper service between cipherService get and apiService get. also check for custom user permissions
2024-03-26 15:22:35 -04:00