IMD SolutionComputing LibraryShop main store

Troubleshooting

Why node-red-contrib-iiot-opcua installs with 3 npm vulnerabilities

Edge computing and IIoT Published 7 min read

Short answer

The install did not fail: the transcript shows npm completing a global install, and the three reported vulnerabilities are audit findings on a dependency tree no update will change, because node-red-contrib-iiot-opcua is deprecated and closed since April 2020. Back up the flows, run npm audit fix followed by npm audit, and migrate new work to node-red-contrib-opcua after checking node compatibility.

On this page
  1. Did the node-red-contrib-iiot-opcua install fail?
  2. What do the npm warnings and vulnerabilities in the output mean?
  3. Is the debug ReDoS warning one of the three vulnerabilities?
  4. How do I run npm audit fix and npm audit on the edge PC?
  5. Why is node-red-contrib-iiot-opcua deprecated and closed?
  6. Should I migrate to node-red-contrib-opcua?
  7. What if my project is locked to the iiot nodes?
  8. What is the decision for each case?
  9. Questions asked

The install did not fail. changed 250 packages, and audited 251 packages is npm reporting a finished global install, and the 3 vulnerabilities (1 high, 2 critical) line is npm audit's summary of known advisories in the dependency tree, not an installation error. The real problem is lifecycle, not mechanics: the package's own npm page marks node-red-contrib-iiot-opcua deprecated and closed since April 2020, so the tree that produced those findings will never be updated under that name. Back up your flows, run npm audit fix followed by npm audit, and decide from that report — migrate new work to node-red-contrib-opcua, and hold any flow you cannot change yet on an isolated host.

Did the node-red-contrib-iiot-opcua install fail? #

No. The output shows a completed install: npm changed 250 packages and audited 251 of them, finishing in about three minutes on that machine, and none of the five lines is a fatal error, so there is nothing to reinstall.

Read each line as the message class it belongs to:

  • changed 250 packages, and audited 251 packages in 3m — the completion summary. npm rewrote the module tree, then ran its audit pass over it.
  • the npm deprecation warning naming the debug package at version 4.1.1 — a deprecation notice for one dependency version inside that tree; the ranges and the recommended releases come from the debug project's own advisory.
  • 41 packages are looking for funding — informational; it affects neither the install result nor security.
  • 3 vulnerabilities (1 high, 2 critical) — npm audit's severity count for the tree as installed, not an error message.
  • To address all issues, run: npm audit fix — the remediation npm suggests for that count; it is a next step, not a complaint.

Repeating the install, with the same command or from another mirror, reproduces the same tree, because every version comes from what the package last published. The findings belong to the audit, and the audit is where the work is.

What do the npm warnings and vulnerabilities in the output mean? #

They are three different message classes on one transcript. The deprecation warning marks one dependency version as retired, the funding line is housekeeping, and the vulnerabilities line is npm audit's severity verdict on the whole tree: one high and two critical.

npm audit compares every installed package against its advisory database and grades each match critical, high, moderate or low, with critical the most severe. The audit ran during the install because npm audits whenever an install changes the tree; you did not switch anything on. Because the scan reflects the advisory database as of install day, the same tree can report differently months later, which is why the count alone is never the verdict and the named report from npm audit is the document to keep.

Is the debug ReDoS warning one of the three vulnerabilities? #

No. The deprecation notice for the debug package at version 4.1.1 sits outside the audit count: npm reports the three vulnerabilities separately, and the warning itself names the repaired releases as 3.2.7 or 4.3.1 of the debug package.

Worked example, using the versions in the warning. The advisory excludes every debug release from 3.2.0 up to but not including 3.2.7, and every release from 4.0.0 up to but not including 4.3.1. Place the installed copy in those bands: 4.0.0 ≤ 4.1.1 and 4.1.1 < 4.3.1, so 4.1.1 falls inside the affected 4.x band, and the first documented clean release above it is 4.3.1. npm audit fix will therefore try to raise the dependency to 4.3.1; whether it can depends on the version range the closed package allows, and the follow-up npm audit report is the only proof of what actually moved.

How do I run npm audit fix and npm audit on the edge PC? #

Back up first, then run npm audit fix and finish with npm audit, so the final report shows exactly what the fix left behind. An empty report closes the finding; any remaining severity count leaves the tree uncleared.

  1. Stop Node-RED and copy the flows JSON file and its credentials file out of the user directory.
  2. Capture the starting point with npm audit in the same install context. If npm replies that it cannot audit a global tree, install the node set into the Node-RED user directory instead — the documented location Node-RED loads extra nodes from — where the project lockfile gives npm audit something to read.
  3. Run npm audit fix and let it rewrite whatever the version ranges allow.
  4. Run npm audit again and compare severity counts and package names against the first report.
  5. Restart Node-RED and exercise one OPC UA read and one subscription against a test server before the flow returns to service.

An unsuccessful fix is not an unsuccessful install: it means npm could not build a dependency set that removes every finding, which is a different problem with a different decision below.

Why is node-red-contrib-iiot-opcua deprecated and closed? #

Because the maintainer ended it. The package's npm page opens by stating it is deprecated and closed since April 2020, its linked source pages no longer resolve, and it no longer appears in the Node-RED flow library — so no release under that name can ever clear the audit findings.

Two continuations exist, and neither changes that. Text preserved with the project describes a 2022 revitalization of the 2017 original, and a community continuation published as node-red-contrib-iiot-opcua-gem is listed in the flow library, introduced after the deprecation. Under the name you installed, the vulnerable pins stay exactly as last published; vetting a fork's change log and dependency tree becomes your work, not the original maintainer's. Keep the blame placement honest too: without the per-dependency npm audit output, the only documented fact is that the advisories sit in this package's tree — not in the host image and not in Node-RED itself.

Should I migrate to node-red-contrib-opcua? #

Yes for new projects, and for any existing flow you can afford to retest. node-red-contrib-opcua is the actively maintained OPC UA node set for Node-RED and the only migration path that puts these flows back on a maintained, auditable dependency tree.

Treat the move as a rebuild, not a rename: node types between the iiot set and the replacement do not map one to one, and migrators report gaps when translating flows. Inventory the node types your flows actually use — client reads, subscriptions, writes, method calls — rebuild each against the new set, and verify against a live or simulated server. Before you install or update the package, check the fix for node-red-contrib-opcua npm updates that will not refresh, so a stale cache does not read as a broken package. If the same box also feeds a broker, build that side on the maintained set from the start; the Bridging OPC UA PLC data to MQTT with an edge PC walkthrough shows the pattern.

What if my project is locked to the iiot nodes? #

Keep the host, not the trust: run the fix, keep the audit report as your open finding, put the machine on its own plant segment, and book a migration date. The package will not ship a repair, so containment plus a deadline is the whole plan.

A critical advisory inside a node set that talks to live PLCs is a plant risk, not only an IT ticket: keep that host off any routable network until the report is clean or the segment is in place. The controls that matter are the ones for a Node-RED OPC UA server exposing PLC tags — restrict who can reach the OPC UA endpoint on its default TCP port 4840, and disable node types the flow never uses. When you later rebuild the same gateway on fresh hardware, pinning exact node versions keeps the audited tree identical on every box, which is what stable gateway flows with vendor-pinned nodes are for.

What is the decision for each case? #

Install: nothing to repair, it completed. Immediate action: flows backup, then npm audit fix, then npm audit, and keep that report. New work: migrate to node-red-contrib-opcua after verifying node compatibility. Locked-in flows: isolate the host and set a migration date.

Every path ends at the same place: a maintained node set, an audit report you can file, and an edge PC that does not carry an unpatched critical finding onto the plant network. The lifecycle fact does not move with any audit result — a package closed since April 2020 owns that tree, and the sooner your flows leave it, the smaller the finding stays.

Questions asked

Can node-red-contrib-iiot-opcua still be installed from the Node-RED palette?

No. The package is no longer listed in the Node-RED flow library, so palette search will not offer it. npm still serves the last published copy from the registry, which is why the deprecated version can be installed directly and why the two paths leave different impressions of the package's status.

Why did npm audit fix not remove every finding?

npm audit fix can only move dependencies to versions that the installed package's own version ranges permit. A closed package publishes no update, so its ranges hold the vulnerable pins in place. Anything the fix cannot change comes back in the npm audit report, and that report is the record to keep and act on.

How do I back up flows before changing dependencies?

Stop Node-RED first, then copy both the flows JSON file and its matching credentials file from the Node-RED user directory. The credentials file holds the encrypted secrets configured in the nodes; a flows backup without it restores the wiring but loses passwords and keys. Rehearse the restore on a second instance before touching the production host.

Is node-red-contrib-opcua a drop-in replacement for the iiot nodes?

No. Node names and their configuration fields do not correspond one to one, and migrators report gaps when translating flows. Rebuild each flow against the new node set, verify reads, subscriptions and writes against a test server, and keep the old host runnable until the replacement has completed a full shift of production data.

Does a clean npm audit mean the edge PC is safe for the plant network?

No. npm audit checks known advisories in the dependency tree at the moment it runs; it does not cover undisclosed flaws, misconfigured endpoints or unpatched firmware elsewhere on the machine. Segmentation, endpoint access control and operating system patching remain separate controls that no npm report can grant.

Keep reading

  • Troubleshooting

    Troubleshoot Node-RED OPC UA When UaExpert Connects

    UaExpert connecting proves the server is up, not that Node-RED negotiates the same endpoint and certificate exchange. Set the security policy to None on an isolated network: if Node-RED then connects, the fault is certificate or encryption compatibility. The deciding evidence is the server-side log line for the same attempt, time-correlated against Node-RED's error.

    Edge computing and IIoT

  • Troubleshooting

    Why S7 nodes disappear from the Node-RED palette

    Installing an S7 package such as node-red-contrib-s7 can break another package's startup registration, which empties its node types out of the Node-RED palette; the flows and the S7-1200 are untouched. Compare the installed-package list and startup log against your baseline, reinstall the missing package through the deployment's supported method, restart and hard-refresh, then set the S7-1200's PUT/GET permission, rack and slot, and a non-optimized test block.

    Edge computing and IIoT

  • How-to

    Set up the MQTT Client SL library on a CODESYS controller

    MQTT Client SL is part of the CODESYS IIoT Libraries SL package. Verify the exact controller runtime and its license, pin the library version, batch JSON per asset, and set the controller clock before opening a TLS session.

    Edge computing and IIoT

Migrate a TagHistoryProvider to Ignition 8.3.3