diff --git a/utils/endian.go b/utils/endian.go index 8f1c76f..b1fcbed 100644 --- a/utils/endian.go +++ b/utils/endian.go @@ -4,7 +4,7 @@ import "encoding/binary" func EncodeEndian(value uint64, length int) []byte { byteSlice := make([]byte, length) - binary.LittleEndian.PutUint64(byteSlice, value) + binary.BigEndian.PutUint64(byteSlice, value) return byteSlice } @@ -12,5 +12,5 @@ func DecodeEndian(byteSlice []byte) uint64 { buffer := make([]byte, 8) copy(buffer, byteSlice) - return binary.LittleEndian.Uint64(buffer) + return binary.BigEndian.Uint64(buffer) }