mirror of
https://github.com/bitwarden/server.git
synced 2025-04-17 19:18:16 -05:00
Set user API key on account creation through SSO auto provision (#1003)
This commit is contained in:
parent
028ad46c47
commit
2e6368d11a
@ -21,6 +21,7 @@ using System.Linq;
|
|||||||
using System.Security.Claims;
|
using System.Security.Claims;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Bit.Core.Models.Api;
|
using Bit.Core.Models.Api;
|
||||||
|
using Bit.Core.Utilities;
|
||||||
|
|
||||||
namespace Bit.Sso.Controllers
|
namespace Bit.Sso.Controllers
|
||||||
{
|
{
|
||||||
@ -453,7 +454,8 @@ namespace Bit.Sso.Controllers
|
|||||||
user = new User
|
user = new User
|
||||||
{
|
{
|
||||||
Name = name,
|
Name = name,
|
||||||
Email = email
|
Email = email,
|
||||||
|
ApiKey = CoreHelpers.SecureRandomString(30)
|
||||||
};
|
};
|
||||||
await _userService.RegisterUserAsync(user);
|
await _userService.RegisterUserAsync(user);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user