OPC Unified Architecture, Part 3 13 Release 1.04
4.8.2 Well Known Roles
All Servers should support the well-known Roles which are defined in Table 2. The NodeIds
for the well-known Roles are defined in Part 6.
Table 2 – Well-Known Roles
BrowseName Suggested Permissions
Anonymous The Role has very limited access for use when a Session has anonymous credentials.
AuthenticatedUser The Role has limited access for use when a Session has valid non-anonymous credentials
but has not been explicitly granted access to a Role.
Observer The Role is allowed to browse, read live data, read historical data/events or subscribe to data/events.
Operator The Role is allowed to browse, read live data, read historical data/events or subscribe to data/events.
In addition, the Session is allowed to write some live data and call some Methods.
Engineer The Role is allowed to browse, read/write configuration data, read historical data/events,
call Methods or subscribe to data/events.
Supervisor The Role is allowed to browse, read live data, read historical data/events, call Methods or
subscribe to data/events.
ConfigureAdmin The Role is allowed to change the non-security related config
SecurityAdmin The Role is allowed to change security related settings.
RegisterServerManager is responsible to Register an opcua server on a LDS or LDS-ME server
This class takes in charge :
the initial registration of a server
the regular registration renewal (every 8 minutes or so ...)
dealing with cases where LDS is not up and running when server starts.
( in this case the connection will be continuously attempted using the infinite
back-off strategy
the un-registration of the server ( during shutdown for instance)
Events:
Emitted when the server is trying to registered the LDS
but when the connection to the lds has failed
serverRegistrationPending is sent when the backoff signal of the
connection process is rained
this method install the access right restriction on the given node and its children
values will only be available to user with role Administrator or supervisor and
with a signed and encrypted channel.
lowerFirstLetter convert a OPCUA Identifier to a javascript Identifier
summary
OPCUA and Javascript use two different rules to build identifiers.
OPCUA Identifier usually starts with a upper case letter and word are join together, this is known as
the Pascal case, or CapitalizedWords convention. (for instance HelloWorld)
But sometime, OPCUA identifiers do not follow this convention strictly and we can find various
other convention being applied such as underscore between word, or addition of ACRONYMIC prefixes.
On it's own, this causes great confusion and inconsistency in programming style.
Javascript uses a slightly different convention called camelCase where word are joined together
and inner words starts with a capital letter whereas first word starts with a lower case letter.
(for instance helloWorld)
In node-opcua we have taken the opinionated decision to consistently use camelCase convention for
object properties so that all the code look nice and consistent.
the lowerFirstLetter method can be used to easily convert from the OPCUA naming convention
to javascript naming convention by applying the following rules.
each ascii sequence in a identifier will be converted to lower camel case.
when an identifier only contains upper case letter then it will be untouched. ( i.e CQDF => CQFD)
(this rules helps to preserve acronyms)
when a identifier starts with more than one UpperCase letter but still contain lowercase letter
then the first Uppercase letter excluding the last one will be converted to lower case
( ie: EURange = > euRange)
when a identifier contains several sequences delimited with underscores (_) the above rules
will be applied to each of the element of the sequence
( ie: ALM_FlowOutOfTolerance => ALM_flowOutOfTolerance ( ALM=>ALM , FlowOutOfTolerance=>flowOutOfTolerance)
HelloWorld => helloWorld
XAxis => xAxis
EURange => euRange
DATE => DATE
XYZ => XYZ
AB => AB
Ab => ab
A => a
T1ABC8 => T1ABC8
F_ABC_D => F_ABC_D
ALM_Timeout => ALM_timeout
SV_GasOn => SV_gasOn
DI_VAL_FlowImp => DI_VAL_flowImp
Parameters
str: string
Returns string
makeAccessLevelExFlag
makeAccessLevelExFlag(str: string | number | null): AccessLevelExFlag
construct a RelativePath from a string containing the relative path description.
The string must comply to the OPCUA BNF for RelativePath ( see part 4 - Annexe A)
OPC Unified Architecture, Part 3 13 Release 1.04 4.8.2 Well Known Roles All Servers should support the well-known Roles which are defined in Table 2. The NodeIds for the well-known Roles are defined in Part 6. Table 2 – Well-Known Roles BrowseName Suggested Permissions
Anonymous The Role has very limited access for use when a Session has anonymous credentials. AuthenticatedUser The Role has limited access for use when a Session has valid non-anonymous credentials but has not been explicitly granted access to a Role. Observer The Role is allowed to browse, read live data, read historical data/events or subscribe to data/events. Operator The Role is allowed to browse, read live data, read historical data/events or subscribe to data/events. In addition, the Session is allowed to write some live data and call some Methods. Engineer The Role is allowed to browse, read/write configuration data, read historical data/events, call Methods or subscribe to data/events. Supervisor The Role is allowed to browse, read live data, read historical data/events, call Methods or subscribe to data/events. ConfigureAdmin The Role is allowed to change the non-security related config SecurityAdmin The Role is allowed to change security related settings.