Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Sign in
issue
issue
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 9
    • Issues 9
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar

新注册的用户请输入邮箱并保存,随后登录邮箱激活账号。后续可直接使用邮箱登录!

  • chainmaker
  • issueissue
  • Issues
  • #963

Closed
Open
Opened Dec 22, 2023 by zhang yong@zhangy

bc.yml 配置改进意见

版本

  • 长安链版本:2030200

问题

由于创世区块依赖于bc.yml,而bc.yml的TrustRoots只能填写组织CA证书路径,将导致以下两个场景无法正常使用:

  1. 不支持证书更新后新增节点。当组织CA证书更新后,新增节点(node1)bc.yml的TrustRoots将指向新的组织CA证书路径,在节点(node1)启动后,其通过bc.yml构建的创世区块将与其它节点的创世区块存在差异,无法进行相关账本的同步。
  2. 不支持删除组织后新增节点。当组织(org1)从链上移除后,若删除组织(org1)的相关证书材料,那么在后续进行新增节点时,在读取bc.yml过程中将读不到CA证书,直接启动失败。

改进意见

通过动态判断bc.yml中TrustRoots的Root字段,若是合法路径则去对应路径读CA证书文件内容;若是CA证书内容,则直接解析证书。

在chainconf.go:112加入以上判断,将兼容现有版本的使用: image

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: chainmaker/issue#963

Copyright © 2021 ChainMaker Org. All Rights Reserved. 长安链 版权所有。