Reference
OpcUserNameAcl Members
Represents the access control list of an OpcServerSecurity which authenticates user name identity tokens using the OpcServerIdentity instances of its entries.
Reference
OpcUserNameAcl Members
- Type
- OpcUserNameAcl
- Namespace
- Opc.UaFx.Server
- Assembly
- Opc.UaFx.Advanced.dll
- Package
- Opc.UaFx.Advanced v2.59.0
Inherits members from OpcAccessControlList.
Constructors
OpcUserNameAcl
Initializes a new instance of the OpcUserNameAcl class using the owner specified.
public OpcUserNameAcl(OpcServerBase owner)Public Sub New(owner As OpcServerBase)Parameters
| Name | Type | Description |
|---|---|---|
owner | OpcServerBase | The OpcServerBase the list belongs to. |
Exceptions
| Exception | Condition |
|---|---|
| Argument | The owner is a null reference ( |
Remarks
The entries created by the list evaluate operations and endpoints using the mode Whitelist.
Properties
TokenType
Gets the type of the identity tokens the list is responsible for.
protected override OpcAccessControlTokenType TokenType { get; }Protected Overrides ReadOnly Property TokenType As OpcAccessControlTokenTypeProperty value
Always UserName.
Overrides
Methods
AddEntry
| Overload | Description |
|---|---|
| AddEntry( | Adds an entry for a user with the userName and password specified. |
| AddEntry( | Adds an entry for a user with the userName and password specified. |
| AddEntry( | Adds an entry for a user with the userName and password specified using the operation specified. |
| AddEntry( | Adds an entry for a user with the userName and password specified using the operation specified. |
| AddEntry( | Adds an entry for a user with the userName and password specified using the operation and endpoint specified. |
| AddEntry( | Adds an entry for a user with the userName and password specified using the operation and endpoint specified. |
| AddEntry( | Adds an entry for the identity specified. |
| AddEntry( | Adds an entry for the identity specified using the operation specified. |
| AddEntry( | Adds an entry for the identity specified using the operation and endpoint specified. |
AddEntry(string, string)
Adds an entry for a user with the userName and password specified.
public OpcAccessControlEntry AddEntry(string userName, string password)Public Function AddEntry(
userName As String,
password As String) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | String | The password of the user. |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
The entry uses the OperationAccessMode and the EndpointAccessMode of the list. Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(string, byte[])
Adds an entry for a user with the userName and password specified.
public OpcAccessControlEntry AddEntry(string userName, byte[] password)Public Function AddEntry(
userName As String,
password As Byte()) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | Byte[] | The bytes of the password of the user, which need to equal the result of Transform |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
The entry uses the OperationAccessMode and the EndpointAccessMode of the list. Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(string, string, OpcAccessControlMode)
Adds an entry for a user with the userName and password specified using the operationAccessMode specified.
public OpcAccessControlEntry AddEntry(
string userName,
string password,
OpcAccessControlMode operationAccessMode)Public Function AddEntry(
userName As String,
password As String,
operationAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | String | The password of the user. |
operation | Opc | One of the members defined by the Opc |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
The entry uses the EndpointAccessMode of the list. Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(string, byte[], OpcAccessControlMode)
Adds an entry for a user with the userName and password specified using the operationAccessMode specified.
public OpcAccessControlEntry AddEntry(
string userName,
byte[] password,
OpcAccessControlMode operationAccessMode)Public Function AddEntry(
userName As String,
password As Byte(),
operationAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | Byte[] | The bytes of the password of the user, which need to equal the result of Transform |
operation | Opc | One of the members defined by the Opc |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
The entry uses the EndpointAccessMode of the list. Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(string, string, OpcAccessControlMode, OpcAccessControlMode)
Adds an entry for a user with the userName and password specified using the operationAccessMode and endpointAccessMode specified.
public OpcAccessControlEntry AddEntry(
string userName,
string password,
OpcAccessControlMode operationAccessMode,
OpcAccessControlMode endpointAccessMode)Public Function AddEntry(
userName As String,
password As String,
operationAccessMode As OpcAccessControlMode,
endpointAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | String | The password of the user. |
operation | Opc | One of the members defined by the Opc |
endpoint | Opc | One of the members defined by the Opc |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(string, byte[], OpcAccessControlMode, OpcAccessControlMode)
Adds an entry for a user with the userName and password specified using the operationAccessMode and endpointAccessMode specified.
public OpcAccessControlEntry AddEntry(
string userName,
byte[] password,
OpcAccessControlMode operationAccessMode,
OpcAccessControlMode endpointAccessMode)Public Function AddEntry(
userName As String,
password As Byte(),
operationAccessMode As OpcAccessControlMode,
endpointAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
userName | String | The name of the user. |
password | Byte[] | The bytes of the password of the user, which need to equal the result of Transform |
operation | Opc | One of the members defined by the Opc |
endpoint | Opc | One of the members defined by the Opc |
Returns
The new OpcAccessControlEntry of the user.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The userName is equals Empty. |
| Argument | The userName or password is a null reference ( |
Remarks
Each call adds a new entry, also for a user name which is already used by another entry; Authenticate uses the first matching entry.
AddEntry(OpcServerIdentity)
Adds an entry for the identity specified.
public OpcAccessControlEntry AddEntry(OpcServerIdentity identity)Public Function AddEntry(identity As OpcServerIdentity) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
identity | Opc | The Opc |
Returns
The OpcAccessControlEntry of the identity.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The identity is a null reference ( |
Remarks
A new entry uses the OperationAccessMode and the EndpointAccessMode of the list. If the list already contains an entry for the identity, that entry is returned unchanged.
AddEntry(OpcServerIdentity, OpcAccessControlMode)
Adds an entry for the identity specified using the operationAccessMode specified.
public OpcAccessControlEntry AddEntry(
OpcServerIdentity identity,
OpcAccessControlMode operationAccessMode)Public Function AddEntry(
identity As OpcServerIdentity,
operationAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
identity | Opc | The Opc |
operation | Opc | One of the members defined by the Opc |
Returns
The OpcAccessControlEntry of the identity.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The identity is a null reference ( |
Remarks
A new entry uses the EndpointAccessMode of the list. If the list already contains an entry for the identity, that entry is returned unchanged, also if it uses another mode.
AddEntry(OpcServerIdentity, OpcAccessControlMode, OpcAccessControlMode)
Adds an entry for the identity specified using the operationAccessMode and endpointAccessMode specified.
public OpcAccessControlEntry AddEntry(
OpcServerIdentity identity,
OpcAccessControlMode operationAccessMode,
OpcAccessControlMode endpointAccessMode)Public Function AddEntry(
identity As OpcServerIdentity,
operationAccessMode As OpcAccessControlMode,
endpointAccessMode As OpcAccessControlMode) As OpcAccessControlEntryParameters
| Name | Type | Description |
|---|---|---|
identity | Opc | The Opc |
operation | Opc | One of the members defined by the Opc |
endpoint | Opc | One of the members defined by the Opc |
Returns
The OpcAccessControlEntry of the identity.
Exceptions
| Exception | Condition |
|---|---|
| Argument | The identity is a null reference ( |
Remarks
If the list already contains an entry for the identity, that entry is returned unchanged, also if it uses other modes.
Authenticate
Authenticates the identityToken specified if it is a user name identity token which matches the OpcServerIdentity of an entry.
public override OpcPrincipal Authenticate(OpcIdentityToken identityToken)Public Overrides Function Authenticate(
identityToken As OpcIdentityToken) As OpcPrincipalParameters
| Name | Type | Description |
|---|---|---|
identityToken | OpcIdentityToken | The OpcIdentityToken to authenticate. |
Returns
The OpcPrincipal of the first entry whose identity matches the user name and password of the identityToken (see Matches); otherwise a null reference (Nothing in Visual Basic).
Exceptions
| Exception | Condition |
|---|---|
| OpcException | The user name and password of the identityToken cannot be compared with an entry, for example because the token provides no password; the exception states Bad |
Overrides
Remarks
An authenticated principal is assigned to the role AuthenticatedUser.

