-
Notifications
You must be signed in to change notification settings - Fork 217
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
Additional tweaks with regards to static address construction via the API #2318
Additional tweaks with regards to static address construction via the API #2318
Conversation
3b00583
to
4c4c963
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Left some suggestions. Very fond of infographic you included!
…onKey' The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code.
- give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group
7462fb4
to
5c8cabe
Compare
bors r+ |
2318: Additional tweaks with regards to static address construction via the API r=KtorZ a=KtorZ # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> ADP-461 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - 9b362af 📍 **return non-extended public key (without chain code) as 'ApiVerificationKey'** The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code. - 3b00583 📍 **revise API documentation regarding address construction from script** - give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group # Comments <!-- Additional comments or screenshots to attach if any --> TODO: use public key in script construction instead of hashes, and do the hashing internally. <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: KtorZ <[email protected]>
@@ -998,23 +999,19 @@ spec = describe "SHELLEY_WALLETS" $ do | |||
matrix = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Idea for integration test:
- create empty shelley wallet that has {walletId}
- let paymentKey =
GET /wallets/{walletId}/keys/utxo_external/0
- let stakeKey =
GET /wallets/{walletId}/keys/mutable_account/0
- Construct address:
POST /addresses
{payment: ${paymentKey}, stake: ${stakeKey}}
- verify that this address is first address on {walletId}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds like it would work 👍
Build failed:
|
bors r+ |
2318: Additional tweaks with regards to static address construction via the API r=Anviking a=KtorZ # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> ADP-461 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - 9b362af 📍 **return non-extended public key (without chain code) as 'ApiVerificationKey'** The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code. - 3b00583 📍 **revise API documentation regarding address construction from script** - give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group # Comments <!-- Additional comments or screenshots to attach if any --> TODO: use public key in script construction instead of hashes, and do the hashing internally. <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: KtorZ <[email protected]>
Build failed:
|
bors retry |
2318: Additional tweaks with regards to static address construction via the API r=Anviking a=KtorZ # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> ADP-461 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - 9b362af 📍 **return non-extended public key (without chain code) as 'ApiVerificationKey'** The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code. - 3b00583 📍 **revise API documentation regarding address construction from script** - give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group # Comments <!-- Additional comments or screenshots to attach if any --> TODO: use public key in script construction instead of hashes, and do the hashing internally. <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: KtorZ <[email protected]>
Build failed:
|
bors retry |
2318: Additional tweaks with regards to static address construction via the API r=Anviking a=KtorZ # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> ADP-461 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - 9b362af 📍 **return non-extended public key (without chain code) as 'ApiVerificationKey'** The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code. - 3b00583 📍 **revise API documentation regarding address construction from script** - give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group # Comments <!-- Additional comments or screenshots to attach if any --> TODO: use public key in script construction instead of hashes, and do the hashing internally. <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: KtorZ <[email protected]>
Build failed:
|
bors retry |
2318: Additional tweaks with regards to static address construction via the API r=Anviking a=KtorZ # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> ADP-461 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - 9b362af 📍 **return non-extended public key (without chain code) as 'ApiVerificationKey'** The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code. - 3b00583 📍 **revise API documentation regarding address construction from script** - give more details about how scripts are constructed - move description around so they show up correctly in ReDoc. - move address endpoints into the 'Address' group and remove the 'Utils' group # Comments <!-- Additional comments or screenshots to attach if any --> TODO: use public key in script construction instead of hashes, and do the hashing internally. <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: KtorZ <[email protected]>
Build failed:
|
bors retry please. |
Build succeeded: |
Issue Number
ADP-461
Overview
9b362af
📍 return non-extended public key (without chain code) as 'ApiVerificationKey'
The chain code is useless because there's no further derivation that can happen at this stage. Plus, it does make it harder to re-use the output from the 'getWalletKey' endpoint into others because one needs to decode the bech32 string and strip away the chain code.
3b00583
📍 revise API documentation regarding address construction from script
Comments
TODO: use public key in script construction instead of hashes, and do the hashing internally.