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

[tools] support key rotation offer capability in libra-txs #208

Merged
merged 12 commits into from
Mar 12, 2024

Conversation

0xzoz
Copy link
Contributor

@0xzoz 0xzoz commented Mar 12, 2024

Want to allow delegating key rotation to another user, e.g. alice delegates key rotation to bob, such that bob can rotate alice's key

  • add test for key rotation cli
  • add cli command to offer rotation capability to another user
  • add test for offer rotation capability cli
  • Add test to validate that bob indeed can rotatte a key for alice
  • add cli command to revoke rotation capability
  • add test to ensure that bob no longer can rotate alice's key
  • enhance key-rotation cli to supply target address to rotate keys for, e.g. bob can specify alice's address to rotate keys on her behalf
    New cli to offer/revoke rotation capability:
libra-txs  user rotation-capability --help
Offer rotation capability to a delegate address. A delegate address now can rotate a key for this account owner

Usage: libra-txs user rotation-capability --action <ACTION> --delegate-address <DELEGATE_ADDRESS>

Options:
  -a, --action <ACTION>                      
  -d, --delegate-address <DELEGATE_ADDRESS>  
  -h, --help

updated rotate-key cli:

libra-txs  user  rotate-key --help
Usage: libra-txs user rotate-key [OPTIONS]

Options:
  -n, --new-private-key <NEW_PRIVATE_KEY>
          The new authkey to be used
  -a, --account-address <ACCOUNT_ADDRESS>
          Account address for which rotation is done. It can be different from caller's address if rotation capability has been granted to the caller. Do not specify this if you want to rotate your own key

Question: I have a few tests failed. Is it expected? It doesn't look like it is related ot my changes by who knows?
failures:
smoke_upgrade_mainnet_compatible_libra
smoke_upgrade_mainnet_compatible_multiple
smoke_upgrade_mainnet_force_libra
smoke_upgrade_mainnet_force_multiple

@0xzoz 0xzoz merged commit 4035750 into main Mar 12, 2024
24 checks passed
@0o-de-lally 0o-de-lally deleted the cli-key-rotation branch March 15, 2024 15:06
0o-de-lally pushed a commit that referenced this pull request Aug 8, 2024
Co-authored-by: coin1111 <celticsnow123@gmail.com>
0o-de-lally pushed a commit that referenced this pull request Aug 8, 2024
Co-authored-by: coin1111 <celticsnow123@gmail.com>
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 16, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 16, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 16, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 16, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 16, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit to 0o-de-lally/libra-framework that referenced this pull request Aug 17, 2024
0o-de-lally pushed a commit that referenced this pull request Aug 17, 2024
Co-authored-by: coin1111 <celticsnow123@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants