.NET Based OPC UA Client/Server SDK  3.3.3.537
UnifiedAutomation.UaServer.SessionManager Class Reference

A generic session manager object for a server. More...

Inherits UnifiedAutomation.UaServer.ISessionManager, and IDisposable.

Public Member Functions

 SessionManager (ServerManager server, SessionLimits limits)
 Initializes the manager with its configuration. More...
 
void Dispose ()
 Frees any unmanaged resources. More...
 
virtual void Startup ()
 Starts the session manager. More...
 
virtual void Shutdown ()
 Stops the session manager and closes all sessions. More...
 
virtual Session CreateSession (RequestContext context, ICertificate serverCertificate, string sessionName, byte[] clientNonce, ApplicationDescription clientDescription, string endpointUrl, ICertificate clientCertificate, double requestedSessionTimeout, uint maxResponseMessageSize, out NodeId sessionId, out NodeId authenticationToken, out byte[] serverNonce, out double revisedSessionTimeout)
 Creates a new session. More...
 
virtual bool ActivateSession (RequestContext context, NodeId authenticationToken, SignatureData clientSignature, List< SignedSoftwareCertificate > clientSoftwareCertificates, ExtensionObject userIdentityToken, SignatureData userTokenSignature, StringCollection localeIds, out byte[] serverNonce)
 Activates an existing session More...
 
virtual void CloseSession (NodeId sessionId)
 Closes the specified session. More...
 
virtual RequestContext CreateRequestContext (RequestHeader requestHeader, ServiceType requestType)
 Validates request header and returns a request context. More...
 
List< SessionGetSessions (RequestContext context)
 Returns all of the sessions known to the session manager. More...
 

Protected Member Functions

virtual void Dispose (bool disposing)
 An overrideable version of the Dispose. More...
 
virtual Session CreateSession (RequestContext context, ICertificate serverCertificate, NodeId sessionCookie, byte[] serverNonce, string sessionName, ApplicationDescription clientDescription, string endpointUrl, ICertificate clientCertificate, double sessionTimeout, uint maxResponseMessageSize)
 Creates a new instance of a session. More...
 
virtual void RaiseSessionEvent (Session session, SessionEventReason reason)
 Raises an event related to a session. More...
 

Properties

SessionLimits SessionLimits [get]
 Gets the session limits (must not be modified by the called). More...
 
SessionEventHandler SessionCreated
 
SessionEventHandler SessionActivated
 
SessionEventHandler SessionClosing
 
ImpersonateEventHandler ImpersonateUser
 Callback to validate UserIdentitoken passed in ActivateSession. More...
 

Additional Inherited Members

- Events inherited from UnifiedAutomation.UaServer.ISessionManager
SessionEventHandler SessionCreated
 Raised after a new session is created. More...
 
SessionEventHandler SessionActivated
 Raised whenever a session is activated and the user identity or preferred locales changed. More...
 
SessionEventHandler SessionClosing
 Raised before a session is closed. More...
 
ImpersonateEventHandler ImpersonateUser
 Raised before the user identity for a session is changed. More...
 

Detailed Description

A generic session manager object for a server.

Constructor & Destructor Documentation

UnifiedAutomation.UaServer.SessionManager.SessionManager ( ServerManager  server,
SessionLimits  limits 
)

Initializes the manager with its configuration.

Member Function Documentation

virtual bool UnifiedAutomation.UaServer.SessionManager.ActivateSession ( RequestContext  context,
NodeId  authenticationToken,
SignatureData  clientSignature,
List< SignedSoftwareCertificate clientSoftwareCertificates,
ExtensionObject  userIdentityToken,
SignatureData  userTokenSignature,
StringCollection  localeIds,
out byte[]  serverNonce 
)
virtual

Activates an existing session

virtual void UnifiedAutomation.UaServer.SessionManager.CloseSession ( NodeId  sessionId)
virtual

Closes the specified session.

This method should not throw an exception if the session no longer exists.

virtual RequestContext UnifiedAutomation.UaServer.SessionManager.CreateRequestContext ( RequestHeader  requestHeader,
ServiceType  requestType 
)
virtual

Validates request header and returns a request context.

This method verifies that the session id valid and that it uses secure channel id associated with current thread. It also verifies that the timestamp is not too and that the sequence number is not out of order (update requests only).

virtual Session UnifiedAutomation.UaServer.SessionManager.CreateSession ( RequestContext  context,
ICertificate  serverCertificate,
string  sessionName,
byte[]  clientNonce,
ApplicationDescription  clientDescription,
string  endpointUrl,
ICertificate  clientCertificate,
double  requestedSessionTimeout,
uint  maxResponseMessageSize,
out NodeId  sessionId,
out NodeId  authenticationToken,
out byte[]  serverNonce,
out double  revisedSessionTimeout 
)
virtual

Creates a new session.

virtual Session UnifiedAutomation.UaServer.SessionManager.CreateSession ( RequestContext  context,
ICertificate  serverCertificate,
NodeId  sessionCookie,
byte[]  serverNonce,
string  sessionName,
ApplicationDescription  clientDescription,
string  endpointUrl,
ICertificate  clientCertificate,
double  sessionTimeout,
uint  maxResponseMessageSize 
)
protectedvirtual

Creates a new instance of a session.

void UnifiedAutomation.UaServer.SessionManager.Dispose ( )

Frees any unmanaged resources.

virtual void UnifiedAutomation.UaServer.SessionManager.Dispose ( bool  disposing)
protectedvirtual

An overrideable version of the Dispose.

List<Session> UnifiedAutomation.UaServer.SessionManager.GetSessions ( RequestContext  context)

Returns all of the sessions known to the session manager.

Parameters
contextThe request context.
Returns
A list of the sessions.

Implements UnifiedAutomation.UaServer.ISessionManager.

virtual void UnifiedAutomation.UaServer.SessionManager.RaiseSessionEvent ( Session  session,
SessionEventReason  reason 
)
protectedvirtual

Raises an event related to a session.

virtual void UnifiedAutomation.UaServer.SessionManager.Shutdown ( )
virtual

Stops the session manager and closes all sessions.

virtual void UnifiedAutomation.UaServer.SessionManager.Startup ( )
virtual

Starts the session manager.

Property Documentation

ImpersonateEventHandler UnifiedAutomation.UaServer.SessionManager.ImpersonateUser
addremove

Callback to validate UserIdentitoken passed in ActivateSession.

SessionLimits UnifiedAutomation.UaServer.SessionManager.SessionLimits
get

Gets the session limits (must not be modified by the called).

The session limits.


The documentation for this class was generated from the following file: