다음을 통해 공유


SetAuthTicket Method (String, Boolean, Int32)

Sets an encrypted MSCSAuth ticket for a registered user with the authorization time set to the specified time window.

Namespace:  Microsoft.CommerceServer.Runtime
Assembly:  Microsoft.CommerceServer.Runtime (in Microsoft.CommerceServer.Runtime.dll)

Syntax

'Declaration
Public Sub SetAuthTicket ( _
    userID As String, _
    cookieSupport As Boolean, _
    timeWindow As Integer _
)
'Usage
Dim instance As AuthManager
Dim userID As String
Dim cookieSupport As Boolean
Dim timeWindow As Integer

instance.SetAuthTicket(userID, cookieSupport, _
    timeWindow)
public void SetAuthTicket(
    string userID,
    bool cookieSupport,
    int timeWindow
)
public:
void SetAuthTicket(
    String^ userID, 
    bool cookieSupport, 
    int timeWindow
)
public function SetAuthTicket(
    userID : String, 
    cookieSupport : boolean, 
    timeWindow : int
)

Parameters

  • userID
    Type: System..::.String
    The user identifier. This parameter should be set to an empty string when the user logs off.
  • cookieSupport
    Type: System..::.Boolean
    A value indicating whether the client supports cookies. true if the user supports cookies; otherwise, false.

Exceptions

Exception Condition
CommerceAuthenticationException

The ticket could not be set.

Remarks

Use this method to set an encrypted MSCSAuth ticket for a registered user with the specified time window.

Permissions

See Also

Reference

AuthManager Class

AuthManager Members

SetAuthTicket Overload

Microsoft.CommerceServer.Runtime Namespace