1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-15 15:53:27 +00:00
Commit Graph

617 Commits

Author SHA1 Message Date
Daniel James Smith
cf2d8b266a [PM-1071] Display import-details-dialog on successful import (#4817)
* Prefer callback over error-flow to prompt for password

Remove error-flow to request file password
Prefer callback, which has to be provided when retrieving/creating an instance.
Delete ImportError
Call BitwardenPasswordProtector for all Bitwarden json imports, as it extends BitwardenJsonImporter
Throw errors instead of returning
Return ImportResult
Fix and extend tests import.service
Replace "@fluffy-spoon/substitute" with "jest-mock-extended"

* Fix up test cases

Delete bitwarden-json-importer.spec.ts
Add test case to ensure bitwarden-json-importer.ts is called given unencrypted or account-protected files

* Move file-password-prompt into dialog-folder

* Add import success dialog

* Fix typo

* Only list the type when at least one got imported

* update copy based on design feedback

* Remove unnecessary /index import

* Remove promptForPassword_callback from interface

PR feedback from @MGibson1 that giving every importer the ability to request a password is unnecessary. Instead, we can pass the callback into the constructor for every importer that needs this functionality

* Remove unneeded import of BitwardenJsonImporter

* Fix spec constructor

* Fixed organizational import

Added an else statement, or else we'd import into an org and then also import into an individual vault
2023-04-06 22:41:09 +02:00
Thomas Rittson
7899b25ab3 [PM-1426] Refactor uri matching (#5003)
* Move URI matching logic into uriView

* Fix url parsing: always assign default protocol, otherwise no protocol with port is parsed incorrectly

* Codescene: refactor domain matching logic
2023-04-06 13:30:26 +10:00
Vincent Salucci
576d85b268 [AC-1202] Update enums filenames for admin-console/billing teams (#5169)
* refactor: add barrel file for admin-console enums, update references, refs AC-1202

* fix: lint/prettier updates, refs AC-1202

* refactor: add enum suffix, refs AC-1202

* refactor: add barrel file for billing enums, update imports to use it, refs AC-1202

* fix: prettier, refs AC-1202

* refactor: add enum suffix for billing enums, refs AC-1202
2023-04-05 20:34:23 -05:00
aj-rosado
c6bc97cf5c [PS-2390] Passing folder and collection id on import (#4802)
* PS-2390 - Passing folder and collection id on import
Reading groupingid from lastpass csv as collection or folder id

* PS-2390 - Added toDomain and toModel on FolderWithIdExport model and created CollectionWithIdExport model

* PS-2390 - renamed groupingid into bwcollectionid on lastpass importer

* PS-2390 - Updated collection/folder-with-id export to reuse parent toDomain and toView

* PS-2390 Undo the lastpass importer groupingId rename

* PS-2390 Undo lastpass importer changes

* PS-2390 - Removed externalId set. Cleaning collection-with-id-request to user parent properties

* Lint prettier
2023-04-05 19:15:33 +01:00
Andreas Coroiu
2992142681 [EC-598] fix: send correct excluded cipher ids 2023-04-05 16:47:48 +02:00
Andreas Coroiu
034f16f29e [EC-598] feat: add rudimentary support for excluded credentials 2023-04-05 16:43:13 +02:00
Andreas Coroiu
183af55491 [EC-598] feat: make fallback working again 2023-04-05 16:28:46 +02:00
Andreas Coroiu
cd70b17b9a [EC-598] feat: fully refactored user interface
Now uses sessions instead of single request-response style communcation
2023-04-05 16:17:40 +02:00
Andreas Coroiu
11d340bc97 [EC-598] feat: add initial implementation of UI sessions 2023-04-05 11:38:32 +02:00
Vincent Salucci
bacb8828de [AC-1266] Enums filename conventions (#5140)
* refactor: update clientType enum

* refactor: update deviceType filename

* refactor: update encryptedExportType filename

* refactor: update encryptionType filename

* refactor: update eventType filename

* refactor: update fieldType filename

* refactor: update fileUploadType filename

* refactor: update hashPurpose filename

* refactor: update htmlStorageLocation filename

* refactor: update kdfType filename

* refactor: update keySuffixOptions filename

* refactor: update linkedIdType filename

* refactor: update logLevelType filename

* refactor: update nativeMessagingVersion filename

* refactor: update notificationType filename

* refactor: update productType filename

* refactor: update secureNoteType filename

* refactor: update stateVersion filename

* refactor: update storageLocation filename

* refactor: update themeType filename

* refactor: update uriMatchType filename

* fix: update kdfType classes missed in initial pass, refs AC-1266

* fix: missing import update for device-type

* refactor: add barrel file for enums and update pathed import statements, refs AC-1266

* fix: incorrect import statements for web, refs AC-1266

* fix: missed import statement updates (browser), refs AC-1266

* fix: missed import statement changes (cli), refs AC-1266

* fix: missed import statement changes (desktop), refs AC-1266

* fix: prettier, refs AC-1266

* refactor: (libs) update relative paths to use barrel file, refs AC-1266

* fix: missed find/replace import statements for SecureNoteType, refs AC-1266

* refactor: apply .enum suffix to enums folder and modify leftover relative paths, refs AC-1266

* fix: find/replace errors for native-messaging-version, refs AC-1266
2023-04-04 22:42:21 -05:00
Jared Snider
4d6d3c4bd5 PM-1354 - Fix master password not auto focused on web login flow (#5139) 2023-04-04 16:39:49 -04:00
Andreas Coroiu
55cd736ec3 [EC-598] feat: fully wokring non-discoverable implementation 2023-04-04 16:21:43 +02:00
Andreas Coroiu
c74ae9dd15 Merge branch 'master' into EC-598-beeep-properly-store-passkeys-in-bitwarden 2023-04-04 09:41:22 +02:00
SmithThe4th
a78ed4c548 [AC-1260] Removed ssoRequired field from the sso details response (#5123)
* Removed ssoRequired field from the sso details response

* Fixed PR comment
2023-04-03 11:45:22 -04:00
Oscar Hinton
a68631c7b7 Fix broken export spec (#5152) 2023-04-03 12:26:11 +02:00
Andreas Coroiu
bdadf68274 [EC-598] fix: invalid signature due to double hashing 2023-03-31 17:45:59 +02:00
Andreas Coroiu
7039ad1870 [EC-598] fix: data not getting saved properly 2023-03-31 17:10:15 +02:00
Andreas Coroiu
e2df24c5ae [EC-598] fix: wrong flags in tests 2023-03-31 17:09:10 +02:00
Andreas Coroiu
61437bae00 [EC-598] fix: flag saying authData doesnt contain attestation 2023-03-31 16:27:21 +02:00
Andreas Coroiu
3edd7887a4 [EC-598] fix: some smaller bugs 2023-03-31 15:53:10 +02:00
Andreas Coroiu
e8c9b887c4 [EC-598] fix: rpId validation logic 2023-03-31 14:26:18 +02:00
Bernd Schoolmann
1f472ea309 [PS-2264] Make password protected exports support account's iterations and argon2 (#4479)
* Fix encrypted export using fixed PBKDF2 iterations

* Replace hardcoded KdfType in importer

* Clean up kdf handling in password-protected export

* Extract BitwardenPasswordProtectedFileFormat

* Rename bitwarden-json-types

* Move StateService import to fix linting issue

* Make linter happy

* Use abstraction instead of implementation

---------

Co-authored-by: Daniel James Smith <djsmith@web.de>
2023-03-31 13:49:07 +02:00
Andreas Coroiu
1d9dde95b7 [EC-598] feat: remove orgigin 2023-03-31 12:32:07 +02:00
Andreas Coroiu
380e545c90 [EC-598] feat: make everything compile again 2023-03-31 10:26:19 +02:00
Andreas Coroiu
25ebbec0eb [EC-598] feat: implement assertCredential 2023-03-31 09:41:28 +02:00
SmithThe4th
b79554a13b [PM-283] Fix Reports UI behavior for premium and free users (#4926)
* Prevent rerouting to dispaly modal message, and refactored components where thsi was used

* Added upgrade badge to organization reports view

* created guard to prevent free organization users from accessing reports

* Added isUpgradeRequired getter to organization class

* Modifiewd reports home to pass upgrade badge and add new guard to organization reports module

* Fixed routing bug when routing to billing subscription page

* Refactored to use async pipe and observables

* Renamed getter name to be more descriptive

* Removed checkAccess from reports

* Renamed guard

* Removed unused variables

* Lint fix

* Lint fix

* prettier fix

* Corrected organiztion service reference

* Moved homepage to ngonInit

* [PM-1629] Update the upgrade dialog for users without billing rights (#5102)

* Show dialog with description when user does not have access to the billing page

* switched conditions to nested if to make the logic clearer
2023-03-30 16:27:03 -04:00
Oscar Hinton
1129b48b2a [PM-1644] Resolve active tab using the wrong background color (#5097) 2023-03-30 21:03:42 +02:00
Oscar Hinton
873c35fbd4 [SM-574] Hide edit/delete when user only has read access (#4941)
* Hide edit/delete when user only has read access

* Wire up read/write for secret response

* Remove variable

* Resolve changes after merge

* SM-671: Fix small bug in sm/SM-574 branch to pass secret instead of secret id on deletion (#5096)

---------

Co-authored-by: Colton Hurst <colton@coltonhurst.com>
2023-03-30 16:51:31 +02:00
Andreas Coroiu
1b7a9858a4 [EC-598] feat: fully implement createCredential 2023-03-30 16:04:49 +02:00
Andreas Coroiu
43a13cb451 [EC-598] feat: extend return from authenticator 2023-03-30 15:57:46 +02:00
Andreas Coroiu
6fd5801739 [EC-598] feat: hash client data and throw if aborted 2023-03-30 15:05:58 +02:00
Andreas Coroiu
259e646ed7 [EC-598] feat: check for supported key algorithms 2023-03-30 14:37:36 +02:00
Andreas Coroiu
142aa016d4 [EC-598] feat: check origin and rp.id effective domains 2023-03-30 14:25:10 +02:00
Andreas Coroiu
b8821ccd3d [EC-598] feat: check user id length 2023-03-30 13:54:46 +02:00
Andreas Coroiu
f172625f26 [EC-598] feat: start working on new Fido2ClientService 2023-03-30 13:24:07 +02:00
Andreas Coroiu
e7454501ea [EC-598] feat: add general error handling for attestation 2023-03-30 10:59:19 +02:00
Andreas Coroiu
b3d5ab4472 [EC-598] feat: add signatures to attestation 2023-03-30 10:55:59 +02:00
Andreas Coroiu
151afeb241 [EC-598] feat: implement assertion 2023-03-30 09:12:54 +02:00
Andreas Coroiu
5bf4156fc6 [EC-598] feat: increment counter during assertion 2023-03-29 16:55:09 +02:00
Daniel James Smith
e238ea20a9 [PM-328] Move Send to Tools (#5104)
* Move send in libs/common

* Move send in libs/angular

* Move send in browser

* Move send in cli

* Move send in desktop

* Move send in web
2023-03-29 16:23:37 +02:00
Andreas Coroiu
597bc0b197 [EC-598] feat: add user confirmation test to assertion
also rewrite to use cipher views in tests
2023-03-29 16:23:19 +02:00
Andreas Coroiu
c2ec87a3f3 [EC-598] feat: implement missing credential checks 2023-03-29 10:37:02 +02:00
Andreas Coroiu
231edf82f7 [EC-598] chore: add todo tests about deleted items 2023-03-29 09:51:53 +02:00
Vincent Salucci
5008acfd13 fix: update downstream imports for org-api-key.request file move, refs AC-1202 2023-03-28 14:28:58 -05:00
Vincent Salucci
16f86d1da2 refactor: move organization-api-key.request to admin-console, refs AC-1202 2023-03-28 14:18:40 -05:00
Robyn MacCallum
d799529428 [SG 623] Send Service Refactor (#4327)
* Split out api methods into sendApiService

* Move SendService and abstraction

* Libs updates

* Web updates

* CLI updates

* Desktop updates

* libs send service fixes

* browser factory additions

* Browser updates

* Fix service injection for CLI SendReceiveCommand

* Deprecate directly calling send state service methods

* SendService observables updates

* Update components to use new observables

* Modify CLI to use state service instead of observables

* Remove unnecessary await on get()

* Move delete() to InternalSendService

* SendService unit tests

* Split fileUploadService by send and cipher

* send and cipher service factory updates

* Add file upload methods to get around circular dependency issues

* Move api methods from sendService to sendApiService

* Update cipherService to use fileApi methods

* libs service injection and component changes

* browser service injection and component changes

* Desktop component changes

* Web component changes

* cipher service test fix

* Fix file capitalization

* CLI service import and command updates

* Remove extra abstract fileUploadService

* WIP: Condense callbacks for file upload

Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>

* Send callbacks for file upload

* Fix circular service dependencies

* Fix response return on upload

* Fix function definitions

* Service injection fixes and bug fixes

* Fix folder casing

* Service injection cleanup

* Remove deleted file from capital letters whitelist

* Create new SendApiService for popup

* Move cipherFileUploadService to vault

* Move SendFileUploadService methods into SendApiService

* Rename methods to remove 'WithServer'

* Properly subscribe to sendViews

* Fix Send serialization

* Implement fromJSON on sendFile and sendText

* [PM-1347] Fix send key serialization (#4989)

* Properly serialize key on send fromJSON

* Remove call that nulled out decrypted sends

* Fix null checks in fromJSON methods for models

* lint fixes

---------

Co-authored-by: Matt Gibson <mgibson@bitwarden.com>
2023-03-28 12:37:40 -04:00
Oscar Hinton
c2bfb2497b [CL-85] Fix dialog background color (#5047) 2023-03-28 15:54:38 +02:00
Andreas Coroiu
80fbfc9d13 [EC-598] fix: properly convert credentials to guid raw format 2023-03-28 15:50:01 +02:00
Andreas Coroiu
c882c37f82 [EC-598] feat: add separate nonDiscoverableId to keys 2023-03-28 15:04:16 +02:00
Andreas Coroiu
6d90489ace [EC-598] feat: start implementing getAssertion 2023-03-28 10:38:25 +02:00