SecurityTokenService.GetTokenLifetime(Lifetime) 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.
Gets the lifetime for the issued token.
protected:
virtual System::IdentityModel::Protocols::WSTrust::Lifetime ^ GetTokenLifetime(System::IdentityModel::Protocols::WSTrust::Lifetime ^ requestLifetime);
protected virtual System.IdentityModel.Protocols.WSTrust.Lifetime GetTokenLifetime (System.IdentityModel.Protocols.WSTrust.Lifetime requestLifetime);
abstract member GetTokenLifetime : System.IdentityModel.Protocols.WSTrust.Lifetime -> System.IdentityModel.Protocols.WSTrust.Lifetime
override this.GetTokenLifetime : System.IdentityModel.Protocols.WSTrust.Lifetime -> System.IdentityModel.Protocols.WSTrust.Lifetime
Protected Overridable Function GetTokenLifetime (requestLifetime As Lifetime) As Lifetime
Parameters
Returns
A Lifetime that represents the granted lifetime.
Remarks
This method is normally called with the lifetime that arrived in the RST. In the default implementation, the token lifetime is calculated according to the following table.
Created (in) | Expires (in) | Created (in) | Expires (out) |
---|---|---|---|
null |
null |
DateTime.UtcNow | DateTime.UtcNow + SecurityTokenServiceConfiguration.DefaultTokenLifetime |
C | null |
C | C + SecurityTokenServiceConfiguration.DefaultTokenLifetime |
null |
E | DateTime.UtcNow | E |
C | E | C | E |
This method is called from the default token issuance pipeline implemented in the Issue method.
Applies to
See also
Σχόλια
https://aka.ms/ContentUserFeedback.
Σύντομα διαθέσιμα: Καθ' όλη τη διάρκεια του 2024 θα καταργήσουμε σταδιακά τα ζητήματα GitHub ως μηχανισμό ανάδρασης για το περιεχόμενο και θα το αντικαταστήσουμε με ένα νέο σύστημα ανάδρασης. Για περισσότερες πληροφορίες, ανατρέξτε στο θέμα:Υποβολή και προβολή σχολίων για