plgd-dev / go-coap

Implementation of CoAP Server & Client in Go

Home Page:https://coap.technology

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Little endian ETag?

JosefWN opened this issue · comments

According to RFC7252:

All multi-byte integers in this protocol are interpreted in network byte order.

... but it seems GetETag returns a little endian checksum, is this intentional?

binary.LittleEndian.PutUint64(b, c64.Sum64())

That seems really suspicious indeed.

@jkralik: any reason why this is little endian while everything else is big endian?

Yes this is a bug.

Thanks for the catch @JosefWN !