[*] Binary protection state of std2parser2env

  
  	Full RELRO     No Canary found   NX disabled  PIE enabled  No RPATH     No RUNPATH   No Symbols


[*] Function printf tear down of std2parser2env

    ; assembly                           | /* r2dec pseudo code output */
                                         | /* /logs/firmware/unblob_extracted/firmware_extract/4325012-58052244.squashfs_v4_le_extract/usr/bin/std2parser2env @ 0x9a0 */
                                         | #include <stdint.h>
                                         |  
    ; (fcn) main ()                      | int32_t main () {
                                         |     /* [13] -r-x section size 1344 named .text */
    0x000009a0 lui gp, 2                 |     
    0x000009a4 addiu gp, gp, -0x6990     |     
    0x000009a8 addu gp, gp, t9           |     gp += t9;
    0x000009ac addiu sp, sp, -0x48       |     
    0x000009b0 lw t9, -0x7fa8(gp)        |     t9 = sym.imp.ax_log_syslog;
    0x000009b4 sw gp, 0x18(sp)           |     *(var_18h) = gp;
    0x000009b8 sw s1, 0x28(sp)           |     *(var_28h) = s1;
    0x000009bc sw s0, 0x24(sp)           |     *(var_24h) = s0;
    0x000009c0 sw ra, 0x44(sp)           |     *(var_44h) = ra;
    0x000009c4 sw s7, 0x40(sp)           |     *(var_40h) = s7;
    0x000009c8 sw s6, 0x3c(sp)           |     *(var_3ch) = s6;
    0x000009cc sw s5, 0x38(sp)           |     *(var_38h) = s5;
    0x000009d0 sw s4, 0x34(sp)           |     *(var_34h) = s4;
    0x000009d4 sw s3, 0x30(sp)           |     *(var_30h) = s3;
    0x000009d8 sw s2, 0x2c(sp)           |     *(var_2ch) = s2;
    0x000009dc move s0, a0               |     s0 = a0;
    0x000009e0 move s1, a1               |     s1 = a1;
    0x000009e4 jalr t9                   |     t9 ();
    0x000009e8 addiu v0, zero, 2         |     v0 = 2;
    0x000009ec lw gp, 0x18(sp)           |     gp = *(var_18h);
                                         |     if (s0 != v0) {
    0x000009f0 beq s0, v0, 0xa4c         |         
    0x000009f4 lw a3, -0x7fdc(gp)        |         a3 = *((gp - 8183));
    0x000009f8 lw a2, -0x7fdc(gp)        |         a2 = *((gp - 8183));
    0x000009fc lw t9, -0x7f9c(gp)        |         t9 = sym.imp.g_log;
    0x00000a00 addiu s0, s0, -1          |         s0 += -1;
    0x00000a04 sw s0, 0x10(sp)           |         *(var_10h) = s0;
    0x00000a08 addiu a3, a3, 0x1018      |         a3 += 0x1018;
    0x00000a0c addiu a2, a2, 0xfe8       |         a2 += str._sIllegal_number_of_parameters___d____expected_1;
    0x00000a10 addiu a1, zero, 0x100     |         a1 = 0x100;
    0x00000a14 move a0, zero             |         a0 = 0;
    0x00000a18 jalr t9                   |         t9 ();
    0x00000a1c addiu v0, zero, 1         |         v0 = 1;
                                         | label_2:
    0x00000a20 lw ra, 0x44(sp)           |         ra = *(var_44h);
    0x00000a24 lw s7, 0x40(sp)           |         s7 = *(var_40h);
    0x00000a28 lw s6, 0x3c(sp)           |         s6 = *(var_3ch);
    0x00000a2c lw s5, 0x38(sp)           |         s5 = *(var_38h);
    0x00000a30 lw s4, 0x34(sp)           |         s4 = *(var_34h);
    0x00000a34 lw s3, 0x30(sp)           |         s3 = *(var_30h);
    0x00000a38 lw s2, 0x2c(sp)           |         s2 = *(var_2ch);
    0x00000a3c lw s1, 0x28(sp)           |         s1 = *(var_28h);
    0x00000a40 lw s0, 0x24(sp)           |         s0 = *(var_24h);
    0x00000a44 addiu sp, sp, 0x48        |         
    0x00000a48 jr ra                     |         return v0;
                                         |     }
    0x00000a4c lw s0, 4(s1)              |     s0 = *((s1 + 1));
    0x00000a50 lw t9, -0x7fb0(gp)        |     t9 = sym.imp.std2parser_opencfg;
    0x00000a54 move a0, s0               |     a0 = s0;
    0x00000a58 jalr t9                   |     t9 ();
    0x00000a5c lw gp, 0x18(sp)           |     gp = *(var_18h);
                                         |     if (v0 == 0) {
    0x00000a60 beqz v0, 0xb9c            |         goto label_3;
                                         |     }
    0x00000a64 lw t9, -0x7f80(gp)        |     t9 = sym.imp.std2parser_getcfg;
    0x00000a68 lw s6, -0x7fdc(gp)        |     s6 = *((gp - 8183));
    0x00000a6c lw s2, -0x7fdc(gp)        |     s2 = *((gp - 8183));
    0x00000a70 lw s4, -0x7fdc(gp)        |     s4 = *((gp - 8183));
    0x00000a74 lw s3, -0x7fdc(gp)        |     s3 = *((gp - 8183));
    0x00000a78 lw s5, -0x7fdc(gp)        |     s5 = *((gp - 8183));
    0x00000a7c lw s1, -0x7fa0(gp)        |     s1 = *((gp - 8168));
    0x00000a80 addiu s7, s6, 0x1018      |     s7 = s6 + 0x1018;
    0x00000a84 jalr t9                   |     t9 ();
    0x00000a88 addiu s2, s2, 0xdb0       |     s2 += fcn.00000db0;
    0x00000a8c addiu s4, s4, 0x1038      |     s4 += 0x1038;
    0x00000a90 addiu s3, s3, 0x103c      |     s3 += 0x103c;
    0x00000a94 lw gp, 0x18(sp)           |     gp = *(var_18h);
    0x00000a98 move s0, v0               |     s0 = v0;
                                         |     if (v0 == 0) {
    0x00000a9c beqz v0, 0xb74            |         goto label_4;
                                         |     }
                                         | label_1:
    0x00000aa0 move t9, s2               |     t9 = s2;
    0x00000aa4 lw a0, (s0)               |     a0 = *(s0);
    0x00000aa8 bal 0xdb0                 |     fcn_00000db0 ();
    0x00000aac move t9, s2               |     t9 = s2;
    0x00000ab0 lw a0, 4(s0)              |     a0 = *((s0 + 1));
    0x00000ab4 bal 0xdb0                 |     fcn_00000db0 ();
    0x00000ab8 lw gp, 0x18(sp)           |     gp = *(var_18h);
    0x00000abc lw v0, 4(s0)              |     v0 = *((s0 + 1));
    0x00000ac0 lw a3, (s0)               |     a3 = *(s0);
    0x00000ac4 lw t9, -0x7fa4(gp)        |     t9 = sym.imp.__printf_chk
    0x00000ac8 move a2, s7               |     a2 = s7;
    0x00000acc addiu a1, s5, 0x1028      |     a1 = s5 + str._sSTD2__s__s;
    0x00000ad0 addiu a0, zero, 1         |     a0 = 1;
    0x00000ad4 sw v0, 0x10(sp)           |     *(var_10h) = v0;
    0x00000ad8 jalr t9                   |     t9 ();
    0x00000adc lw gp, 0x18(sp)           |     gp = *(var_18h);
    0x00000ae0 lw s0, 8(s0)              |     s0 = *((s0 + 2));
    0x00000ae4 lw a1, (s1)               |     a1 = *(s1);
    0x00000ae8 lw t9, -0x7f84(gp)        |     t9 = sym.imp._IO_putc;
    0x00000aec addiu a0, zero, 0x27      |     a0 = 0x27;
    0x00000af0 jalr t9                   |     t9 ();
    0x00000af4 lb a0, (s0)               |     a0 = *(s0);
    0x00000af8 lw gp, 0x18(sp)           |     gp = *(var_18h);
                                         |     if (a0 == 0) {
    0x00000afc beqz a0, 0xb48            |         goto label_5;
                                         |     }
    0x00000b00 addiu s7, zero, 0x27      |     s7 = 0x27;
    0x00000b04 b 0xb20                   |     
                                         |     while (a0 != s7) {
    0x00000b08 lw a1, (s1)               |         a1 = *(s1);
    0x00000b0c addiu s0, s0, 1           |         s0++;
    0x00000b10 jalr t9                   |         t9 ();
    0x00000b14 lb a0, (s0)               |         a0 = *(s0);
    0x00000b18 lw gp, 0x18(sp)           |         gp = *(var_18h);
                                         |         if (a0 == 0) {
    0x00000b1c beqz a0, 0xb48            |             goto label_5;
                                         |         }
                                         | label_0:
    0x00000b20 lw t9, -0x7f84(gp)        |         t9 = sym.imp._IO_putc;
    0x00000b24 bne a0, s7, 0xb08         |         
                                         |     }
    0x00000b28 lw t9, -0x7fa4(gp)        |     t9 = sym.imp.__printf_chk
    0x00000b2c addiu s0, s0, 1           |     s0++;
    0x00000b30 addiu a0, zero, 1         |     a0 = 1;
    0x00000b34 move a1, s4               |     a1 = s4;
    0x00000b38 jalr t9                   |     t9 ();
    0x00000b3c lb a0, (s0)               |     a0 = *(s0);
    0x00000b40 lw gp, 0x18(sp)           |     gp = *(var_18h);
                                         |     if (a0 != 0) {
    0x00000b44 bnez a0, 0xb20            |         goto label_0;
                                         |     }
                                         | label_5:
    0x00000b48 lw t9, -0x7f84(gp)        |     t9 = sym.imp._IO_putc;
    0x00000b4c lw a1, (s1)               |     a1 = *(s1);
    0x00000b50 addiu a0, zero, 0x27      |     a0 = 0x27;
    0x00000b54 jalr t9                   |     t9 ();
    0x00000b58 lw gp, 0x18(sp)           |     gp = *(var_18h);
    0x00000b5c lw t9, -0x7f80(gp)        |     t9 = sym.imp.std2parser_getcfg;
    0x00000b60 move s7, s3               |     s7 = s3;
    0x00000b64 jalr t9                   |     t9 ();
    0x00000b68 move s0, v0               |     s0 = v0;
    0x00000b6c lw gp, 0x18(sp)           |     gp = *(var_18h);
                                         |     if (v0 != 0) {
    0x00000b70 bnez v0, 0xaa0            |         goto label_1;
                                         |     }
                                         | label_4:
    0x00000b74 lw t9, -0x7fac(gp)        |     t9 = sym.imp.std2parser_ok;
    0x00000b78 jalr t9                   |     t9 ();
    0x00000b7c nop                       |     
    0x00000b80 lw gp, 0x18(sp)           |     gp = *(var_18h);
    0x00000b84 beqz v0, 0xbfc            |     
                                         |     while (1) {
    0x00000b88 lw t9, -0x7f88(gp)        |         t9 = sym.imp.std2parser_closecfg;
    0x00000b8c jalr t9                   |         t9 ();
    0x00000b90 nop                       |         
    0x00000b94 move v0, zero             |         v0 = 0;
    0x00000b98 b 0xa20                   |         goto label_2;
                                         | label_3:
    0x00000b9c lw t9, -0x7f98(gp)        |         t9 = sym.imp.__errno_location;
    0x00000ba0 jalr t9                   |         t9 ();
    0x00000ba4 nop                       |         
    0x00000ba8 lw gp, 0x18(sp)           |         gp = *(var_18h);
    0x00000bac lw t9, -0x7f8c(gp)        |         t9 = sym.imp.strerror;
    0x00000bb0 lw a0, (v0)               |         a0 = *(v0);
    0x00000bb4 jalr t9                   |         t9 ();
    0x00000bb8 lw gp, 0x18(sp)           |         gp = *(var_18h);
    0x00000bbc sw v0, 0x14(sp)           |         *(var_14h) = v0;
    0x00000bc0 addiu a1, zero, 0x100     |         a1 = 0x100;
    0x00000bc4 lw a3, -0x7fdc(gp)        |         a3 = *((gp - 8183));
    0x00000bc8 lw a2, -0x7fdc(gp)        |         a2 = *((gp - 8183));
    0x00000bcc lw t9, -0x7f9c(gp)        |         t9 = sym.imp.g_log;
    0x00000bd0 addiu a3, a3, 0x1018      |         a3 += 0x1018;
    0x00000bd4 addiu a2, a2, 0x101c      |         a2 += str._s_s:__s;
    0x00000bd8 move a0, zero             |         a0 = 0;
    0x00000bdc sw s0, 0x10(sp)           |         *(var_10h) = s0;
    0x00000be0 jalr t9                   |         t9 ();
    0x00000be4 lw gp, 0x18(sp)           |         gp = *(var_18h);
    0x00000be8 lw t9, -0x7f88(gp)        |         t9 = sym.imp.std2parser_closecfg;
    0x00000bec jalr t9                   |         t9 ();
    0x00000bf0 nop                       |         
    0x00000bf4 addiu v0, zero, 2         |         v0 = 2;
    0x00000bf8 b 0xa20                   |         goto label_2;
    0x00000bfc lw t9, -0x7f74(gp)        |         t9 = sym.imp.std2parser_err_str;
    0x00000c00 jalr t9                   |         t9 ();
    0x00000c04 nop                       |         
    0x00000c08 lw gp, 0x18(sp)           |         gp = *(var_18h);
    0x00000c0c sw v0, 0x10(sp)           |         *(var_10h) = v0;
    0x00000c10 addiu a3, s6, 0x1018      |         a3 = s6 + 0x1018;
    0x00000c14 lw a2, -0x7fdc(gp)        |         a2 = *((gp - 8183));
    0x00000c18 lw t9, -0x7f9c(gp)        |         t9 = sym.imp.g_log;
    0x00000c1c addiu a2, a2, 0x1040      |         a2 += str._s_s;
    0x00000c20 addiu a1, zero, 0x100     |         a1 = 0x100;
    0x00000c24 move a0, zero             |         a0 = 0;
    0x00000c28 jalr t9                   |         t9 ();
    0x00000c2c lw gp, 0x18(sp)           |         gp = *(var_18h);
    0x00000c30 b 0xb88                   |         
                                         |     }
                                         | }

[*] Function printf used 3 times std2parser2env