mirror of
https://github.com/bitwarden/server.git
synced 2025-05-29 23:34:53 -05:00
connector client
This commit is contained in:
parent
76664c8427
commit
5a6e189e67
@ -12,7 +12,8 @@ namespace Bit.Core.IdentityServer
|
|||||||
new ApiClient("mobile", 90, 1),
|
new ApiClient("mobile", 90, 1),
|
||||||
new ApiClient("web", 1, 1),
|
new ApiClient("web", 1, 1),
|
||||||
new ApiClient("browser", 30, 1),
|
new ApiClient("browser", 30, 1),
|
||||||
new ApiClient("desktop", 30, 1)
|
new ApiClient("desktop", 30, 1),
|
||||||
|
new ApiClient("connector", 30, 24)
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -22,7 +23,7 @@ namespace Bit.Core.IdentityServer
|
|||||||
string id,
|
string id,
|
||||||
int refreshTokenSlidingDays,
|
int refreshTokenSlidingDays,
|
||||||
int accessTokenLifetimeHours,
|
int accessTokenLifetimeHours,
|
||||||
string[] additionalScopes = null)
|
string[] scopes = null)
|
||||||
{
|
{
|
||||||
ClientId = id;
|
ClientId = id;
|
||||||
RequireClientSecret = false;
|
RequireClientSecret = false;
|
||||||
@ -35,10 +36,9 @@ namespace Bit.Core.IdentityServer
|
|||||||
AccessTokenLifetime = 3600 * accessTokenLifetimeHours;
|
AccessTokenLifetime = 3600 * accessTokenLifetimeHours;
|
||||||
AllowOfflineAccess = true;
|
AllowOfflineAccess = true;
|
||||||
|
|
||||||
var scopes = new List<string> { "api" };
|
if(scopes == null)
|
||||||
if(additionalScopes != null)
|
|
||||||
{
|
{
|
||||||
scopes.AddRange(additionalScopes);
|
scopes = new string[] { "api" };
|
||||||
}
|
}
|
||||||
AllowedScopes = scopes;
|
AllowedScopes = scopes;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user