JsonWebTokenHandler.DecryptToken Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Decrypts a JWE and returns the clear text
public string DecryptToken (Microsoft.IdentityModel.JsonWebTokens.JsonWebToken jwtToken, Microsoft.IdentityModel.Tokens.TokenValidationParameters validationParameters);
member this.DecryptToken : Microsoft.IdentityModel.JsonWebTokens.JsonWebToken * Microsoft.IdentityModel.Tokens.TokenValidationParameters -> string
Public Function DecryptToken (jwtToken As JsonWebToken, validationParameters As TokenValidationParameters) As String
Parameters
- jwtToken
- JsonWebToken
the JWE that contains the cypher text.
- validationParameters
- TokenValidationParameters
contains crypto material.
Returns
the decoded / cleartext contents of the JWE.
Exceptions
if validationParameters
is null.
if 'jwtToken
.Enc' is null or empty.
if decompression failed.
if 'jwtToken
.Kid' is not null AND decryption fails.
if the JWE was not able to be decrypted.
Applies to
Váš názor
https://aka.ms/ContentUserFeedback.
Připravujeme: V průběhu roku 2024 budeme postupně vyřazovat problémy z GitHub coby mechanismus zpětné vazby pro obsah a nahrazovat ho novým systémem zpětné vazby. Další informace naleznete v tématu:Odeslat a zobrazit názory pro