source: FarmatikoServices/Infrastructure/IJwtAuthManager.cs@ 8e74e2f

Last change on this file since 8e74e2f was d23bf72, checked in by DimitarSlezenkovski <dslezenkovski@…>, 4 years ago

Add SystemService, Auth, fix a lil bugs :)

  • Property mode set to 100644
File size: 676 bytes
Line 
1using System;
2using System.Collections.Immutable;
3using System.IdentityModel.Tokens.Jwt;
4using System.Security.Claims;
5
6namespace FarmatikoServices.Infrastructure
7{
8 public interface IJwtAuthManager
9 {
10 IImmutableDictionary<string, RefreshToken> UsersRefreshTokensReadOnlyDictionary { get; }
11 JwtAuthResult GenerateTokens(string username, Claim[] claims, DateTime now);
12 JwtAuthResult Refresh(string refreshToken, string accessToken, DateTime now);
13 void RemoveExpiredRefreshTokens(DateTime now);
14 void RemoveRefreshTokenByUserName(string userName);
15 (ClaimsPrincipal, JwtSecurityToken) DecodeJwtToken(string token);
16 }
17}
Note: See TracBrowser for help on using the repository browser.