Last updated: November 2, 2026
ROS 2 security is the set of built-in protections in the Robot Operating System 2 that authenticate, authorize and encrypt the messages robot software components exchange. It is delivered through SROS2, the ROS 2 security tooling, on top of the OMG DDS-Security standard. It matters because ROS 2 security is turned off by default, and many robots, including humanoids, talk over the same DDS middleware.
How ROS 2 security works
ROS 2 programs (called nodes) send commands and sensor data to each other through a publish/subscribe middleware called DDS (Data Distribution Service). Without security, any device on the same network segment can discover the robot's topics, read them and publish to them.
ROS 2 security uses three of the five plugins defined in the DDS-Security specification (ROS 2 design article):
| DDS-Security plugin | What it does in ROS 2 |
|---|---|
| Authentication (PKI-DH) | Each participant proves its identity with an x.509 certificate signed by a trusted certificate authority |
| Access control | Signed governance and permissions files decide which topics each participant may publish or subscribe to |
| Cryptographic | Encrypts and signs the traffic |
The logging and data-tagging plugins are optional in the spec and are not used by ROS 2.
SROS2 groups these files into security enclaves. Each enclave holds its own certificate and private key plus a signed permissions.p7s, and one enclave can cover a single node, a whole robot or a fleet (ROS 2 docs: About Security). Three environment variables control it: ROS_SECURITY_KEYSTORE (where the files live), ROS_SECURITY_ENABLE=true (the on/off switch) and ROS_SECURITY_STRATEGY=Enforce. The official documentation is blunt: security is off by default, and without Enforce a misconfigured participant still launches, just without security.
Why ROS 2 security matters for humanoid robots
DDS is the robot's internal nervous system. On our humanoid robot attack surface map, internal middleware is one of eight entry points: anyone who reaches an unprotected DDS domain can often send motion or programming commands as if they were the robot's own software.
This is not limited to research robots. Unitree's SDK2 for the Go2, B2 and H1 is built on CycloneDDS, and Unitree says ROS 2 messages can control those robots directly (unitree_ros2 on GitHub).
Encryption is not the whole answer. In 2021, researchers reported 13 vulnerabilities across six DDS implementations and the DDS specification itself, so DDS libraries also need patching (Canonical).
Example: an unauthenticated DDS topic on the Unitree Go2
CVE-2026-27509 shows what happens without DDS authentication. According to the CVE record, Unitree Go2 firmware 1.1.7 to 1.1.9 (and 1.1.11 EDU) did not implement DDS authentication or authorization on a programming topic, so an unauthenticated attacker on the same network could plant code that later ran as root. It is rated 8.5 High (CVSS 4.0) by VulnCheck (advisory). Check current fix status in our Humanoid Robot Vulnerability Tracker.
What to do
- Turn on SROS2 with
ROS_SECURITY_STRATEGY=Enforceand give each node only the topics it needs. - Keep the certificate authority keys off the robot and plan how to rotate or revoke enclave certificates.
- Put robots on their own network segment, as IEC 62443 and other humanoid security standards recommend.
- Patch the DDS implementation, not only the robot application.
- Ask vendors whether their DDS traffic is authenticated before you buy. The free Humanoid Robot Security Checklist covers this.
Related terms
- SROS2 (ROS 2 security) directory profile
- Physical AI
- Vision-Language-Action (VLA) model
- Can humanoid robots be hacked?
FAQ
Is ROS 2 secure by default? No. ROS 2 security features are off by default and must be enabled with ROS_SECURITY_ENABLE=true. Setting ROS_SECURITY_STRATEGY=Enforce makes misconfigured nodes fail to launch instead of running unprotected.
What is the difference between SROS2 and DDS-Security? DDS-Security is the OMG standard that defines authentication, access control and encryption plugins. SROS2 is the ROS 2 tooling that creates keystores, certificates and permission files so ROS 2 can use those plugins.
Does ROS 2 security stop all attacks on a robot? No. It protects traffic between ROS 2 participants. It does not fix bugs in DDS libraries, insecure Bluetooth setup, cloud APIs or a compromised node that already holds valid credentials.
Get the weekly Humanoid Threats Brief → Subscribe


