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

1754 Commits

Author SHA1 Message Date
Federico Maccaroni
6f60d24f5a Email verification for new devices (#1931)
* PS-56 Added Email 2FA on login with new devices that don't have any 2FA enabled

* PS-56 Fixed wrong argument in VerifyTwoFactor call
2022-04-01 17:08:47 -03:00
Lauren N. Liberda
971914871d add some european takeaway domains to global domains (#1915) 2022-03-27 16:54:05 +02:00
Matt Gibson
4814cef245 Feature/self hosted development (#1921)
* Add self-host option to migration runner

* Add Self-host launch options

* Add self-hosted settings override

Let's a single secrets/env config file control both
cloud and self-hosted settings by allowing
overrides to cloud settings with self-hosted

* Allow dev-signed licenses on dev self-hosted

* Allow setting bitwarden cloud api url

Useful for testing api integration between installations and cloud

* Remove testing echoes

* Remove run config property groups

* Use `getopts` for options

* Pass in full environment
2022-03-21 17:13:00 -05:00
Oscar Hinton
e8cb8b67c9 Fix license signature containing LicenseType (#1917) 2022-03-16 16:15:36 +01:00
Vincent Salucci
7046aecfd5 [Captcha] BUG Add null checks | Make ceiling default to zero (#1903)
* [Captcha] BUG Add null checks | Make ceiling default to zero

* Formatting
2022-03-09 12:07:06 -06:00
Justin Baur
dd37745736 Fix OneLogin Import (#1899)
* Add PermissiveStringConverter

* Formatting

* Add value check

* Fix PR feedback

* Run formatter
2022-03-08 13:22:47 -05:00
Matt Gibson
a725802476 Handle null user in captch tokenable (#1897)
* Handle null user in captch tokenable

* Update test/Core.Test/Models/Business/Tokenables/HCaptchaTokenableTests.cs

Co-authored-by: Thomas Rittson <31796059+eliykat@users.noreply.github.com>

Co-authored-by: Thomas Rittson <31796059+eliykat@users.noreply.github.com>
2022-03-08 08:21:54 -06:00
Robyn MacCallum
4deb138fd9 Ignore case on AutoEnrollEnabled so it is deserialized properly (#1900) 2022-03-07 16:53:30 -05:00
Thomas Rittson
3443fe952b Don't send default SsoConfigurationData to clients (#1879) 2022-03-04 07:09:55 +10:00
Robyn MacCallum
17b22ca5a9 Add attachments check before moving ciphers to a free org (#1890) 2022-03-02 17:37:36 -05:00
Vincent Salucci
19d5817f8f [Captcha] Implement failed logins ceiling (#1870)
* [Hacker1] Failed Login Attempts Captcha

* [Captcha] Implement failed logins ceiling

* Formatting

* Updated approach after implementation talks with Kyle

* Updated email templates // Updated calling arch for failed attempts

* Formatting

* Updated 2fa email links

* Renamed baserequest methods to better match their actions

* EF migrations/scripts

* Updated with requested changes

* Defaults for MaxiumumFailedLoginAttempts
2022-03-02 15:45:00 -06:00
Kyle Spearrin
4cbe05da3c SendGrid Mail Delivery Provider (#1892)
* add sendgrid mail delivery service

* <

* remove duplicate code

* fix test by using ISendGridClient interface
2022-03-01 19:09:51 -05:00
Chad Scharf
a7a39fb54d CSA-6 Fix/remove artifact binding (#1885)
* Remove artifact binding, add validation

* Re-add JSON properties but eviscerate them
2022-02-28 13:43:49 -05:00
Oscar Hinton
95998292f7 Ensure we require premium for u2f (#1869) 2022-02-16 20:28:20 +01:00
Oscar Hinton
8d6c49f656 Add lock files for NuGet (#1855) 2022-02-10 15:40:31 +01:00
Justin Baur
1b0d18a7c5 Switch to Legacy Deserialization (#1851) 2022-02-09 10:39:45 -05:00
Oscar Hinton
f824a2aaf1 Revert to using newtonsoft for saving org TwoFactorProviders (#1850) 2022-02-09 14:46:37 +01:00
Oscar Hinton
e05fce18bd Resolve being unable to configure duo (System.Text.Json) (#1847) 2022-02-09 14:12:31 +01:00
Oscar Hinton
2ed8be75dd Fix organization duo 2fa not working due to switch to System.Text.Json (#1846) 2022-02-09 13:45:20 +01:00
Daniel James Smith
cecf052b33 Remove falsely added Microsoft.Azure.Storage.Blobs (#1845) 2022-02-09 13:32:40 +01:00
Oscar Hinton
9c98f0358b Fix newtonsoft complaining about U2f keys (#1844) 2022-02-09 13:05:03 +01:00
Oscar Hinton
cd61c826f9 [BEEEP] Add explicit error message when uploading the wrong license type (#1831) 2022-02-07 09:43:00 +01:00
Justin Baur
9e074bca49 Revert TwoFactorProviders to be saved with numerical value (#1828)
* Add enum key resolver

* Change tests to reflect changes
2022-02-02 14:21:11 -05:00
Matt Gibson
8ce4d56a91 Fix/f4e multiple sponsorships (#1838)
* Use sponosorship from validate to redeem

* Update tests

* Format
2022-02-02 12:59:47 -06:00
Justin Baur
b47c30d4f4 Fix organization_license not reading camelCase (#1832)
* Fix organization_license not reading camelCase

* Fix formatting
2022-02-01 12:26:50 -05:00
Oscar Hinton
a9a5417350 Fix WebAuthn not working after move to System.Text.Json (#1818) 2022-01-24 18:13:43 +01:00
Oscar Hinton
ac8ca46f0f Remove the u2f lib (#1820) 2022-01-24 12:14:04 +01:00
Justin Baur
5268f2781e Start Migration from Newtonsoft.Json to System.Text.Json (#1803)
* Start switch to System.Text.Json

* Work on switching to System.Text.Json

* Main work on STJ refactor

* Fix build errors

* Run formatting

* Delete unused file

* Use legacy for two factor providers

* Run formatter

* Add TokenProviderTests

* Run formatting

* Fix merge issues

* Switch to use JsonSerializer

* Address PR feedback

* Fix formatting

* Ran formatter

* Switch to async

* Ensure Enums are serialized as strings

* Fix formatting

* Enqueue single items as arrays

* Remove CreateAsync method on AzureQueueService
2022-01-21 09:36:25 -05:00
Oscar Hinton
68a8092235 [Emergency Access] Add premium check (#1815) 2022-01-18 16:05:12 +01:00
Oscar Hinton
0def1830af Move identity endpoints to Identity service (#1807) 2022-01-17 13:21:51 +01:00
Federico Maccaroni
56ee3bd290 Fix silent push notifications for iOS, it should not contain alert, badge nor sound keys in aps (#1808) 2022-01-14 10:52:50 -03:00
Oscar Hinton
e4a10aae27 Split out repositories to Infrastructure.Dapper / EntityFramework (#1759) 2022-01-11 10:40:51 +01:00
Matt Gibson
e2c6fc81f4 Feature/token service (#1785)
* Implement draft token service

* Add tokenizer and factory

* Handle expiring tokens through base class

* Allow direct token validity checks

* Add safe unprotect to tokenizer

* Add interface to tokenizer factory

* Use tokenizer

* Fix rebase

* Handle cleartext prefix in tokenizer base

* Use epoch milliseconds for expiration in tokens

* Use tokenizers

* Test tokens

* Linter fixes

* Add TokenizerFactory to DI services

* Test epoch milliseconds deserialization

* Use separate injectables for each token type

* Fix directory

* Add functional unprotect to token

* Fix namespace and correct object names

* Remove Tokenable interface

* Test remaining Tokens classes

* Dotnet format

* Fix sut provider errors with update

* Remove useless property

Co-authored-by: Hinton <oscar@oscarhinton.com>
2022-01-10 09:58:16 -06:00
Daniel James Smith
355bf2127b Migrate deprecated Microsoft.Azure.Storage.Blob to Azure.Storage.Blobs (#1732)
* Migrate from deprecated Microsoft.Azure.Storage to Azure.Storage.Blobs

* Remove and order usings

* Do not fetch BlobProperties before uploading a new file.

* Save an api call by calling GetPropertiesAsync and catching an error instead of calling Exists first

* Formatted files

* Verified ContentLength is the correct blob property for file-size

* Use a generic Exception catch for file validation

* Added a catch all to the GetBlobCertificateAsync in case something throws

* Remove and sort using

* Changes after running dotnet-format

* Remove checks for CanGenerateSasUri
2021-12-22 19:47:35 +01:00
Haneef
5a8f334550 Added transferwise equivalent domains (#1743)
* Added transferwise domains

TransferWise.com and Wise.com

* Remove empty line

Co-authored-by: Daniel James Smith <djsmith@web.de>
2021-12-19 14:00:08 +01:00
huntb4646
224bfb6ff1 Add wellsfargoadvisors.com as equivalent domain (#1722)
wellsfargoadvisors.com uses the same authentication as wellsfargo.com and Wells Fargo's other sites. It should be considered an equivalent domain for these purposes.
2021-12-17 17:55:17 +01:00
huntb4646
2f518fb93f Add Ubisoft equivalent domains (#1723)
* Add Ubisoft to Global Equivalent Domain enum

* Add Ubisoft equivalent domains list

Adding ubisoft.com and ubi.com as equivalent domains under new list.
2021-12-17 17:45:01 +01:00
Jake Fink
11aafac915 remove re-throws of exceptions, which clear the stack trace (#1760)
* remove re-throws of exceptions, which clear the stack trace

* remove whitespace
2021-12-16 15:35:07 -05:00
Oscar Hinton
23b0a1f9df Run dotnet format (#1764) 2021-12-16 15:35:09 +01:00
Matt Gibson
e999f66a28 Send invites for both all collection and limited collection users (#1765)
* Send invites for both all collection and limited collection users

* Test all access and limited access invites

* Remove comment
2021-12-14 10:29:31 -06:00
Oscar Hinton
63f6dd9a24 Move request/response models (#1754) 2021-12-14 16:05:07 +01:00
Thomas Rittson
3ae573bd8d Make optional ssoConfig fields nullable (#1752) 2021-12-14 20:02:22 +10:00
Vince Grassia
2ec10cfd2a Standardize '/version' endpoint on all services (#1755) 2021-12-09 15:45:45 -05:00
Oscar Hinton
71c4b53999 Fix recursive call in TwoFactorWebAuthnDeleteRequestModel (#1750)
* Fix recursive call in TwoFactorwebAuthnDeleteRequestModel

* Add new befoer IEnumerable

* Use virtual and override
2021-12-08 12:43:21 -05:00
Matt Gibson
d7e92dae5b Determine self hosted from global settings (#1744) 2021-12-07 10:52:36 -06:00
Matt Gibson
9177ad1ca8 Parse enqueued mail message model to object (#1742)
* Parse enqueued mail message model to object

The model of an MailQueueMessage is of type object to enable enqueueing
of any message. However, this means the we are not able to parse a
serialized json object back into the original object.
Provide the model type to enable this deserialization

* Use ExpandoObject for deserialized queue message model
2021-12-03 12:12:46 -06:00
Oscar Hinton
71229c2366 Streamline error message for removed user account with CME (#1741) 2021-12-02 18:38:27 +00:00
Matt Gibson
a70564cea8 Families for enterprise/fix new org sponsorship after deleted sponsored org (#1740)
* Sponsorship exists only if sponsored org is not null

* Replace existing sponsorship if necessary

* Update src/Core/Services/Implementations/OrganizationSponsorshipService.cs

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

* Fix tests

Co-authored-by: Robyn MacCallum <nickersthecat@gmail.com>
2021-12-02 10:27:41 -06:00
Matt Gibson
dc3d70cf3a Pay 0 cost invoices that have not been paid (#1739) 2021-12-01 14:41:05 -06:00
Matt Gibson
757927e02a Null org, org user ids, and friendly name to indicate invalid, unused sponsorship state (#1738)
* Null org, org user ids, and friendly name to indicate invalid, unused sponsorship state

* Match EF queries to MSSQL sprocs
2021-12-01 14:34:56 -06:00