[*] Binary protection state of libarchive.so.13.5.3
Full RELRO Canary found NX enabled DSO No RPATH No RUNPATH No Symbols
[*] Function mmap tear down of libarchive.so.13.5.3
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libarchive.so.13.5.3 @ 0x108a4 */
| #include <stdint.h>
|
; (fcn) sym.__archive_check_magic () | void archive_check_magic (int16_t arg1, uint32_t arg2, uint32_t arg3, uint32_t arg4) {
| int16_t var_0h;
| int32_t var_0h_2;
| uint32_t var_8h;
| int16_t var_ch;
| int16_t var_14h;
| int16_t var_54h;
| int16_t var_94h;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
| r3 = arg4;
0x000108a4 ldr.w ip, [pc, 0x114] | ip = *(0x000109bc);
0x000108a8 push {r4, r5, lr} |
0x000108aa mov r5, r0 | r5 = r0;
0x000108ac ldr r4, [r0] | r4 = *(r0);
0x000108ae sub sp, 0x9c |
0x000108b0 add ip, pc |
0x000108b2 ldr r0, [pc, 0x10c] |
0x000108b4 ldr.w r0, [ip, r0] | r0 = *((ip + r0));
0x000108b8 ldr r0, [r0] | r0 = *(0x109c2);
0x000108ba str r0, [sp, 0x94] | var_94h = r0;
0x000108bc mov.w r0, 0 | r0 = 0;
0x000108c0 movw r0, 0x11c9 |
0x000108c4 movt r0, 0xcad | r0 = 0xcad11c9;
0x000108c8 cmp r4, r0 |
| if (r4 == r0) {
0x000108ca beq 0x1093a | goto label_2;
| }
| if (r4 < r0) {
0x000108cc bls 0x10910 | goto label_3;
| }
0x000108ce movw r0, 0xc0de |
0x000108d2 movt r0, 0xb0c5 | r0 = 0xb0c5c0de;
0x000108d6 cmp r4, r0 |
| if (r4 == r0) {
0x000108d8 beq 0x1092e | goto label_4;
| }
0x000108da movw r0, 0xb0c5 |
0x000108de movt r0, 0xc001 | r0 = 0xc001b0c5;
0x000108e2 cmp r4, r0 |
| if (r4 != r0) {
0x000108e4 bne 0x1099c | goto label_5;
| }
0x000108e6 ldr r0, [pc, 0xdc] |
0x000108e8 add r0, pc | r0 = 0x212b2;
| do {
| label_0:
0x000108ea cmp r4, r1 |
| if (r4 != r1) {
0x000108ec bne 0x1097c | goto label_6;
| }
0x000108ee ldr r1, [r5, 4] | r1 = *((r5 + 4));
0x000108f0 tst r1, r2 |
0x000108f2 it ne |
| if ((r1 & r2) == 0) {
0x000108f4 movne r0, 0 | r0 = 0;
| }
| if ((r1 & r2) == 0) {
0x000108f6 beq 0x10940 | goto label_7;
| }
| label_1:
0x000108f8 ldr r2, [pc, 0xcc] |
0x000108fa ldr r3, [pc, 0xc4] | r3 = *(0x109c2);
0x000108fc add r2, pc | r2 = 0x212c8;
0x000108fe ldr r3, [r2, r3] | r3 = *(0x212c8);
0x00010900 ldr r2, [r3] | r2 = *(0x212c8);
0x00010902 ldr r3, [sp, 0x94] | r3 = var_94h;
0x00010904 eors r2, r3 | r2 ^= r3;
0x00010906 mov.w r3, 0 | r3 = 0;
| if (r2 != r3) {
0x0001090a bne 0x10998 | goto label_8;
| }
0x0001090c add sp, 0x9c |
0x0001090e pop {r4, r5, pc} |
| label_3:
0x00010910 movw r0, 0xb0c5 |
0x00010914 movt r0, 0xde | r0 = 0xdeb0c5;
0x00010918 cmp r4, r0 |
| if (r4 == r0) {
0x0001091a beq 0x10934 | goto label_9;
| }
0x0001091c movw r0, 0xb0c5 |
0x00010920 movt r0, 0xbad | r0 = 0xbadb0c5;
0x00010924 cmp r4, r0 |
| if (r4 != r0) {
0x00010926 bne 0x1099c | goto label_5;
| }
0x00010928 ldr r0, [pc, 0xa0] |
0x0001092a add r0, pc | r0 = 0x212fa;
0x0001092c b 0x108ea |
| } while (1);
| label_4:
0x0001092e ldr r0, [pc, 0xa0] |
0x00010930 add r0, pc | r0 = 0x21306;
0x00010932 b 0x108ea | goto label_0;
| label_9:
0x00010934 ldr r0, [pc, 0x9c] |
0x00010936 add r0, pc | r0 = 0x2130e;
0x00010938 b 0x108ea | goto label_0;
| label_2:
0x0001093a ldr r0, [pc, 0x9c] |
0x0001093c add r0, pc | r0 = 0x2131a;
0x0001093e b 0x108ea | goto label_0;
| label_7:
0x00010940 cmp.w r1, 0x8000 |
0x00010944 strd r2, r3, [sp, 8] | __asm ("strd r2, r3, [var_8h]");
| if (r1 != 0x8000) {
0x00010948 beq 0x10970 |
0x0001094a add r0, sp, 0x14 | r0 += var_14h;
0x0001094c bl 0x107d0 | fcn_000107d0 (r0, r1);
0x00010950 ldr r2, [sp, 8] | r2 = var_8h;
0x00010952 mov r4, r0 | r4 = r0;
0x00010954 add r0, sp, 0x54 | r0 += var_54h;
0x00010956 mov r1, r2 | r1 = r2;
0x00010958 bl 0x107d0 | fcn_000107d0 (r0, r1);
0x0001095c ldr r2, [pc, 0x7c] |
0x0001095e mov.w r1, -1 | r1 = -1;
0x00010962 strd r4, r0, [sp] | __asm ("strd r4, r0, [sp]");
0x00010966 mov r0, r5 | r0 = r5;
0x00010968 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0001096a add r2, pc | r2 = 0x2134a;
0x0001096c blx 0xc278 | fcn_0000c278 ();
| }
0x00010970 mov.w r3, 0x8000 | r3 = 0x8000;
0x00010974 mvn r0, 0x1d | r0 = ~0x1d;
0x00010978 str r3, [r5, 4] | *((r5 + 4)) = r3;
0x0001097a b 0x108f8 | goto label_1;
| label_6:
0x0001097c ldr r2, [pc, 0x60] |
0x0001097e mov.w r1, -1 | r1 = -1;
0x00010982 str r0, [sp] | *(sp) = r0;
0x00010984 mov r0, r5 | r0 = r5;
0x00010986 add r2, pc | r2 = 0x2136a;
0x00010988 blx 0xc278 | fcn_0000c278 ();
0x0001098c mov.w r3, 0x8000 | r3 = 0x8000;
0x00010990 mvn r0, 0x1d | r0 = ~0x1d;
0x00010994 str r3, [r5, 4] | *((r5 + 4)) = r3;
0x00010996 b 0x108f8 | goto label_1;
| label_8:
0x00010998 blx 0xd48c | fcn_0000d48c ();
| label_5:
0x0001099c ldr r0, [pc, 0x44] |
0x0001099e str r3, [sp, 8] | var_8h = r3;
0x000109a0 add r0, pc | r0 = 0x21388;
0x000109a2 bl 0xdd38 | entry0 (r0);
0x000109a6 ldr r3, [sp, 8] | r3 = var_8h;
0x000109a8 mov r0, r3 | r0 = r3;
0x000109aa bl 0xdd38 | entry0 (r0);
0x000109ae ldr r0, [pc, 0x38] |
0x000109b0 add r0, pc | r0 = 0x2139e;
0x000109b2 bl 0xdd38 | r0 = entry0 (r0);
0x000109b6 blx 0xc15c | fcn_0000c15c ();
0x000109ba nop |
0x000109bc ldrb r0, [r1, 0x18] | r0 = *((r1 + 0x18));
0x000109be movs r7, r0 | r7 = r0;
0x000109c0 lsrs r4, r5, 4 | r4 = r5 >> 4;
0x000109c2 movs r0, r0 |
0x000109c4 bics r0, r3 | __asm ("bics r0, r3");
0x000109c6 movs r5, r0 | r5 = r0;
0x000109c8 ldrb r4, [r7, 0x16] | r4 = *((r7 + 0x16));
0x000109ca movs r7, r0 | r7 = r0;
0x000109cc muls r2, r0, r2 | r2 = r0 * r2;
0x000109ce movs r5, r0 | r5 = r0;
0x000109d0 muls r4, r6, r4 | r4 = r6 * r4;
0x000109d2 movs r5, r0 | r5 = r0;
0x000109d4 muls r6, r3, r6 | r6 = r3 * r6;
0x000109d6 movs r5, r0 | r5 = r0;
0x000109d8 orrs r0, r4 | r0 |= r4;
0x000109da movs r5, r0 | r5 = r0;
0x000109dc mvns r6, r4 | r6 = ~r4;
0x000109de movs r5, r0 | r5 = r0;
0x000109e0 muls r2, r6, r2 | r2 = r6 * r2;
0x000109e2 movs r5, r0 | r5 = r0;
0x000109e4 orrs r4, r2 | r4 |= r2;
0x000109e6 movs r5, r0 | r5 = r0;
0x000109e8 orrs r0, r4 | r0 |= r4;
0x000109ea movs r5, r0 | r5 = r0;
| }
[*] Function mmap used 1 times libarchive.so.13.5.3