Skip to content

Commit ab4975f

Browse files
authored
Add support for DDS Security. (#626)
* Add support for DDS Security. * Upgraded Cyclors version to 0.3.10. Includes support for DDS Security on Linux and macOS.
1 parent 3dd5654 commit ab4975f

File tree

6 files changed

+104
-3
lines changed

6 files changed

+104
-3
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ jobs:
7171
- name: Build zenoh-plugin-dds (with prefix_symbols)
7272
run: cargo build -p zenoh-plugin-dds --features prefix_symbols --verbose --all-targets
7373

74+
- name: Build zenoh-plugin-dds (with dds_security)
75+
if: ${{ ! startsWith(matrix.os,'windows') }}
76+
run: cargo build -p zenoh-plugin-dds --features dds_security --verbose --all-targets
77+
7478
- name: Build zenoh-bridge-dds
7579
run: cargo build -p zenoh-bridge-dds --verbose --all-targets
7680

@@ -81,6 +85,10 @@ jobs:
8185
- name: Build zenoh-bridge-dds (with prefix_symbols)
8286
run: cargo build -p zenoh-bridge-dds --features prefix_symbols --verbose --all-targets
8387

88+
- name: Build zenoh-bridge-dds (with dds_security)
89+
if: ${{ ! startsWith(matrix.os,'windows') }}
90+
run: cargo build -p zenoh-bridge-dds --features dds_security --verbose --all-targets
91+
8492
- name: Run tests
8593
run: cargo test --verbose
8694

@@ -91,6 +99,10 @@ jobs:
9199
- name: Run tests (with prefix_symbols)
92100
run: cargo test --features prefix_symbols --verbose
93101

102+
- name: Run tests (with dds_security)
103+
if: ${{ ! startsWith(matrix.os,'windows') }}
104+
run: cargo test --features dds_security --verbose
105+
94106
markdown_lint:
95107
runs-on: ubuntu-latest
96108
steps:

Cargo.lock

Lines changed: 69 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ async-trait = "0.1.66"
3434
bincode = "1.3.3"
3535
cdr = "0.2.4"
3636
clap = "3.2.23"
37-
cyclors = "=0.3.9"
37+
cyclors = "=0.3.10"
3838
derivative = "2.2.0"
3939
flume = "0.11.0"
4040
futures = "0.3.26"

README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,26 @@ cargo build --release -p zenoh-bridge-dds --features prefix_symbols
175175

176176
**Note:** The ```prefix_symbols``` feature cannot be used at the same time as the ```dds_shm``` feature.
177177

178+
### Enabling DDS Security Support
179+
180+
To build the zenoh bridge for DDS with support for DDS Security the `dds_security` optional feature must be enabled during the build process as follows:
181+
182+
- plugin library:
183+
184+
```bash
185+
cargo build --release -p zenoh-plugin-dds --features dds_security
186+
```
187+
188+
- standalone executable binary:
189+
190+
```bash
191+
cargo build --release -p zenoh-bridge-dds --features dds_security
192+
```
193+
194+
**Note:** DDS Security is only supported on Linux and macOS.
195+
196+
See [here](https://cyclonedds.io/docs/cyclonedds/latest/security/dds_security.html) for more information on DDS Security support in Cyclone DDS.
197+
178198
## ROS 2 package
179199

180200
:warning: **Please consider using [`zenoh-bridge-ros2dds`](https://github.com/eclipse-zenoh/zenoh-plugin-ros2dds) which is dedicated to ROS 2.**

zenoh-bridge-dds/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ description = "Zenoh bridge for ROS2 and DDS in general"
2424
publish = false
2525

2626
[features]
27+
dds_security = ["zenoh-plugin-dds/dds_security"]
2728
dds_shm = ["zenoh-plugin-dds/dds_shm"]
2829
prefix_symbols = ["zenoh-plugin-dds/prefix_symbols"]
2930

zenoh-plugin-dds/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ crate-type = ["cdylib", "rlib"]
2929
[features]
3030
default = ["dynamic_plugin"]
3131
dynamic_plugin = []
32+
dds_security = ["cyclors/dds_security"]
3233
dds_shm = ["cyclors/iceoryx"]
3334
prefix_symbols = ["cyclors/prefix_symbols"]
3435
stats = ["zenoh/stats"]

0 commit comments

Comments
 (0)