2022-12-14 15:28:51 +01:00
|
|
|
|
// <auto-generated />
|
|
|
|
|
using System;
|
|
|
|
|
using Bit.Infrastructure.EntityFramework.Repositories;
|
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
|
|
|
|
|
|
|
|
#nullable disable
|
|
|
|
|
|
|
|
|
|
namespace Bit.SqliteMigrations.Migrations
|
|
|
|
|
{
|
|
|
|
|
[DbContext(typeof(DatabaseContext))]
|
|
|
|
|
partial class DatabaseContextModelSnapshot : ModelSnapshot
|
|
|
|
|
{
|
|
|
|
|
protected override void BuildModel(ModelBuilder modelBuilder)
|
|
|
|
|
{
|
|
|
|
|
#pragma warning disable 612, 618
|
2024-07-02 16:08:34 +02:00
|
|
|
|
modelBuilder.HasAnnotation("ProductVersion", "8.0.6");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("AllowAdminAccessToAllCollectionItems")
|
|
|
|
|
.HasColumnType("INTEGER")
|
|
|
|
|
.HasDefaultValue(true);
|
|
|
|
|
|
|
|
|
|
b.Property<string>("BillingEmail")
|
2024-07-05 03:14:37 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress1")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress2")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress3")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessCountry")
|
|
|
|
|
.HasMaxLength(2)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessName")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessTaxNumber")
|
|
|
|
|
.HasMaxLength(30)
|
2023-06-15 23:54:08 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("ExpirationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2024-01-11 04:25:57 +01:00
|
|
|
|
b.Property<bool>("FlexibleCollections")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte?>("Gateway")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("GatewayCustomerId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("GatewaySubscriptionId")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Identifier")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("LicenseKey")
|
|
|
|
|
.HasMaxLength(100)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("LimitCollectionCreationDeletion")
|
|
|
|
|
.HasColumnType("INTEGER")
|
|
|
|
|
.HasDefaultValue(true);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("MaxAutoscaleSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-06-15 23:54:08 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("MaxAutoscaleSmSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("MaxAutoscaleSmServiceAccounts")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<short?>("MaxCollections")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<short?>("MaxStorageGb")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Name")
|
2024-07-05 03:14:37 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(50)
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("OwnersNotifiedOfAutoscaling")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Plan")
|
2024-07-05 03:14:37 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(50)
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("PlanType")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("PrivateKey")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("PublicKey")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ReferenceData")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("Seats")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("SelfHost")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("SmSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int?>("SmServiceAccounts")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Status")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<long?>("Storage")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("TwoFactorProviders")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Use2fa")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseApi")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseCustomPermissions")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseDirectory")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseEvents")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseGroups")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseKeyConnector")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UsePasswordManager")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UsePolicies")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseResetPassword")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseScim")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("UseSecretsManager")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("UseSso")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("UseTotp")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("UsersGetPremium")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("Id", "Enabled")
|
|
|
|
|
.HasAnnotation("Npgsql:IndexInclude", new[] { "UseTotp" });
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Organization", (string)null);
|
2023-05-01 15:32:06 +02:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Policy", b =>
|
2023-05-01 15:32:06 +02:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Data")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-05-01 15:32:06 +02:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId", "Type")
|
|
|
|
|
.IsUnique()
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Policy", (string)null);
|
2023-05-01 15:32:06 +02:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", b =>
|
2023-05-01 15:32:06 +02:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("Id")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BillingEmail")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BillingPhone")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress1")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress2")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessAddress3")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessCountry")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessName")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-05-01 15:32:06 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("BusinessTaxNumber")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2024-06-05 20:42:02 +02:00
|
|
|
|
b.Property<byte?>("Gateway")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
b.Property<string>("GatewayCustomerId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("GatewaySubscriptionId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Status")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("UseEvents")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Provider", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.ProviderOrganization", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("Id")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("ProviderId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Settings")
|
|
|
|
|
.HasColumnType("TEXT");
|
[AC-1373] Flexible Collections (#3245)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* fix: merge conflict resolution
* [AC-1174] CollectionUser and CollectionGroup authorization handlers (#3194)
* [AC-1174] Introduce BulkAuthorizationHandler.cs
* [AC-1174] Introduce CollectionUserAuthorizationHandler
* [AC-1174] Add CreateForNewCollection CollectionUser requirement
* [AC-1174] Add some more details to CollectionCustomization
* [AC-1174] Formatting
* [AC-1174] Add CollectionGroupOperation.cs
* [AC-1174] Introduce CollectionGroupAuthorizationHandler.cs
* [AC-1174] Cleanup CollectionFixture customization
Implement and use re-usable extension method to support seeded Guids
* [AC-1174] Introduce WithValueFromList AutoFixtureExtensions
Modify CollectionCustomization to use multiple organization Ids for auto generated test data
* [AC-1174] Simplify CollectionUserAuthorizationHandler.cs
Modify the authorization handler to only perform authorization logic. Validation logic will need to be handled by any calling commands/controllers instead.
* [AC-1174] Introduce shared CollectionAccessAuthorizationHandlerBase
A shared base authorization handler was created for both CollectionUser and CollectionGroup resources, as they share the same underlying management authorization logic.
* [AC-1174] Update CollectionUserAuthorizationHandler and CollectionGroupAuthorizationHandler to use the new CollectionAccessAuthorizationHandlerBase class
* [AC-1174] Formatting
* [AC-1174] Cleanup typo and redundant ToList() call
* [AC-1174] Add check for provider users
* [AC-1174] Reduce nested loops
* [AC-1174] Introduce ICollectionAccess.cs
* [AC-1174] Remove individual CollectionGroup and CollectionUser auth handlers and use base class instead
* [AC-1174] Tweak unit test to fail minimally
* [AC-1174] Reorganize authorization handlers in Core project
* [AC-1174] Introduce new AddCoreAuthorizationHandlers() extension method
* [AC-1174] Move CollectionAccessAuthorizationHandler into Api project
* [AC-1174] Move CollectionFixture to Vault folder
* [AC-1174] Rename operation to CreateUpdateDelete
* [AC-1174] Require single organization for collection access authorization handler
- Add requirement that all target collections must belong to the same organization
- Simplify logic related to multiple organizations
- Update tests and helpers
- Use ToHashSet to improve lookup time
* [AC-1174] Fix null reference exception
* [AC-1174] Throw bad request exception when collections belong to different organizations
* [AC-1174] Switch to CollectionAuthorizationHandler instead of CollectionAccessAuthorizationHandler to reduce complexity
* Fix improper merge conflict resolution
* fix: add permission check for collection management api, refs AC-1647 (#3252)
* [AC-1125] Enforce org setting for creating/deleting collections (#3241)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* feat: created collection auth handler/operations, added LimitCollectionCdOwnerAdmin to CurrentContentOrganization, refs AC-1125
* feat: create vault service collection extensions and register with base services, refs AC-1125
* feat: deprecated CurrentContext.CreateNewCollections, refs AC-1125
* feat: deprecate DeleteAnyCollection for single resource usages, refs AC-1125
* feat: move service registration to api, update references, refs AC-1125
* feat: add bulk delete authorization handler, refs AC-1125
* feat: always assign user and give manage access on create, refs AC-1125
* fix: updated CurrentContextOrganization type, refs AC-1125
* feat: combined existing collection authorization handlers/operations, refs AC-1125
* fix: OrganizationServiceTests -> CurrentContentOrganization typo, refs AC-1125
* fix: format, refs AC-1125
* fix: update collection controller tests, refs AC-1125
* fix: dotnet format, refs AC-1125
* feat: removed extra BulkAuthorizationHandler, refs AC-1125
* fix: dotnet format, refs AC-1125
* fix: change string to guid for org id, update bulk delete request model, refs AC-1125
* fix: remove delete many collection check, refs AC-1125
* fix: clean up collection auth handler, refs AC-1125
* fix: format fix for CollectionOperations, refs AC-1125
* fix: removed unnecessary owner check, add org null check to custom permission validation, refs AC-1125
* fix: remove unused methods in CurrentContext, refs AC-1125
* fix: removed obsolete test, fixed failling delete many test, refs AC-1125
* fix: CollectionAuthorizationHandlerTests fixes, refs AC-1125
* fix: OrganizationServiceTests fix broken test by mocking GetOrganization, refs AC-1125
* fix: CollectionAuthorizationHandler - remove unused repository, refs AC-1125
* feat: moved UserId null check to common method, refs AC-1125
* fix: updated auth handler tests to remove dependency on requirement for common code checks, refs AC-1125
* feat: updated conditionals/comments for create/delete methods within colleciton auth handler, refs AC-1125
* feat: added create/delete collection auth handler success methods, refs AC-1125
* fix: new up permissions to prevent excessive null checks, refs AC-1125
* fix: remove old reference to CreateNewCollections, refs AC-1125
* fix: typo within ViewAssignedCollections method, refs AC-1125
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
* refactor: remove organizationId from CollectionBulkDeleteRequestModel, refs AC-1649 (#3282)
* [AC-1174] Bulk Collection Management (#3229)
* [AC-1174] Update SelectionReadOnlyRequestModel to use Guid for Id property
* [AC-1174] Introduce initial bulk-access collection endpoint
* [AC-1174] Introduce BulkAddCollectionAccessCommand and validation logic/tests
* [AC-1174] Add CreateOrUpdateAccessMany method to CollectionRepository
* [AC-1174] Add event logs for bulk add collection access command
* [AC-1174] Add User_BumpAccountRevisionDateByCollectionIds and database migration script
* [AC-1174] Implement EF repository method
* [AC-1174] Improve null checks
* [AC-1174] Remove unnecessary BulkCollectionAccessRequestModel helpers
* [AC-1174] Add unit tests for new controller endpoint
* [AC-1174] Fix formatting
* [AC-1174] Remove comment
* [AC-1174] Remove redundant organizationId parameter
* [AC-1174] Ensure user and group Ids are distinct
* [AC-1174] Cleanup tests based on PR feedback
* [AC-1174] Formatting
* [AC-1174] Update CollectionGroup alias in the sproc
* [AC-1174] Add some additional comments to SQL sproc
* [AC-1174] Add comment explaining additional SaveChangesAsync call
---------
Co-authored-by: Thomas Rittson <trittson@bitwarden.com>
* [AC-1646] Rename LimitCollectionCdOwnerAdmin column (#3300)
* Rename LimitCollectionCdOwnerAdmin -> LimitCollectionCreationDeletion
* Rename and bump migration script
* [AC-1666] Removed EditAnyCollection from Create/Delete permission checks (#3301)
* fix: remove EditAnyCollection from Create/Delete permission check, refs AC-1666
* fix: updated comment, refs AC-1666
* [AC-1669] Bug - Remove obsolete assignUserId from CollectionService.SaveAsync(...) (#3312)
* fix: remove AssignUserId from CollectionService.SaveAsync, refs AC-1669
* fix: add manage access conditional before creating collection, refs AC-1669
* fix: move access logic for create/update, fix all tests, refs AC-1669
* fix: add CollectionAccessSelection fixture, update tests, update bad reqeuest message, refs AC-1669
* fix: format, refs AC-1669
* fix: update null params with specific arg.is null checks, refs Ac-1669
* fix: update attribute class name, refs AC-1669
* [AC-1713] [Flexible collections] Add feature flags to server (#3334)
* Add feature flags for FlexibleCollections and BulkCollectionAccess
* Flag new routes and behaviour
---------
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
* Add joint codeownership for auth handlers (#3346)
* [AC-1717] Update default values for LimitCollectionCreationDeletion (#3365)
* Change default value in organization create sproc to 1
* Drop old column name still present in some QA instances
* Set LimitCollectionCreationDeletion value in code based on feature flag
* Fix: add missing namespace after merging in master
* Fix: add missing namespace after merging in master
* [AC-1683] Fix DB migrations for new Manage permission (#3307)
* [AC-1683] Update migration script and introduce V2 procedures and types
* [AC-1683] Update repository calls to use new V2 procedures / types
* [AC-1684] Update bulk add collection migration script to use new V2 type
* [AC-1683] Undo Manage changes to more original procedures
* [AC-1683] Restore whitespace changes
* [AC-1683] Clarify comments regarding explicit column lists
* [AC-1683] Update migration script dates
* [AC-1683] Split the migration script for readability
* [AC-1683] Re-name SelectReadOnlyArray_V2 to CollectionAccessSelectionType
* [AC-1648] [Flexible Collections] Bump migration scripts before feature branch merge (#3371)
* Bump dates on sql migration scripts
* Bump date on ef migrations
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
Co-authored-by: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com>
Co-authored-by: Vincent Salucci <vincesalucci21@gmail.com>
Co-authored-by: Shane Melton <smelton@bitwarden.com>
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
2023-11-01 10:30:52 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("ProviderId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("ProviderOrganization", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.ProviderUser", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("Id")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Email")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Permissions")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("ProviderId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Status")
|
[AC-1373] Flexible Collections (#3245)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* fix: merge conflict resolution
* [AC-1174] CollectionUser and CollectionGroup authorization handlers (#3194)
* [AC-1174] Introduce BulkAuthorizationHandler.cs
* [AC-1174] Introduce CollectionUserAuthorizationHandler
* [AC-1174] Add CreateForNewCollection CollectionUser requirement
* [AC-1174] Add some more details to CollectionCustomization
* [AC-1174] Formatting
* [AC-1174] Add CollectionGroupOperation.cs
* [AC-1174] Introduce CollectionGroupAuthorizationHandler.cs
* [AC-1174] Cleanup CollectionFixture customization
Implement and use re-usable extension method to support seeded Guids
* [AC-1174] Introduce WithValueFromList AutoFixtureExtensions
Modify CollectionCustomization to use multiple organization Ids for auto generated test data
* [AC-1174] Simplify CollectionUserAuthorizationHandler.cs
Modify the authorization handler to only perform authorization logic. Validation logic will need to be handled by any calling commands/controllers instead.
* [AC-1174] Introduce shared CollectionAccessAuthorizationHandlerBase
A shared base authorization handler was created for both CollectionUser and CollectionGroup resources, as they share the same underlying management authorization logic.
* [AC-1174] Update CollectionUserAuthorizationHandler and CollectionGroupAuthorizationHandler to use the new CollectionAccessAuthorizationHandlerBase class
* [AC-1174] Formatting
* [AC-1174] Cleanup typo and redundant ToList() call
* [AC-1174] Add check for provider users
* [AC-1174] Reduce nested loops
* [AC-1174] Introduce ICollectionAccess.cs
* [AC-1174] Remove individual CollectionGroup and CollectionUser auth handlers and use base class instead
* [AC-1174] Tweak unit test to fail minimally
* [AC-1174] Reorganize authorization handlers in Core project
* [AC-1174] Introduce new AddCoreAuthorizationHandlers() extension method
* [AC-1174] Move CollectionAccessAuthorizationHandler into Api project
* [AC-1174] Move CollectionFixture to Vault folder
* [AC-1174] Rename operation to CreateUpdateDelete
* [AC-1174] Require single organization for collection access authorization handler
- Add requirement that all target collections must belong to the same organization
- Simplify logic related to multiple organizations
- Update tests and helpers
- Use ToHashSet to improve lookup time
* [AC-1174] Fix null reference exception
* [AC-1174] Throw bad request exception when collections belong to different organizations
* [AC-1174] Switch to CollectionAuthorizationHandler instead of CollectionAccessAuthorizationHandler to reduce complexity
* Fix improper merge conflict resolution
* fix: add permission check for collection management api, refs AC-1647 (#3252)
* [AC-1125] Enforce org setting for creating/deleting collections (#3241)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* feat: created collection auth handler/operations, added LimitCollectionCdOwnerAdmin to CurrentContentOrganization, refs AC-1125
* feat: create vault service collection extensions and register with base services, refs AC-1125
* feat: deprecated CurrentContext.CreateNewCollections, refs AC-1125
* feat: deprecate DeleteAnyCollection for single resource usages, refs AC-1125
* feat: move service registration to api, update references, refs AC-1125
* feat: add bulk delete authorization handler, refs AC-1125
* feat: always assign user and give manage access on create, refs AC-1125
* fix: updated CurrentContextOrganization type, refs AC-1125
* feat: combined existing collection authorization handlers/operations, refs AC-1125
* fix: OrganizationServiceTests -> CurrentContentOrganization typo, refs AC-1125
* fix: format, refs AC-1125
* fix: update collection controller tests, refs AC-1125
* fix: dotnet format, refs AC-1125
* feat: removed extra BulkAuthorizationHandler, refs AC-1125
* fix: dotnet format, refs AC-1125
* fix: change string to guid for org id, update bulk delete request model, refs AC-1125
* fix: remove delete many collection check, refs AC-1125
* fix: clean up collection auth handler, refs AC-1125
* fix: format fix for CollectionOperations, refs AC-1125
* fix: removed unnecessary owner check, add org null check to custom permission validation, refs AC-1125
* fix: remove unused methods in CurrentContext, refs AC-1125
* fix: removed obsolete test, fixed failling delete many test, refs AC-1125
* fix: CollectionAuthorizationHandlerTests fixes, refs AC-1125
* fix: OrganizationServiceTests fix broken test by mocking GetOrganization, refs AC-1125
* fix: CollectionAuthorizationHandler - remove unused repository, refs AC-1125
* feat: moved UserId null check to common method, refs AC-1125
* fix: updated auth handler tests to remove dependency on requirement for common code checks, refs AC-1125
* feat: updated conditionals/comments for create/delete methods within colleciton auth handler, refs AC-1125
* feat: added create/delete collection auth handler success methods, refs AC-1125
* fix: new up permissions to prevent excessive null checks, refs AC-1125
* fix: remove old reference to CreateNewCollections, refs AC-1125
* fix: typo within ViewAssignedCollections method, refs AC-1125
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
* refactor: remove organizationId from CollectionBulkDeleteRequestModel, refs AC-1649 (#3282)
* [AC-1174] Bulk Collection Management (#3229)
* [AC-1174] Update SelectionReadOnlyRequestModel to use Guid for Id property
* [AC-1174] Introduce initial bulk-access collection endpoint
* [AC-1174] Introduce BulkAddCollectionAccessCommand and validation logic/tests
* [AC-1174] Add CreateOrUpdateAccessMany method to CollectionRepository
* [AC-1174] Add event logs for bulk add collection access command
* [AC-1174] Add User_BumpAccountRevisionDateByCollectionIds and database migration script
* [AC-1174] Implement EF repository method
* [AC-1174] Improve null checks
* [AC-1174] Remove unnecessary BulkCollectionAccessRequestModel helpers
* [AC-1174] Add unit tests for new controller endpoint
* [AC-1174] Fix formatting
* [AC-1174] Remove comment
* [AC-1174] Remove redundant organizationId parameter
* [AC-1174] Ensure user and group Ids are distinct
* [AC-1174] Cleanup tests based on PR feedback
* [AC-1174] Formatting
* [AC-1174] Update CollectionGroup alias in the sproc
* [AC-1174] Add some additional comments to SQL sproc
* [AC-1174] Add comment explaining additional SaveChangesAsync call
---------
Co-authored-by: Thomas Rittson <trittson@bitwarden.com>
* [AC-1646] Rename LimitCollectionCdOwnerAdmin column (#3300)
* Rename LimitCollectionCdOwnerAdmin -> LimitCollectionCreationDeletion
* Rename and bump migration script
* [AC-1666] Removed EditAnyCollection from Create/Delete permission checks (#3301)
* fix: remove EditAnyCollection from Create/Delete permission check, refs AC-1666
* fix: updated comment, refs AC-1666
* [AC-1669] Bug - Remove obsolete assignUserId from CollectionService.SaveAsync(...) (#3312)
* fix: remove AssignUserId from CollectionService.SaveAsync, refs AC-1669
* fix: add manage access conditional before creating collection, refs AC-1669
* fix: move access logic for create/update, fix all tests, refs AC-1669
* fix: add CollectionAccessSelection fixture, update tests, update bad reqeuest message, refs AC-1669
* fix: format, refs AC-1669
* fix: update null params with specific arg.is null checks, refs Ac-1669
* fix: update attribute class name, refs AC-1669
* [AC-1713] [Flexible collections] Add feature flags to server (#3334)
* Add feature flags for FlexibleCollections and BulkCollectionAccess
* Flag new routes and behaviour
---------
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
* Add joint codeownership for auth handlers (#3346)
* [AC-1717] Update default values for LimitCollectionCreationDeletion (#3365)
* Change default value in organization create sproc to 1
* Drop old column name still present in some QA instances
* Set LimitCollectionCreationDeletion value in code based on feature flag
* Fix: add missing namespace after merging in master
* Fix: add missing namespace after merging in master
* [AC-1683] Fix DB migrations for new Manage permission (#3307)
* [AC-1683] Update migration script and introduce V2 procedures and types
* [AC-1683] Update repository calls to use new V2 procedures / types
* [AC-1684] Update bulk add collection migration script to use new V2 type
* [AC-1683] Undo Manage changes to more original procedures
* [AC-1683] Restore whitespace changes
* [AC-1683] Clarify comments regarding explicit column lists
* [AC-1683] Update migration script dates
* [AC-1683] Split the migration script for readability
* [AC-1683] Re-name SelectReadOnlyArray_V2 to CollectionAccessSelectionType
* [AC-1648] [Flexible Collections] Bump migration scripts before feature branch merge (#3371)
* Bump dates on sql migration scripts
* Bump date on ef migrations
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
Co-authored-by: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com>
Co-authored-by: Vincent Salucci <vincesalucci21@gmail.com>
Co-authored-by: Shane Melton <smelton@bitwarden.com>
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
2023-11-01 10:30:52 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Type")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("ProviderId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ProviderUser", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.AuthRequest", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("AccessCode")
|
|
|
|
|
.HasMaxLength(25)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool?>("Approved")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("AuthenticationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Key")
|
2023-06-10 03:36:12 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("MasterPasswordHash")
|
2023-06-10 03:36:12 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
2023-06-10 03:36:12 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("PublicKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("RequestDeviceIdentifier")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("RequestDeviceType")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("RequestIpAddress")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("ResponseDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ResponseDeviceId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ResponseDeviceId");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("AuthRequest", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.EmergencyAccess", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Email")
|
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("GranteeId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("GrantorId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("KeyEncrypted")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("LastNotificationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("RecoveryInitiatedDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Status")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("WaitTimeDays")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GranteeId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantorId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("EmergencyAccess", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.Grant", b =>
|
|
|
|
|
{
|
2023-12-28 21:04:45 +01:00
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-03-21 16:15:49 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ClientId")
|
2023-12-28 21:04:45 +01:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(200)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("ConsumedDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Data")
|
2023-12-28 21:04:45 +01:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Description")
|
|
|
|
|
.HasMaxLength(200)
|
2023-02-24 16:44:33 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("ExpirationDate")
|
2023-02-24 16:44:33 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-28 21:04:45 +01:00
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.IsRequired()
|
|
|
|
|
.HasMaxLength(200)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("SessionId")
|
|
|
|
|
.HasMaxLength(100)
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("SubjectId")
|
|
|
|
|
.HasMaxLength(200)
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Type")
|
2023-12-28 21:04:45 +01:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-28 21:04:45 +01:00
|
|
|
|
b.HasKey("Id")
|
2024-02-05 21:51:31 +01:00
|
|
|
|
.HasName("PK_Grant")
|
2023-12-28 21:04:45 +01:00
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
2024-01-17 17:42:43 +01:00
|
|
|
|
b.HasIndex("ExpirationDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2023-12-28 21:04:45 +01:00
|
|
|
|
b.HasIndex("Key")
|
|
|
|
|
.IsUnique();
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Grant", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.SsoConfig", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<long>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Data")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("SsoConfig", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.SsoUser", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<long>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ExternalId")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("UserId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2024-01-17 17:42:43 +01:00
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("UserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2024-01-17 17:42:43 +01:00
|
|
|
|
b.HasIndex("OrganizationId", "ExternalId")
|
|
|
|
|
.IsUnique()
|
|
|
|
|
.HasAnnotation("Npgsql:IndexInclude", new[] { "UserId" })
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId", "UserId")
|
|
|
|
|
.IsUnique()
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("SsoUser", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.WebAuthnCredential", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("AaGuid")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int>("Counter")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("CredentialId")
|
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedPrivateKey")
|
|
|
|
|
.HasMaxLength(2000)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedPublicKey")
|
|
|
|
|
.HasMaxLength(2000)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedUserKey")
|
|
|
|
|
.HasMaxLength(2000)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("PublicKey")
|
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("SupportsPrf")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Type")
|
|
|
|
|
.HasMaxLength(20)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("UserId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
[AC-1373] Flexible Collections (#3245)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* fix: merge conflict resolution
* [AC-1174] CollectionUser and CollectionGroup authorization handlers (#3194)
* [AC-1174] Introduce BulkAuthorizationHandler.cs
* [AC-1174] Introduce CollectionUserAuthorizationHandler
* [AC-1174] Add CreateForNewCollection CollectionUser requirement
* [AC-1174] Add some more details to CollectionCustomization
* [AC-1174] Formatting
* [AC-1174] Add CollectionGroupOperation.cs
* [AC-1174] Introduce CollectionGroupAuthorizationHandler.cs
* [AC-1174] Cleanup CollectionFixture customization
Implement and use re-usable extension method to support seeded Guids
* [AC-1174] Introduce WithValueFromList AutoFixtureExtensions
Modify CollectionCustomization to use multiple organization Ids for auto generated test data
* [AC-1174] Simplify CollectionUserAuthorizationHandler.cs
Modify the authorization handler to only perform authorization logic. Validation logic will need to be handled by any calling commands/controllers instead.
* [AC-1174] Introduce shared CollectionAccessAuthorizationHandlerBase
A shared base authorization handler was created for both CollectionUser and CollectionGroup resources, as they share the same underlying management authorization logic.
* [AC-1174] Update CollectionUserAuthorizationHandler and CollectionGroupAuthorizationHandler to use the new CollectionAccessAuthorizationHandlerBase class
* [AC-1174] Formatting
* [AC-1174] Cleanup typo and redundant ToList() call
* [AC-1174] Add check for provider users
* [AC-1174] Reduce nested loops
* [AC-1174] Introduce ICollectionAccess.cs
* [AC-1174] Remove individual CollectionGroup and CollectionUser auth handlers and use base class instead
* [AC-1174] Tweak unit test to fail minimally
* [AC-1174] Reorganize authorization handlers in Core project
* [AC-1174] Introduce new AddCoreAuthorizationHandlers() extension method
* [AC-1174] Move CollectionAccessAuthorizationHandler into Api project
* [AC-1174] Move CollectionFixture to Vault folder
* [AC-1174] Rename operation to CreateUpdateDelete
* [AC-1174] Require single organization for collection access authorization handler
- Add requirement that all target collections must belong to the same organization
- Simplify logic related to multiple organizations
- Update tests and helpers
- Use ToHashSet to improve lookup time
* [AC-1174] Fix null reference exception
* [AC-1174] Throw bad request exception when collections belong to different organizations
* [AC-1174] Switch to CollectionAuthorizationHandler instead of CollectionAccessAuthorizationHandler to reduce complexity
* Fix improper merge conflict resolution
* fix: add permission check for collection management api, refs AC-1647 (#3252)
* [AC-1125] Enforce org setting for creating/deleting collections (#3241)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* feat: created collection auth handler/operations, added LimitCollectionCdOwnerAdmin to CurrentContentOrganization, refs AC-1125
* feat: create vault service collection extensions and register with base services, refs AC-1125
* feat: deprecated CurrentContext.CreateNewCollections, refs AC-1125
* feat: deprecate DeleteAnyCollection for single resource usages, refs AC-1125
* feat: move service registration to api, update references, refs AC-1125
* feat: add bulk delete authorization handler, refs AC-1125
* feat: always assign user and give manage access on create, refs AC-1125
* fix: updated CurrentContextOrganization type, refs AC-1125
* feat: combined existing collection authorization handlers/operations, refs AC-1125
* fix: OrganizationServiceTests -> CurrentContentOrganization typo, refs AC-1125
* fix: format, refs AC-1125
* fix: update collection controller tests, refs AC-1125
* fix: dotnet format, refs AC-1125
* feat: removed extra BulkAuthorizationHandler, refs AC-1125
* fix: dotnet format, refs AC-1125
* fix: change string to guid for org id, update bulk delete request model, refs AC-1125
* fix: remove delete many collection check, refs AC-1125
* fix: clean up collection auth handler, refs AC-1125
* fix: format fix for CollectionOperations, refs AC-1125
* fix: removed unnecessary owner check, add org null check to custom permission validation, refs AC-1125
* fix: remove unused methods in CurrentContext, refs AC-1125
* fix: removed obsolete test, fixed failling delete many test, refs AC-1125
* fix: CollectionAuthorizationHandlerTests fixes, refs AC-1125
* fix: OrganizationServiceTests fix broken test by mocking GetOrganization, refs AC-1125
* fix: CollectionAuthorizationHandler - remove unused repository, refs AC-1125
* feat: moved UserId null check to common method, refs AC-1125
* fix: updated auth handler tests to remove dependency on requirement for common code checks, refs AC-1125
* feat: updated conditionals/comments for create/delete methods within colleciton auth handler, refs AC-1125
* feat: added create/delete collection auth handler success methods, refs AC-1125
* fix: new up permissions to prevent excessive null checks, refs AC-1125
* fix: remove old reference to CreateNewCollections, refs AC-1125
* fix: typo within ViewAssignedCollections method, refs AC-1125
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
* refactor: remove organizationId from CollectionBulkDeleteRequestModel, refs AC-1649 (#3282)
* [AC-1174] Bulk Collection Management (#3229)
* [AC-1174] Update SelectionReadOnlyRequestModel to use Guid for Id property
* [AC-1174] Introduce initial bulk-access collection endpoint
* [AC-1174] Introduce BulkAddCollectionAccessCommand and validation logic/tests
* [AC-1174] Add CreateOrUpdateAccessMany method to CollectionRepository
* [AC-1174] Add event logs for bulk add collection access command
* [AC-1174] Add User_BumpAccountRevisionDateByCollectionIds and database migration script
* [AC-1174] Implement EF repository method
* [AC-1174] Improve null checks
* [AC-1174] Remove unnecessary BulkCollectionAccessRequestModel helpers
* [AC-1174] Add unit tests for new controller endpoint
* [AC-1174] Fix formatting
* [AC-1174] Remove comment
* [AC-1174] Remove redundant organizationId parameter
* [AC-1174] Ensure user and group Ids are distinct
* [AC-1174] Cleanup tests based on PR feedback
* [AC-1174] Formatting
* [AC-1174] Update CollectionGroup alias in the sproc
* [AC-1174] Add some additional comments to SQL sproc
* [AC-1174] Add comment explaining additional SaveChangesAsync call
---------
Co-authored-by: Thomas Rittson <trittson@bitwarden.com>
* [AC-1646] Rename LimitCollectionCdOwnerAdmin column (#3300)
* Rename LimitCollectionCdOwnerAdmin -> LimitCollectionCreationDeletion
* Rename and bump migration script
* [AC-1666] Removed EditAnyCollection from Create/Delete permission checks (#3301)
* fix: remove EditAnyCollection from Create/Delete permission check, refs AC-1666
* fix: updated comment, refs AC-1666
* [AC-1669] Bug - Remove obsolete assignUserId from CollectionService.SaveAsync(...) (#3312)
* fix: remove AssignUserId from CollectionService.SaveAsync, refs AC-1669
* fix: add manage access conditional before creating collection, refs AC-1669
* fix: move access logic for create/update, fix all tests, refs AC-1669
* fix: add CollectionAccessSelection fixture, update tests, update bad reqeuest message, refs AC-1669
* fix: format, refs AC-1669
* fix: update null params with specific arg.is null checks, refs Ac-1669
* fix: update attribute class name, refs AC-1669
* [AC-1713] [Flexible collections] Add feature flags to server (#3334)
* Add feature flags for FlexibleCollections and BulkCollectionAccess
* Flag new routes and behaviour
---------
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
* Add joint codeownership for auth handlers (#3346)
* [AC-1717] Update default values for LimitCollectionCreationDeletion (#3365)
* Change default value in organization create sproc to 1
* Drop old column name still present in some QA instances
* Set LimitCollectionCreationDeletion value in code based on feature flag
* Fix: add missing namespace after merging in master
* Fix: add missing namespace after merging in master
* [AC-1683] Fix DB migrations for new Manage permission (#3307)
* [AC-1683] Update migration script and introduce V2 procedures and types
* [AC-1683] Update repository calls to use new V2 procedures / types
* [AC-1684] Update bulk add collection migration script to use new V2 type
* [AC-1683] Undo Manage changes to more original procedures
* [AC-1683] Restore whitespace changes
* [AC-1683] Clarify comments regarding explicit column lists
* [AC-1683] Update migration script dates
* [AC-1683] Split the migration script for readability
* [AC-1683] Re-name SelectReadOnlyArray_V2 to CollectionAccessSelectionType
* [AC-1648] [Flexible Collections] Bump migration scripts before feature branch merge (#3371)
* Bump dates on sql migration scripts
* Bump date on ef migrations
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
Co-authored-by: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com>
Co-authored-by: Vincent Salucci <vincesalucci21@gmail.com>
Co-authored-by: Shane Melton <smelton@bitwarden.com>
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
2023-11-01 10:30:52 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("UserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("WebAuthnCredential", (string)null);
|
|
|
|
|
});
|
2023-06-13 00:48:17 +02:00
|
|
|
|
|
2024-06-06 19:25:13 +02:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Billing.Models.ProviderInvoiceItem", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("AssignedSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2024-07-05 16:12:03 +02:00
|
|
|
|
b.Property<Guid?>("ClientId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2024-06-06 19:25:13 +02:00
|
|
|
|
b.Property<string>("ClientName")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2024-07-02 16:08:34 +02:00
|
|
|
|
.HasMaxLength(50)
|
2024-06-06 19:25:13 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("Created")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("InvoiceId")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2024-07-02 16:08:34 +02:00
|
|
|
|
.HasMaxLength(50)
|
2024-06-06 19:25:13 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("InvoiceNumber")
|
2024-07-02 16:08:34 +02:00
|
|
|
|
.HasMaxLength(50)
|
2024-06-06 19:25:13 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PlanName")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2024-07-02 16:08:34 +02:00
|
|
|
|
.HasMaxLength(50)
|
2024-06-06 19:25:13 +02:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("ProviderId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<decimal>("Total")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("UsedSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ProviderId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ProviderInvoiceItem", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Billing.Models.ProviderPlan", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("AllocatedSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("PlanType")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("ProviderId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("PurchasedSeats")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("SeatMinimum")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ProviderId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("Id", "PlanType")
|
|
|
|
|
.IsUnique();
|
|
|
|
|
|
|
|
|
|
b.ToTable("ProviderPlan", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2024-07-03 18:48:23 +02:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Cache", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<string>("Id")
|
|
|
|
|
.HasMaxLength(449)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("AbsoluteExpiration")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("ExpiresAtTime")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<long?>("SlidingExpirationInSeconds")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<byte[]>("Value")
|
|
|
|
|
.HasColumnType("BLOB");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ExpiresAtTime")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.ToTable("Cache", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Collection", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-06-13 00:48:17 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ExternalId")
|
|
|
|
|
.HasMaxLength(300)
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Collection", (string)null);
|
|
|
|
|
});
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionCipher", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("CollectionId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("CipherId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("CollectionId", "CipherId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("CipherId");
|
2023-07-26 21:55:28 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("CollectionCipher", (string)null);
|
|
|
|
|
});
|
2023-04-14 12:13:16 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionGroup", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("CollectionId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-06-13 00:48:17 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("GroupId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-06-13 00:48:17 +02:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("HidePasswords")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Manage")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("ReadOnly")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("CollectionId", "GroupId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("GroupId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("CollectionGroups");
|
|
|
|
|
});
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("CollectionId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationUserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("HidePasswords")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Manage")
|
2023-06-13 00:48:17 +02:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("ReadOnly")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("CollectionId", "OrganizationUserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationUserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("CollectionUsers");
|
|
|
|
|
});
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Device", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedPrivateKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedPublicKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("EncryptedUserKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Identifier")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Name")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(50)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("PushToken")
|
|
|
|
|
.HasMaxLength(255)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("Identifier")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "Identifier")
|
|
|
|
|
.IsUnique()
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Device", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Event", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ActingUserId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("CipherId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("CollectionId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("Date")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte?>("DeviceType")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("DomainName")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("GroupId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("InstallationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("IpAddress")
|
|
|
|
|
.HasMaxLength(50)
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("OrganizationUserId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("PolicyId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-03-02 14:50:27 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ProviderId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ProviderOrganizationId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ProviderUserId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("SecretId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("ServiceAccountId")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte?>("SystemUser")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-03-02 14:50:27 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2023-03-02 14:50:27 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("Date", "OrganizationId", "ActingUserId", "CipherId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("Event", (string)null);
|
2023-03-02 14:50:27 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Group", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("AccessAll")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ExternalId")
|
|
|
|
|
.HasMaxLength(300)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Name")
|
2024-07-05 03:14:37 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(100)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Group", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.GroupUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("GroupId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationUserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("GroupId", "OrganizationUserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationUserId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("GroupUser", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Installation", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Email")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<string>("Key")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(150)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Installation", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationApiKey", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ApiKey")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(30)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("OrganizationApiKey", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationConnection", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Config")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Enabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("OrganizationConnection", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationDomain", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("DomainName")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(255)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<int>("JobRunCount")
|
|
|
|
|
.HasColumnType("INTEGER");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("LastCheckedDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime>("NextRunDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("Txt")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("VerifiedDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("OrganizationDomain", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationSponsorship", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("FriendlyName")
|
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<DateTime?>("LastSyncDate")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("OfferedToEmail")
|
|
|
|
|
.HasMaxLength(256)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<byte?>("PlanSponsorshipType")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("SponsoredOrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid?>("SponsoringOrganizationId")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("SponsoringOrganizationUserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("ToDelete")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("ValidUntil")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("SponsoredOrganizationId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasIndex("SponsoringOrganizationId");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("SponsoringOrganizationUserId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("OrganizationSponsorship", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<bool>("AccessAll")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("AccessSecretsManager")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Email")
|
2023-12-13 16:03:42 +01:00
|
|
|
|
.HasMaxLength(256)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ExternalId")
|
|
|
|
|
.HasMaxLength(300)
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<string>("Permissions")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<string>("ResetPasswordKey")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.Property<short>("Status")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("UserId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "OrganizationId", "Status")
|
|
|
|
|
.HasAnnotation("Npgsql:IndexInclude", new[] { "AccessAll" })
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.ToTable("OrganizationUser", (string)null);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Send", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("AccessCount")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2024-03-05 01:31:33 +01:00
|
|
|
|
b.Property<Guid?>("CipherId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Data")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("DeletionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Disabled")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("ExpirationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool?>("HideEmail")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("MaxAccessCount")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Password")
|
|
|
|
|
.HasMaxLength(300)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-09 16:46:45 +01:00
|
|
|
|
b.HasIndex("DeletionDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
2024-01-09 16:46:45 +01:00
|
|
|
|
b.HasIndex("UserId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
|
|
|
|
b.ToTable("Send", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.TaxRate", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<string>("Id")
|
|
|
|
|
.HasMaxLength(40)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Active")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Country")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PostalCode")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(10)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<decimal>("Rate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("State")
|
|
|
|
|
.HasMaxLength(2)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("TaxRate", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Transaction", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<decimal>("Amount")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Details")
|
|
|
|
|
.HasMaxLength(100)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte?>("Gateway")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("GatewayId")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte?>("PaymentMethodType")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
b.Property<Guid?>("ProviderId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<bool?>("Refunded")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<decimal?>("RefundedAmount")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
b.HasIndex("ProviderId");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("UserId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "OrganizationId", "CreationDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
2022-12-14 15:28:51 +01:00
|
|
|
|
|
|
|
|
|
b.ToTable("Transaction", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.User", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("AccountRevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ApiKey")
|
|
|
|
|
.IsRequired()
|
|
|
|
|
.HasMaxLength(30)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-01-10 13:50:34 +01:00
|
|
|
|
b.Property<string>("AvatarColor")
|
|
|
|
|
.HasMaxLength(7)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Culture")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasMaxLength(10)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Email")
|
|
|
|
|
.IsRequired()
|
|
|
|
|
.HasMaxLength(256)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("EmailVerified")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("EquivalentDomains")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ExcludedGlobalEquivalentDomains")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("FailedLoginCount")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("ForcePasswordReset")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<byte?>("Gateway")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("GatewayCustomerId")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("GatewaySubscriptionId")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Kdf")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("KdfIterations")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2023-01-25 13:56:54 +01:00
|
|
|
|
b.Property<int?>("KdfMemory")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("KdfParallelism")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-02-02 20:39:57 +01:00
|
|
|
|
b.Property<DateTime?>("LastEmailChangeDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<DateTime?>("LastFailedLoginDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-02-02 20:39:57 +01:00
|
|
|
|
b.Property<DateTime?>("LastKdfChangeDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("LastKeyRotationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("LastPasswordChangeDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Property<string>("LicenseKey")
|
|
|
|
|
.HasMaxLength(100)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("MasterPassword")
|
|
|
|
|
.HasMaxLength(300)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("MasterPasswordHint")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<short?>("MaxStorageGb")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Premium")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("PremiumExpirationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PrivateKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PublicKey")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ReferenceData")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("RenewalReminderDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("SecurityStamp")
|
|
|
|
|
.IsRequired()
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<long?>("Storage")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("TwoFactorProviders")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("TwoFactorRecoveryCode")
|
|
|
|
|
.HasMaxLength(32)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("UsesKeyConnector")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2024-01-10 19:03:16 +01:00
|
|
|
|
b.HasIndex("Email")
|
|
|
|
|
.IsUnique()
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("Premium", "PremiumExpirationDate", "RenewalReminderDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.ToTable("User", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Discriminator")
|
|
|
|
|
.IsRequired()
|
2024-07-02 16:08:34 +02:00
|
|
|
|
.HasMaxLength(34)
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Read")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("Write")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.ToTable("AccessPolicy", (string)null);
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator<string>("Discriminator").HasValue("AccessPolicy");
|
2023-07-26 21:55:28 +02:00
|
|
|
|
|
|
|
|
|
b.UseTphMappingStrategy();
|
2023-02-01 19:27:13 +01:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ApiKey", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
2023-06-21 20:16:06 +02:00
|
|
|
|
b.Property<string>("ClientSecretHash")
|
|
|
|
|
.HasMaxLength(128)
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("EncryptedPayload")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasMaxLength(4000)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("ExpireAt")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Key")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasMaxLength(200)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Scope")
|
2024-07-03 22:21:25 +02:00
|
|
|
|
.IsRequired()
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.HasMaxLength(4000)
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("ServiceAccountId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ServiceAccountId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.ToTable("ApiKey", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("DeletedDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("DeletedDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.ToTable("Project", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("DeletedDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Note")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Value")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("DeletedDate")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.ToTable("Secret", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", true);
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId")
|
|
|
|
|
.HasAnnotation("SqlServer:Clustered", false);
|
|
|
|
|
|
|
|
|
|
b.ToTable("ServiceAccount", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2023-03-23 14:08:49 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Vault.Models.Cipher", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Attachments")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Data")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("DeletedDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Favorites")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Folders")
|
|
|
|
|
.HasColumnType("TEXT");
|
[AC-1122] Add AllowAdminAccessToAllCollectionItems setting to Organizations (#3379)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* fix: merge conflict resolution
* [AC-1174] CollectionUser and CollectionGroup authorization handlers (#3194)
* [AC-1174] Introduce BulkAuthorizationHandler.cs
* [AC-1174] Introduce CollectionUserAuthorizationHandler
* [AC-1174] Add CreateForNewCollection CollectionUser requirement
* [AC-1174] Add some more details to CollectionCustomization
* [AC-1174] Formatting
* [AC-1174] Add CollectionGroupOperation.cs
* [AC-1174] Introduce CollectionGroupAuthorizationHandler.cs
* [AC-1174] Cleanup CollectionFixture customization
Implement and use re-usable extension method to support seeded Guids
* [AC-1174] Introduce WithValueFromList AutoFixtureExtensions
Modify CollectionCustomization to use multiple organization Ids for auto generated test data
* [AC-1174] Simplify CollectionUserAuthorizationHandler.cs
Modify the authorization handler to only perform authorization logic. Validation logic will need to be handled by any calling commands/controllers instead.
* [AC-1174] Introduce shared CollectionAccessAuthorizationHandlerBase
A shared base authorization handler was created for both CollectionUser and CollectionGroup resources, as they share the same underlying management authorization logic.
* [AC-1174] Update CollectionUserAuthorizationHandler and CollectionGroupAuthorizationHandler to use the new CollectionAccessAuthorizationHandlerBase class
* [AC-1174] Formatting
* [AC-1174] Cleanup typo and redundant ToList() call
* [AC-1174] Add check for provider users
* [AC-1174] Reduce nested loops
* [AC-1174] Introduce ICollectionAccess.cs
* [AC-1174] Remove individual CollectionGroup and CollectionUser auth handlers and use base class instead
* [AC-1174] Tweak unit test to fail minimally
* [AC-1174] Reorganize authorization handlers in Core project
* [AC-1174] Introduce new AddCoreAuthorizationHandlers() extension method
* [AC-1174] Move CollectionAccessAuthorizationHandler into Api project
* [AC-1174] Move CollectionFixture to Vault folder
* [AC-1174] Rename operation to CreateUpdateDelete
* [AC-1174] Require single organization for collection access authorization handler
- Add requirement that all target collections must belong to the same organization
- Simplify logic related to multiple organizations
- Update tests and helpers
- Use ToHashSet to improve lookup time
* [AC-1174] Fix null reference exception
* [AC-1174] Throw bad request exception when collections belong to different organizations
* [AC-1174] Switch to CollectionAuthorizationHandler instead of CollectionAccessAuthorizationHandler to reduce complexity
* Fix improper merge conflict resolution
* fix: add permission check for collection management api, refs AC-1647 (#3252)
* [AC-1125] Enforce org setting for creating/deleting collections (#3241)
* [AC-1117] Add manage permission (#3126)
* Update sql files to add Manage permission
* Add migration script
* Rename collection manage migration file to remove duplicate migration date
* Migrations
* Add manage to models
* Add manage to repository
* Add constraint to Manage columns
* Migration lint fixes
* Add manage to OrganizationUserUserDetails_ReadWithCollectionsById
* Add missing manage fields
* Add 'Manage' to UserCollectionDetails
* Use CREATE OR ALTER where possible
* [AC-1374] Limit collection creation/deletion to Owner/Admin (#3145)
* feat: update org table with new column, write migration, refs AC-1374
* feat: update views with new column, refs AC-1374
* feat: Alter sprocs (org create/update) to include new column, refs AC-1374
* feat: update entity/data/request/response models to handle new column, refs AC-1374
* feat: update necessary Provider related views during migration, refs AC-1374
* fix: update org create to default new column to false, refs AC-1374
* feat: added new API/request model for collection management and removed property from update request model, refs AC-1374
* fix: renamed migration script to be after secrets manage beta column changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: add ef migrations to reflect mssql changes, refs AC-1374
* fix: dotnet format, refs AC-1374
* feat: update API signature to accept Guid and explain Cd verbiage, refs AC-1374
* feat: created collection auth handler/operations, added LimitCollectionCdOwnerAdmin to CurrentContentOrganization, refs AC-1125
* feat: create vault service collection extensions and register with base services, refs AC-1125
* feat: deprecated CurrentContext.CreateNewCollections, refs AC-1125
* feat: deprecate DeleteAnyCollection for single resource usages, refs AC-1125
* feat: move service registration to api, update references, refs AC-1125
* feat: add bulk delete authorization handler, refs AC-1125
* feat: always assign user and give manage access on create, refs AC-1125
* fix: updated CurrentContextOrganization type, refs AC-1125
* feat: combined existing collection authorization handlers/operations, refs AC-1125
* fix: OrganizationServiceTests -> CurrentContentOrganization typo, refs AC-1125
* fix: format, refs AC-1125
* fix: update collection controller tests, refs AC-1125
* fix: dotnet format, refs AC-1125
* feat: removed extra BulkAuthorizationHandler, refs AC-1125
* fix: dotnet format, refs AC-1125
* fix: change string to guid for org id, update bulk delete request model, refs AC-1125
* fix: remove delete many collection check, refs AC-1125
* fix: clean up collection auth handler, refs AC-1125
* fix: format fix for CollectionOperations, refs AC-1125
* fix: removed unnecessary owner check, add org null check to custom permission validation, refs AC-1125
* fix: remove unused methods in CurrentContext, refs AC-1125
* fix: removed obsolete test, fixed failling delete many test, refs AC-1125
* fix: CollectionAuthorizationHandlerTests fixes, refs AC-1125
* fix: OrganizationServiceTests fix broken test by mocking GetOrganization, refs AC-1125
* fix: CollectionAuthorizationHandler - remove unused repository, refs AC-1125
* feat: moved UserId null check to common method, refs AC-1125
* fix: updated auth handler tests to remove dependency on requirement for common code checks, refs AC-1125
* feat: updated conditionals/comments for create/delete methods within colleciton auth handler, refs AC-1125
* feat: added create/delete collection auth handler success methods, refs AC-1125
* fix: new up permissions to prevent excessive null checks, refs AC-1125
* fix: remove old reference to CreateNewCollections, refs AC-1125
* fix: typo within ViewAssignedCollections method, refs AC-1125
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
* refactor: remove organizationId from CollectionBulkDeleteRequestModel, refs AC-1649 (#3282)
* [AC-1174] Bulk Collection Management (#3229)
* [AC-1174] Update SelectionReadOnlyRequestModel to use Guid for Id property
* [AC-1174] Introduce initial bulk-access collection endpoint
* [AC-1174] Introduce BulkAddCollectionAccessCommand and validation logic/tests
* [AC-1174] Add CreateOrUpdateAccessMany method to CollectionRepository
* [AC-1174] Add event logs for bulk add collection access command
* [AC-1174] Add User_BumpAccountRevisionDateByCollectionIds and database migration script
* [AC-1174] Implement EF repository method
* [AC-1174] Improve null checks
* [AC-1174] Remove unnecessary BulkCollectionAccessRequestModel helpers
* [AC-1174] Add unit tests for new controller endpoint
* [AC-1174] Fix formatting
* [AC-1174] Remove comment
* [AC-1174] Remove redundant organizationId parameter
* [AC-1174] Ensure user and group Ids are distinct
* [AC-1174] Cleanup tests based on PR feedback
* [AC-1174] Formatting
* [AC-1174] Update CollectionGroup alias in the sproc
* [AC-1174] Add some additional comments to SQL sproc
* [AC-1174] Add comment explaining additional SaveChangesAsync call
---------
Co-authored-by: Thomas Rittson <trittson@bitwarden.com>
* [AC-1646] Rename LimitCollectionCdOwnerAdmin column (#3300)
* Rename LimitCollectionCdOwnerAdmin -> LimitCollectionCreationDeletion
* Rename and bump migration script
* [AC-1666] Removed EditAnyCollection from Create/Delete permission checks (#3301)
* fix: remove EditAnyCollection from Create/Delete permission check, refs AC-1666
* fix: updated comment, refs AC-1666
* [AC-1669] Bug - Remove obsolete assignUserId from CollectionService.SaveAsync(...) (#3312)
* fix: remove AssignUserId from CollectionService.SaveAsync, refs AC-1669
* fix: add manage access conditional before creating collection, refs AC-1669
* fix: move access logic for create/update, fix all tests, refs AC-1669
* fix: add CollectionAccessSelection fixture, update tests, update bad reqeuest message, refs AC-1669
* fix: format, refs AC-1669
* fix: update null params with specific arg.is null checks, refs Ac-1669
* fix: update attribute class name, refs AC-1669
* [AC-1713] [Flexible collections] Add feature flags to server (#3334)
* Add feature flags for FlexibleCollections and BulkCollectionAccess
* Flag new routes and behaviour
---------
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
* Add joint codeownership for auth handlers (#3346)
* [AC-1717] Update default values for LimitCollectionCreationDeletion (#3365)
* Change default value in organization create sproc to 1
* Drop old column name still present in some QA instances
* Set LimitCollectionCreationDeletion value in code based on feature flag
* Fix: add missing namespace after merging in master
* Fix: add missing namespace after merging in master
* [AC-1683] Fix DB migrations for new Manage permission (#3307)
* [AC-1683] Update migration script and introduce V2 procedures and types
* [AC-1683] Update repository calls to use new V2 procedures / types
* [AC-1684] Update bulk add collection migration script to use new V2 type
* [AC-1683] Undo Manage changes to more original procedures
* [AC-1683] Restore whitespace changes
* [AC-1683] Clarify comments regarding explicit column lists
* [AC-1683] Update migration script dates
* [AC-1683] Split the migration script for readability
* [AC-1683] Re-name SelectReadOnlyArray_V2 to CollectionAccessSelectionType
* [AC-1648] [Flexible Collections] Bump migration scripts before feature branch merge (#3371)
* Bump dates on sql migration scripts
* Bump date on ef migrations
* [AC-1727] Add AllowAdminAccessToAllCollectionItems column to Organization table
* [AC-1720] Update stored procedures and views that query the organization table and new column
* [AC-1727] Add EF migrations for new DB column
* [AC-1729] Update API request/response models
* [AC-1122] Add new setting to CurrentContextOrganization.cs
* [AC-1122] Ensure new setting is disabled for new orgs when the feature flag is enabled
* [AC-1122] Use V1 feature flag for new setting
* [AC-1122] Formatting
* [AC-1122] Update migration script date
---------
Co-authored-by: Robyn MacCallum <robyntmaccallum@gmail.com>
Co-authored-by: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com>
Co-authored-by: Vincent Salucci <vincesalucci21@gmail.com>
Co-authored-by: Thomas Rittson <trittson@bitwarden.com>
Co-authored-by: Thomas Rittson <31796059+eliykat@users.noreply.github.com>
Co-authored-by: Rui Tomé <108268980+r-tome@users.noreply.github.com>
2023-11-27 20:44:07 +01:00
|
|
|
|
|
2023-09-28 14:45:13 +02:00
|
|
|
|
b.Property<string>("Key")
|
|
|
|
|
.HasColumnType("TEXT");
|
2023-03-23 14:08:49 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte?>("Reprompt")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<byte>("Type")
|
|
|
|
|
.HasColumnType("INTEGER");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Cipher", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Vault.Models.Folder", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("CreationDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("RevisionDate")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Folder", (string)null);
|
|
|
|
|
});
|
|
|
|
|
|
2023-01-13 15:02:53 +01:00
|
|
|
|
modelBuilder.Entity("ProjectSecret", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("ProjectsId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("SecretsId")
|
|
|
|
|
.HasColumnType("TEXT");
|
|
|
|
|
|
|
|
|
|
b.HasKey("ProjectsId", "SecretsId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("SecretsId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ProjectSecret");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedProjectId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GroupId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("group_project");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedSecretId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GroupId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("group_secret");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupServiceAccountAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedServiceAccountId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GroupId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GroupId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("group_service_account");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccountProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedProjectId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("ServiceAccountId")
|
2024-02-22 17:06:39 +01:00
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("service_account_project");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccountSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedSecretId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("ServiceAccountId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("service_account_secret");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedProjectId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationUserId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedProjectId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("user_project");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedSecretId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationUserId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedSecretId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("user_secret");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserServiceAccountAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasBaseType("Bit.Infrastructure.EntityFramework.SecretsManager.Models.AccessPolicy");
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("GrantedServiceAccountId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid?>("OrganizationUserId")
|
|
|
|
|
.ValueGeneratedOnUpdateSometimes()
|
|
|
|
|
.HasColumnType("TEXT")
|
|
|
|
|
.HasColumnName("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.HasDiscriminator().HasValue("user_service_account");
|
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Policy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
|
|
|
|
.WithMany("Policies")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.ProviderOrganization", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", "Provider")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProviderId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Provider");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.ProviderUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", "Provider")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProviderId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("UserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Provider");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2023-05-01 15:32:06 +02:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.AuthRequest", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-06-15 23:54:08 +02:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Device", "ResponseDevice")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ResponseDeviceId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
2023-06-15 23:54:08 +02:00
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Navigation("ResponseDevice");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2023-05-01 15:32:06 +02:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.EmergencyAccess", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "Grantee")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("GranteeId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "Grantor")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("GrantorId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Grantee");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Grantor");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.SsoConfig", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.WithMany("SsoConfigs")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.SsoUser", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-05-01 15:32:06 +02:00
|
|
|
|
.WithMany("SsoUsers")
|
|
|
|
|
.HasForeignKey("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany("SsoUsers")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Auth.Models.WebAuthnCredential", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2024-06-06 19:25:13 +02:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Billing.Models.ProviderInvoiceItem", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", "Provider")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProviderId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Provider");
|
|
|
|
|
});
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Billing.Models.ProviderPlan", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", "Provider")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProviderId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Provider");
|
|
|
|
|
});
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Collection", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.WithMany("Collections")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionCipher", b =>
|
|
|
|
|
{
|
2023-03-23 14:08:49 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Vault.Models.Cipher", "Cipher")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("CollectionCiphers")
|
|
|
|
|
.HasForeignKey("CipherId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Collection", "Collection")
|
|
|
|
|
.WithMany("CollectionCiphers")
|
|
|
|
|
.HasForeignKey("CollectionId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Cipher");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Collection");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionGroup", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Collection", "Collection")
|
|
|
|
|
.WithMany("CollectionGroups")
|
|
|
|
|
.HasForeignKey("CollectionId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Group", "Group")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("GroupId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Collection");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Group");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.CollectionUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Collection", "Collection")
|
|
|
|
|
.WithMany("CollectionUsers")
|
|
|
|
|
.HasForeignKey("CollectionId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", "OrganizationUser")
|
|
|
|
|
.WithMany("CollectionUsers")
|
|
|
|
|
.HasForeignKey("OrganizationUserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Collection");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUser");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Device", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Group", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("Groups")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.GroupUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Group", "Group")
|
|
|
|
|
.WithMany("GroupUsers")
|
|
|
|
|
.HasForeignKey("GroupId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", "OrganizationUser")
|
2023-01-13 20:24:58 +01:00
|
|
|
|
.WithMany("GroupUsers")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.HasForeignKey("OrganizationUserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Group");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUser");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationApiKey", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("ApiKeys")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationConnection", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("Connections")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
2023-03-02 14:50:27 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationDomain", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-03-02 14:50:27 +01:00
|
|
|
|
.WithMany("Domains")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationSponsorship", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "SponsoredOrganization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("SponsoredOrganizationId");
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "SponsoringOrganization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("SponsoringOrganizationId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("SponsoredOrganization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("SponsoringOrganization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("OrganizationUsers")
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany("OrganizationUsers")
|
|
|
|
|
.HasForeignKey("UserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Send", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("UserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Transaction", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2022-12-14 15:28:51 +01:00
|
|
|
|
.WithMany("Transactions")
|
|
|
|
|
.HasForeignKey("OrganizationId");
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Provider.Provider", "Provider")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProviderId");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany("Transactions")
|
|
|
|
|
.HasForeignKey("UserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
2024-03-21 16:15:49 +01:00
|
|
|
|
b.Navigation("Provider");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ApiKey", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", "ServiceAccount")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("ServiceAccount");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-02-01 19:27:13 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
});
|
|
|
|
|
|
2023-03-23 14:08:49 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Vault.Models.Cipher", b =>
|
|
|
|
|
{
|
2023-12-13 16:03:42 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", "Organization")
|
2023-03-23 14:08:49 +01:00
|
|
|
|
.WithMany("Ciphers")
|
|
|
|
|
.HasForeignKey("OrganizationId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany("Ciphers")
|
|
|
|
|
.HasForeignKey("UserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organization");
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Vault.Models.Folder", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.User", "User")
|
|
|
|
|
.WithMany("Folders")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
});
|
|
|
|
|
|
2023-01-13 15:02:53 +01:00
|
|
|
|
modelBuilder.Entity("ProjectSecret", b =>
|
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", null)
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ProjectsId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", null)
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("SecretsId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", "GrantedProject")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany("GroupAccessPolicies")
|
2023-09-22 00:22:08 +02:00
|
|
|
|
.HasForeignKey("GrantedProjectId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Group", "Group")
|
|
|
|
|
.WithMany()
|
2023-09-22 00:22:08 +02:00
|
|
|
|
.HasForeignKey("GroupId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedProject");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Group");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", "GrantedSecret")
|
|
|
|
|
.WithMany("GroupAccessPolicies")
|
|
|
|
|
.HasForeignKey("GrantedSecretId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Group", "Group")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("GroupId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedSecret");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Group");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.GroupServiceAccountAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", "GrantedServiceAccount")
|
|
|
|
|
.WithMany("GroupAccessPolicies")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.HasForeignKey("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.Group", "Group")
|
|
|
|
|
.WithMany()
|
2023-09-22 00:22:08 +02:00
|
|
|
|
.HasForeignKey("GroupId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedServiceAccount");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Group");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccountProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", "GrantedProject")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany("ServiceAccountAccessPolicies")
|
2023-09-22 00:22:08 +02:00
|
|
|
|
.HasForeignKey("GrantedProjectId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", "ServiceAccount")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedProject");
|
|
|
|
|
|
|
|
|
|
b.Navigation("ServiceAccount");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccountSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", "GrantedSecret")
|
|
|
|
|
.WithMany("ServiceAccountAccessPolicies")
|
|
|
|
|
.HasForeignKey("GrantedSecretId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", "ServiceAccount")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("ServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedSecret");
|
|
|
|
|
|
|
|
|
|
b.Navigation("ServiceAccount");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserProjectAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", "GrantedProject")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.WithMany("UserAccessPolicies")
|
2023-09-22 00:22:08 +02:00
|
|
|
|
.HasForeignKey("GrantedProjectId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
2023-01-13 15:02:53 +01:00
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", "OrganizationUser")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedProject");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUser");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserSecretAccessPolicy", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", "GrantedSecret")
|
|
|
|
|
.WithMany("UserAccessPolicies")
|
|
|
|
|
.HasForeignKey("GrantedSecretId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", "OrganizationUser")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedSecret");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUser");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.UserServiceAccountAccessPolicy", b =>
|
2023-01-13 15:02:53 +01:00
|
|
|
|
{
|
2023-02-01 19:27:13 +01:00
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", "GrantedServiceAccount")
|
|
|
|
|
.WithMany("UserAccessPolicies")
|
2023-01-13 15:02:53 +01:00
|
|
|
|
.HasForeignKey("GrantedServiceAccountId");
|
|
|
|
|
|
|
|
|
|
b.HasOne("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", "OrganizationUser")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("OrganizationUserId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("GrantedServiceAccount");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUser");
|
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.AdminConsole.Models.Organization", b =>
|
2022-12-14 15:28:51 +01:00
|
|
|
|
{
|
|
|
|
|
b.Navigation("ApiKeys");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Ciphers");
|
|
|
|
|
|
2023-03-02 14:50:27 +01:00
|
|
|
|
b.Navigation("Collections");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Navigation("Connections");
|
|
|
|
|
|
2023-03-02 14:50:27 +01:00
|
|
|
|
b.Navigation("Domains");
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
b.Navigation("Groups");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUsers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Policies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("SsoConfigs");
|
|
|
|
|
|
|
|
|
|
b.Navigation("SsoUsers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Transactions");
|
|
|
|
|
});
|
|
|
|
|
|
2023-12-13 16:03:42 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Collection", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("CollectionCiphers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("CollectionGroups");
|
|
|
|
|
|
|
|
|
|
b.Navigation("CollectionUsers");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.Group", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("GroupUsers");
|
|
|
|
|
});
|
|
|
|
|
|
2022-12-14 15:28:51 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.OrganizationUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("CollectionUsers");
|
2023-01-13 20:24:58 +01:00
|
|
|
|
|
|
|
|
|
b.Navigation("GroupUsers");
|
2022-12-14 15:28:51 +01:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Models.User", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Ciphers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Folders");
|
|
|
|
|
|
|
|
|
|
b.Navigation("OrganizationUsers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("SsoUsers");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Transactions");
|
|
|
|
|
});
|
2023-02-01 19:27:13 +01:00
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Project", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("GroupAccessPolicies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("ServiceAccountAccessPolicies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("UserAccessPolicies");
|
|
|
|
|
});
|
|
|
|
|
|
2024-02-22 17:06:39 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.Secret", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("GroupAccessPolicies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("ServiceAccountAccessPolicies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("UserAccessPolicies");
|
|
|
|
|
});
|
|
|
|
|
|
2023-02-01 19:27:13 +01:00
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.SecretsManager.Models.ServiceAccount", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("GroupAccessPolicies");
|
|
|
|
|
|
|
|
|
|
b.Navigation("UserAccessPolicies");
|
|
|
|
|
});
|
2023-03-23 14:08:49 +01:00
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Bit.Infrastructure.EntityFramework.Vault.Models.Cipher", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("CollectionCiphers");
|
|
|
|
|
});
|
2022-12-14 15:28:51 +01:00
|
|
|
|
#pragma warning restore 612, 618
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|