Matrikon Windows Security Configuration OPC Communication
Matrikon Windows Security Configuration OPC Communication
Document
Date Description Author
Version
2013-01-14 1.0 Initial document. TS
2013-04-05 1.1 Revisions. TS
2014-08-18 1.2 Revisions. TS
2020-07-30 2.0 Revisions and update CC
1
DOCUMENT VERSION
Version: 2.0
COPYRIGHT INFORMATION
© Copyright 1997 - 2020, Matrikon Inc. All rights reserved. Apart from any use permitted under the Copyright Act, no part of this
manual may be reproduced by any process without the written permission of Matrikon Inc.
CONFIDENTIAL
The information contained herein is confidential and proprietary to Matrikon Inc. It may not be disclosed or transferred, directly or
indirectly, to any third party without the explicit written permission of Matrikon Inc.
LIMITATIONS
Matrikon has made its best effort to prepare this manual. Matrikon makes no representation or warranties of any kind
with regard to the completeness or accuracy of the contents herein and accepts no liability of any kind including
without limitation warranties of merchantable quality, satisfactory quality, merchantability and fitness for a particular
purpose on those arising by law, statute, usage of trade, course of dealing or otherwise. Matrikon shall not be liable for
any losses or damages of any kind caused or alleged to be caused directly or indirectly from this manual.
LICENSE AGREEMENT
This document and the software described in this document are supplied under a license agreement and may only be used in
accordance with the terms of that agreement.
TRADEMARK INFORMATION
The following are either trademarks or registered trademarks of their respective organizations:
MatrikonOPC™ is a division of Matrikon™ Inc. Matrikon and MatrikonOPC are trademarks or registered trademarks of Matrikon Inc.
Adobe, the Adobe logo, Acrobat, the Adobe PDF logo, Distiller and Reader are either registered trademarks or trademarks of Ad obe
Systems Incorporated in the United States and/or other countries.
Identities ................................................................................................................................ 6
All OPC communication is based on the proprietary COM technology integral to the Windows operating system. In fact,
the connection between OPC applications is defined not by the OPC specification, but by COM. The connection process
is therefore a COM process and is subject to the security apparatus in Windows. As most systems where OPC
applications are employed are distributed systems and depend on various networking technologies, these must also be
examined to ensure that they are not responsible for the lack of connectivity.
This document presents a process for ensuring that the connection between OPC applications is not compromised by the
security configuration of either the Windows platforms on which they are installed or the network apparatus that connects
them. For the most part this will involve reducing the various security mechanism to near non-existence. As this can pose
serious security risks in itself, we will work from the inside out to ensure that system-wide security is minimally impacted.
Platform Compatibility
This document, and the screenshots included within, apply to the Windows 10/ Windows Server 2012 R2 platform.
Although the procedures described are applicable for earlier versions, access to the configuration tools may very slightly.
For older versions pre-Windows XP/Server 2003, some of these may not apply. Should that be the case, consult your
user documentation, your IT team, or your software vendor’s support team.
If you have completed all of the steps outlined in this document and are still unable to connect to your OPC server, there
may be GPOs in place that are affecting OPC connectivity. There is, unfortunately, no easy process for troubleshooting
this. You need to consult with your IT Department / System Administrator to analyze the GPOs configured on your system
to ascertain these effects.
To force a permission elevation, you can right-click on an icon and choose Run as administrator; if the launching user is
not part of the Administrators group you will be prompted for administrator credentials.
As MatrikonOPC products require access to protected parts of the filesystem to perform certain tasks, we strongly
recommend using Run as administrator to install and license MatrikonOPC software and run MatrikonOPC configuration
utilities. Please note that access to all of the utilities and configuration tools described in this document require an account
with local administrator privileges.
Client Identities
These are special identities in Windows that are added to the security settings on the COM (OPC) servers to determine
who has access to the server.
Everyone – all authenticated users on the local machine. This group applies to local users only.
Interactive – any user logged on to the local system. This identity allows only local users to access a resource.
Network – all users logged in through a network connection. This identity allows only remote users to access a resource.
System – a service account used by the operating system.
Any user account or group can be added to the server’s security settings. Refer to the Security tab Custom DCOM
Permissions section of this document. For additional information on Special Accounts in Windows refer to Microsoft Docs.
Server Identities
These are the accounts used to run the COM (OPC) servers.
Launching User – server runs with the identity of the user that launched the instance of the server. Each user (client)
runs its own instance of the server. This can cause issues with server access and resource usage.
Interactive User – server runs with the identity of the logged in user. All clients connect to the same instance of the
server, but if no user is logged on the server will not run.
System Account – only available if server is registered as a service. All clients connect to a single instance of the server.
Normally a safe choice, unless there are restrictions on the resource the server is attempting to access.
This User – an account specified by the administrator that meets all security requirements of the resource to be
accessed.
These identities are configured in the Identity tab of the Custom DCOM Permissions for each server object. For further
information on these identities refer to Microsoft Docs.
Server Listing
When a client is launched, it should list all available servers in the target machine. This list is generated either directly
from the registry or from a utility from the OPC Foundation called the OPC Server List utility, or OPC Enumerator (OPC
Enum for brevity). This is a COM server that manages server name and supported specification information for locally
installed OPC servers. If this list is not available, it is possible that the permissions on this utility are not properly
configured. To set these permissions, refer to the Custom DCOM Security Settings.
1. Data Execution Prevention (DEP) which prevents unauthorized code from running in protected system memory
areas.
2. The DCOM Security Settings that determine which identities have permission to interact with COM (OPC)
objects.
3. The Local Security Policy Options that control access to the machine in a workgroup environment.
4. The Windows Firewall.
5. Security Configuration and Network Components
DEP will also prevent many installations from running and has been known to cause other software issues. It should be
noted that the effects of DEP are known and that many modern applications are no longer affected by DEP. MatrikonOPC
software released from late 2006 to July 2009 will detect the DEP setting and, if set to Turn on DEP for all programs
and services except those I select (On), terminate the installation process. MatrikonOPC software released since
August 2009 no longer requires DEP to be turned off. To verify this, or for non-Matrikon software, consult the release
notes and user manual for each application.
If DEP is turned ON in your system and you believe that it may indeed be responsible for the bad behaviour exhibited by
your applications, the following procedure details how to turn DEP OFF. Please note that for this to be effective, DEP
must be turned off during software installation. If DEP is ON and the software has been installed, you will need to turn
DEP OFF, restart the machine, uninstall the software, and then perform a fresh install of the software. A machine restart
may also be required after the uninstall.
5. Click OK. If you changed the setting, it will be necessary to restart the operating system.
In order for an OPC client to connect to and communicate with an OPC server, these security settings must be configured
to allow the client identity to interact with the server object. The first step in troubleshooting whether these settings are
affecting connectivity is to determine if the server is using the default settings or custom settings. This can be determined
by checking the DCOMCNFG properties for the OPC server.
2. Right-click on dcomcnfg.exe and select the Run as administrator option. This utility can also be accessed through
the Control Panel > Administrative Tools > Component Services link.
3. In the left-hand panel, expand Component Services to find the DCOM config branch.
5. In the properties dialogue select the Security tab. Here you see the settings for three sets of permissions, Launch
and Activation, Access, and Configuration. Here you also see Use Default or Customize for each of these
permission sets. For this server, the Customize option is selected. This means that this server has a set of
6. If the server under investigation has Default selected, proceed to the section on the Default DCOM Permissions.
7. If the server under investigation has Customize selected, proceed to the section on the Custom DCOM Permissions.
Note
There are many mechanisms for modifying the ACL for each COM server. Most of these can have damaging effects in the
event of misuse or accidental misconfiguration. They are therefore meant for advanced Windows users. DCOMCNFG is a
graphic configuration utility that is the recommended method for making the required changes in these security settings.
In changing these settings, it is important to remember that this will change the DCOM Security settings on most of the
COM objects installed on the machine. It is necessary to observe the following precautions.
1. Inform your IT department or System Administrator that you are going to modify these settings. They may have
specific precautions that must also be observed.
2. Do not delete, remove, or edit any existing settings unless this document specifically instructs. In this case you
must document any changes that have been made so that they can be restored once testing is completed.
3. If the server under investigation has the Customize option selected, do not modify these settings. Proceed to the
Custom Default Permissions section.
3. In the My Computer Properties window select the Default Properties tab. Ensure that
a. The Enable Distributed COM on this computer option is checked
4. Select the COM Security tab. In each of the Access Permissions and the Launch and Activation Permissions
click on the Edit Default button
5. Add the following users to each permission set and Allow both Local and Remote;
a. Everyone
b. Interactive
c. Network
7. The Edit Limits option in this tab applies machine-wide limits for Access and Launch permissions. These buttons
may be inactive (greyed out as shown), in which case no action is required. If they are active add the same users as
were added to the Default permissions.
8. These settings effectively reduce the default security for the COM objects installed on the machine to minimum levels.
If the issue you are investigating is being caused by one of these settings, connection should now be possible. If you
are still unable to connect to the OPC server then these settings are not the cause of your issue. Possible next steps
include
a. Create a set of Custom Permissions for this server that specifically include the client identity. Refer to the
section on creating/setting Custom DCOM Permissions for information on this.
b. Continue with the other topics in this document, especially GPO’s and Network Security.
9. Once you have completed testing these new settings, return the Default Settings to their previous state prior to
implementing a solution or continuing your investigation. This specifically includes
a. Removing any identities that were added to the existing configuration
It should be noted that for Matrikon OPC servers, the installation program registers the server as a service and creates a
set of custom permissions identical to the settings implemented in this document. Both of these items are selectable at
installation and can be modified once installation is complete.
2. Selecting DCOM config displays a list of COM server objects in the center panel. Locate the server under
investigation, right-click on it and select Properties (double-clicking does not function in this utility).
6. In the Security tab, ensure that the Customize radio button is selected for each of the Launch and Activation
Permissions and the Access Permissions.
12. This setting depends upon the specific requirements of your system. Refer to Server Identities for further information.
Select the appropriate identity and then click on the OK button.
13. At this point you have completed the configuration of the Custom DCOM Permissions. The settings implemented in
this document have reduced the security on the server under investigation to minimum levels, effectively removing
security from the server object. Test these settings by attempting to connect your client to your server. If you are now
able to create this connection, your initial security settings were at fault and need to be reconfigured. If still unable to
connect, these settings are not the issue and additional troubleshooting is required.
To access/modify the Local Security Policy Options, perform the following steps:
1. There are a number of ways to access the Local Security Policy settings, depending on the version of Windows. This
is most commonly available through the Administrative Tools in the Control Panel. However, to see the Local Security
Policies in their wider context, click the Start button and type gpedit.msc in the search window. Regardless of the path
chosen, access to this tool requires an account with administrator privileges.
2. In the left panel of the Policy Editor window, expand the Security Settings to find the Security Options.
3. The Security Options will be listed in the center panel. To configure the machine-wide settings for COM, you will need
to modify two items;
a. DCOM: Machine Access Restrictions in Security Descriptor Definition Language (SDDL) syntax
b. DCOM: Machine Launch Restrictions in Security Descriptor Definition Language (SDDL) syntax
4. Double-click, or right-click and select Properties on each in turn to open the Properties dialogue.
9. From the User Rights Assignment policies, select Access this computer from the network. Double-click to open the
Properties dialogue. Ensure that the Everyone and Users groups have been added to this policy.
10. As with the settings in previous sections of this document, the security on your system has been set to minimum
levels. Successful connection indicates that one or more of these policies (or the default settings if undefined) were
responsible for the connection issues you were experiencing. Should this be the case, consult with your IT
Department and vendor support team to implement the proper security configuration. If you are still unable to connect
client to server, additional troubleshooting is required.
2. Select Turn Windows Firewall on or off on the left side of the window.
3. For the appropriate network type (Domain network settings not pictured here), select the Turn off Windows
Firewall radio button.
4. If this restores/permits connectivity, you will need to configure the Firewall to allow the OPC components access or
make arrangements as necessary to turn the Firewall off on a permanent basis. Alternatively, Matrikon’s OPC UA
Tunneller can be used to simplify configuration (refer to the Network Components section of this document).
Network components and architecture can likewise erect barriers between OPC applications. Network segmentation,
multiple domains, hardware firewalls, NAT, and port-forwarding configurations can all prevent OPC clients from
connecting and communicating with OPC servers.
Command line utilities such as Ping, TraceRT, Telnet, Netstat, and Netsh, as well as applications such as Wireshark can
be used to investigate whether the network is at issue when experiencing OPC communication failure. When using these
utilities / applications, coordinate with your IT Department / System Administrator to ensure such tools fall within the
acceptable use guidelines for you system.
Limitations
DCOM was developed to function in a specific environment where the following conditions applied:
All of these were typical of a LAN setup in an average office environment; however, this bears little resemblance to the
process control networks of today. Multiple domains, security-oriented IT policies, geographically dispersed data sources,
and a multitude of other factors all make OPC communication based on DCOM extremely complicated to configure while
maintaining security.
Matrikon’s OPC UA Tunneller provides successful OPC communications across firewalls or domain/workgroup barriers.
Using a single TCP port to the remote computer, it is much easier to configure routers and firewalls without sacrificing
security. It is one of our most popular products because of its ease of use, automatic reconnection system, and time
savings in implementation that it offers.
Contact your Account Manager or visit our website at www.matrikonopc.com for more information on this and other
MatrikonOPC solutions.