[*] Binary protection state of blkid.util-linux
Full RELRO Canary found NX disabled PIE enabled No RPATH No RUNPATH No Symbols
[*] Function sprintf tear down of blkid.util-linux
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/4325012-58052244.squashfs_v4_le_extract/usr/sbin/blkid.util-linux @ 0x10f64 */
| #include <stdint.h>
|
; (fcn) sym.ul_new_path () | void ul_new_path () {
0x00010f64 lui gp, 2 |
0x00010f68 addiu gp, gp, 0x50ec |
0x00010f6c addu gp, gp, t9 | gp += t9;
0x00010f70 addiu sp, sp, -0x40 |
0x00010f74 lw t9, -0x7df0(gp) | t9 = sym.imp.calloc;
0x00010f78 sw s1, 0x30(sp) | *(var_30h) = s1;
0x00010f7c lw s1, -0x7bc0(gp) | s1 = *((gp - 7920));
0x00010f80 sw a1, 0x44(sp) | *(arg_44h) = a1;
0x00010f84 sw gp, 0x18(sp) | *(var_18h) = gp;
0x00010f88 lw v0, (s1) | v0 = *(s1);
0x00010f8c sw s2, 0x34(sp) | *(var_34h) = s2;
0x00010f90 sw s0, 0x2c(sp) | *(var_2ch) = s0;
0x00010f94 sw ra, 0x3c(sp) | *(var_3ch) = ra;
0x00010f98 sw s3, 0x38(sp) | *(var_38h) = s3;
0x00010f9c move s2, a0 | s2 = a0;
0x00010fa0 sw a2, 0x48(sp) | *(arg_48h) = a2;
0x00010fa4 sw a3, 0x4c(sp) | *(arg_4ch) = a3;
0x00010fa8 addiu a1, zero, 0x101c | a1 = 0x101c;
0x00010fac addiu a0, zero, 1 | a0 = 1;
0x00010fb0 sw v0, 0x24(sp) | *(var_24h) = v0;
0x00010fb4 jalr t9 | t9 ();
0x00010fb8 nop |
0x00010fbc move s0, v0 | s0 = v0;
0x00010fc0 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 == 0) {
0x00010fc4 beqz v0, 0x11020 | goto label_0;
| }
0x00010fc8 lw v0, -0x7fdc(gp) | v0 = *((gp - 8183));
0x00010fcc lw v0, -0x1ae0(v0) | v0 = *((v0 - 1720));
0x00010fd0 andi v0, v0, 4 | v0 &= 4;
0x00010fd4 lw v0, -0x7b90(gp) | v0 = *((gp - 7908));
0x00010fd8 bnez v0, 0x1104c |
| while (1) {
0x00010fdc addiu v0, zero, 1 | v0 = 1;
0x00010fe0 sw v0, 8(s0) | *((s0 + 2)) = v0;
0x00010fe4 addiu v0, zero, -1 | v0 = -1;
0x00010fe8 sw v0, (s0) | *(s0) = v0;
| if (s2 != 0) {
0x00010fec beqz s2, 0x11020 |
0x00010ff0 lw t9, -0x7ce4(gp) | t9 = sym.imp.__vasprintf_chk
0x00010ff4 addiu a3, sp, 0x44 | a3 = sp + 0x44;
0x00010ff8 sw a3, 0x20(sp) | *(var_20h) = a3;
0x00010ffc move a2, s2 | a2 = s2;
0x00011000 addiu a1, zero, 1 | a1 = 1;
0x00011004 addiu a0, s0, 4 | a0 = s0 + 4;
0x00011008 jalr t9 | t9 ();
0x0001100c lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 < 0) {
0x00011010 bltz v0, 0x110b4 | goto label_1;
| }
0x00011014 lw v0, 4(s0) | v0 = *((s0 + 1));
0x00011018 lw t9, -0x7f60(gp) | t9 = sym.ul_unref_path;
| if (v0 == 0) {
0x0001101c beqz v0, 0x110b8 | goto label_2;
| }
| }
| label_0:
0x00011020 lw a0, 0x24(sp) | a0 = *(var_24h);
0x00011024 lw v1, (s1) | v1 = *(s1);
0x00011028 move v0, s0 | v0 = s0;
| if (a0 != v1) {
0x0001102c bne a0, v1, 0x110cc | goto label_3;
| }
0x00011030 lw ra, 0x3c(sp) | ra = *(var_3ch);
0x00011034 lw s3, 0x38(sp) | s3 = *(var_38h);
0x00011038 lw s2, 0x34(sp) | s2 = *(var_34h);
0x0001103c lw s1, 0x30(sp) | s1 = *(var_30h);
0x00011040 lw s0, 0x2c(sp) | s0 = *(var_2ch);
0x00011044 addiu sp, sp, 0x40 |
0x00011048 jr ra | return v0;
0x0001104c lw t9, -0x7c4c(gp) | t9 = sym.imp.getpid;
0x00011050 lw s3, (v0) | s3 = *(v0);
0x00011054 jalr t9 | t9 ();
0x00011058 lw gp, 0x18(sp) | gp = *(var_18h);
0x0001105c move a3, v0 | a3 = v0;
0x00011060 addiu a1, zero, 1 | a1 = 1;
0x00011064 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
0x00011068 lw a2, -0x7fd0(gp) | a2 = *((gp - 8180));
| /* esilref: 'CXT' */
0x0001106c addiu v0, v0, -0x3490 | v0 += -0x3490;
0x00011070 sw v0, 0x14(sp) | *(var_14h) = v0;
0x00011074 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
0x00011078 lw t9, -0x7da0(gp) | t9 = sym.imp.__fprintf_chk;
| /* str.ulpath */
0x0001107c addiu v0, v0, -0x2b18 | v0 += -0x2b18;
| /* str._d:__s:__8s:_ */
0x00011080 addiu a2, a2, -0x34a0 | a2 += -0x34a0;
0x00011084 move a0, s3 | a0 = s3;
0x00011088 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0001108c jalr t9 | t9 ();
0x00011090 lw gp, 0x18(sp) | gp = *(var_18h);
0x00011094 move a0, s0 | a0 = s0;
0x00011098 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x0001109c lw t9, -0x7f74(gp) | t9 = *(gp);
| /* fcn.00010320 */
0x000110a0 addiu t9, t9, 0x320 | t9 += 0x320;
| /* str.alloc */
0x000110a4 addiu a1, a1, -0x2a68 | a1 += -0x2a68;
0x000110a8 bal 0x10320 | fcn_00010320 ();
0x000110ac lw gp, 0x18(sp) | gp = *(var_18h);
0x000110b0 b 0x10fdc |
| }
| label_1:
0x000110b4 lw t9, -0x7f60(gp) | t9 = sym.ul_unref_path;
| label_2:
0x000110b8 move a0, s0 | a0 = s0;
0x000110bc bal 0x10e3c | sym_ul_unref_path ();
0x000110c0 move s0, zero | s0 = 0;
0x000110c4 lw gp, 0x18(sp) | gp = *(var_18h);
0x000110c8 b 0x11020 | goto label_0;
| label_3:
0x000110cc lw t9, -0x7bec(gp) | t9 = sym.imp.__stack_chk_fail;
0x000110d0 jalr t9 | t9 ();
0x000110d4 nop |
| if (a0 != 0) {
0x000110d8 beqz a0, 0x110f0 |
0x000110dc nop |
0x000110e0 lw v0, (a0) | v0 = *(a0);
0x000110e4 nor v0, zero, v0 | __asm ("nor v0, zero, v0");
0x000110e8 srl v0, v0, 0x1f | v0 >>= 0x1f;
0x000110ec jr ra | return v0;
| }
0x000110f0 move v0, zero | v0 = 0;
0x000110f4 jr ra | return v0;
| }
[*] Function sprintf used 2 times blkid.util-linux