Skip to content

Commit

Permalink
fix: Use fixed value of aud field in JWT claim (#896)
Browse files Browse the repository at this point in the history
Closes: SDK-3020
  • Loading branch information
lukaszsocha2 authored Mar 13, 2023
1 parent d789081 commit 8c9982d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Box.V2/JWTAuth/BoxJWTAuth.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ public BoxJWTAuth(IBoxConfig boxConfig, IBoxService boxService)
/// <param name="boxConfig">Config contains information about client id, client secret, enterprise id, private key, private key password, public key id </param>
/// <param name="boxService">Box service is used to perform GetToken requests</param>
/// <param name="retryStrategy">Retry strategy used when retrying http request</param>
///
///
public BoxJWTAuth(IBoxConfig boxConfig, IBoxService boxService, IRetryStrategy retryStrategy) : this(boxConfig, boxService)
{
_retryStrategy = retryStrategy;
Expand Down Expand Up @@ -265,7 +265,7 @@ private string ConstructJWTAssertion(string sub, string boxSubType, DateTimeOffs
expireTime = nowOverride.Value.AddSeconds(30);
}

var payload = new JwtPayload(_boxConfig.ClientId, new Uri(_boxConfig.BoxApiHostUri, Constants.AuthTokenEndpointString).ToString(),
var payload = new JwtPayload(_boxConfig.ClientId, new Uri(Constants.BoxAuthTokenApiUriString).ToString(),
claims, null, expireTime.LocalDateTime);

var header = new JwtHeader(signingCredentials: _credentials);
Expand Down

0 comments on commit 8c9982d

Please sign in to comment.