0

I am doing reverse engineering on some network protocol. It is client to server communication and I am pretty stuck with identifying checksum (or CRC) algorithm used in packet structure.

I tried reveng util but without any result (so maybe it is not CRC). Also I lookout on standard CRCs algorithm online but nothing fits my samples.

Here are some examples of packets:

client to server:

66  01 00 01 fa 00 00 00  b7 33  00 00 fc 00 00 00  99 
66  01 00 03 fa 00 00 00  c7 d9  00 00 fd 00 00 00  99
66  01 00 03 fa 00 00 80  d1 c2  08  99
66  01 00 03 fa 00 00 71  46 42  00 00 05 00 00 00 ab 55 52 5c 5b 50 51 55 55 55 54 73  99
66  01 00 03 fa 00 00 04  45 a2  00 00 6b 00 00 00 ab 55 40 5c 49 3e 47 1d 55 b4 55 55 55 55 55 55 55 55 55 55 55 55 55 55 45 bb  99 

server to client:

66  01 fa 00 00 01 00 00  91 57  0a  99
66  01 fa 00 00 03 00 00  8a bb  0a  99
66  01 fa 00 00 01 00 96  9d 37  00 00 00 00 00 00 ab 55 55 55 ab  99
66  01 fa 00 00 03 00 7f  61 68  00 00 44 00 00 00 ab 55 51 54 56 11 54 55 1e  99 
66  01 fa 00 00 03 00 7a  70 dd  08 99

I think checksum is 16-bit number begin on 9th byte. Also, I believe that the first and last bytes are not significant to count the checksum algorithm (start and stop constat).

I can provide more samples if it helps.

I will be grateful for any help or advice from you.

0

Finally, I figure it out by myself.

All bytes, including start and stop byte, must be passed to CRC algorithm. Important part is CRC bytes must be substituted with zero.

For example

66 01 fa 00 00 01 00 00 00 00 0a 99

get result 0x9157 in standard CRC-16/TELEDISK algorithm.

I found very useful this online CRC calculator: https://crccalc.com/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.