mirror of
https://github.com/bitwarden/server.git
synced 2025-06-30 07:36:14 -05:00
[SG-763] Store the fact that a Passwordless request was denied in the AuthRequest table (#2363)
* Added migrations for sqlserver and mysql * Added migrations for postgres * renamed mysql migration script to make naming uniform * introduced approved field to the update auth request controller;This change would keep track of denied passwordless requests * Recreated the authRequestView, introduced the approved field to the create procedure and updated the response model * Formatted code * fixed incorrect syntax in the AuthRequest_Create.sql SP
This commit is contained in:
1675
util/MySqlMigrations/Migrations/20221024210500_PasswordlessAuthRequestAddApprovedColumn.Designer.cs
generated
Normal file
1675
util/MySqlMigrations/Migrations/20221024210500_PasswordlessAuthRequestAddApprovedColumn.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,24 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Bit.MySqlMigrations.Migrations;
|
||||
|
||||
public partial class PasswordlessAuthRequestAddApprovedColumn : Migration
|
||||
{
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "Approved",
|
||||
table: "AuthRequest",
|
||||
type: "tinyint(1)",
|
||||
nullable: true);
|
||||
}
|
||||
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Approved",
|
||||
table: "AuthRequest");
|
||||
}
|
||||
}
|
@ -28,6 +28,9 @@ namespace Bit.MySqlMigrations.Migrations
|
||||
.HasMaxLength(25)
|
||||
.HasColumnType("varchar(25)");
|
||||
|
||||
b.Property<bool?>("Approved")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<DateTime?>("AuthenticationDate")
|
||||
.HasColumnType("datetime(6)");
|
||||
|
||||
|
Reference in New Issue
Block a user