Skip to content

Commit

Permalink
Add SighashTypeID
Browse files Browse the repository at this point in the history
  • Loading branch information
gagliardetto committed Aug 29, 2021
1 parent 5b7d020 commit 81bf4e8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sighash.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ func Sighash(namespace string, name string) []byte {
return sum[0:8]
}

func SighashTypeID(namespace string, name string) TypeID {
return TypeIDFromBytes(Sighash(namespace, name))
}

// Namespace for calculating state instruction sighash signatures.
const SIGHASH_STATE_NAMESPACE string = "state"

Expand Down

0 comments on commit 81bf4e8

Please sign in to comment.