Location: Symbol Reference > Classes > TJwSecurityToken Class > TJwSecurityToken Methods > TJwSecurityToken.GetTokenInformation Method
JWSCL Documentation
ContentsIndexHome
PreviousUpNext
TJwSecurityToken.GetTokenInformation Method
Pascal
procedure GetTokenInformation(hTokenHandle: TJwTokenHandle; TokenInformationClass: TTokenInformationClass; out TokenInformation: Pointer); virtual;
Parameters 
Description 
hTokenHandle: TJwTokenHandle 
receives the token handle  
out TokenInformation: Pointer 
contains the requested information. You must convert the type to the appropiate token type information class. 
aTokenInformationClass 
receives token class. Legend : o defines already implemented structures.
  • TokenDefaultDacl The buffer receives a TOKEN_DEFAULT_DACL structure containing the default DACL for newly created objects.
  • o TokenGroups The buffer receives a TOKEN_GROUPS structure containing the group accounts associated with the token.
  • TokenGroupsAndPrivileges The buffer receives a TOKEN_GROUPS_AND_PRIVILEGES structure containing the user SID, the group accounts, the restricted SIDs, and the authentication ID associated with the token.
  • o TokenImpersonationLevel The buffer receives a SECURITY_IMPERSONATION_LEVEL value indicating the impersonation level of the token. If the access token is not an impersonation token, the function fails.
  • o TokenOrigin The buffer receives a TOKEN_ORIGIN value that contains information about the logon session ID.
  • o TokenOwner The buffer receives a TOKEN_OWNER structure containing the default owner SID for newly created objects.
  • o TokenPrimaryGroup The buffer receives a TOKEN_PRIMARY_GROUP structure containing the default primary group SID for newly created objects.
  • o TokenPrivileges The buffer receives a TOKEN_PRIVILEGES structure containing the token's privileges.
  • o TokenRestrictedSids The buffer receives a TOKEN_GROUPS structure containing the list of restricting SIDs in a restricted token.
  • TokenSandBoxInert The buffer receives a DWORD value that is nonzero if the token includes the SANDBOX_INERT flag.
  • o TokenSessionId The buffer receives a DWORD value that contains the Terminal Services session identifier associated with the token. If the token is associated with the Terminal Server console session, the session identifier is zero. A nonzero session identifier indicates a Terminal Services client session. In a non-Terminal Services environment, the session identifier is zero.
  • o TokenSource The buffer receives a TOKEN_SOURCE structure containing the source of the token. TOKEN_QUERY_SOURCE access is needed to retrieve this information.
  • TokenStatistics The buffer receives a TOKEN_STATISTICS structure containing various token statistics.
  • o TokenType The buffer receives a TOKEN_TYPE value indicating whether the token is a primary or impersonation token.
  • o TokenUser The buffer receives a TOKEN_USER structure containing the token's user account.

 

GetTokenInformation returns a buffer filled with token information.

Exceptions 
Description 
is raised if a call to GetTokenInformation failed. 
is raised if the given token access rights is not enough to do the necessary work. In this case the token instance must be reopened with sufficient rights. 
is raised if the token handle is invalid. Not opened or closed already. 
is raised if a call to HeapAlloc failed because of not enough space. 
Copyright (c) 2010. All rights reserved.
This help was created by Doc-O-Matic sponsored by toolsfactory software inc.
What do you think about this topic? Send feedback!