-
Notifications
You must be signed in to change notification settings - Fork 68
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
[Masternode] Offline signing endpoints #526
base: release/1.1.0.0
Are you sure you want to change the base?
Conversation
994875c
to
2a11b18
Compare
2a11b18
to
db60245
Compare
Hi Rowan, what was the requirement for this? (Looks good though) |
Nothing formal AFAIK, just thought it might be more useful to split the method up this way to enable an offline collateral address to join. |
@@ -92,16 +72,76 @@ public async Task<PubKey> JoinFederationAsync(JoinFederationRequestModel request | |||
throw new Exception($"The call to sign the join federation request failed: '{err.Message}'."); | |||
} | |||
|
|||
if (!VerifyCollateralSignature(joinRequest)) |
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.
You check this inside BroadcastSignedJoinRequestAsync
too - as that method gets called in two places it makes sense to keep the if
inside it only
/// <summary> | ||
/// Called by a miner wanting to join the federation. | ||
/// </summary> | ||
/// <param name="request">See <see cref="JoinFederationRequestModel"></see>.</param> |
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.
Copy pasted?
/// <summary> | ||
/// Called by a miner wanting to join the federation. | ||
/// </summary> | ||
/// <param name="request">See <see cref="JoinFederationRequestModel"></see>.</param> |
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.
JoinFederationRequestWithSignature
?
Add two new endpoints
Add verification of the collateral signature