-
Notifications
You must be signed in to change notification settings - Fork 106
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
Update creator node middleware for new eth contracts (take 2) #897
Conversation
…o dm-cnode-middleware-new-eth-contracts-2
This reverts commit 46c39e5.
…o dm-cnode-middleware-new-eth-contracts-2
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.
net new changes (libs v bump) are fine, one question on old code but doesn't block merge
const walletAddress = EthereumWallet.fromPrivateKey(privateKeyBuffer).getAddressString() | ||
if (walletAddress !== config.get('delegateOwnerWallet').toLowerCase()) { | ||
throw new Error('Invalid delegatePrivateKey/delegateOwnerWallet pair') | ||
} |
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.
looks good, curious why not use web3.eth.accounts.privateKeyToAccount
(https://web3js.readthedocs.io/en/v1.3.0/web3-eth-accounts.html#privatekeytoaccount)
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.
this is how identity relay does wallet extraction, so just used the same code honestly
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.
ye makes sense. clearly it works
Description
Built off #896. Needed to bump libs to v1.0.0 in the same PR as those changes because those ETH contract libs wrappers do not exist in our current libs version.
For al other context see old PR #896