Commit Graph

1624 Commits

Author SHA1 Message Date
Alex Morask
15e71aa93d [PM-33894] Schedule price increases (#7293) 2026-03-24 17:22:50 -05:00
Patrick-Pimentel-Bitwarden
70daa856a1 feat(redirect): [PM-30810] Https Redirection for Cloud Users (#6852)
* feat(redirect): [PM-26578] Https Redirection for Cloud Users - Added deeplink scheme to duo redirect uri.
2026-03-24 21:05:33 +00:00
Rui Tomé
7c05036c01 [PM-19143] Fix custom permissions not persisting via InviteOrganizationUsersCommand (#7285) 2026-03-24 14:12:44 +00:00
Todd Martin
063ae435cb chore(flags): [PM-33972] Remove pm-26140-marketing-initiated-premium-flow feature flag 2026-03-24 08:19:40 -04:00
Thomas Rittson
524c5459d4 [PM-33819] Enforce use of authorize attributes (#7242)
Add tests to ensure we are using authorize attributes

Also clean up non-compliant and deprecated methods on PoliciesController.
2026-03-24 09:46:57 +10:00
Derek Nance
5dcb8ca712 Allow SMTP TLS CRL status retrieval failures (#7271) 2026-03-23 15:20:33 -05:00
Derek Nance
bf4266556a User-friendly cookie vendor error message (#7270) 2026-03-23 15:08:20 -05:00
Alex Morask
c84ac1403e [PM-33980] Only verify UseMyItems when claim exists (#7278)
* fix(licensing): skip UseMyItems comparison for pre-2026.3.0 license files

* docs(licensing): add backward-compatibility guidance to ability flag README
2026-03-23 13:52:28 -05:00
renovate[bot]
783fd5ad9e [deps] Auth: Update Duende.IdentityServer to 7.4.6 (#6323)
* [deps] Auth: Update Duende.IdentityServer to 7.4.6
* fix: address test changes required to complete the update
* feat: move Discovery Generateion to CoreHelpers.cs
* test: add SSO discovery document tests

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ike Kottlowski <ikottlowski@bitwarden.com>
Co-authored-by: Ike <137194738+ike-kottlowski@users.noreply.github.com>
2026-03-23 10:00:06 -04:00
Daniel García
8a1aedc133 [PM-33895] Filter [BindNever] parameters from OpenAPI schema (#7257)
* [PM-33895] Filter [BindNever] parameters from OpenAPI schema

* Fmt
2026-03-23 14:11:50 +01:00
Jared McCannon
463ca89710 [PM-32066] - Add Org Ability View (#7194)
* Added sproc, view, repo methods, and tests
2026-03-23 08:09:22 -05:00
Thomas Avery
005c74456c [PM-33435] Add new user key rotation endpoint with MP support (#7216)
* Add new user key rotation endpoint with MP support

* Increase test coverage

* Add note on request model
2026-03-20 11:06:27 -05:00
Thomas Avery
53907c2f14 [PM-33162] Refactor user key rotation (#7201)
* Refactor user key rotation to use base data composition

* Update tests
2026-03-20 10:31:25 -05:00
Alex Morask
212a0609c0 [PM-33415] [PM-33418] Fix add-on item proration and Families > Teams/Enterprise upgrade seat count (#7259)
* fix(billing): replace per-change IsStructural with changeset-level ChargeImmediately flag

* fix(billing): set seat quantity when upgrading from non-seat-based to seat-based plan
2026-03-20 09:29:45 -05:00
sven-bitwarden
081bbe66d0 [PM-30993] Better Error Message for Expired Invitation Tokens (#6971)
* Send better error message when token is expired

* Add comment indicating frontend usage

* Add testcase for Invalid Token scenario

* Update comment in test-case

* Fix merge issue

* Fix method name

* Consolidate token validation error calculation, apply to new area

* Move away from magic strings, fix tests

* Adjust class name

* Clean up old method name references

* Change errors to fields for singleton behavior

* Formatting
2026-03-20 08:35:39 -05:00
cyprain-okeke
fae3e95492 [PM-32480] Add endpoint for Stripe billing portal session (#7227)
* Implement the portal session url

* Remove comment

* formatting issues have been resolved

* Allow deep linking url

* remove thr return url request

* Resolve review comments around comments

* Fix the failing test after removing _globalSettings

* Fix the failing unit test
2026-03-20 09:31:43 +01:00
Jimmy Vo
7371705530 [PM-33364] Fix the emergency access help URL. (#7262) 2026-03-19 17:55:11 -04:00
John Harrington
6fcf007672 [PM-33232] Update UX implemented in PM-33219 to resolve VULN-458 (#7204)
* expect AuthType in request and update tests

* handle older clients lacking AuthType in request gracefully

* update exception message to match behavior

* use presence of AuthType to branch to new logic, preserving old for null AuthType
2026-03-19 13:36:51 -07:00
Alex Dragovich
50e1847d4b [PM-32512] validate direct file upload in self-hosted env can only be done by owner of send (#7195) 2026-03-19 13:04:59 -07:00
Shane Melton
d501a88ead [PM-33900] Remove server-side view password validation from CipherService (#7260) 2026-03-19 12:45:46 -07:00
Ike
d977ba44e0 [PM-30370] Add salt to vault sync response (#7248)
* feat: Replace email salt with `user.GetMasterPasswordSalt()`

* test: update SyncControllerTest
2026-03-19 14:39:52 -04:00
Jordan Aasen
2187c2a2cb Revert "[PM-30751] - add secure SSRF protection for internal IPs (#7184)" (#7255)
This reverts commit 0cba609304.
2026-03-19 10:10:58 -07:00
Maciej Zieniuk
0f0990be08 [PM-29728] remove pm-28813-data-recovery-tool feature flag (#7249)
* remove pm-28813-data-recovery-tool feature flag

* remove feature flagged regenerate-keys
2026-03-19 16:45:51 +01:00
cyprain-okeke
768de5f1e2 [PM-32477]PremiumStatusChanged Push Notification (#7198)
* changes for the premium push notification

* Fix the lint build

* implement the hub-helper

* Resolve the pr comments

* fix the lint error

* move PremiumStatusPushNotification to billing
2026-03-19 15:51:36 +01:00
Kyle Denney
2efacd596d [PM-30101] add multiple coupon support to server preview/purchase (#7229)
* [PM-30101] add multiple coupon support to server preview/purchase

* pr feedback
2026-03-19 09:07:49 -05:00
Ike
1bc5f4ec1e [PM-21926] [PM-30350] [PM-32389] Read salt from database (#7230)
feat: add MasterPasswordSalt to database responses and DTOs

- Add Dapper migration scripts and update SQL project
- Include MasterPasswordSalt in database response models and DTOs
- Add null coalescing to User entity for MasterPasswordSalt
- Update EF queries to return MasterPasswordSalt
- Rename migrations for consistency
- Add test coverage for affected repositories
- Update EmergencyAccessTakeOverResponseModel tests
2026-03-18 16:18:16 -04:00
Jordan Aasen
0cba609304 [PM-30751] - add secure SSRF protection for internal IPs (#7184)
* secure SSRP protection for internal requests

* remove nullable enable

* explicitly handle redirect requests for SSRF

* track current uri in SsrfProtectionHandler. add followRedirects option in AddSsrfProtection

* preserve request method for 301 and 302 requests
2026-03-18 09:11:25 -07:00
Thomas Rittson
f9f123b757 Revert MasterPasswordPolicyRequirement implementation (#7232)
This was being used to combine policies before sending them
to the client. Instead, the server just send the policies and
the client should process/combine them. Revert this to save
unnecessary QA (etc) and we will refactor this away in the
future.
2026-03-18 09:50:32 +10:00
Jared Snider
80e6f87afd Auth/PM-33168 - Emergency Access - Prevent grantor from inviting themselves as an emergency access contact (#7165) 2026-03-17 14:39:15 -04:00
Stephon Brown
8302509bf9 [PM-31645] Implement Swiss Tax Logic (#7186)
* feat(tax): introduce direct tax country utilities and Switzerland constant

* refactor(tax): use `TaxHelpers.IsDirectTaxCountry` for country checks

* feat(tax): implement customer tax exempt status alignment

* test(tax): add comprehensive unit tests for tax exempt alignment logic

* tests(billing): clarify tests

* fix(billing): run dotnet format

* fix(billing): run dotnet format

* fix(billing): Prevent NullReferenceException when accessing customer country

* test(billing): Add Stripe adapter mocks for AdjustSubscription scenarios

* refactor(billing): apply null-conditional operator for address country access

* feat(billing): update missing tax exemption determinations

* test(billing): add unit tests for tax exemption updates

* fix(billing) run dotnet format

* fix(billing): add nullability

* style(files): normalize file encoding for billing utilities

* refactor(TaxHelpers): simplify tax exempt status determination

* test(Tax): update tax exempt determination tests

* fix(billing): revert postal code validation

* test(billing): update tax exempt tests

* fix(billing): run dotnet format
2026-03-17 14:09:41 -04:00
Thomas Rittson
99454f5fe7 [PM-33216] Finalize RequireSsoPolicyRequirement (#7173)
* Add more efficient sproc to retrieve PolicyDetails
  for a single user. This closely matches the existing sproc
  used by PolicyService and should be performant enough
  to be used in the login flow

* Maintain feature flag for this critical path
2026-03-17 08:30:51 +10:00
John Harrington
c118f23e78 [PM-32885] Fix incorrect behavior for expired sends (#7203)
* fix unexpected/randomized error response for expired Sends
2026-03-16 13:19:35 -07:00
Nick Krantz
1fe173d253 [PM-31657] Address Overwriting Attachments (#7053)
* check permissions when uploading attachment for self hosted users to remove possibility of overwriting an existing attachment.

* expose `ValidateCipherEditForAttachmentAsync`

* add additional logic to support admin users

* add unit tests for new edit checks
2026-03-13 11:22:52 -07:00
Rui Tomé
454a6dbc81 [PM-19143] Refactor public API MembersController POST to use CommandResult pattern (#7182)
* Add CommandResultRefactor constant to FeatureFlagKeys in Constants.cs

* Add method to convert MemberCreateRequestModel to InviteOrganizationUsersRequest

- Introduced ToInviteRequest method for transforming MemberCreateRequestModel into InviteOrganizationUsersRequest.
- Enhanced model with additional using directives for improved functionality.

* Update GetInviterEmailAsync method to include a check for Guid.Empty to prevent unnecessary DB lookups

* Feature flag MembersController POST to use InviteOrganizationUsersCommand

Add a new code path behind the CommandResultRefactor feature flag that
replaces the legacy InviteUserAsync call with the InviteOrganizationUsersCommand.
Integration tests verify both paths produce identical results.

* Refactor feature flag for member invites from CommandResultRefactor to PublicMembersInviteRefactor in MembersController and update related tests.
2026-03-13 16:48:37 +00:00
Mick Letofsky
662828a16a Decouple seeder cipher encryption from internal vault crates (#7211) 2026-03-13 14:35:42 +01:00
Jimmy Vo
0ad7a10c56 [PM-32665] Fix Cross-Organization IDOR in Bulk User Revoke (#7206) 2026-03-13 09:32:16 -04:00
Jason Ng
fe3a8c2020 [PM-31820] added a null check to the id/partial route (#7066) 2026-03-12 14:04:17 -04:00
Patrick-Pimentel-Bitwarden
e0a08710a8 feat(emergency-access): [PM-29585] Prevent New EA Invitations or Acceptance (#6940)
* feat(emergency-access): [PM-29585] Prevent New EA Invitations or Acceptance - Initial implementation

* fix(emergency-access): [PM-29585] Prevent New EA Invitations or Acceptance - Changes in a good place. Need to write tests.

* test(emergency-access): [PM-29585] Prevent New EA Invitations or Acceptance - Service tests have been added.

* fix(emergency-access): [PM-29585] Prevent New EA Invitations or Acceptance - Fixed comment.
2026-03-12 16:48:19 +00:00
cd-bitwarden
ae5508d146 Restrict users from sending altered project name/value and it being saved to the database as an invalid encrypted value. (#6853) 2026-03-11 17:42:27 -04:00
Jared
09f0a7bca3 Refactor email confirmation logic to remove legacy mail service usage and streamline organization confirmation process (#7192) 2026-03-11 11:34:36 -04:00
Jimmy Vo
d96b885432 [PM-33040] Add new interface methods to IApplicationCacheService (#7187) 2026-03-11 11:33:54 -04:00
Bernd Schoolmann
79089a06c6 [PM-30584] Add support for key-connector-migration setting key (#7136)
* Add key-connector enrollment

* Fix tests

* Update src/Api/KeyManagement/Controllers/AccountsKeyManagementController.cs

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

* Move validation to request model

* Add tests

* Fix build

* Attempt to fix build

* Attempt to fix remaining tests

* Fix tests

* Format

---------

Co-authored-by: Thomas Avery <43214426+Thomas-Avery@users.noreply.github.com>
2026-03-11 09:15:41 +01:00
Jordan Aasen
3bb4467d1d [PM-32597] - create short-lived signed attachment URL for self-hosted instances (#7100)
* create short-lived signed attachment URL for self-hosted instances

* move local attachment logic to service

* remove comment

* remove unusued var. add happy-path test for file download
2026-03-10 13:24:07 -07:00
renovate[bot]
c7c17e850a [deps] Billing: Update coverlet.collector to v8 (#7118)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-10 11:02:50 -05:00
Todd Martin
f4956349b6 chore(flags): Remove pm-19394-send-access-control feature flag
* Remove feature flag.

* Fixed import statements.

* Fixed constructor.
2026-03-10 11:40:01 -04:00
Mick Letofsky
bf40668fc8 Seeder - Adding density distributions (#7191) 2026-03-10 16:22:23 +01:00
Jared
8037d373dc [PM-32666] Fixes endpoint issue where you can update another by providing a valid org ID (#7185)
* fix(controller): add null check for provider organization ID in ProviderClientsController

* feat(tests): add test for updating provider organization with different provider ID
2026-03-10 10:49:35 -04:00
Brandon Treston
49ec89d821 remove flagged logic (#7179) 2026-03-09 16:43:50 -04:00
Alex Morask
ed861d89f8 [PM-32581] Refactor organization subscription update process (#7132)
* chore: add CLAUDE.local.md and .worktrees to gitignore

* feat(billing): add Stripe interval and payment behavior constants and feature flag

* feat(billing): add OrganizationSubscriptionChangeSet model and unit tests

* refactor(billing): rename UpdateOrganizationSubscriptionCommand to BulkUpdateOrganizationSubscriptionsCommand

* feat(billing): add UpdateOrganizationSubscriptionCommand with tests

* feat(billing): use UpdateOrganizationSubscriptionCommand in BulkUpdateOrganizationSubscriptions behind feature flag

* feat(billing): use UpdateOrganizationSubscriptionCommand in SetUpSponsorshipCommand behind feature flag

* feat(billing): add UpgradeOrganizationPlanVNextCommand with tests and feature flag gate

* feat(billing): use UpdateOrganizationSubscriptionCommand in OrganizationService.AdjustSeatsAsync behind feature flag

* feat(billing): use UpdateOrganizationSubscriptionCommand in UpdateSecretsManagerSubscriptionCommand behind feature flag

* feat(billing): use UpdateOrganizationSubscriptionCommand in BillingHelpers.AdjustStorageAsync behind feature flag

* chore: run dotnet format

* fix(billing): missed optional owner in OrganizationBillingService.Finalize after merge

* refactor(billing): address PR feedback on UpdateOrganizationSubscription
2026-03-09 15:37:51 -05:00
Stephon Brown
4732d7fcd2 [PM-33061] Tax Id Should Be Added When Upgrading to Teams or Enterprise (#7131)
* refactor(billing): change billing address request type

* feat(billing): add tax id support for international business plans

* feat(billing): add billing address tax id handling

* test: add tests for tax id handling during upgrade

* fix(billing): run dotnet format

* fix(billing): remove extra line

* fix(billing): modify return type of HandleAsync

* test(billing): update tests to reflect updated command signature

* fix(billing): run dotnet format

* tests(billing): fix tests

* test(billing): format
2026-03-09 17:27:15 +00:00