ZBLOG

12.4. Security Plugins Settings As described in the Security section, the security plugins admit a set of settings that can be configured. 12.4.1. Authentication plugin settings The DDS:Auth:PKI-DH authentication plugin, can be activated settin...

这段文本描述了安全插件的设置,特别是 DDS (Data Distribution Service) 中的身份验证插件配置。以下是各部分的解释:

12.4. Security Plugins Settings

这一部分概述了在 DDS 中如何配置安全插件的相关设置。

12.4.1. Authentication Plugin Settings

这里详细介绍了 DDS:Auth:PKI-DH 身份验证插件的激活和配置方法。

  • Plugin Activation:通过设置 DomainParticipantQosdds.sec.auth.plugin 属性为 builtin.PKI-DH 来激活此插件。

  • Properties Table

    • identity_ca:身份 CA 的 X.509 v3 证书的 URI,以 PEM 格式存储,支持 file URI。
    • identity_certificate:由身份 CA 签名的 X.509 v3 证书 URI,以 PEM 格式存储,包含参与者的公钥。
    • identity_crl (可选):X.509 撤销列表 (CRL) 的 URI,支持 file URI。
    • private_key:参与者私钥的 URI,支持 file 和 PKCS#11。
    • password (可选):用于解密私钥的密码,如果没有提供密码,则私钥需要以解密形式给出。
    • preferred_key_agreement (可选):首选算法,用于生成会话共享秘密,可以选择 DH、ECDH 或 AUTO(根据签名算法自动选择)。
    • transmit_algorithms_as_legacy (可选):是否以非标准旧格式传输算法标识符,默认值为 false。

所有属性都以前缀 dds.sec.auth.builtin.PKI-DH. 开头。例如,dds.sec.auth.builtin.PKI-DH.identity_ca

12.4.2. Authentication Handshake Settings

这一部分讲述身份验证过程中的握手设置。

  • 握手阶段从接收到远程 DomainParticipants 的发现信息开始,此时发送握手请求直到收到响应。一些参数影响这个交换过程:
    • max_handshake_requests:控制最大握手请求数。
    • initial_handshake_resend_period:初始重发第一个握手请求等待时间(毫秒)。
    • handshake_resend_period_gain:两次握手请求之间时间间隔增长因子。

在每次迭代中,新握手请求发送之前等待时间按上一次两个请求之间的时间乘以增益进行计算,从而使得等待时间逐渐增加。

属性表

  • 所有 listed properties 都有前缀 dds.sec.auth.builtin.PKI-DH.。例如,dds.sec.auth.builtin.PKI-DH.max_handshake_requests

示例代码

提供了如何在 C++ 和 XML 中配置这些属性的方法示例:

C++ 示例

DomainParticipantQos pqos;

pqos.properties().properties().emplace_back(
    "dds.sec.auth.builtin.PKI-DH.max_handshake_requests",
    "5");
pqos.properties().properties().emplace_back(
    "dds.sec.auth.builtin.PKI-DH.initial_handshake_resend_period",
    "250");
pqos.properties().properties().emplace_back(
    "dds.sec.auth.builtin.PKI-DH.handshake_resend_period_gain",
    "1.5");

XML 示例

<participant profile_name="secure_domainparticipant_conf_auth_handshake_props_xml_profile">
    <rtps>
        <propertiesPolicy>
            <properties>
                <property>
                    <name>dds.sec.auth.builtin.PKI-DH.max_handshake_requests</name>
                    <value>5</value>
                </property>
                <property>
                    <name>dds.sec.auth.builtin.PKI-DH.initial_handshake_resend_period</name>
                    <value>250</value>
                </property>
                <property>
                    <name>dds.sec.auth.builtin.PKI-DH.handshake_resend_period_gain</name>
                    <value>1.5</value>
                </property>
            </properties>
        </propertiesPolicy>
    </rtps>
</participant>

以上内容概述了如何配置和使用 DDS 中的 PKI 身份验证插件及其握手设置。这对于实现分布式系统中的安全通信非常重要。


内容由零声教学AI助手提供,问题来源于学员提问

本站部分文章来源于网络,版权归原作者所有,如有侵权请联系站长删除。
转载请注明出处:https://sdn.0voice.com/?id=7459

分享:
扫描分享到社交APP
上一篇
下一篇
发表列表
游客 游客
此处应有掌声~
评论列表

还没有评论,快来说点什么吧~

联系我们

在线咨询: 点击这里给我发消息

微信号:3007537140

上班时间: 10:30-22:30

关注我们
x

注册

已经有帐号?