1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-06 02:22:49 -05:00

[Reset Password] Enrollment API, Service, and Model updates (#1245)

* [Reset Password] Enrollment API, Service and Model updates

* Added conditional check for calling User's ID
This commit is contained in:
Vincent Salucci
2021-03-30 09:48:52 -05:00
committed by GitHub
parent 339292f536
commit 296e3d881d
9 changed files with 40 additions and 0 deletions

View File

@ -84,4 +84,9 @@ namespace Bit.Core.Models.Api
[Required]
public IEnumerable<string> GroupIds { get; set; }
}
public class OrganizationUserResetPasswordEnrollmentRequestModel
{
public string ResetPasswordKey { get; set; }
}
}

View File

@ -30,6 +30,8 @@ namespace Bit.Core.Models.Api
SsoBound = !string.IsNullOrWhiteSpace(organization.SsoExternalId);
Identifier = organization.Identifier;
Permissions = CoreHelpers.LoadClassFromJsonData<Permissions>(organization.Permissions);
ResetPasswordKey = organization.ResetPasswordKey;
UserId = organization.UserId?.ToString();
}
public string Id { get; set; }
@ -55,5 +57,7 @@ namespace Bit.Core.Models.Api
public bool SsoBound { get; set; }
public string Identifier { get; set; }
public Permissions Permissions { get; set; }
public string ResetPasswordKey { get; set; }
public string UserId { get; set; }
}
}