D
D
dfhkjhg2020-11-12 02:03:07
Node.js
dfhkjhg, 2020-11-12 02:03:07

How to decode binary message webscoket?

Here is an example message:

00000000: 1ac5 090a c209 0a0a 4761 6d65 4d61 726b
........
00000002: 2F31 2F31 2431 4039 3012 1631 7C35 3831 /1/[email protected]|581
00000003: 3637 3936 7C31 7C2F 312F 3124 3040 6796 | 1 |/1.1/1 $ 0
00000004: 3012 1731 7C35 3831 3637 3936 7C31 7C2F 0..1 | 5816796 | 1 |/
00000005: 312C 3136 2F31 2430 4030 1216 317c 3538 1.16/ 1 $ 0..1 | 58
00000006: 3136 3739 367c 2F32 2F31 2431 4031 16796 | |/2/[email protected]
00000007: 3330 1216 317c 3538 3136 3739 367c 317c 30..1|5816796|1|
00000008: 2f32 2c31 2f31 2430 4030 1217 317c 3538
/2.1/[email protected]|58
0000000a : 3040 3012 1631 7c35 3831 3637
3936 7C34 0 322F 3124 3140 816796 | 4 |/2/1 $ [email protected]
0000000d: 3135 3012 1531 7c35 3831 3637 3936 7c35 150..1 | 5816796 | 5
0000000E: 7C2F 302F 3124 3140 1216 317C 3538 |/0/10/1 $ [email protected] 50. .1|58
0000000f: 3136 3739 367c 357c 2f31 2f31 2431 4031 16796|5|/1/[email protected]
00000010: 3230 1216 317c 3538 3136 3739 367c 357c 20.1|
00000011: 2F32 2F31 2431 4031 3630 1214 317c 3538
/2/1 [email protected]|58 000012: 3136 3739 367c 367c 2f31 2F31 2430 4030 16796 | 6 |/1/1 $ 0
00000013: 1214 317c 3538 3136 376 376 376 376 376 376 376 3 367c 367c 2f32 ..1|5816796|6|/2
00000014: 2f31 2430 4030 1214 317c 3538 3136 3739
/[email protected]|581679
00000016: 3538 3136 3739 367c 397c 2f32 2f31 2430 5816796 | 9 | / 2/1 $ 0
00000017 4030 1216 3538 3136 3739 317c 367c 3136 @ 0..1 | 5816796 | 16
00000018: 7c2f 302f 3124 3140 3730 1216 3538 317c | / 0/1 $ 1 @70..1 | 58
000019: 3136 3739 367c 3234 347c 2f31 2F31 2430 16796 | 244 |/1/1/1 $ 0
0000001a: 4030 1216 317c 3538 3136 3739 367C 3234 @0..1 | 5816796 | 24
0000001 : 347c 2F32 2F31 2430 4030 1216 317C 3538 4 | /2/1 [email protected] | 58
0000001c: 3136 3739 367c 3234 3574 357C 2F31 2430 16796 | 245 |/1/1/ 1 $ 0
00000016: 4030 1216 317c 3538 3136 3136 376 376 376 376 376 376 376 376 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3136 3AP 367c 3234 @0..1|5816796|24
0000001e: 357c 2f32 2f31 2430 4030 1217 317c 3538 5 | /2/[email protected] | 58
0000001f: 3136 3739 3234 367c 367c 312f 312f 3124 16796 | 246 | 1/1/1 $
00,000,020 3040 3012 1831 7c35 3831 3637 3936 7C32 [email protected] | 5816796 | 2
00000021: 3436 7C31 362F 312F 3124 3040 3012 1731 46 | 16/1/1 $ [email protected]
000022: 7c35 3831 3637 3936 7C32 3436 7C31 2F31 2F31 2F31 2F316799 | 246 | 1/2
00000023: 2f31 2430 4030 1218 317c 3538 3136 3736 3739
/1 [email protected]@0..1|581679 000024: 367c 3234 367c 3136 2F32 2F31 2430 403 | 16/2/1 $ 0
000025: 1217: 1217 317c 3538 3136 3739 367c 3234 377c ..1|5816796|247|
00000026: 312f 312f 3124 3040 3012 1731 7c35 3831 1/1/[email protected]|
581
00000028: 4030 1217 317c 3538 3136 3739 367c 3234 @0..1 | 5816796 | 24 00000029: 377c 312F 322F 3124 3040 3012 1731 7C35 7 | 1/2/1
$ 0
3437 7c32 2f32 2f31 816796|247|2/2/1
0000002b: 2430 4030 1216 317c 3538 3136 3739 367c [email protected]|5816796|
0000002c: 3234 387c 2f31 2f31 2430 4030 1216 317c 248|/1/[email protected]|
0000002d: 3538 3136 3739 367c 3234 387c 2f32 2f31 5816796|248|/2/1
0000002e: 2430 4030 1219 317c 3538 3136 3739 367c [email protected]||
0000002f: 3236 337c 312c 312f 312f 3124 3040 3012 263|1.1/1/[email protected]
00000030: 1a31 7c35 3831 3637 3936 7c32 3633 7c31 .1|5816796|263|
1
00000032: 3831 3637 3936 7C32 3633 7C31 2C31 2F32 816796 | 263 | 1.1 /2
00000033: 2F31 2430 4030 121A 317C 3538 3136 3739 /
1 [email protected] 00000034) |263|1.16/2/1$0
00000035: 4030 121b 317c 3538 3136 3739 367c 3330 @0..1|5816796|30
00000036: 317c 372e 352f 312c 312f 3131.10| @0. 00000037: 1c31 7c35 3831 3637 3936 7c33
3031 7c37 .1 | 5816796 | 7
00000038: 2e35 2F31 2C31 3624 3040 3012 1b31 .5/1,16/1 $ 0
7c37 2e35 | 5816796 | 301 | 7.5
0000003A: 2F32 2C31 2F31 2F31 2430 4030 121c 317c 3538 / 2,1/1 [email protected]@[email protected]
0000003b: 3136 3739 367c 3330 317c 372E 352F 322C 16796 | 301 | 7.5/2, 2, 7.5/2, 2, 2, 7.5/2, 2, 7.5/2
0000003C: 3136 2F31 2430 4030 1218 317C 3538 3136 16/1
$ 0
367c 3336 @0..1 | 5816796 | 36
0000003F: 327c 2F31 2C31 362F 3124 3040 3012 1831 2 | /1,16/16/[email protected]
000040: 7c35 3831 3637 3936 7C33 3632 7C2F 322C | 5816796 | 362 | /2,
00000041: 312F 3124 3040 3012 1931 7c35 3831 3637 1/1 $ [email protected] | 58167
000042: 3936 7C33 3632 7C2F 322C 3136 2F31 2430 96 |
/2.16/1 $ 0 3538 3136 3739 367c 3336 @0..1|5816796|36
00000044: 337c 3130 2f31 2f31 2430 4030 1217 317c 3|10/1/[email protected]|
00000045: 3538 3136 3739 367c 3336 337c 352f 312f 5816796|363|5/1/
00000046: 3124 3040 3012 1831 7c35 3831 3637 3936 [email protected]|
5816796
00000048: 1731 7c35 3831 3637 3936 7C33 3633 7C35 .1 | 5816796 | 363 | 5
00000049: 2F32 2F31 2430 4030 1216 317C 3538 3136 /2/1 [email protected]_5816
0000004A: 3739 367C 3934 327C 2F31 2F 796|942|/1/[email protected]
0000004b: 1216 317c 3538 3136 3739 367c 3934 327c ..1|5816796|942|
0000004c: 2f32 2f31 2430 4030 /2/[email protected]

How can it be converted to normal text?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey P, 2020-11-12
@ruddy22

Buffer.from(<your_message>).toString('utf-8') // or latin-1

for detailed info here

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question