we have a method that validates token and takes the user from Bearer token, but this method is not authorized, so how we retrieve the User data from string token
private static bool ValidateToken(string authToken)
{
var tokenHandler = new JwtSecurityTokenHandler();
var validationParameters = GetValidationParameters();
SecurityToken validatedToken;
IPrincipal principal = tokenHandler.ValidateToken(authToken, validationParameters, out validatedToken);
//Get ID from Token
var isValid = GetValidId(id)
return true;
}