You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And, we could not believe messages from network, so this sender can not be treated as a cache. We have to calculate it from signature.
sender in SignedTransaction
The sender in SignedTransaction is redundant, too.
Because we can recover public key from UnverifiedTransaction.signature, then we can calculate address (sender) from public key.
But, this sender can be used as a cache (we trust the micro-services in the same node), so we could keep this sender.
yeah.
I notice some codes like signature.recover(&message.crypt_hash()) and pubkey_to_address(&pubkey) == sender. we check the sender from the signature, i'm not sure why do we need it at the beginning.
Both
sender
andsignature
inVote
:https://github.com/cryptape/cita-proto/blob/b1409605bd4f7cf9b857d43fcad1b44b435df3a6/consensus.proto#L23-L27
And
sender
can be recovered fromsignature
.Ref:
The text was updated successfully, but these errors were encountered: