zenoh 用户密码支持

zenoh 支持基本的用户密码认证,client以及peer 支持与router 以及peer 进行认证

配置说明

  • 参考配置 client
{
  /// The node's mode (router, peer or client)
  mode: "client",
  transport: {
    auth: {
      /// The configuration of authentication.
      /// A password implies a username is required.
      usrpwd: {
        user: "clientusername",
        password: "clientpassword",
      },
    },
  },
}

router 配置,同时支持基于目录的配置

{
  /// The node's mode (router, peer or client)
  mode: "router",
  transport: {
    auth: {
      /// The configuration of authentication.
      usrpwd: {
        user: "routerusername",
        password: "routerpassword",
        /// The path to a file containing the user password dictionary
        dictionary_file: "credentials.txt",
      },
    },
  },
}

用户密码格式

上边说了可以基于文件的格式,支持基于明文的,以及基于sha256的

明文格式

clientusername:clientpassword

sha256 格式

clientusername:92df0d4f39c218607e3200bf93ccac87a80cb910e811d84b286bebe0a8860724

说明

如果为了安全简单的基于用户密码的就可以了,同时zenoh还支持访问控制,推荐结合起来,可以确保系统的安全

参考资料

https://zenoh.io/docs/manual/user-password/

posted on   荣锋亮  阅读(11)  评论(0编辑  收藏  举报

相关博文:
阅读排行:
· 全程不用写代码,我用AI程序员写了一个飞机大战
· DeepSeek 开源周回顾「GitHub 热点速览」
· 记一次.NET内存居高不下排查解决与启示
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· .NET10 - 预览版1新功能体验(一)
历史上的今天:
2020-12-16 golang 几个面向应用的通用存储层处理包
2020-12-16 soheilhy/cmux 网络端口复用服务
2020-12-16 使用go_reuseport 提升socket 应用性能
2020-12-16 dkron cloud native 的分布式cron服务
2020-12-16 gjson 更好用的golang json 处理包.
2019-12-16 pcp 基本使用
2018-12-16 ipfs docker 运行试用

导航

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5
点击右上角即可分享
微信分享提示