[*] Binary protection state of zeroconf-ip
Full RELRO Canary found NX disabled PIE enabled No RPATH No RUNPATH No Symbols
[*] Function fprintf tear down of zeroconf-ip
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/4325012-58052244.squashfs_v4_le_extract/usr/sbin/zeroconf-ip @ 0x1de4 */
| #include <stdint.h>
|
; (fcn) fcn.00001de4 () | void fcn_00001de4 () {
0x00001de4 lui gp, 2 |
0x00001de8 addiu gp, gp, -0x4dc4 |
0x00001dec addu gp, gp, t9 | gp += t9;
0x00001df0 lw v0, -0x7eec(gp) | v0 = *((gp - 8123));
0x00001df4 addiu sp, sp, -0x20 |
0x00001df8 lw a2, -0x7fdc(gp) | a2 = *((gp - 8183));
0x00001dfc lw t9, -0x7fa4(gp) | t9 = sym.imp.__fprintf_chk
0x00001e00 move a3, a0 | a3 = a0;
0x00001e04 lw a0, (v0) | a0 = *(v0);
0x00001e08 addiu a2, a2, 0x3cb8 | a2 += str.zeroconf_ip:_unrecognized_option___s_n;
0x00001e0c sw gp, 0x10(sp) | *(var_10h) = gp;
0x00001e10 sw ra, 0x1c(sp) | *(var_1ch) = ra;
0x00001e14 addiu a1, zero, 1 | a1 = 1;
0x00001e18 jalr t9 | t9 ();
0x00001e1c lw gp, 0x10(sp) | gp = *(var_10h);
0x00001e20 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00001e24 addiu t9, t9, 0x1cc0 | t9 += fcn.00001cc0;
0x00001e28 addiu a0, zero, 1 | a0 = 1;
0x00001e2c bal 0x1cc0 | fcn_00001cc0 ();
0x00001e30 addiu v1, zero, 8 | v1 = 8;
0x00001e34 sh v1, 2(a3) | *((a3 + 1)) = v1;
0x00001e38 addiu v0, zero, 0x100 | v0 = 0x100;
0x00001e3c addiu v1, zero, 0x406 | v1 = 0x406;
0x00001e40 sh v0, (a3) | *(a3) = v0;
0x00001e44 sh v0, 6(a3) | *((a3 + 3)) = v0;
0x00001e48 sh v1, 4(a3) | *((a3 + 2)) = v1;
0x00001e4c lw v1, 0x14(a0) | v1 = *((a0 + 5));
0x00001e50 addiu v0, a3, 8 | v0 = a3 + 8;
0x00001e54 swl v1, 0xb(a3) | __asm ("swl v1, 0xb(a3)");
0x00001e58 swr v1, (v0) | __asm ("swr v1, (v0)");
0x00001e5c lhu a0, 0x18(a0) | a0 = *((a0 + 12));
0x00001e60 addiu v1, a3, 0xe | v1 = a3 + 0xe;
0x00001e64 sh a0, 4(v0) | *((v0 + 2)) = a0;
0x00001e68 swl a1, 0x11(a3) | __asm ("swl a1, 0x11(a3)");
0x00001e6c swr a1, (v1) | __asm ("swr a1, (v1)");
0x00001e70 addiu v0, a3, 0x18 | v0 = a3 + 0x18;
0x00001e74 sh zero, 0x12(a3) | *((a3 + 9)) = 0;
0x00001e78 sh zero, 0x14(a3) | *((a3 + 10)) = 0;
0x00001e7c sh zero, 0x16(a3) | *((a3 + 11)) = 0;
0x00001e80 swl a2, 0x1b(a3) | __asm ("swl a2, 0x1b(a3)");
0x00001e84 sw a1, 4(sp) | *(var_4h) = a1;
0x00001e88 sw a2, 8(sp) | *(var_8h) = a2;
0x00001e8c swr a2, (v0) | __asm ("swr a2, (v0)");
0x00001e90 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/4325012-58052244.squashfs_v4_le_extract/usr/sbin/zeroconf-ip @ 0x20a4 */
| #include <stdint.h>
|
; (fcn) fcn.000020a4 () | void fcn_000020a4 () {
0x000020a4 lui gp, 2 |
0x000020a8 addiu gp, gp, -0x5084 |
0x000020ac addu gp, gp, t9 | gp += t9;
0x000020b0 move v1, a0 | v1 = a0;
0x000020b4 addiu sp, sp, -0x20 |
0x000020b8 lw v0, (v1) | v0 = *(v1);
0x000020bc sw gp, 0x10(sp) | *(var_10h) = gp;
0x000020c0 sw ra, 0x1c(sp) | *(var_1ch) = ra;
0x000020c4 lw a3, (v0) | a3 = *(v0);
0x000020c8 addiu a0, zero, 0x2d | a0 = 0x2d;
0x000020cc lb a2, (a3) | a2 = *(a3);
0x000020d0 lw a3, -0x7fdc(gp) | a3 = *((gp - 8183));
| if (a2 != a0) {
0x000020d4 bnel a2, a0, 0x212c |
0x000020d8 lb a0, 1(a3) | a0 = *((a3 + 1));
| if (a0 == 0) {
0x000020dc beql a0, zero, 0x212c | goto label_0;
| }
0x000020e0 lw a3, -0x7fdc(gp) | a3 = *((gp - 8183));
0x000020e4 lb a2, 2(a3) | a2 = *((a3 + 2));
0x000020e8 addiu a0, v0, 4 | a0 = v0 + 4;
| if (a2 == 0) {
0x000020ec bnez a2, 0x2114 |
0x000020f0 lw a2, 4(v0) | a2 = *((v0 + 1));
0x000020f4 sw a0, (v1) | *(v1) = a0;
| if (a2 == 0) {
0x000020f8 beqz a2, 0x214c | goto label_1;
| }
0x000020fc lw ra, 0x1c(sp) | ra = *(var_1ch);
0x00002100 addiu a0, v0, 8 | a0 = v0 + 8;
0x00002104 sw a2, (a1) | *(a1) = a2;
0x00002108 sw a0, (v1) | *(v1) = a0;
0x0000210c addiu sp, sp, 0x20 |
0x00002110 jr ra | return v0;
| }
0x00002114 lw ra, 0x1c(sp) | ra = *(var_1ch);
0x00002118 addiu a3, a3, 2 | a3 += 2;
0x0000211c sw a3, (a1) | *(a1) = a3;
0x00002120 sw a0, (v1) | *(v1) = a0;
0x00002124 addiu sp, sp, 0x20 |
0x00002128 jr ra | return v0;
| }
| label_0:
0x0000212c lw a1, -0x7fdc(gp) | a1 = *((gp - 8183));
0x00002130 lw a0, -0x7fdc(gp) | a0 = *((gp - 8183));
0x00002134 lw t9, -0x7fb4(gp) | t9 = sym.imp.__assert_fail;
0x00002138 addiu a3, a3, 0x43a4 | a3 += str.set_opt_value;
0x0000213c addiu a2, zero, 0x4c7 | a2 = 0x4c7;
0x00002140 addiu a1, a1, 0x3ce0 | a1 += str.zeroconf_ip.c;
0x00002144 addiu a0, a0, 0x3d54 | a0 += str._pargv__0_______pargv__1____0;
0x00002148 jalr t9 | t9 ();
| label_1:
0x0000214c lw a0, -0x7eec(gp) | a0 = *((gp - 8123));
0x00002150 lw a2, -0x7fdc(gp) | a2 = *((gp - 8183));
0x00002154 lw t9, -0x7fa4(gp) | t9 = sym.imp.__fprintf_chk
0x00002158 lw a0, (a0) | a0 = *(a0);
0x0000215c addiu a2, a2, 0x3d80 | a2 += str.zeroconf_ip:_argument_to___s_is_missing_n;
0x00002160 sw v0, (v1) | *(v1) = v0;
0x00002164 addiu a1, zero, 1 | a1 = 1;
0x00002168 jalr t9 | t9 ();
0x0000216c lw gp, 0x10(sp) | gp = *(var_10h);
0x00002170 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00002174 addiu t9, t9, 0x1cc0 | t9 += fcn.00001cc0;
0x00002178 addiu a0, zero, 1 | a0 = 1;
0x0000217c bal 0x1cc0 | return fcn_00001cc0 ();
| }
[*] Function fprintf used 3 times zeroconf-ip