Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport pallet-identity double encoding on signature payload fix into crates io release 1.7.0 #4702

Closed

Commits on Jun 5, 2024

  1. [Identity] Remove double encoding username signature payload (#4646)

    In order to receive a username in `pallet-identity`, users have to,
    among other things, provide a signature of the desired username. Right
    now, there is an [extra encoding
    step](https://github.com/paritytech/polkadot-sdk/blob/4ab078d6754147ce731523292dd1882f8a7b5775/substrate/frame/identity/src/lib.rs#L1119)
    when generating the payload to sign.
    
    Encoding a `Vec` adds extra bytes related to the length, which changes
    the payload. This is unnecessary and confusing as users expect the
    payload to sign to be just the username bytes. This PR fixes this issue
    by validating the signature directly against the username bytes.
    
    ---------
    
    Signed-off-by: georgepisaltu <[email protected]>
    georgepisaltu committed Jun 5, 2024
    Configuration menu
    Copy the full SHA
    49edb86 View commit details
    Browse the repository at this point in the history
  2. Set pallet-identity version to v29.0.2

    Signed-off-by: georgepisaltu <[email protected]>
    georgepisaltu committed Jun 5, 2024
    Configuration menu
    Copy the full SHA
    06508f2 View commit details
    Browse the repository at this point in the history
  3. Fix bench compilation warning

    Signed-off-by: georgepisaltu <[email protected]>
    georgepisaltu committed Jun 5, 2024
    Configuration menu
    Copy the full SHA
    4ad27f4 View commit details
    Browse the repository at this point in the history
  4. Bump identity version in deps

    Signed-off-by: georgepisaltu <[email protected]>
    georgepisaltu committed Jun 5, 2024
    Configuration menu
    Copy the full SHA
    b551625 View commit details
    Browse the repository at this point in the history