Update transaction_signing.go

This commit is contained in:
majtte 2026-01-19 14:58:38 +01:00 committed by GitHub
parent d0af257aa2
commit 405c2f9943
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -392,21 +392,11 @@ func (s EIP155Signer) Hash(tx *Transaction) common.Hash {
// replay-protected. // replay-protected.
type HomesteadSigner struct{ FrontierSigner } type HomesteadSigner struct{ FrontierSigner }
func (hs HomesteadSigner) ChainID() *big.Int {
return nil
}
func (hs HomesteadSigner) Equal(s2 Signer) bool { func (hs HomesteadSigner) Equal(s2 Signer) bool {
_, ok := s2.(HomesteadSigner) _, ok := s2.(HomesteadSigner)
return ok return ok
} }
// SignatureValues returns signature values. This signature
// needs to be in the [R || S || V] format where V is 0 or 1.
func (hs HomesteadSigner) SignatureValues(tx *Transaction, sig []byte) (r, s, v *big.Int, err error) {
return hs.FrontierSigner.SignatureValues(tx, sig)
}
func (hs HomesteadSigner) Sender(tx *Transaction) (common.Address, error) { func (hs HomesteadSigner) Sender(tx *Transaction) (common.Address, error) {
if tx.Type() != LegacyTxType { if tx.Type() != LegacyTxType {
return common.Address{}, ErrTxTypeNotSupported return common.Address{}, ErrTxTypeNotSupported