Intrinsic component configuration examples: Difference between revisions

From OPC Labs Knowledge Base
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[Category:Examples]]
= Ensure data integrity in COM =
In order to instruct the components to use RPC_C_AUTHN_LEVEL_PKT_INTEGRITY for the COM authentication level ([https://msrc.microsoft.com/update-guide/vulnerability/CVE-2021-26414 CVE-2021-26414]), you can use the following ''appsettings.json'' file (in QuickOPC 2022.1 and later):
<syntaxhighlight lang="json">
{
  "OpcLabs.BaseLib.Runtime.InteropServices.ComManagement": {
    "Configuration": {
      "SecurityParameters": {
        "EnsureDataIntegrity": true
      }
    }
  }
}
</syntaxhighlight>
= Set the default URL of the OPC UA Global Discovery Server (GDS) =
= Set the default URL of the OPC UA Global Discovery Server (GDS) =
In order to set the default URL of the OPC UA Global Discovery Server (GDS) used by QuickOPC global discovery operations, you can use the following ''appsettings.json'' file:
In order to set the default URL of the OPC UA Global Discovery Server (GDS) used by QuickOPC global discovery operations, you can use the following ''appsettings.json'' file:
Line 46: Line 61:
</syntaxhighlight>
</syntaxhighlight>
[[File:Appsettings-using-net-api-implementation-of-opc-data-access-client-2.zip|thumb]]
[[File:Appsettings-using-net-api-implementation-of-opc-data-access-client-2.zip|thumb]]
= Use NET API implementation for all OPC Classic operations =
<syntaxhighlight lang="json">
{
  "OpcLabs.EasyOpc.AlarmsAndEvents.EasyAEClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  },
  "OpcLabs.EasyOpc.AlarmsAndEvents.Forms.Browsing.AEDialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },
  "OpcLabs.EasyOpc.DataAccess.EasyDAClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  },
  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.DADialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },
  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.OpcBrowseControl": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },
  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.OpcBrowseDialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  }
}
</syntaxhighlight>
[[File:Appsettings-using-net-api-implementation-for-all-opc-classic.zip|thumb]]

Latest revision as of 10:59, 19 February 2024

Ensure data integrity in COM

In order to instruct the components to use RPC_C_AUTHN_LEVEL_PKT_INTEGRITY for the COM authentication level (CVE-2021-26414), you can use the following appsettings.json file (in QuickOPC 2022.1 and later):

{
  "OpcLabs.BaseLib.Runtime.InteropServices.ComManagement": {
    "Configuration": {
      "SecurityParameters": {
        "EnsureDataIntegrity": true
      }
    }
  }
}

Set the default URL of the OPC UA Global Discovery Server (GDS)

In order to set the default URL of the OPC UA Global Discovery Server (GDS) used by QuickOPC global discovery operations, you can use the following appsettings.json file:

{
  "OpcLabs.EasyOpc.UA.EasyUAClient": {
    "InstanceParameters": {
      "GdsEndpointDescriptor": {
        "UrlString": "opc.tcp://opcua.demo-this.com:58810/GlobalDiscoveryServer"
      }
    }
  } 
}

Use NET API implementation of OPC Data Access client

{
  "OpcLabs.EasyOpc.DataAccess.EasyDAClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  } 
}

File:Appsettings-using-net-api-implementation-of-opc-data-access-client.zip

If your project involves user interface, it needs to be configured too:

{
  "OpcLabs.EasyOpc.DataAccess.EasyDAClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  },

  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.DADialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  }
}

File:Appsettings-using-net-api-implementation-of-opc-data-access-client-2.zip

Use NET API implementation for all OPC Classic operations

{
  "OpcLabs.EasyOpc.AlarmsAndEvents.EasyAEClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  },

  "OpcLabs.EasyOpc.AlarmsAndEvents.Forms.Browsing.AEDialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },

  "OpcLabs.EasyOpc.DataAccess.EasyDAClient": {
    "InstanceParameters": {
      "EnableNativeClient": false,
      "EnableNetApiClient": true
    }
  },

  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.DADialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },

  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.OpcBrowseControl": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  },

  "OpcLabs.EasyOpc.DataAccess.Forms.Browsing.OpcBrowseDialog": {
    "ClientSelector": {
      "InstanceParameters": {
        "EnableNativeClient": false,
        "EnableNetApiClient": true
      }
    }
  }
}

File:Appsettings-using-net-api-implementation-for-all-opc-classic.zip