Skip to content

Commit

Permalink
Added peer template and config key and cert
Browse files Browse the repository at this point in the history
Signed-off-by: Alejandro Hernández Cordero <[email protected]>
  • Loading branch information
ahcorde committed Jan 20, 2025
1 parent 0c2f3be commit 6cdfbe1
Show file tree
Hide file tree
Showing 4 changed files with 762 additions and 22 deletions.
59 changes: 59 additions & 0 deletions zenoh_security_configuration/README.md
Original file line number Diff line number Diff line change
@@ -1 +1,60 @@
# zenoh security configuration

### Configure the router

```bash
ros2 run zenoh_security_configuration zenoh_security_configuration \
-o zenoh_config \
-t router \
--listen_endpoint="tls/localhost:7447" \
--protocols=tls \
paths \
--root_ca_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/public/ca.cert.pem \
--listen_private_key /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/zenohd/key.pem \
--connect_private_key /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/zenohd/key.pem \
--connect_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/zenohd/cert.pem \
--listen_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/zenohd/cert.pem
```

Using enclaves generated with `ros2 security create_enclave`

```bash
ros2 run zenoh_security_configuration zenoh_security_configuration \
-o zenoh_config \
-t router \
--listen_endpoint="tls/localhost:0" \
--protocols=tls \
enclave \
--enclave_path /home/ahcorde/sros2_demo/demo_keystore_zenoh \
--enclave_name /zenoh
```

### Configure a Peer

```bash
ros2 run zenoh_security_configuration zenoh_security_configuration \
-o zenoh_config \
-t peer \
--listen_endpoint="tls/localhost:0" \
--protocols=tls \
paths \
--root_ca_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/public/ca.cert.pem \
--listen_private_key /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/listener/key.pem \
--connect_private_key /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/listener/key.pem \
--connect_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/listener/cert.pem \
--listen_certificate /home/ahcorde/sros2_demo/demo_keystore_zenoh/enclaves/listener/cert.pem
```

Using enclaves generated with `ros2 security create_enclave`


```bash
ros2 run zenoh_security_configuration zenoh_security_configuration \
-o zenoh_config \
-t peer \
--listen_endpoint="tls/localhost:0" \
--protocols=tls \
enclave \
--enclave_path /home/ahcorde/sros2_demo/demo_keystore_zenoh \
--enclave_name /talker_listener/talker
```
Loading

0 comments on commit 6cdfbe1

Please sign in to comment.