[*] Binary protection state of libss.so.2.0
Full RELRO Canary found NX enabled DSO No RPATH No RUNPATH No Symbols
[*] Function fprintf tear down of libss.so.2.0
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libss.so.2.0 @ 0x2878 */
| #include <stdint.h>
|
; (fcn) sym.ss_page_stdin () | void ss_page_stdin () {
| FILE * stream;
| int16_t var_84h;
| int16_t var_0h;
| int16_t var_d4h;
| if (? < ?) {
0x00002878 strhs r4, [r3], -0xa30 | *(r3) = r4;
| r3 += -0xa30;
| }
0x0000287c ldr r3, [pc, 0xc0] |
0x0000287e push {r7, lr} |
0x00002880 sub sp, 0xd8 |
0x00002882 add r2, pc | r2 += pc;
0x00002884 ldr r5, [pc, 0xbc] |
0x00002886 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x00002888 add r5, pc | r5 = 0x51d0;
0x0000288a ldr r3, [r3] | r3 = *(0x2940);
0x0000288c str r3, [sp, 0xd4] | var_d4h = r3;
0x0000288e mov.w r3, 0 | r3 = 0;
| do {
0x00002892 mov r0, r4 | r0 = r4;
0x00002894 adds r4, 1 | r4++;
0x00002896 blx 0x1710 | fcn_00001710 ();
0x0000289a cmp r4, 0x20 |
0x0000289c bne 0x2892 |
| } while (r4 != 0x20);
0x0000289e movs r1, 0 | r1 = 0;
0x000028a0 movs r0, 2 | r0 = 2;
0x000028a2 blx 0x1494 | fcn_00001494 ();
0x000028a6 add r4, sp, 4 | r4 += stream;
0x000028a8 movs r1, 0 | r1 = 0;
0x000028aa mov r2, r4 | r2 = r4;
0x000028ac mov r0, r1 | r0 = r1;
0x000028ae blx 0x1418 | setjmp (r0);
0x000028b2 movs r1, 2 | r1 = 2;
0x000028b4 mov r0, r4 | r0 = r4;
0x000028b6 blx 0x161c | fclose (r0);
0x000028ba mov r1, r4 | r1 = r4;
0x000028bc movs r2, 0 | r2 = 0;
0x000028be movs r0, 2 | r0 = 2;
0x000028c0 blx 0x1418 | setjmp (r0);
0x000028c4 ldr r3, [pc, 0x80] | r3 = *(0x2948);
0x000028c6 ldr r4, [r5, r3] | r4 = *((r5 + r3));
0x000028c8 ldr r1, [r4] | r1 = *(r4);
| if (r1 == 0) {
0x000028ca cbz r1, 0x2920 | goto label_4;
| }
| label_3:
0x000028cc movs r2, 0 | r2 = 0;
0x000028ce mov r0, r1 | r0 = r1;
0x000028d0 blx 0x147c | fcn_0000147c ();
0x000028d4 add r7, sp, 0x84 | r7 += var_84h;
0x000028d6 blx 0x15b8 | r0 = fcn_000015b8 ();
0x000028da mov r6, r0 | r6 = r0;
| do {
| label_2:
0x000028dc movs r2, 0x50 | r2 = 0x50;
0x000028de mov r1, r7 | r1 = r7;
0x000028e0 movs r0, 0 | r0 = 0;
0x000028e2 blx 0x13f0 | r0 = fcn_000013f0 ();
0x000028e6 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 <= r0) {
0x000028e8 ble 0x291a | goto label_5;
| }
0x000028ea mov r5, r7 | r5 = r7;
| label_1:
0x000028ec mov r2, r4 | r2 = r4;
0x000028ee mov r1, r5 | r1 = r5;
0x000028f0 movs r0, 1 | r0 = 1;
0x000028f2 blx 0x1610 | r0 = fprintf_chk ()
0x000028f6 cmp r0, 0 |
| if (r0 < 0) {
0x000028f8 blt 0x290e | goto label_6;
| }
| label_0:
0x000028fa subs r4, r4, r0 | r4 -= r0;
0x000028fc add r5, r0 | r5 += r0;
0x000028fe beq 0x28dc |
| } while (r4 == r4);
0x00002900 mov r2, r4 | r2 = r4;
0x00002902 mov r1, r5 | r1 = r5;
0x00002904 movs r0, 1 | r0 = 1;
0x00002906 blx 0x1610 | r0 = fprintf_chk ()
0x0000290a cmp r0, 0 |
| if (r0 >= 0) {
0x0000290c bge 0x28fa | goto label_0;
| }
| label_6:
0x0000290e ldr r3, [r6] | r3 = *(r6);
0x00002910 cmp r3, 4 |
0x00002912 it ne |
| if (r3 == 4) {
0x00002914 cmpne r3, 0xb | __asm ("cmpne r3, 0xb");
| goto label_7;
| }
| if (r3 == 4) {
| label_7:
0x00002916 beq 0x28ec | goto label_1;
| }
0x00002918 b 0x28dc | goto label_2;
| label_5:
0x0000291a ldr r0, [r6] | r0 = *(r6);
0x0000291c blx 0x1588 | fcn_00001588 ();
| label_4:
0x00002920 ldr r0, [pc, 0x28] |
0x00002922 add r0, pc | r0 = 0x5272;
0x00002924 blx 0x143c | r0 = free (r0);
0x00002928 mov r1, r0 | r1 = r0;
| if (r0 != 0) {
0x0000292a cbz r0, 0x2930 |
0x0000292c str r0, [r4] | *(r4) = r0;
0x0000292e b 0x28cc | goto label_3;
| }
0x00002930 ldr r3, [pc, 0x1c] |
0x00002932 add r3, pc | r3 = 0x5286;
0x00002934 mov r1, r3 | r1 = r3;
0x00002936 str r3, [r4] | *(r4) = r3;
0x00002938 b 0x28cc | goto label_3;
| }
[*] Function fprintf used 3 times libss.so.2.0