[*] Binary protection state of ip_set_hash_netnet.ko
No RELRO No Canary found NX disabled REL No RPATH No RUNPATH Symbols
[*] Function fprintf tear down of ip_set_hash_netnet.ko
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/modules/5.10.52-axis8/kernel/net/netfilter/ipset/ip_set_hash_netnet.ko @ 0x8000814 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) sym.hash_netnet4_flush () | void hash_netnet4_flush (int32_t arg_8h, int32_t arg_10h, int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h_2;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_14h;
| r0 = arg1;
0x08000814 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x08000818 mov r5, r0 | r5 = r0;
0x0800081c mov r7, 0 | r7 = 0;
0x08000820 sub sp, sp, 0x14 |
0x08000824 mov r3, sp | r3 = sp;
0x08000828 bic r3, r3, 0x1fc0 | r3 = BIT_MASK (r3, 0x1fc0);
0x0800082c bic r3, r3, 0x3f | r3 = BIT_MASK (r3, 0x3f);
0x08000830 str r3, [sp, 8] | var_8h = r3;
0x08000834 ldr r3, [r0, 0x54] | r3 = *((r0 + 0x54));
0x08000838 str r3, [sp, 0xc] | var_ch = r3;
0x0800083c ldr fp, [r3] | fp = *(r3);
| label_1:
0x08000840 ldrb r3, [fp, 8] | r3 = *(arg_8h);
0x08000844 cmp r3, 9 |
| if (r3 <= 9) {
0x08000848 subhi r3, r3, 0xa | r3 -= 0xa;
| }
| if (r3 <= 9) {
0x0800084c movhi r1, 1 | r1 = 1;
| }
| if (r3 > 9) {
0x08000850 movls r3, 1 | r3 = 1;
| }
| if (r3 <= 9) {
0x08000854 lslhi r3, r1, r3 | r3 = r1 << r3;
| }
0x08000858 cmp r7, r3 |
| if (r7 >= r3) {
0x0800085c bhs 0x8000938 | goto label_2;
| }
0x08000860 ldr r2, [sp, 8] | r2 = var_8h;
0x08000864 lsl r1, r7, 3 | r1 = r7 << 3;
0x08000868 str r1, [sp] | *(sp) = r1;
0x0800086c ldr r3, [r2, 4] | r3 = *((r2 + 4));
0x08000870 add r3, r3, 0x200 | r3 += 0x200;
0x08000874 add r3, r3, 1 | r3++;
0x08000878 str r3, [r2, 4] | *((r2 + 4)) = r3;
0x0800087c ldrb r0, [fp, 8] | r0 = *(arg_8h);
0x08000880 mov sb, 1 | sb = 1;
0x08000884 mov r6, 0 | r6 = 0;
0x08000888 cmp r0, 9 |
| if (r0 <= 9) {
0x0800088c lslhi r4, r7, 0xa | r4 = r7 << 0xa;
| }
0x08000890 add r7, r7, 1 | r7++;
| if (r0 > 9) {
0x08000894 movls r4, 0 | r4 = 0;
| }
0x08000898 str r7, [sp, 4] | var_4h_2 = r7;
0x0800089c add r3, fp, r4, lsl 2 | r3 = fp + (r4 << 2);
0x080008a0 lsl r8, r7, 0xa | r8 = r7 << 0xa;
0x080008a4 add sl, r3, 0x10 | sl = r3 + 0x10;
0x080008a8 b 0x80008cc | goto label_3;
| label_0:
0x080008ac add r3, r4, 4 | r3 = r4 + 4;
0x080008b0 mov r0, r7 | r0 = r7;
0x080008b4 mov r1, 0 | r1 = 0;
0x080008b8 add r3, fp, r3, lsl 2 | r3 = fp + (r3 << 2);
0x080008bc str r6, [r3, 4] | *((r3 + 4)) = r6;
0x080008c0 stmdaeq r0, {r1, r4, sb, ip, pc} | __asm ("stmdaeq r0, {r1, r4, sb, ip, pc}");
0x080008c4 ldrb r0, [fp, 8] | r0 = *(arg_8h);
| do {
0x080008c8 add r4, r4, 1 | r4++;
| label_3:
0x080008cc cmp r0, 9 |
| if (r0 > 9) {
0x080008d0 lslls r3, sb, r0 | r3 = sb << r0;
| }
| if (r0 <= 9) {
0x080008d4 movhi r3, r8 | r3 = r8;
| }
0x080008d8 cmp r4, r3 |
| if (r4 >= r3) {
0x080008dc bhs 0x8000908 | goto label_4;
| }
0x080008e0 ldr r7, [sl, 4]! | r7 = *((sl += 4));
0x080008e4 cmp r7, 0 |
0x080008e8 beq 0x80008c8 |
| } while (r7 == 0);
0x080008ec ldrsb r3, [r5, 0x32] | r3 = *((r5 + 0x32));
0x080008f0 cmp r3, 0 |
| if (r3 >= 0) {
0x080008f4 bge 0x80008ac | goto label_0;
| }
0x080008f8 mov r1, r7 | r1 = r7;
0x080008fc mov r0, r5 | r0 = r5;
0x08000900 bl 0x80004c0 | hash_netnet4_ext_cleanup ();
0x08000904 b 0x80008ac | goto label_0;
| label_4:
0x08000908 ldr r3, [fp, 0x10] | r3 = *(arg_10h);
0x0800090c mov ip, 0 |
0x08000910 ldr r2, [sp] | r2 = *(sp);
0x08000914 movw r1, 0x201 | r1 = 0x201;
0x08000918 ldr r0, [pc, 0x34] | r0 = *(0x8000950);
0x0800091c ldr r7, [sp, 4] | r7 = var_4h_2;
0x08000920 str ip, [r3, r2] | *((r3 + r2)) = ip;
0x08000924 ldr r3, [fp, 0x10] | r3 = *(arg_10h);
0x08000928 add r3, r3, r2 | r3 += r2;
0x0800092c str ip, [r3, 4] | *((r3 + 4)) = ip;
0x08000930 stmdaeq r0, {r1, r3, sb, ip, pc} | __asm ("stmdaeq r0, {r1, r3, sb, ip, pc}");
0x08000934 b 0x8000840 | goto label_1;
| label_2:
0x08000938 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0800093c mov r2, 0x180 | r2 = 0x180;
0x08000940 mov r1, 0 | r1 = 0;
0x08000944 add r0, r3, 0x58 | r0 = r3 + 0x58;
0x08000948 add sp, sp, 0x14 |
0x0800094c pop {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x08000950 stmdaeq r0, {r1, sb, ip, pc} | __asm ("stmdaeq r0, {r1, sb, ip, pc}");
0x08000954 stmdaeq r0, {r4, r5, r6} | __asm ("stmdaeq r0, {r4, r5, r6}");
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/modules/5.10.52-axis8/kernel/net/netfilter/ipset/ip_set_hash_netnet.ko @ 0x8000544 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) sym.hash_netnet6_flush () | void hash_netnet6_flush (int32_t arg_8h, int32_t arg_10h, int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_14h;
| r0 = arg1;
0x08000544 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x08000548 mov r5, r0 | r5 = r0;
0x0800054c mov r7, 0 | r7 = 0;
0x08000550 sub sp, sp, 0x14 |
0x08000554 mov r3, sp | r3 = sp;
0x08000558 bic r3, r3, 0x1fc0 | r3 = BIT_MASK (r3, 0x1fc0);
0x0800055c bic r3, r3, 0x3f | r3 = BIT_MASK (r3, 0x3f);
0x08000560 str r3, [sp, 8] | var_8h = r3;
0x08000564 ldr r3, [r0, 0x54] | r3 = *((r0 + 0x54));
0x08000568 str r3, [sp, 0xc] | var_ch = r3;
0x0800056c ldr fp, [r3] | fp = *(r3);
| label_1:
0x08000570 ldrb r3, [fp, 8] | r3 = *(arg_8h);
0x08000574 cmp r3, 9 |
| if (r3 <= 9) {
0x08000578 subhi r3, r3, 0xa | r3 -= 0xa;
| }
| if (r3 <= 9) {
0x0800057c movhi r1, 1 | r1 = 1;
| }
| if (r3 > 9) {
0x08000580 movls r3, 1 | r3 = 1;
| }
| if (r3 <= 9) {
0x08000584 lslhi r3, r1, r3 | r3 = r1 << r3;
| }
0x08000588 cmp r7, r3 |
| if (r7 >= r3) {
0x0800058c bhs 0x8000668 | goto label_2;
| }
0x08000590 ldr r2, [sp, 8] | r2 = var_8h;
0x08000594 lsl r1, r7, 3 | r1 = r7 << 3;
0x08000598 str r1, [sp] | *(sp) = r1;
0x0800059c ldr r3, [r2, 4] | r3 = *((r2 + 4));
0x080005a0 add r3, r3, 0x200 | r3 += 0x200;
0x080005a4 add r3, r3, 1 | r3++;
0x080005a8 str r3, [r2, 4] | *((r2 + 4)) = r3;
0x080005ac ldrb r0, [fp, 8] | r0 = *(arg_8h);
0x080005b0 mov sb, 1 | sb = 1;
0x080005b4 mov r6, 0 | r6 = 0;
0x080005b8 cmp r0, 9 |
| if (r0 <= 9) {
0x080005bc lslhi r4, r7, 0xa | r4 = r7 << 0xa;
| }
0x080005c0 add r7, r7, 1 | r7++;
| if (r0 > 9) {
0x080005c4 movls r4, 0 | r4 = 0;
| }
0x080005c8 str r7, [sp, 4] | var_4h = r7;
0x080005cc add r3, fp, r4, lsl 2 | r3 = fp + (r4 << 2);
0x080005d0 lsl r8, r7, 0xa | r8 = r7 << 0xa;
0x080005d4 add sl, r3, 0x10 | sl = r3 + 0x10;
0x080005d8 b 0x80005fc | goto label_3;
| label_0:
0x080005dc add r3, r4, 4 | r3 = r4 + 4;
0x080005e0 mov r0, r7 | r0 = r7;
0x080005e4 mov r1, 0 | r1 = 0;
0x080005e8 add r3, fp, r3, lsl 2 | r3 = fp + (r3 << 2);
0x080005ec str r6, [r3, 4] | *((r3 + 4)) = r6;
0x080005f0 stmdaeq r0, {r1, r4, sb, ip, pc} | __asm ("stmdaeq r0, {r1, r4, sb, ip, pc}");
0x080005f4 ldrb r0, [fp, 8] | r0 = *(arg_8h);
| do {
0x080005f8 add r4, r4, 1 | r4++;
| label_3:
0x080005fc cmp r0, 9 |
| if (r0 > 9) {
0x08000600 lslls r3, sb, r0 | r3 = sb << r0;
| }
| if (r0 <= 9) {
0x08000604 movhi r3, r8 | r3 = r8;
| }
0x08000608 cmp r4, r3 |
| if (r4 >= r3) {
0x0800060c bhs 0x8000638 | goto label_4;
| }
0x08000610 ldr r7, [sl, 4]! | r7 = *((sl += 4));
0x08000614 cmp r7, 0 |
0x08000618 beq 0x80005f8 |
| } while (r7 == 0);
0x0800061c ldrsb r3, [r5, 0x32] | r3 = *((r5 + 0x32));
0x08000620 cmp r3, 0 |
| if (r3 >= 0) {
0x08000624 bge 0x80005dc | goto label_0;
| }
0x08000628 mov r1, r7 | r1 = r7;
0x0800062c mov r0, r5 | r0 = r5;
0x08000630 bl 0x80004c0 | hash_netnet4_ext_cleanup ();
0x08000634 b 0x80005dc | goto label_0;
| label_4:
0x08000638 ldr r3, [fp, 0x10] | r3 = *(arg_10h);
0x0800063c mov ip, 0 |
0x08000640 ldr r2, [sp] | r2 = *(sp);
0x08000644 movw r1, 0x201 | r1 = 0x201;
0x08000648 ldr r0, [pc, 0x34] | r0 = *(0x8000680);
0x0800064c ldr r7, [sp, 4] | r7 = var_4h;
0x08000650 str ip, [r3, r2] | *((r3 + r2)) = ip;
0x08000654 ldr r3, [fp, 0x10] | r3 = *(arg_10h);
0x08000658 add r3, r3, r2 | r3 += r2;
0x0800065c str ip, [r3, 4] | *((r3 + 4)) = ip;
0x08000660 stmdaeq r0, {r1, r3, sb, ip, pc} | __asm ("stmdaeq r0, {r1, r3, sb, ip, pc}");
0x08000664 b 0x8000570 | goto label_1;
| label_2:
0x08000668 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0800066c mov r2, 0x600 | r2 = 0x600;
0x08000670 mov r1, 0 | r1 = 0;
0x08000674 add r0, r3, 0x6c | r0 = r3 + 0x6c;
0x08000678 add sp, sp, 0x14 |
0x0800067c pop {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x08000680 stmdaeq r0, {r1, sb, ip, pc} | __asm ("stmdaeq r0, {r1, sb, ip, pc}");
0x08000684 stmdaeq r0, {r4, r5, r6} | __asm ("stmdaeq r0, {r4, r5, r6}");
| }
[*] Function fprintf used 1 times ip_set_hash_netnet.ko