CyberChef icon indicating copy to clipboard operation
CyberChef copied to clipboard

Bug report: fields of a protobuf are automatically sorted

Open fejesjoco opened this issue 2 years ago • 0 comments

Describe the bug I wanted to investigate a problem about the ordering of fields inside a protobuf. I thought that the ordering is wrong, but CyberChef displayed them in order. Then I decoded the protobuf myself with the pen-and-paper method and noticed that the ordering was indeed wrong. CyberChef silently reordered my message. I believe this is a bug because it corrupted the true nature of my binary data.

To Reproduce Steps to reproduce the behaviour or a link to the recipe / input used to cause the bug:

https://gchq.github.io/CyberChef/#recipe=From_Binary('Space',8)Protobuf_Decode('',false,false)&input=MDAwMTAwMDAgMDAwMDAwMDAgMDAwMDEwMDAgMDAwMDAwMDA

Expected behaviour It should display: { 2: 0, 1: 0 }

Screenshots It actually displays: { 1: 0, 2: 0 }

Desktop (if relevant, please complete the following information): Shouldn't be relevant.

Additional context N/A

fejesjoco avatar May 10 '22 21:05 fejesjoco