[*] Binary protection state of libevent_extra-2.1.so.6.0.2
Partial RELRO No Canary found NX disabled DSO No RPATH No RUNPATH No Symbols
[*] Function printf tear down of libevent_extra-2.1.so.6.0.2
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/lib/libevent_extra-2.1.so.6.0.2 @ 0xc848 */
| #include <stdint.h>
|
; (fcn) fcn.0000c848 () | void fcn_0000c848 (int32_t arg_1h, int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_94h;
| r0 = arg1;
| r1 = arg2;
0x0000c848 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0000c84c ldr r6, [pc, 0x544] | r6 = *(0xcd94);
0x0000c850 mov sb, r3 | sb = r3;
0x0000c854 ldr r3, [r0, 0x70] | r3 = *((r0 + 0x70));
0x0000c858 mov r4, r0 | r4 = r0;
0x0000c85c ldr r0, [r3, 0xec] | r0 = *((r3 + 0xec));
0x0000c860 add r6, pc, r6 | r6 = pc + r6;
0x0000c864 cmp r0, 0 |
0x0000c868 sub sp, sp, 0x94 |
0x0000c86c mov r5, r1 | r5 = r1;
0x0000c870 mov r7, r2 | r7 = r2;
| if (r0 == 0) {
0x0000c874 beq 0xc8d0 | goto label_6;
| }
0x0000c878 ldr r3, [pc, 0x51c] |
0x0000c87c ldr r3, [r6, r3] | r3 = *((r6 + r3));
0x0000c880 ldr r3, [r3] | r3 = *(0xcd98);
0x0000c884 cmp r3, 0 |
| if (r3 == 0) {
0x0000c888 beq 0xc8d0 | goto label_6;
| }
0x0000c88c bl 0x54c0 | r0 = loc_imp_evthread_is_debug_lock_held_ ();
0x0000c890 cmp r0, 0 |
| if (r0 != 0) {
0x0000c894 bne 0xc8d0 | goto label_6;
| }
0x0000c898 ldr r3, [pc, 0x500] |
0x0000c89c ldr r2, [pc, 0x500] | r2 = *(0xcda0);
0x0000c8a0 add r3, pc, r3 | r3 = pc + r3;
0x0000c8a4 add r3, r3, 0x38c | r3 = 0xd128;
0x0000c8a8 str r3, [sp, 4] | var_4h = r3;
0x0000c8ac ldr r3, [pc, 0x4f4] | r3 = *(0xcda4);
0x0000c8b0 ldr r1, [pc, 0x4f4] | r1 = *(0xcda8);
0x0000c8b4 add r3, pc, r3 | r3 = pc + r3;
0x0000c8b8 str r3, [sp] | *(sp) = r3;
0x0000c8bc add r2, pc, r2 | r2 = pc + r2;
0x0000c8c0 mov r3, 0x36c | r3 = 0x36c;
0x0000c8c4 add r1, pc, r1 | r1 = pc + r1;
| do {
| label_0:
0x0000c8c8 ldr r0, [pc, 0x4e0] | r0 = *(0xcdac);
0x0000c8cc bl 0x55bc | loc_imp_event_errx ();
| label_6:
0x0000c8d0 ldr r2, [r4, 0x74] | r2 = *((r4 + 0x74));
0x0000c8d4 cmp r2, 0 |
| if (r2 != 0) {
0x0000c8d8 beq 0xc8e8 |
0x0000c8dc ldr r3, [r2] | r3 = *(r2);
0x0000c8e0 cmp r3, r4 |
| if (r3 == r4) {
0x0000c8e4 beq 0xc91c | goto label_7;
| }
| }
0x0000c8e8 ldr r3, [pc, 0x4c4] |
0x0000c8ec ldr r2, [pc, 0x4c4] | r2 = *(0xcdb4);
0x0000c8f0 add r3, pc, r3 | r3 = pc + r3;
0x0000c8f4 add r3, r3, 0x38c | r3 = 0xd13c;
0x0000c8f8 str r3, [sp, 4] | var_4h = r3;
0x0000c8fc ldr r3, [pc, 0x4b8] | r3 = *(0xcdb8);
0x0000c900 ldr r1, [pc, 0x4b8] | r1 = *(0xcdbc);
0x0000c904 add r3, pc, r3 | r3 = pc + r3;
0x0000c908 str r3, [sp] | *(sp) = r3;
0x0000c90c add r2, pc, r2 | r2 = pc + r2;
0x0000c910 ldr r3, [pc, 0x4ac] | r3 = *(0xcdc0);
0x0000c914 add r1, pc, r1 | r1 = pc + r1;
0x0000c918 b 0xc8c8 |
| } while (1);
| label_7:
0x0000c91c ldr r3, [pc, 0x4a4] | r3 = *(0xcdc4);
0x0000c920 clz r8, sb | r8 &= sb;
0x0000c924 lsr r8, r8, 5 | r8 >>= 5;
0x0000c928 and r3, r3, r5 | r3 &= r5;
0x0000c92c cmp r3, 0 |
| if (r3 == 0) {
0x0000c930 movne r8, 1 | r8 = 1;
| }
0x0000c934 cmp r8, 0 |
| if (r8 == 0) {
0x0000c938 bne 0xc948 |
0x0000c93c ldrb r3, [sb, 4] | r3 = *((sb + 4));
0x0000c940 tst r3, 1 |
| if ((r3 & 1) != 0) {
0x0000c944 bne 0xcd64 | goto label_8;
| }
| }
0x0000c948 ands r8, r5, 0x200 | r8 = r5 & 0x200;
| if (r8 != r5) {
0x0000c94c bne 0xcbd0 | goto label_9;
| }
0x0000c950 ands r5, r5, 0xf | r5 &= 0xf;
| if (r5 == r5) {
0x0000c954 beq 0xca34 | goto label_10;
| }
0x0000c958 sub r5, r5, 1 | r5--;
0x0000c95c lsl r5, r5, 0x10 | r5 <<= 0x10;
0x0000c960 lsr r5, r5, 0x10 | r5 >>= 0x10;
0x0000c964 cmp r5, 4 |
| if (r5 > 4) {
0x0000c968 bhi 0xcbd8 | goto label_11;
| }
0x0000c96c ldr r3, [pc, 0x458] | r3 = *(0xcdc8);
0x0000c970 add r3, pc, r3 | r3 = pc + r3;
0x0000c974 add r5, r3, r5, lsl 2 | r5 = r3 + (r5 << 2);
0x0000c978 ldr sb, [r5, 0x39c] | sb = *((r5 + 0x39c));
0x0000c97c cmp sb, 2 |
| if (sb == 2) {
0x0000c980 beq 0xcb94 | goto label_12;
| }
| if (sb < 2) {
0x0000c984 blt 0xc994 | goto label_2;
| }
0x0000c988 sub r3, sb, 4 | r3 = sb - 4;
0x0000c98c cmp r3, 1 |
| if (r3 < 1) {
0x0000c990 bls 0xca50 | goto label_13;
| }
| do {
| label_2:
0x0000c994 ldr r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x0000c998 ldr r1, [r3, 0x118] | r1 = *((r3 + 0x118));
0x0000c99c cmp r2, r1 |
| if (r2 != r1) {
0x0000c9a0 moveq r2, 0 | r2 = 0;
| }
| if (r2 != r1) {
0x0000c9a4 streq r2, [r3, 0x118] | *((r3 + 0x118)) = r2;
| }
0x0000c9a8 ldr r0, [r4, 0x1c] | r0 = *((r4 + 0x1c));
0x0000c9ac bl 0xae74 | fcn_0000ae74 (r0);
| label_1:
0x0000c9b0 ldr r5, [r4, 0x74] | r5 = *((r4 + 0x74));
0x0000c9b4 ldr r3, [r5, 0x10] | r3 = *((r5 + 0x10));
0x0000c9b8 cmp r3, 0 |
| if (r3 == 0) {
0x0000c9bc beq 0xcc74 | goto label_4;
| }
0x0000c9c0 ldrb r3, [r4, 4] | r3 = *((r4 + 4));
0x0000c9c4 cmp r3, 0xc |
| if (r3 == 0xc) {
0x0000c9c8 beq 0xcc74 | goto label_4;
| }
0x0000c9cc ldr r8, [r5] | r8 = *(r5);
0x0000c9d0 ldr sl, [r8, 0x70] | sl = *((r8 + 0x70));
0x0000c9d4 ldr r0, [sl, 0xec] | r0 = *((sl + 0xec));
0x0000c9d8 cmp r0, 0 |
| if (r0 == 0) {
0x0000c9dc beq 0xcbe0 | goto label_14;
| }
0x0000c9e0 ldr r3, [pc, 0x3b4] |
0x0000c9e4 ldr r3, [r6, r3] | r3 = *((r6 + r3));
0x0000c9e8 ldr r3, [r3] | r3 = *(0xcd98);
0x0000c9ec cmp r3, 0 |
| if (r3 == 0) {
0x0000c9f0 beq 0xcbe0 | goto label_14;
| }
0x0000c9f4 bl 0x54c0 | r0 = loc_imp_evthread_is_debug_lock_held_ ();
0x0000c9f8 cmp r0, 0 |
| if (r0 != 0) {
0x0000c9fc bne 0xcbe0 | goto label_14;
| }
0x0000ca00 ldr r3, [pc, 0x3c8] |
0x0000ca04 ldr r2, [pc, 0x3c8] | r2 = *(0xcdd0);
0x0000ca08 add r3, pc, r3 | r3 = pc + r3;
0x0000ca0c add r3, r3, 0x3c0 | r3 = 0xd18c;
0x0000ca10 str r3, [sp, 4] | var_4h = r3;
0x0000ca14 ldr r3, [pc, 0x3bc] | r3 = *(0xcdd4);
0x0000ca18 ldr r1, [pc, 0x3bc] | r1 = *(0xcdd8);
0x0000ca1c add r3, pc, r3 | r3 = pc + r3;
0x0000ca20 str r3, [sp] | *(sp) = r3;
0x0000ca24 add r2, pc, r2 | r2 = pc + r2;
0x0000ca28 ldr r3, [pc, 0x3b0] | r3 = *(0xcddc);
0x0000ca2c add r1, pc, r1 | r1 = pc + r1;
0x0000ca30 b 0xc8c8 | goto label_0;
| label_10:
0x0000ca34 cmp sb, 0 |
| if (sb == 0) {
0x0000ca38 beq 0xcbd8 | goto label_11;
| }
0x0000ca3c ldrb r3, [sb, 4] | r3 = *((sb + 4));
0x0000ca40 tst r3, 1 |
| if ((r3 & 1) == 0) {
0x0000ca44 movne sb, 0x42 | sb = 0x42;
| }
| if ((r3 & 1) != 0) {
0x0000ca48 moveq sb, 0x46 | sb = 0x46;
| }
0x0000ca4c b 0xc994 |
| } while (1);
| label_13:
0x0000ca50 ldr r3, [r4, 0x70] | r3 = *((r4 + 0x70));
0x0000ca54 ldr r2, [r4, 0xc] | r2 = *((r4 + 0xc));
0x0000ca58 ldr r3, [r3, 0x2c] | r3 = *((r3 + 0x2c));
0x0000ca5c cmp r2, r3 |
| if (r2 >= r3) {
0x0000ca60 bge 0xc9b0 | goto label_1;
| }
0x0000ca64 mov r0, sb | r0 = sb;
0x0000ca68 bl 0x5490 | fcn_00005490 ();
0x0000ca6c ldr r2, [pc, 0x370] | r2 = *(0xcde0);
0x0000ca70 add r5, sp, 0x10 | r5 += var_10h;
0x0000ca74 mov r3, sb | r3 = sb;
0x0000ca78 add r2, pc, r2 | r2 = pc + r2;
0x0000ca7c mov r1, 0x40 | r1 = 0x40;
0x0000ca80 str r0, [sp] | *(sp) = r0;
0x0000ca84 mov r0, r5 | r0 = r5;
0x0000ca88 bl 0x50ac | loc_imp_evutil_snprintf ()
0x0000ca8c mov r1, r5 | r1 = r5;
0x0000ca90 ldr r0, [r4, 0x1c] | r0 = *((r4 + 0x1c));
0x0000ca94 bl 0x740c | fcn_0000740c (r0, r1);
0x0000ca98 ldr r3, [r4, 0x70] | r3 = *((r4 + 0x70));
0x0000ca9c ldr r5, [r4, 0x1c] | r5 = *((r4 + 0x1c));
0x0000caa0 ldr r0, [r3, 0xec] | r0 = *((r3 + 0xec));
0x0000caa4 cmp r0, 0 |
| if (r0 != 0) {
0x0000caa8 beq 0xcb00 |
0x0000caac ldr r3, [pc, 0x2e8] |
0x0000cab0 ldr r3, [r6, r3] | r3 = *((r6 + r3));
0x0000cab4 ldr r3, [r3] | r3 = *(0xcd98);
0x0000cab8 cmp r3, 0 |
| if (r3 == 0) {
0x0000cabc beq 0xcb00 | goto label_15;
| }
0x0000cac0 bl 0x54c0 | r0 = loc_imp_evthread_is_debug_lock_held_ ();
0x0000cac4 cmp r0, 0 |
| if (r0 != 0) {
0x0000cac8 bne 0xcb00 | goto label_15;
| }
0x0000cacc ldr r3, [pc, 0x314] |
0x0000cad0 ldr r2, [pc, 0x314] | r2 = *(0xcde8);
0x0000cad4 add r3, pc, r3 | r3 = pc + r3;
0x0000cad8 add r3, r3, 0x3b0 | r3 = 0xd194;
0x0000cadc str r3, [sp, 4] | var_4h = r3;
0x0000cae0 ldr r3, [pc, 0x308] | r3 = *(0xcdec);
0x0000cae4 ldr r1, [pc, 0x308] | r1 = *(0xcdf0);
0x0000cae8 add r3, pc, r3 | r3 = pc + r3;
0x0000caec str r3, [sp] | *(sp) = r3;
0x0000caf0 add r2, pc, r2 | r2 = pc + r2;
0x0000caf4 ldr r3, [pc, 0x2fc] | r3 = *(0xcdf4);
0x0000caf8 add r1, pc, r1 | r1 = pc + r1;
0x0000cafc b 0xc8c8 | goto label_0;
| }
| label_15:
0x0000cb00 ldr r3, [r4, 0x74] | r3 = *((r4 + 0x74));
0x0000cb04 cmp r3, 0 |
| if (r3 != 0) {
0x0000cb08 beq 0xcb18 |
0x0000cb0c ldr r3, [r3] | r3 = *(r3);
0x0000cb10 cmp r4, r3 |
| if (r4 == r3) {
0x0000cb14 beq 0xcb4c | goto label_16;
| }
| }
0x0000cb18 ldr r3, [pc, 0x2dc] |
0x0000cb1c ldr r2, [pc, 0x2dc] | r2 = *(0xcdfc);
0x0000cb20 add r3, pc, r3 | r3 = pc + r3;
0x0000cb24 add r3, r3, 0x3b0 | r3 = 0xd1a8;
0x0000cb28 str r3, [sp, 4] | var_4h = r3;
0x0000cb2c ldr r3, [pc, 0x2d0] | r3 = *(0xce00);
0x0000cb30 ldr r1, [pc, 0x2d0] | r1 = *(0xce04);
0x0000cb34 add r3, pc, r3 | r3 = pc + r3;
0x0000cb38 str r3, [sp] | *(sp) = r3;
0x0000cb3c add r2, pc, r2 | r2 = pc + r2;
0x0000cb40 ldr r3, [pc, 0x2c4] | r3 = *(0xce08);
0x0000cb44 add r1, pc, r1 | r1 = pc + r1;
0x0000cb48 b 0xc8c8 | goto label_0;
| label_16:
0x0000cb4c ldr r0, [r4, 0x70] | r0 = *((r4 + 0x70));
0x0000cb50 bl 0x5b34 | r0 = fcn_00005b34 (r0);
0x0000cb54 mov r1, r0 | r1 = r0;
0x0000cb58 add r0, r4, 0x1c | r0 = r4 + 0x1c;
0x0000cb5c bl 0x7374 | fcn_00007374 (r0, r1);
0x0000cb60 ldr r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x0000cb64 cmp r5, r3 |
| if (r5 == r3) {
0x0000cb68 beq 0xc9b0 | goto label_1;
| }
0x0000cb6c ldr r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x0000cb70 add r3, r3, 1 | r3++;
0x0000cb74 str r3, [r4, 0xc] | *((r4 + 0xc)) = r3;
0x0000cb78 mov r3, 0 | r3 = 0;
0x0000cb7c str r3, [r4, 0x10] | *((r4 + 0x10)) = r3;
0x0000cb80 ldrb r3, [r4, 0x6a] | r3 = *((r4 + 0x6a));
0x0000cb84 orr r3, r3, 2 | r3 |= 2;
0x0000cb88 strb r3, [r4, 0x6a] | *((r4 + 0x6a)) = r3;
| do {
| label_3:
0x0000cb8c add sp, sp, 0x94 |
0x0000cb90 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_12:
0x0000cb94 ldr r0, [r4, 0x1c] | r0 = *((r4 + 0x1c));
0x0000cb98 add r1, sp, 0x10 | r1 += var_10h;
0x0000cb9c mov r2, 0x80 | r2 = 0x80;
0x0000cba0 add r0, r0, 4 | r0 += 4;
0x0000cba4 bl 0x4f2c | loc_imp_evutil_format_sockaddr_port_ ();
0x0000cba8 ldr r1, [pc, 0x260] | r1 = *(0xce0c);
0x0000cbac add r1, pc, r1 | r1 = pc + r1;
0x0000cbb0 mov r2, r0 | r2 = r0;
0x0000cbb4 mov r0, r8 | r0 = r8;
0x0000cbb8 bl 0x61d8 | fcn_000061d8 (r0);
0x0000cbbc mov r2, r4 | r2 = r4;
0x0000cbc0 mov r1, r8 | r1 = r8;
0x0000cbc4 mov r0, r8 | r0 = r8;
0x0000cbc8 bl 0x83f8 | fcn_000083f8 ();
0x0000cbcc b 0xcb8c |
| } while (1);
| label_9:
0x0000cbd0 mov sb, 0x41 | sb = 0x41;
0x0000cbd4 b 0xc994 | goto label_2;
| label_11:
0x0000cbd8 mov sb, 0x42 | sb = 0x42;
0x0000cbdc b 0xc994 | goto label_2;
| label_14:
0x0000cbe0 ldr r6, [r5, 0x10] | r6 = *((r5 + 0x10));
0x0000cbe4 cmp r6, 0 |
| if (r6 != 0) {
0x0000cbe8 beq 0xcc74 |
0x0000cbec ldr r1, [r5, 0xc] | r1 = *((r5 + 0xc));
0x0000cbf0 ldr r3, [r5, 0x14] | r3 = *((r5 + 0x14));
0x0000cbf4 add r1, r1, 1 | r1++;
0x0000cbf8 str r1, [r5, 0xc] | *((r5 + 0xc)) = r1;
0x0000cbfc ldr r2, [r6, 8] | r2 = *((r6 + 8));
0x0000cc00 cmp r1, r2 |
| if (r1 < r2) {
0x0000cc04 movge r0, r3 | r0 = r3;
| }
| if (r1 < r2) {
0x0000cc08 movge r2, 0 | r2 = 0;
| }
| if (r1 >= r2) {
0x0000cc0c bge 0xccb8 | goto label_17;
| }
0x0000cc10 add r0, r6, 0xc | r0 = r6 + 0xc;
0x0000cc14 mov r2, r3 | r2 = r3;
0x0000cc18 bl 0x770c | r0 = fcn_0000770c (r0, r1);
0x0000cc1c subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 == r0) {
0x0000cc20 beq 0xcc74 | goto label_4;
| }
0x0000cc24 ldr r1, [pc, 0x1e8] | r1 = *(0xce10);
0x0000cc28 ldr r3, [r5, 0xc] | r3 = *((r5 + 0xc));
0x0000cc2c mov r2, r6 | r2 = r6;
0x0000cc30 add r1, pc, r1 | r1 = pc + r1;
0x0000cc34 mov r0, 0 | r0 = 0;
0x0000cc38 bl 0x61d8 | fcn_000061d8 (r0);
0x0000cc3c ldr r3, [r8, 0x14] | r3 = *((r8 + 0x14));
0x0000cc40 ldrb r2, [r8, 4] | r2 = *((r8 + 4));
0x0000cc44 str r3, [sp, 4] | var_4h = r3;
0x0000cc48 ldr r3, [r8, 0x18] | r3 = *((r8 + 0x18));
0x0000cc4c mov r1, 0 | r1 = 0;
0x0000cc50 str r3, [sp] | *(sp) = r3;
0x0000cc54 mov r0, sl | r0 = sl;
0x0000cc58 mov r3, r6 | r3 = r6;
0x0000cc5c bl 0x90b4 | r0 = fcn_000090b4 (r0, r1, r2, r3);
0x0000cc60 mov sl, r0 | sl = r0;
0x0000cc64 mov r0, r6 | r0 = r6;
0x0000cc68 bl 0x4e9c | loc_imp_event_mm_free_ ();
0x0000cc6c cmp sl, 0 |
| if (sl != 0) {
0x0000cc70 bne 0xcd2c | goto label_18;
| }
| }
| label_4:
0x0000cc74 mov r3, 0 | r3 = 0;
0x0000cc78 mov r2, sb | r2 = sb;
0x0000cc7c mov r1, r7 | r1 = r7;
0x0000cc80 mov r0, r4 | r0 = r4;
0x0000cc84 bl 0x6d34 | fcn_00006d34 (r0, r1);
| label_5:
0x0000cc88 ldr r5, [r4, 0x70] | r5 = *((r4 + 0x70));
0x0000cc8c ldrh r0, [r4, 0x68] | r0 = *((r4 + 0x68));
0x0000cc90 ldr r1, [r5, 0xc] | r1 = *((r5 + 0xc));
0x0000cc94 bl 0x16fa0 | fcn_00016fa0 (r0, r1);
0x0000cc98 ldr r3, [r5] | r3 = *(r5);
0x0000cc9c mov r2, 1 | r2 = 1;
0x0000cca0 mov r0, r4 | r0 = r4;
0x0000cca4 add r1, r3, r1, lsl 2 | r1 = r3 + (r1 << 2);
0x0000cca8 bl 0x81a8 | fcn_000081a8 (r0, r1);
0x0000ccac b 0xcb8c | goto label_3;
| do {
0x0000ccb0 add r0, fp, 1 | r0 += arg_1h;
0x0000ccb4 add r2, r2, 1 | r2++;
| label_17:
0x0000ccb8 mov r1, 0x2e | r1 = 0x2e;
0x0000ccbc str r2, [sp, 0xc] | var_ch = r2;
0x0000ccc0 str r3, [sp, 8] | var_8h = r3;
0x0000ccc4 bl 0x5664 | strchr (r0, r1);
0x0000ccc8 ldr r3, [sp, 8] | r3 = var_8h;
0x0000cccc ldr r2, [sp, 0xc] | r2 = var_ch;
0x0000ccd0 subs fp, r0, 0 |
0x0000ccd4 bne 0xccb0 |
| } while (fp != r0);
0x0000ccd8 ldr r1, [r6, 4] | r1 = *((r6 + 4));
0x0000ccdc cmp r1, r2 |
| if (r1 <= r2) {
0x0000cce0 ble 0xcc74 | goto label_4;
| }
0x0000cce4 ldr r1, [r8, 0x14] | r1 = *((r8 + 0x14));
0x0000cce8 ldrb r2, [r8, 4] | r2 = *((r8 + 4));
0x0000ccec str r1, [sp, 4] | var_4h = r1;
0x0000ccf0 ldr r1, [r8, 0x18] | r1 = *((r8 + 0x18));
0x0000ccf4 mov r0, sl | r0 = sl;
0x0000ccf8 str r1, [sp] | *(sp) = r1;
0x0000ccfc mov r1, fp | r1 = fp;
0x0000cd00 bl 0x90b4 | fcn_000090b4 (r0, r1, r2, r3);
0x0000cd04 ldr r1, [pc, 0x10c] | r1 = *(0xce14);
0x0000cd08 ldr r2, [r5, 0x14] | r2 = *((r5 + 0x14));
0x0000cd0c add r1, pc, r1 | r1 = pc + r1;
0x0000cd10 mov sl, r0 | sl = r0;
0x0000cd14 mov r0, fp | r0 = fp;
0x0000cd18 bl 0x61d8 | fcn_000061d8 (r0);
0x0000cd1c cmp sl, 0 |
| if (sl == 0) {
0x0000cd20 beq 0xcc74 | goto label_4;
| }
0x0000cd24 mov r0, r5 | r0 = r5;
0x0000cd28 bl 0x7624 | fcn_00007624 (r0);
| label_18:
0x0000cd2c ldr r4, [r8, 0x70] | r4 = *((r8 + 0x70));
0x0000cd30 ldrh r0, [r8, 0x68] | r0 = *((r8 + 0x68));
0x0000cd34 ldr r1, [r4, 0xc] | r1 = *((r4 + 0xc));
0x0000cd38 bl 0x16fa0 | fcn_00016fa0 (r0, r1);
0x0000cd3c ldr r3, [r4] | r3 = *(r4);
0x0000cd40 mov r0, r8 | r0 = r8;
0x0000cd44 mov r2, 0 | r2 = 0;
0x0000cd48 add r1, r3, r1, lsl 2 | r1 = r3 + (r1 << 2);
0x0000cd4c bl 0x81a8 | fcn_000081a8 (r0, r1);
0x0000cd50 str sl, [r5] | *(r5) = sl;
0x0000cd54 mov r0, sl | r0 = sl;
0x0000cd58 str r5, [sl, 0x74] | *((sl + 0x74)) = r5;
0x0000cd5c bl 0x7da4 | fcn_00007da4 (r0);
0x0000cd60 b 0xcb8c | goto label_3;
| label_8:
0x0000cd64 mov r3, sb | r3 = sb;
0x0000cd68 mov r2, r8 | r2 = r8;
0x0000cd6c mov r1, r7 | r1 = r7;
0x0000cd70 mov r0, r4 | r0 = r4;
0x0000cd74 bl 0x6d34 | fcn_00006d34 (r0, r1);
0x0000cd78 ldr r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x0000cd7c ldr r1, [r4, 0x74] | r1 = *((r4 + 0x74));
0x0000cd80 ldr r2, [r3, 0x118] | r2 = *((r3 + 0x118));
0x0000cd84 cmp r1, r2 |
| if (r1 != r2) {
0x0000cd88 streq r8, [r3, 0x118] | *((r3 + 0x118)) = r8;
| }
0x0000cd8c ldr r0, [r4, 0x1c] | r0 = *((r4 + 0x1c));
0x0000cd90 bl 0xae74 | fcn_0000ae74 (r0);
0x0000cd94 b 0xcc88 | goto label_5;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/lib/libevent_extra-2.1.so.6.0.2 @ 0x10bcc */
| #include <stdint.h>
|
; (fcn) fcn.00010bcc () | void fcn_00010bcc (uint32_t arg1, int32_t arg2) {
| int32_t var_4h;
| int32_t var_8h;
| void * s;
| int32_t var_10h;
| int32_t var_28h;
| int32_t var_48h;
| r0 = arg1;
| r1 = arg2;
0x00010bcc cmp r0, 0 |
0x00010bd0 push {r4, r5, r6, lr} |
0x00010bd4 mov r4, r1 | r4 = r1;
0x00010bd8 clz r1, r1 | r1 &= r1;
0x00010bdc lsr r1, r1, 5 | r1 >>= 5;
| if (r0 == 0) {
0x00010be0 movne r1, 0 | r1 = 0;
| }
0x00010be4 cmp r1, 0 |
0x00010be8 sub sp, sp, 0x48 |
| if (r1 == 0) {
0x00010bec beq 0x10c0c | goto label_2;
| }
0x00010bf0 mov r1, 0 | r1 = 0;
0x00010bf4 mov r0, r1 | r0 = r1;
0x00010bf8 bl 0x107f8 | r0 = fcn_000107f8 (r0, r1);
0x00010bfc mov r4, r0 | r4 = r0;
| do {
| label_1:
0x00010c00 mov r0, r4 | r0 = r4;
0x00010c04 add sp, sp, 0x48 |
0x00010c08 pop {r4, r5, r6, pc} |
| label_2:
0x00010c0c mov r5, r0 | r5 = r0;
0x00010c10 mov r6, r2 | r6 = r2;
0x00010c14 add r0, sp, 0xc | r0 += s;
0x00010c18 mov r2, 0x1c | r2 = 0x1c;
0x00010c1c str r1, [sp, 4] | var_4h = r1;
0x00010c20 bl 0x54a8 | memset (r0, r1, r2);
0x00010c24 mov r3, 1 | r3 = 1;
0x00010c28 ldr r2, [pc, 0x98] | r2 = *(0x10cc4);
0x00010c2c str r3, [sp, 0x10] | var_10h = r3;
0x00010c30 mov r3, 0x21 | r3 = 0x21;
0x00010c34 str r3, [sp, 8] | var_8h = r3;
0x00010c38 mov r3, r4 | r3 = r4;
0x00010c3c add r4, sp, 0x28 | r4 += var_28h;
0x00010c40 add r2, pc, r2 | r2 = pc + r2;
0x00010c44 mov r1, 0x20 | r1 = 0x20;
0x00010c48 mov r0, r4 | r0 = r4;
0x00010c4c bl 0x50ac | loc_imp_evutil_snprintf ()
0x00010c50 add r3, sp, 4 | r3 += var_4h;
0x00010c54 add r2, sp, 8 | r2 += var_8h;
0x00010c58 mov r1, r4 | r1 = r4;
0x00010c5c mov r0, r5 | r0 = r5;
0x00010c60 bl 0x5298 | r0 = loc_imp_evutil_getaddrinfo ();
0x00010c64 subs r3, r0, 0 | r3 = r0 - 0;
| if (r3 == r0) {
0x00010c68 beq 0x10ca0 | goto label_3;
| }
0x00010c6c cmn r3, 0xb |
| if (r3 != 0xb) {
0x00010c70 bne 0x10c88 | goto label_4;
| }
0x00010c74 ldr r0, [pc, 0x50] | r0 = *(0x10cc8);
0x00010c78 add r0, pc, r0 | r0 = pc + r0;
0x00010c7c bl 0x5178 | loc_imp_event_warn ();
| label_0:
0x00010c80 mvn r4, 0 | r4 = ~0;
0x00010c84 b 0x10c00 |
| } while (1);
| label_4:
0x00010c88 bl 0x50b8 | r0 = loc_imp_evutil_gai_strerror ();
0x00010c8c mov r1, r0 | r1 = r0;
0x00010c90 ldr r0, [pc, 0x38] | r0 = *(0x10ccc);
0x00010c94 add r0, pc, r0 | r0 = pc + r0;
0x00010c98 bl 0x5700 | loc_imp_event_warnx ();
0x00010c9c b 0x10c80 | goto label_0;
| label_3:
0x00010ca0 ldr r5, [sp, 4] | r5 = var_4h;
0x00010ca4 cmp r5, 0 |
| if (r5 == 0) {
0x00010ca8 beq 0x10c80 | goto label_0;
| }
0x00010cac mov r1, r6 | r1 = r6;
0x00010cb0 mov r0, r5 | r0 = r5;
0x00010cb4 bl 0x107f8 | r0 = fcn_000107f8 (r0, r1);
0x00010cb8 mov r4, r0 | r4 = r0;
0x00010cbc mov r0, r5 | r0 = r5;
0x00010cc0 bl 0x5070 | loc_imp_evutil_freeaddrinfo ();
0x00010cc4 b 0x10c00 | goto label_1;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/lib/libevent_extra-2.1.so.6.0.2 @ 0x119a8 */
| #include <stdint.h>
|
; (fcn) fcn.000119a8 () | void fcn_000119a8 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_ch;
| int32_t var_40h;
| r0 = arg1;
| r1 = arg2;
0x000119a8 push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x000119ac mov r7, r0 | r7 = r0;
0x000119b0 sub sp, sp, 0x40 |
0x000119b4 ldr r0, [r0, 0xc] | r0 = *((r0 + 0xc));
0x000119b8 mov r4, r1 | r4 = r1;
0x000119bc bl 0x5694 | loc_imp_bufferevent_get_output ();
0x000119c0 ldr r3, [r4, 0x24] | r3 = *((r4 + 0x24));
0x000119c4 cmp r3, 0 |
0x000119c8 mov r6, r0 | r6 = r0;
| if (r3 != 0) {
0x000119cc bne 0x11b90 | goto label_4;
| }
0x000119d0 ldr r1, [pc, 0x3e8] | r1 = *(0x11dbc);
0x000119d4 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x000119d8 add r1, pc, r1 | r1 = pc + r1;
0x000119dc bl 0x4ed8 | fcn_00004ed8 ();
0x000119e0 ldr r3, [r4, 0x28] | r3 = *((r4 + 0x28));
0x000119e4 cmp r3, 0x10 |
| if (r3 == 0x10) {
0x000119e8 beq 0x11b54 | goto label_5;
| }
| if (r3 > 0x10) {
0x000119ec bhi 0x11b18 | goto label_6;
| }
0x000119f0 cmp r3, 2 |
| if (r3 == 2) {
0x000119f4 beq 0x11db4 | goto label_7;
| }
| if (r3 > 2) {
0x000119f8 bhi 0x11afc | goto label_8;
| }
0x000119fc cmp r3, 1 |
| if (r3 == 1) {
0x00011a00 beq 0x11b78 | goto label_9;
| }
| do {
| label_1:
0x00011a04 ldr r5, [pc, 0x3b8] | r5 = *(0x11dc0);
0x00011a08 add r5, pc, r5 | r5 = pc + r5;
| label_0:
0x00011a0c ldr r0, [r7, 0xc] | r0 = *((r7 + 0xc));
0x00011a10 bl 0x5694 | loc_imp_bufferevent_get_output ();
0x00011a14 ldrb r3, [r4, 0x3d] | r3 = *((r4 + 0x3d));
0x00011a18 ldr r1, [pc, 0x3a8] | r1 = *(0x11dc4);
0x00011a1c str r3, [sp, 4] | var_4h = r3;
0x00011a20 ldrb r3, [r4, 0x3c] | r3 = *((r4 + 0x3c));
0x00011a24 mov r2, r5 | r2 = r5;
0x00011a28 str r3, [sp] | *(sp) = r3;
0x00011a2c add r1, pc, r1 | r1 = pc + r1;
0x00011a30 ldr r3, [r4, 0x34] | r3 = *((r4 + 0x34));
0x00011a34 bl 0x54fc | loc_imp_evbuffer_add_printf ()
0x00011a38 ldr r3, [r4, 0x28] | r3 = *((r4 + 0x28));
0x00011a3c cmp r3, 8 |
0x00011a40 cmpne r3, 2 | __asm ("cmpne r3, 2");
| if (r3 == 8) {
0x00011a44 bne 0x11a98 |
0x00011a48 ldr r7, [pc, 0x37c] | r7 = *(0x11dc8);
0x00011a4c ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011a50 add r7, pc, r7 | r7 = pc + r7;
0x00011a54 mov r1, r7 | r1 = r7;
0x00011a58 bl 0x522c | r0 = fcn_0000522c ();
0x00011a5c cmp r0, 0 |
| if (r0 != 0) {
0x00011a60 bne 0x11a98 | goto label_2;
| }
0x00011a64 ldr r0, [r4, 0x5c] | r0 = *((r4 + 0x5c));
0x00011a68 bl 0x519c | loc_imp_evbuffer_get_length ();
0x00011a6c ldr r2, [pc, 0x35c] | r2 = *(0x11dcc);
0x00011a70 add r5, sp, 0xc | r5 += var_ch;
0x00011a74 add r2, pc, r2 | r2 = pc + r2;
0x00011a78 mov r1, 0x16 | r1 = 0x16;
0x00011a7c mov r3, r0 | r3 = r0;
0x00011a80 mov r0, r5 | r0 = r5;
0x00011a84 bl 0x50ac | loc_imp_evutil_snprintf ()
0x00011a88 mov r2, r5 | r2 = r5;
0x00011a8c mov r1, r7 | r1 = r7;
0x00011a90 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011a94 bl 0x5514 | fcn_00005514 ();
| }
| label_2:
0x00011a98 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x00011a9c ldr r7, [pc, 0x330] | r7 = *(0x11dd0);
0x00011aa0 ldr r5, [r3] | r5 = *(r3);
0x00011aa4 add r7, pc, r7 | r7 = pc + r7;
| label_3:
0x00011aa8 cmp r5, 0 |
| if (r5 != 0) {
0x00011aac bne 0x11d98 | goto label_10;
| }
0x00011ab0 ldr r1, [pc, 0x320] | r1 = *(0x11dd4);
0x00011ab4 mov r2, 2 | r2 = 2;
0x00011ab8 add r1, pc, r1 | r1 = pc + r1;
0x00011abc mov r0, r6 | r0 = r6;
0x00011ac0 bl 0x4f80 | loc_imp_evbuffer_add ();
0x00011ac4 mov r1, r5 | r1 = r5;
0x00011ac8 mov r0, r4 | r0 = r4;
0x00011acc bl 0x1171c | r0 = fcn_0001171c (r0, r1);
0x00011ad0 cmp r0, 1 |
| if (r0 != 1) {
0x00011ad4 beq 0x11af4 |
0x00011ad8 ldr r0, [r4, 0x5c] | r0 = *((r4 + 0x5c));
0x00011adc bl 0x519c | r0 = loc_imp_evbuffer_get_length ();
0x00011ae0 cmp r0, 0 |
| if (r0 == 0) {
0x00011ae4 beq 0x11af4 | goto label_11;
| }
0x00011ae8 ldr r1, [r4, 0x5c] | r1 = *((r4 + 0x5c));
0x00011aec mov r0, r6 | r0 = r6;
0x00011af0 bl 0x5064 | loc_imp_evbuffer_add_buffer ();
| }
| label_11:
0x00011af4 add sp, sp, 0x40 |
0x00011af8 pop {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_8:
0x00011afc cmp r3, 4 |
| if (r3 == 4) {
0x00011b00 beq 0x11b84 | goto label_12;
| }
0x00011b04 cmp r3, 8 |
0x00011b08 bne 0x11a04 |
| } while (r3 != 8);
0x00011b0c ldr r5, [pc, 0x2c8] | r5 = *(0x11dd8);
0x00011b10 add r5, pc, r5 | r5 = pc + r5;
0x00011b14 b 0x11a0c | goto label_0;
| label_6:
0x00011b18 cmp r3, 0x40 |
| if (r3 == 0x40) {
0x00011b1c beq 0x11b60 | goto label_13;
| }
| if (r3 > 0x40) {
0x00011b20 bhi 0x11b38 | goto label_14;
| }
0x00011b24 cmp r3, 0x20 |
| if (r3 != 0x20) {
0x00011b28 bne 0x11a04 | goto label_1;
| }
0x00011b2c ldr r5, [pc, 0x2ac] | r5 = *(0x11ddc);
0x00011b30 add r5, pc, r5 | r5 = pc + r5;
0x00011b34 b 0x11a0c | goto label_0;
| label_14:
0x00011b38 cmp r3, 0x80 |
| if (r3 == 0x80) {
0x00011b3c beq 0x11b6c | goto label_15;
| }
0x00011b40 cmp r3, 0x100 |
| if (r3 != 0x100) {
0x00011b44 bne 0x11a04 | goto label_1;
| }
0x00011b48 ldr r5, [pc, 0x294] | r5 = *(0x11de0);
0x00011b4c add r5, pc, r5 | r5 = pc + r5;
0x00011b50 b 0x11a0c | goto label_0;
| label_5:
0x00011b54 ldr r5, [pc, 0x28c] | r5 = *(0x11de4);
0x00011b58 add r5, pc, r5 | r5 = pc + r5;
0x00011b5c b 0x11a0c | goto label_0;
| label_13:
0x00011b60 ldr r5, [pc, 0x284] | r5 = *(0x11de8);
0x00011b64 add r5, pc, r5 | r5 = pc + r5;
0x00011b68 b 0x11a0c | goto label_0;
| label_15:
0x00011b6c ldr r5, [pc, 0x27c] | r5 = *(0x11dec);
0x00011b70 add r5, pc, r5 | r5 = pc + r5;
0x00011b74 b 0x11a0c | goto label_0;
| label_9:
0x00011b78 ldr r5, [pc, 0x274] | r5 = *(0x11df0);
0x00011b7c add r5, pc, r5 | r5 = pc + r5;
0x00011b80 b 0x11a0c | goto label_0;
| label_12:
0x00011b84 ldr r5, [pc, 0x26c] | r5 = *(0x11df4);
0x00011b88 add r5, pc, r5 | r5 = pc + r5;
0x00011b8c b 0x11a0c | goto label_0;
| label_4:
0x00011b90 ldr r0, [r4, 0x10] | r0 = *((r4 + 0x10));
0x00011b94 bl 0x116d8 | r0 = fcn_000116d8 ();
0x00011b98 mov r5, r0 | r5 = r0;
0x00011b9c ldr r0, [r7, 0xc] | r0 = *((r7 + 0xc));
0x00011ba0 bl 0x5694 | loc_imp_bufferevent_get_output ();
0x00011ba4 ldr r1, [r4, 0x44] | r1 = *((r4 + 0x44));
0x00011ba8 ldrb r3, [r4, 0x3d] | r3 = *((r4 + 0x3d));
0x00011bac str r1, [sp, 4] | var_4h = r1;
0x00011bb0 ldr r1, [r4, 0x40] | r1 = *((r4 + 0x40));
0x00011bb4 ldrb r2, [r4, 0x3c] | r2 = *((r4 + 0x3c));
0x00011bb8 str r1, [sp] | *(sp) = r1;
0x00011bbc ldr r1, [pc, 0x238] | r1 = *(0x11df8);
0x00011bc0 add r1, pc, r1 | r1 = pc + r1;
0x00011bc4 bl 0x54fc | loc_imp_evbuffer_add_printf ()
0x00011bc8 ldrb r3, [r4, 0x3c] | r3 = *((r4 + 0x3c));
0x00011bcc cmp r3, 1 |
| if (r3 == 1) {
0x00011bd0 bne 0x11cf4 |
0x00011bd4 ldrb r3, [r4, 0x3d] | r3 = *((r4 + 0x3d));
0x00011bd8 cmp r3, 0 |
| if (r3 != 0) {
0x00011bdc beq 0x11c28 |
0x00011be0 ldr sb, [pc, 0x218] | sb = *(0x00011e00);
0x00011be4 ldr r8, [r4, 0x14] | r8 = *((r4 + 0x14));
0x00011be8 add sb, pc, sb | sb = pc + sb;
0x00011bec mov r1, sb | r1 = sb;
0x00011bf0 mov r0, r8 | r0 = r8;
0x00011bf4 bl 0x522c | r0 = fcn_0000522c ();
0x00011bf8 subs r2, r0, 0 | r2 = r0 - 0;
| if (r2 != r0) {
0x00011bfc bne 0x11c28 | goto label_16;
| }
0x00011c00 add sl, sp, 0xc | sl += var_ch;
0x00011c04 mov r1, 0x32 | r1 = 0x32;
0x00011c08 mov r0, sl | r0 = sl;
0x00011c0c bl 0x52e0 | r0 = loc_imp_evutil_date_rfc1123 ();
0x00011c10 cmp r0, 0x32 |
| if (r0 == 0x32) {
0x00011c14 beq 0x11c28 | goto label_16;
| }
0x00011c18 mov r2, sl | r2 = sl;
0x00011c1c mov r1, sb | r1 = sb;
0x00011c20 mov r0, r8 | r0 = r8;
0x00011c24 bl 0x5514 | fcn_00005514 ();
| }
| label_16:
0x00011c28 ldrb r3, [r4, 0x3d] | r3 = *((r4 + 0x3d));
0x00011c2c adds r5, r5, 0 | r5 += 0;
| if (r5 == r5) {
0x00011c30 movne r5, 1 | r5 = 1;
| }
0x00011c34 cmp r3, 0 |
| if (r3 != 0) {
0x00011c38 moveq r3, r5 | r3 = r5;
| }
| if (r3 == 0) {
0x00011c3c movne r3, 0 | r3 = 0;
| }
0x00011c40 cmp r3, 0 |
| if (r3 != 0) {
0x00011c44 beq 0x11c60 |
0x00011c48 ldr r2, [pc, 0x1b4] | r2 = *(0x11e00);
0x00011c4c ldr r1, [pc, 0x1b4] | r1 = *(0x11e04);
0x00011c50 add r2, pc, r2 | r2 = pc + r2;
0x00011c54 add r1, pc, r1 | r1 = pc + r1;
0x00011c58 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011c5c bl 0x5514 | fcn_00005514 ();
| }
0x00011c60 ldrb r3, [r4, 0x3d] | r3 = *((r4 + 0x3d));
0x00011c64 mov r0, r4 | r0 = r4;
0x00011c68 cmp r3, 0 |
| if (r3 == 0) {
0x00011c6c movne r5, 1 | r5 = 1;
| }
0x00011c70 bl 0x10628 | fcn_00010628 (r0);
0x00011c74 cmp r5, 0 |
| if (r5 == 0) {
0x00011c78 beq 0x11cf4 | goto label_17;
| }
0x00011c7c cmp r0, 0 |
| if (r0 == 0) {
0x00011c80 beq 0x11d3c | goto label_18;
| }
0x00011c84 ldr r0, [r4, 0x5c] | r0 = *((r4 + 0x5c));
0x00011c88 ldr r8, [r4, 0x14] | r8 = *((r4 + 0x14));
0x00011c8c bl 0x519c | loc_imp_evbuffer_get_length ();
0x00011c90 ldr r1, [pc, 0x174] | r1 = *(0x11e08);
0x00011c94 add r1, pc, r1 | r1 = pc + r1;
0x00011c98 mov r5, r0 | r5 = r0;
0x00011c9c mov r0, r8 | r0 = r8;
0x00011ca0 bl 0x522c | r0 = fcn_0000522c ();
0x00011ca4 cmp r0, 0 |
| if (r0 != 0) {
0x00011ca8 bne 0x11cf4 | goto label_17;
| }
0x00011cac ldr sb, [pc, 0x15c] | sb = *(0x11e0c);
0x00011cb0 mov r0, r8 | r0 = r8;
0x00011cb4 add sb, pc, sb | sb = pc + sb;
0x00011cb8 mov r1, sb | r1 = sb;
0x00011cbc bl 0x522c | r0 = fcn_0000522c ();
0x00011cc0 cmp r0, 0 |
| if (r0 != 0) {
0x00011cc4 bne 0x11cf4 | goto label_17;
| }
0x00011cc8 ldr r2, [pc, 0x144] | r2 = *(0x11e10);
0x00011ccc mov r3, r5 | r3 = r5;
0x00011cd0 add r5, sp, 0xc | r5 += var_ch;
0x00011cd4 add r2, pc, r2 | r2 = pc + r2;
0x00011cd8 mov r1, 0x16 | r1 = 0x16;
0x00011cdc mov r0, r5 | r0 = r5;
0x00011ce0 bl 0x50ac | loc_imp_evutil_snprintf ()
0x00011ce4 mov r2, r5 | r2 = r5;
0x00011ce8 mov r1, sb | r1 = sb;
0x00011cec mov r0, r8 | r0 = r8;
0x00011cf0 bl 0x5514 | fcn_00005514 ();
| }
| label_17:
0x00011cf4 mov r0, r4 | r0 = r4;
0x00011cf8 bl 0x10628 | r0 = fcn_00010628 (r0);
0x00011cfc cmp r0, 0 |
| if (r0 != 0) {
0x00011d00 beq 0x11d3c |
0x00011d04 ldr r5, [pc, 0x10c] | r5 = *(0x11e14);
0x00011d08 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011d0c add r5, pc, r5 | r5 = pc + r5;
0x00011d10 mov r1, r5 | r1 = r5;
0x00011d14 bl 0x522c | r0 = fcn_0000522c ();
0x00011d18 cmp r0, 0 |
| if (r0 != 0) {
0x00011d1c bne 0x11d3c | goto label_18;
| }
0x00011d20 ldr r3, [r7, 0x90] | r3 = *((r7 + 0x90));
0x00011d24 ldr r2, [r3, 0x4c] | r2 = *((r3 + 0x4c));
0x00011d28 cmp r2, 0 |
| if (r2 == 0) {
0x00011d2c beq 0x11d3c | goto label_18;
| }
0x00011d30 mov r1, r5 | r1 = r5;
0x00011d34 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011d38 bl 0x5514 | fcn_00005514 ();
| }
| label_18:
0x00011d3c ldr r1, [r4, 0x10] | r1 = *((r4 + 0x10));
0x00011d40 ldr r0, [r4, 0xc] | r0 = *((r4 + 0xc));
0x00011d44 bl 0x11614 | r0 = fcn_00011614 (r0, r1);
0x00011d48 cmp r0, 0 |
| if (r0 == 0) {
0x00011d4c beq 0x11a98 | goto label_2;
| }
0x00011d50 ldr r5, [pc, 0xc4] | r5 = *(0x11e18);
0x00011d54 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011d58 add r5, pc, r5 | r5 = pc + r5;
0x00011d5c mov r1, r5 | r1 = r5;
0x00011d60 bl 0x4ed8 | fcn_00004ed8 ();
0x00011d64 ldr r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x00011d68 tst r3, 2 |
| if ((r3 & 2) == 0) {
0x00011d6c bne 0x11d84 |
0x00011d70 ldr r2, [pc, 0xa8] | r2 = *(0x11e1c);
0x00011d74 mov r1, r5 | r1 = r5;
0x00011d78 add r2, pc, r2 | r2 = pc + r2;
0x00011d7c ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011d80 bl 0x5514 | fcn_00005514 ();
| }
0x00011d84 ldr r1, [pc, 0x98] | r1 = *(0x11e20);
0x00011d88 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x00011d8c add r1, pc, r1 | r1 = pc + r1;
0x00011d90 bl 0x4ed8 | fcn_00004ed8 ();
0x00011d94 b 0x11a98 | goto label_2;
| label_10:
0x00011d98 ldr r3, [r5, 0xc] | r3 = *((r5 + 0xc));
0x00011d9c ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x00011da0 mov r1, r7 | r1 = r7;
0x00011da4 mov r0, r6 | r0 = r6;
0x00011da8 bl 0x54fc | loc_imp_evbuffer_add_printf ()
0x00011dac ldr r5, [r5] | r5 = *(r5);
0x00011db0 b 0x11aa8 | goto label_3;
| label_7:
0x00011db4 ldr r5, [pc, 0x6c] | r5 = *(0x11e24);
0x00011db8 add r5, pc, r5 | r5 = pc + r5;
0x00011dbc b 0x11a0c | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/lib/libevent_extra-2.1.so.6.0.2 @ 0xc16c */
| #include <stdint.h>
|
; (fcn) sym.evdns_base_resolve_reverse () | void evdns_base_resolve_reverse (int32_t arg_48h, int32_t arg1, uint32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_10h;
| int32_t var_30h;
| r0 = arg1;
| r1 = arg2;
0x0000c16c push {r4, r5, r6, r7, r8, lr} |
0x0000c170 ldr r5, [pc, 0x14c] | r5 = *(0xc2c0);
0x0000c174 cmp r1, 0 |
0x0000c178 add r5, pc, r5 | r5 = pc + r5;
0x0000c17c sub sp, sp, 0x30 |
| if (r1 == 0) {
0x0000c180 bne 0xc1c0 |
0x0000c184 ldr r3, [pc, 0x13c] |
0x0000c188 ldr r2, [pc, 0x13c] | r2 = *(0xc2c8);
0x0000c18c add r3, pc, r3 | r3 = pc + r3;
0x0000c190 add r3, r3, 0x350 | r3 = 0xc614;
0x0000c194 add r3, r3, 1 | r3++;
0x0000c198 str r3, [sp, 4] | var_4h = r3;
0x0000c19c ldr r3, [pc, 0x12c] | r3 = *(0xc2cc);
0x0000c1a0 ldr r1, [pc, 0x12c] | r1 = *(0xc2d0);
0x0000c1a4 add r3, pc, r3 | r3 = pc + r3;
0x0000c1a8 str r3, [sp] | *(sp) = r3;
0x0000c1ac add r2, pc, r2 | r2 = pc + r2;
0x0000c1b0 ldr r3, [pc, 0x120] | r3 = *(0xc2d4);
0x0000c1b4 add r1, pc, r1 | r1 = pc + r1;
0x0000c1b8 ldr r0, [pc, 0x11c] | r0 = *(0xc2d8);
0x0000c1bc bl 0x55bc | r0 = loc_imp_event_errx ();
| }
0x0000c1c0 mov r6, r0 | r6 = r0;
0x0000c1c4 ldr r0, [r1] | r0 = *(r1);
0x0000c1c8 mov r8, r3 | r8 = r3;
0x0000c1cc bl 0x17988 | fcn_00017988 (r0);
0x0000c1d0 ldr r2, [pc, 0x108] | r2 = *(0xc2dc);
0x0000c1d4 add r7, sp, 0x10 | r7 += var_10h;
0x0000c1d8 add r2, pc, r2 | r2 = pc + r2;
0x0000c1dc mov r1, 0x20 | r1 = 0x20;
0x0000c1e0 lsr r3, r0, 0x18 | r3 = r0 >> 0x18;
0x0000c1e4 str r3, [sp, 8] | var_8h = r3;
0x0000c1e8 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0000c1ec and r3, r3, 0xff | r3 &= 0xff;
0x0000c1f0 str r3, [sp, 4] | var_4h = r3;
0x0000c1f4 lsr r3, r0, 8 | r3 = r0 >> 8;
0x0000c1f8 and r3, r3, 0xff | r3 &= 0xff;
0x0000c1fc str r3, [sp] | *(sp) = r3;
0x0000c200 and r3, r0, 0xff | r3 = r0 & 0xff;
0x0000c204 mov r0, r7 | r0 = r7;
0x0000c208 bl 0x50ac | loc_imp_evutil_snprintf ()
0x0000c20c mov r1, 0x1c | r1 = 0x1c;
0x0000c210 mov r0, 1 | r0 = 1;
0x0000c214 bl 0x4fe0 | r0 = loc_imp_event_mm_calloc_ ();
0x0000c218 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 != r0) {
0x0000c21c beq 0xc2b8 |
0x0000c220 ldr r1, [pc, 0xbc] | r1 = *(0xc2e0);
0x0000c224 mov r2, r7 | r2 = r7;
0x0000c228 add r1, pc, r1 | r1 = pc + r1;
0x0000c22c mov r0, 0 | r0 = 0;
0x0000c230 bl 0x61d8 | fcn_000061d8 (r0);
0x0000c234 ldr r1, [r6, 0xec] | r1 = *((r6 + 0xec));
0x0000c238 cmp r1, 0 |
| if (r1 != 0) {
0x0000c23c beq 0xc254 |
0x0000c240 ldr r3, [pc, 0xa0] |
0x0000c244 mov r0, 0 | r0 = 0;
0x0000c248 ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x0000c24c ldr r3, [r3, 0x10] | r3 = *(0xc2f4);
0x0000c250 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
| }
0x0000c254 ldr r3, [sp, 0x48] | r3 = *(arg_48h);
0x0000c258 str r8, [sp] | *(sp) = r8;
0x0000c25c str r3, [sp, 4] | var_4h = r3;
0x0000c260 mov r2, 0xc | r2 = 0xc;
0x0000c264 mov r3, r7 | r3 = r7;
0x0000c268 mov r1, r4 | r1 = r4;
0x0000c26c mov r0, r6 | r0 = r6;
0x0000c270 bl 0x90b4 | r0 = fcn_000090b4 (r0, r1, r2, r3);
0x0000c274 cmp r0, 0 |
| if (r0 != 0) {
0x0000c278 beq 0xc280 |
0x0000c27c bl 0x7da4 | fcn_00007da4 (r0);
| }
0x0000c280 ldr r7, [r4] | r7 = *(r4);
0x0000c284 cmp r7, 0 |
| if (r7 == 0) {
0x0000c288 bne 0xc298 |
0x0000c28c mov r0, r4 | r0 = r4;
0x0000c290 bl 0x4e9c | loc_imp_event_mm_free_ ();
0x0000c294 mov r4, r7 | r4 = r7;
| }
0x0000c298 ldr r1, [r6, 0xec] | r1 = *((r6 + 0xec));
0x0000c29c cmp r1, 0 |
| if (r1 == 0) {
0x0000c2a0 beq 0xc2b8 | goto label_0;
| }
0x0000c2a4 ldr r3, [pc, 0x3c] |
0x0000c2a8 mov r0, 0 | r0 = 0;
0x0000c2ac ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x0000c2b0 ldr r3, [r3, 0x14] | r3 = *(0xc2f8);
0x0000c2b4 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
| }
| label_0:
0x0000c2b8 mov r0, r4 | r0 = r4;
0x0000c2bc add sp, sp, 0x30 |
0x0000c2c0 pop {r4, r5, r6, r7, r8, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/lib/libevent_extra-2.1.so.6.0.2 @ 0xc328 */
| #include <stdint.h>
|
; (fcn) sym.evdns_base_resolve_reverse_ipv6 () | void evdns_base_resolve_reverse_ipv6 (int32_t arg_70h, int32_t arg1, uint32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_ch;
| int8_t var_3h;
| int8_t var_2h;
| int8_t var_1h;
| int32_t var_10h;
| int32_t var_4h_2;
| void * s1;
| int32_t var_58h;
| r0 = arg1;
| r1 = arg2;
0x0000c328 push {r4, r5, r6, r7, r8, lr} |
0x0000c32c ldr r5, [pc, 0x160] | r5 = *(0xc490);
0x0000c330 cmp r1, 0 |
0x0000c334 add r5, pc, r5 | r5 = pc + r5;
0x0000c338 sub sp, sp, 0x58 |
| if (r1 == 0) {
0x0000c33c bne 0xc378 |
0x0000c340 ldr r3, [pc, 0x150] |
0x0000c344 ldr r2, [pc, 0x150] | r2 = *(0xc498);
0x0000c348 add r3, pc, r3 | r3 = pc + r3;
0x0000c34c add r3, r3, 0x36c | r3 = 0xc800;
0x0000c350 str r3, [sp, 4] | var_4h = r3;
0x0000c354 ldr r3, [pc, 0x144] | r3 = *(0xc49c);
0x0000c358 ldr r1, [pc, 0x144] | r1 = *(0xc4a0);
0x0000c35c add r3, pc, r3 | r3 = pc + r3;
0x0000c360 str r3, [sp] | *(sp) = r3;
0x0000c364 add r2, pc, r2 | r2 = pc + r2;
0x0000c368 ldr r3, [pc, 0x138] | r3 = *(0xc4a4);
0x0000c36c add r1, pc, r1 | r1 = pc + r1;
0x0000c370 ldr r0, [pc, 0x134] | r0 = *(0xc4a8);
0x0000c374 bl 0x55bc | loc_imp_event_errx ();
| }
0x0000c378 ldr ip, [pc, 0x130] | ip = *(0x0000c4b0);
0x0000c37c mov r6, r0 | r6 = r0;
0x0000c380 mov r7, r3 | r7 = r3;
0x0000c384 add r2, r1, 0xf | r2 = r1 + 0xf;
0x0000c388 add r3, sp, 0x10 | r3 += var_10h;
0x0000c38c sub r1, r1, 1 | r1--;
0x0000c390 add ip, pc, ip |
0x0000c394 mov r0, 0x2e | r0 = 0x2e;
| do {
0x0000c398 ldrb lr, [r2], -1 |
0x0000c39c strb r0, [r3, -3] | var_3h = r0;
0x0000c3a0 and r4, lr, 0xf | r4 = lr & 0xf;
0x0000c3a4 ldrb r4, [ip, r4] | r4 = *((ip + r4));
0x0000c3a8 ldrb lr, [ip, lr, lsr 4] |
0x0000c3ac cmp r2, r1 |
0x0000c3b0 strb r4, [r3, -4] | var_ch = r4;
0x0000c3b4 strb lr, [r3, -2] | var_2h = lr;
0x0000c3b8 strb r0, [r3, -1] | var_1h = r0;
0x0000c3bc add r3, r3, 4 | r3 += var_4h_2;
0x0000c3c0 bne 0xc398 |
| } while (r2 != r1);
0x0000c3c4 ldr r1, [pc, 0xe8] | r1 = *(0xc4b0);
0x0000c3c8 mov r2, 9 | r2 = 9;
0x0000c3cc add r1, pc, r1 | r1 = pc + r1;
0x0000c3d0 add r0, sp, 0x4c | r0 += s1;
0x0000c3d4 bl 0x4f50 | memcpy (r0, r1, r2);
0x0000c3d8 mov r1, 0x1c | r1 = 0x1c;
0x0000c3dc mov r0, 1 | r0 = 1;
0x0000c3e0 bl 0x4fe0 | loc_imp_event_mm_calloc_ ();
0x0000c3e4 add r8, sp, 0xc | r8 += var_ch;
0x0000c3e8 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 != r0) {
0x0000c3ec beq 0xc488 |
0x0000c3f0 ldr r1, [pc, 0xc0] | r1 = *(0xc4b4);
0x0000c3f4 mov r2, r8 | r2 = r8;
0x0000c3f8 add r1, pc, r1 | r1 = pc + r1;
0x0000c3fc mov r0, 0 | r0 = 0;
0x0000c400 bl 0x61d8 | fcn_000061d8 (r0);
0x0000c404 ldr r1, [r6, 0xec] | r1 = *((r6 + 0xec));
0x0000c408 cmp r1, 0 |
| if (r1 != 0) {
0x0000c40c beq 0xc424 |
0x0000c410 ldr r3, [pc, 0xa4] |
0x0000c414 mov r0, 0 | r0 = 0;
0x0000c418 ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x0000c41c ldr r3, [r3, 0x10] | r3 = *(0xc4c8);
0x0000c420 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
| }
0x0000c424 ldr r3, [sp, 0x70] | r3 = *(arg_70h);
0x0000c428 str r7, [sp] | *(sp) = r7;
0x0000c42c str r3, [sp, 4] | var_4h = r3;
0x0000c430 mov r2, 0xc | r2 = 0xc;
0x0000c434 mov r3, r8 | r3 = r8;
0x0000c438 mov r1, r4 | r1 = r4;
0x0000c43c mov r0, r6 | r0 = r6;
0x0000c440 bl 0x90b4 | r0 = fcn_000090b4 (r0, r1, r2, r3);
0x0000c444 cmp r0, 0 |
| if (r0 != 0) {
0x0000c448 beq 0xc450 |
0x0000c44c bl 0x7da4 | fcn_00007da4 (r0);
| }
0x0000c450 ldr r7, [r4] | r7 = *(r4);
0x0000c454 cmp r7, 0 |
| if (r7 == 0) {
0x0000c458 bne 0xc468 |
0x0000c45c mov r0, r4 | r0 = r4;
0x0000c460 bl 0x4e9c | loc_imp_event_mm_free_ ();
0x0000c464 mov r4, r7 | r4 = r7;
| }
0x0000c468 ldr r1, [r6, 0xec] | r1 = *((r6 + 0xec));
0x0000c46c cmp r1, 0 |
| if (r1 == 0) {
0x0000c470 beq 0xc488 | goto label_0;
| }
0x0000c474 ldr r3, [pc, 0x40] |
0x0000c478 mov r0, 0 | r0 = 0;
0x0000c47c ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x0000c480 ldr r3, [r3, 0x14] | r3 = *(0xc4cc);
0x0000c484 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
| }
| label_0:
0x0000c488 mov r0, r4 | r0 = r4;
0x0000c48c add sp, sp, 0x58 |
0x0000c490 pop {r4, r5, r6, r7, r8, pc} |
| }
[*] Function printf used 9 times libevent_extra-2.1.so.6.0.2