コード例 #1
0
        private async Task <string> GetNewAccessTokenAsync()
        {
            var refreshTokenString = await _localStorage.GetRefreshTokenAsync();

            var refreshToken = new JwtSecurityToken(refreshTokenString);

            if (VerifyTokenLifetime(refreshToken))
            {
                var query = new GetAccessTokenQuery
                {
                    JwtRefreshToken = refreshTokenString,
                    Thumbprint      = "12345"
                };

                return(await _mediator.Send(query));
            }

            return(null);
        }