1
0
mirror of https://github.com/bitwarden/server synced 2026-01-11 13:03:27 +00:00

Block MSPs from adding SM to a managed org

This commit is contained in:
Thomas Rittson
2023-08-31 15:19:46 +10:00
parent 75fe220970
commit e4600a199f
2 changed files with 21 additions and 0 deletions

View File

@@ -410,6 +410,11 @@ public class OrganizationService : IOrganizationService
var secretsManagerPlan = StaticStore.SecretManagerPlans.FirstOrDefault(p => p.Type == signup.Plan);
if (signup.UseSecretsManager)
{
if (provider)
{
throw new BadRequestException(
"Organizations with a Managed Service Provider do not support Secrets Manager.");
}
ValidateSecretsManagerPlan(secretsManagerPlan, signup);
}