Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// gerador de jws / jwe
var tokenHandler = new JsonWebTokenHandler();
// Criando chave assimetrica
var key = new RsaSecurityKey(RSA.Create(2048));
// criando o jwt
var jwt = new SecurityTokenDescriptor
Issuer = "",
Audience = "your-spa",
// Details hide
SigningCredentials = new SigningCredentials(key, SecurityAlgorithms.RsaSsaPssSha256) // <-- Algoritmo probabilistico
// assinando o jwt
string jws = tokenHandler.CreateToken(jwt);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.