OpcUaClient UserCertificatePath can name any PFX on the node (possible signing oracle — unverified) #836

Closed
opened 2026-11-11 03:27:26 -05:00 by dohertj2 · 1 comment
Owner

Residual from #815's review. The OpcUaClient driver's user-certificate identity takes a file path; a Designer can point it at any PFX readable by the service account and an endpoint they control. A hostile server could then obtain signatures made with that key (ActivateSession user-token signature over server-chosen nonce/cert). Not verified end to end. Options: restrict to a configured certificate directory/store, or to secret:opcuaclient/… references, and refuse at save/deploy/Test Connect like the #815 credential fields.

Residual from #815's review. The OpcUaClient driver's user-certificate identity takes a file path; a Designer can point it at any PFX readable by the service account and an endpoint they control. A hostile server could then obtain signatures made with that key (ActivateSession user-token signature over server-chosen nonce/cert). Not verified end to end. Options: restrict to a configured certificate directory/store, or to `secret:opcuaclient/…` references, and refuse at save/deploy/Test Connect like the #815 credential fields.
dohertj2 added the driver/opcuaclienttype:review-findingpriority:p3 labels 2026-11-11 03:27:26 -05:00
Author
Owner

Fixed (63331b04, review fixes 271b96a6). Pushed to master in d1b6cad2. UserCertificatePath must be a relative path of plain segments inside Drivers:OpcUaClient:UserCertificateDirectory (default <LocalAppData>/OtOpcUa/pki/user-certificates; relative settings resolve against the app directory). Absolute/UNC/drive/../ADS forms are refused at save/deploy/Test Connect/browse; at load the path must stay inside the directory with links resolved. Checked only when AuthType is Certificate; the deploy gate also checks the merged driver+device config. Running drivers with an old absolute path keep loading it with a WARN + credential-compat:UserCertificatePath.

Upgrade note: OpcUaClient drivers using certificate auth must move the PFX under the directory (driver and admin nodes) and switch to the relative path before their next deploy. Follow-up: #850.

Fixed (`63331b04`, review fixes `271b96a6`). Pushed to master in `d1b6cad2`. `UserCertificatePath` must be a relative path of plain segments inside `Drivers:OpcUaClient:UserCertificateDirectory` (default `<LocalAppData>/OtOpcUa/pki/user-certificates`; relative settings resolve against the app directory). Absolute/UNC/drive/`..`/ADS forms are refused at save/deploy/Test Connect/browse; at load the path must stay inside the directory with links resolved. Checked only when AuthType is Certificate; the deploy gate also checks the merged driver+device config. Running drivers with an old absolute path keep loading it with a WARN + `credential-compat:UserCertificatePath`. **Upgrade note:** OpcUaClient drivers using certificate auth must move the PFX under the directory (driver and admin nodes) and switch to the relative path before their next deploy. Follow-up: #850.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dohertj2/lmxopcua#836