Skip to content

fabricx: PP deployment tx hardcodes NsVersion 0 — redeploy rejected once the namespace policy was ever updated #2256

Description

@tinystone007

Summary

token/services/network/fabricx/tms/deployer.go (createPublicParametersTx) builds the public-parameters deployment transaction with a hardcoded NsVersion: 0. Verified present on main as of 2026-08-18.

Effect

On a chain whose token namespace endorsement policy has been updated at least once (namespace version ≥ 1, e.g. after adding a second endorsing organization via fxconfig namespace update), the deployment transaction is invalidated by the committer. This blocks the natural governance sequence "add an org to the endorsement policy, then rotate auditor keys in the public parameters" — the PP redeploy triggered by the endorser's Init can never commit.

Reproduction (live, Fabric-X 4-party network)

  1. fxconfig namespace update the token namespace policy (version 0 → 1).
  2. Change the local PP file (e.g. tokengen update adding an auditor) and trigger the endorser's Init → the deployment tx fails finality as invalid.
  3. Hand-crafting the byte-identical transaction with ns_version set to the actual value (1) and submitting it through fxconfig endorse/submit commits fine, confirming the hardcoded field is the only problem.

Suggested fix

Query the namespace's current version before building the deployment transaction and set NsVersion accordingly.

Related: pp/versionkeeper.go has a sibling issue (endorser restart after a PP update — filed separately).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions