2 entries are registered on port 4840. It is a registered port (1024–49151) — IANA records an assignee, but nothing stops other software from listening here, which is why the number carries more than one entry.
01OPC UA TCPtcp · udp · iana-registered · risk 4/10
OPC Unified Architecture (OPC UA) is a machine-to-machine communication protocol for industrial automation developed by the OPC Foundation. It is designed to facilitate the secure and reliable exchange of data in industrial control systems, supporting complex data modeling while remaining platform-independent.
The registry says what 4840 is registered to. What is listening on it right now is decided by the host, and only the host can be asked. Each of these prints the process behind the socket.
linux
ss -ltnp | grep ':4840\b'
macos
lsof -nP -iTCP:4840 -sTCP:LISTEN
windows
netstat -ano | findstr :4840
On Linux and Windows the process name comes back with the socket; on macOS lsof needs sudo to name a process that isn't yours. Match what it prints against the 2 entries above.
A port number is not a service. Anything may listen on 4840 — what you actually met is decided by the host, not the registry. If a service is missing here, it belongs in the registry.