Skip to content

Reference

OpcAccessControlList Members

Provides the abstract base class of the access control lists of an OpcServerSecurity, which authenticate the identity tokens of one OpcAccessControlTokenType and maintain one OpcAccessControlEntry per OpcPrincipal.

Reference

OpcAccessControlList Members ​

Type
OpcAccessControlList
Namespace
Opc.UaFx.Server
Assembly
Opc.UaFx.Advanced.dll
Package
Opc.UaFx.Advanced v2.59.0

Constructors ​

OpcAccessControlList ​

protected · since v2.6

Initializes a new instance of the OpcAccessControlList class using the owner, operationAccessMode and endpointAccessMode specified.

csharp
protected OpcAccessControlList(
    OpcServerBase owner,
    OpcAccessControlMode operationAccessMode,
    OpcAccessControlMode endpointAccessMode)
vbnet
Protected Sub New(
    owner As OpcServerBase,
    operationAccessMode As OpcAccessControlMode,
    endpointAccessMode As OpcAccessControlMode)

Parameters

NameTypeDescription
ownerOpcServerBaseThe OpcServerBase the list belongs to.
operationAccessModeOpcAccessControlModeOne of the members defined by the OpcAccessControlMode enumeration which specifies how the entries created by the list evaluate an operation which has neither been allowed nor denied explicitly.
endpointAccessModeOpcAccessControlModeOne of the members defined by the OpcAccessControlMode enumeration which specifies how the entries created by the list evaluate an endpoint which has neither been enabled nor disabled explicitly.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe owner is a null reference (Nothing in Visual Basic).

Properties ​

EndpointAccessMode ​

Gets the mode which the entries created by the list use to evaluate an endpoint which has neither been enabled nor disabled explicitly.

csharp
public OpcAccessControlMode EndpointAccessMode { get; }
vbnet
Public ReadOnly Property EndpointAccessMode As OpcAccessControlMode

Property value

OpcAccessControlMode

One of the members defined by the OpcAccessControlMode enumeration.

Entries ​

Gets a read-only collection of the entries of the list.

csharp
public OpcAccessControlEntryReadOnlyCollection Entries { get; }
vbnet
Public ReadOnly Property Entries As OpcAccessControlEntryReadOnlyCollection

Property value

OpcAccessControlEntryReadOnlyCollection

An instance of the OpcAccessControlEntryReadOnlyCollection class.

IsConfigured ​

virtual

Gets a value indicating whether the Configuration states a user token policy of the token type of the access control list.

csharp
public virtual bool IsConfigured { get; }
vbnet
Public Overridable ReadOnly Property IsConfigured As Boolean

Property value

Boolean

The value true if the user token policies of the server configuration contain a policy of the token type of the access control list; otherwise the value false.

Remarks

The value is the default of IsEnabled as long as that has not been set explicitly. While the server runs, the value follows the configuration it has been started with, which the start completes with the policies it offers. The Configuration itself is not changed by a start.

IsEnabled ​

Gets or sets a value indicating whether the server offers the token type of the access control list and uses the list to authenticate and authorize its users.

csharp
public bool IsEnabled { get; set; }
vbnet
Public Property IsEnabled As Boolean

Property value

Boolean

The value true if the access control list is used; otherwise the value false. As long as no value has been set, the value of IsConfigured is used.

Remarks

An access control list that has not been set explicitly follows the configuration and, in case of the OpcAnonymousAcl, the other access control lists: enabling for example only the OpcUserNameAcl disables anonymous access, unless the anonymous access control list is enabled explicitly as well.

To keep the result independent of the other lists, set the value of every access control list used.

OperationAccessMode ​

Gets the mode which the entries created by the list use to evaluate an operation which has neither been allowed nor denied explicitly.

csharp
public OpcAccessControlMode OperationAccessMode { get; }
vbnet
Public ReadOnly Property OperationAccessMode As OpcAccessControlMode

Property value

OpcAccessControlMode

One of the members defined by the OpcAccessControlMode enumeration.

Owner ​

protected

Gets the server the list belongs to.

csharp
protected OpcServerBase Owner { get; }
vbnet
Protected ReadOnly Property Owner As OpcServerBase

Property value

OpcServerBase

The OpcServerBase specified on construction.

TokenType ​

protected · abstract · since v2.42

Gets the type of the identity tokens the list is responsible for.

csharp
protected abstract OpcAccessControlTokenType TokenType { get; }
vbnet
Protected MustOverride ReadOnly Property TokenType As OpcAccessControlTokenType

Property value

OpcAccessControlTokenType

One of the members defined by the OpcAccessControlTokenType enumeration.

Methods ​

AddEntry ​

3 overloads

OverloadDescription
AddEntry(OpcPrincipal)Adds an entry for the principal specified to the list.
AddEntry(OpcPrincipal, OpcAccessControlMode)Adds an entry for the principal specified to the list using the operationAccessMode specified.
AddEntry(OpcPrincipal, OpcAccessControlMode, OpcAccessControlMode)Adds an entry for the principal specified to the list using the operationAccessMode and endpointAccessMode specified.

Exceptions (all overloads)

ExceptionCondition
ArgumentNullExceptionThe principal is a null reference (Nothing in Visual Basic).

AddEntry(OpcPrincipal) ​

Adds an entry for the principal specified to the list.

csharp
public OpcAccessControlEntry AddEntry(OpcPrincipal principal)
vbnet
Public Function AddEntry(principal As OpcPrincipal) As OpcAccessControlEntry

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to add an entry for.

Returns

OpcAccessControlEntry

The OpcAccessControlEntry of the principal.

Remarks

A new entry uses the OperationAccessMode and the EndpointAccessMode of the list. If the list already contains an entry for a principal whose Identity has the same Token, that entry is returned unchanged.

AddEntry(OpcPrincipal, OpcAccessControlMode) ​

Adds an entry for the principal specified to the list using the operationAccessMode specified.

csharp
public OpcAccessControlEntry AddEntry(
    OpcPrincipal principal,
    OpcAccessControlMode operationAccessMode)
vbnet
Public Function AddEntry(
    principal As OpcPrincipal,
    operationAccessMode As OpcAccessControlMode) As OpcAccessControlEntry

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to add an entry for.
operationAccessModeOpcAccessControlModeOne of the members defined by the OpcAccessControlMode enumeration which specifies how a new entry evaluates an operation which has neither been allowed nor denied explicitly.

Returns

OpcAccessControlEntry

The OpcAccessControlEntry of the principal.

Remarks

A new entry uses the EndpointAccessMode of the list. If the list already contains an entry for a principal whose Identity has the same Token, that entry is returned unchanged, also if it uses another mode.

AddEntry(OpcPrincipal, OpcAccessControlMode, OpcAccessControlMode) ​

Adds an entry for the principal specified to the list using the operationAccessMode and endpointAccessMode specified.

csharp
public OpcAccessControlEntry AddEntry(
    OpcPrincipal principal,
    OpcAccessControlMode operationAccessMode,
    OpcAccessControlMode endpointAccessMode)
vbnet
Public Function AddEntry(
    principal As OpcPrincipal,
    operationAccessMode As OpcAccessControlMode,
    endpointAccessMode As OpcAccessControlMode) As OpcAccessControlEntry

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to add an entry for.
operationAccessModeOpcAccessControlModeOne of the members defined by the OpcAccessControlMode enumeration which specifies how a new entry evaluates an operation which has neither been allowed nor denied explicitly.
endpointAccessModeOpcAccessControlModeOne of the members defined by the OpcAccessControlMode enumeration which specifies how a new entry evaluates an endpoint which has neither been enabled nor disabled explicitly.

Returns

OpcAccessControlEntry

The OpcAccessControlEntry of the principal.

Remarks

If the list already contains an entry for a principal whose Identity has the same Token, that entry is returned unchanged, also if it uses other modes.

Allow ​

Allows the operation specified explicitly for the principal specified.

csharp
public void Allow(OpcPrincipal principal, OpcOperationType operation)
vbnet
Public Sub Allow(principal As OpcPrincipal, operation As OpcOperationType)

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to allow the operation for.
operationOpcOperationTypeThe OpcOperationType to allow.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or operation is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

Authenticate ​

abstract · since v2.42

When overridden in a derived class, authenticates the identityToken specified.

csharp
public abstract OpcPrincipal Authenticate(OpcIdentityToken identityToken)
vbnet
Public MustOverride Function Authenticate(
    identityToken As OpcIdentityToken) As OpcPrincipal

Parameters

NameTypeDescription
identityTokenOpcIdentityTokenThe OpcIdentityToken to authenticate.

Returns

OpcPrincipal

The OpcPrincipal of the identityToken if the list accepts the token; otherwise a null reference (Nothing in Visual Basic).

ConfigureCore ​

protected · virtual

When overridden in a derived class, applies the configuration of the Owner to the list.

csharp
protected virtual void ConfigureCore()
vbnet
Protected Overridable Sub ConfigureCore()

Remarks

The method is called when the node managers of the server have been started. The base implementation does nothing.

Deny ​

Denies the operation specified explicitly for the principal specified.

csharp
public void Deny(OpcPrincipal principal, OpcOperationType operation)
vbnet
Public Sub Deny(principal As OpcPrincipal, operation As OpcOperationType)

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to deny the operation for.
operationOpcOperationTypeThe OpcOperationType to deny.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or operation is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

Disable ​

Disables the endpoint specified explicitly for the principal specified.

csharp
public void Disable(OpcPrincipal principal, OpcEndpointIdentity endpoint)
vbnet
Public Sub Disable(principal As OpcPrincipal, endpoint As OpcEndpointIdentity)

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to disable the endpoint for.
endpointOpcEndpointIdentityThe OpcEndpointIdentity to disable.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or endpoint is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

Enable ​

Enables the endpoint specified explicitly for the principal specified.

csharp
public void Enable(OpcPrincipal principal, OpcEndpointIdentity endpoint)
vbnet
Public Sub Enable(principal As OpcPrincipal, endpoint As OpcEndpointIdentity)

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to enable the endpoint for.
endpointOpcEndpointIdentityThe OpcEndpointIdentity to enable.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or endpoint is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsEndpointDisabled ​

virtual · 2 overloads

OverloadDescription
IsEndpointDisabled(OpcPrincipal)virtualDetermines whether the endpoint of the current secure channel is disabled for the principal specified.
IsEndpointDisabled(OpcPrincipal, OpcEndpointIdentity)virtualDetermines whether the endpoint specified is disabled for the principal specified.

IsEndpointDisabled(OpcPrincipal) ​

virtual

Determines whether the endpoint of the current secure channel is disabled for the principal specified.

csharp
public virtual bool IsEndpointDisabled(OpcPrincipal principal)
vbnet
Public Overridable Function IsEndpointDisabled(
    principal As OpcPrincipal) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.

Returns

Boolean

The value true if the entry of the principal disables the endpoint (see IsDisabled); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal is a null reference (Nothing in Visual Basic) or the method is not called in the context of a secure channel (see GetCurrent).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsEndpointDisabled(OpcPrincipal, OpcEndpointIdentity) ​

virtual

Determines whether the endpoint specified is disabled for the principal specified.

csharp
public virtual bool IsEndpointDisabled(
    OpcPrincipal principal,
    OpcEndpointIdentity endpoint)
vbnet
Public Overridable Function IsEndpointDisabled(
    principal As OpcPrincipal,
    endpoint As OpcEndpointIdentity) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.
endpointOpcEndpointIdentityThe OpcEndpointIdentity to verify.

Returns

Boolean

The value true if the entry of the principal disables the endpoint (see IsDisabled); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or endpoint is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsEndpointEnabled ​

virtual · 2 overloads

OverloadDescription
IsEndpointEnabled(OpcPrincipal)virtualDetermines whether the endpoint of the current secure channel is enabled for the principal specified.
IsEndpointEnabled(OpcPrincipal, OpcEndpointIdentity)virtualDetermines whether the endpoint specified is enabled for the principal specified.

IsEndpointEnabled(OpcPrincipal) ​

virtual

Determines whether the endpoint of the current secure channel is enabled for the principal specified.

csharp
public virtual bool IsEndpointEnabled(OpcPrincipal principal)
vbnet
Public Overridable Function IsEndpointEnabled(
    principal As OpcPrincipal) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.

Returns

Boolean

The value true if the entry of the principal enables the endpoint (see IsEnabled); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal is a null reference (Nothing in Visual Basic) or the method is not called in the context of a secure channel (see GetCurrent).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsEndpointEnabled(OpcPrincipal, OpcEndpointIdentity) ​

virtual

Determines whether the endpoint specified is enabled for the principal specified.

csharp
public virtual bool IsEndpointEnabled(
    OpcPrincipal principal,
    OpcEndpointIdentity endpoint)
vbnet
Public Overridable Function IsEndpointEnabled(
    principal As OpcPrincipal,
    endpoint As OpcEndpointIdentity) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.
endpointOpcEndpointIdentityThe OpcEndpointIdentity to verify.

Returns

Boolean

The value true if the entry of the principal enables the endpoint (see IsEnabled); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or endpoint is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsOperationAllowed ​

virtual

Determines whether the operation specified is allowed for the principal specified.

csharp
public virtual bool IsOperationAllowed(
    OpcPrincipal principal,
    OpcOperationType operation)
vbnet
Public Overridable Function IsOperationAllowed(
    principal As OpcPrincipal,
    operation As OpcOperationType) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.
operationOpcOperationTypeThe OpcOperationType to verify.

Returns

Boolean

The value true if the entry of the principal allows the operation (see IsAllowed); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or operation is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

IsOperationDenied ​

virtual

Determines whether the operation specified is denied for the principal specified.

csharp
public virtual bool IsOperationDenied(
    OpcPrincipal principal,
    OpcOperationType operation)
vbnet
Public Overridable Function IsOperationDenied(
    principal As OpcPrincipal,
    operation As OpcOperationType) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal to verify.
operationOpcOperationTypeThe OpcOperationType to verify.

Returns

Boolean

The value true if the entry of the principal denies the operation (see IsDenied); otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal or operation is a null reference (Nothing in Visual Basic).

Remarks

If the list does not yet contain an entry for the principal, an entry using the OperationAccessMode and the EndpointAccessMode of the list is added.

RemoveEntry ​

2 overloads

OverloadDescription
RemoveEntry(OpcAccessControlEntry)Removes the entry specified from the list.
RemoveEntry(OpcPrincipal)Removes the entry of the principal specified from the list.

RemoveEntry(OpcAccessControlEntry) ​

Removes the entry specified from the list.

csharp
public bool RemoveEntry(OpcAccessControlEntry entry)
vbnet
Public Function RemoveEntry(entry As OpcAccessControlEntry) As Boolean

Parameters

NameTypeDescription
entryOpcAccessControlEntryThe OpcAccessControlEntry to remove.

Returns

Boolean

The value true if the entry has been removed; otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe entry is a null reference (Nothing in Visual Basic).

RemoveEntry(OpcPrincipal) ​

Removes the entry of the principal specified from the list.

csharp
public bool RemoveEntry(OpcPrincipal principal)
vbnet
Public Function RemoveEntry(principal As OpcPrincipal) As Boolean

Parameters

NameTypeDescription
principalOpcPrincipalThe OpcPrincipal whose entry is to be removed.

Returns

Boolean

The value true if the list contained an entry for the principal and the entry has been removed; otherwise the value false.

Exceptions

ExceptionCondition
ArgumentNullExceptionThe principal is a null reference (Nothing in Visual Basic).