[*] Binary protection state of ipv6_release
Full RELRO Canary found NX disabled No PIE No RPATH No RUNPATH No Symbols
[*] Function system tear down of ipv6_release
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/DUMP/mtdblock8_unblob_extracted/mtdblock8_extract/0-9650176.squashfs_v4_le_extract/sbin/ipv6_release @ 0x4038dc */
| #include <stdint.h>
|
; (fcn) sym.release_ip_char_ () | void release_ip_char_ () {
| /* release_ip(char*) */
0x004038dc lui gp, 2 |
0x004038e0 addiu gp, gp, -0x18bc |
0x004038e4 addu gp, gp, t9 | gp += t9;
0x004038e8 addiu sp, sp, -0x2a0 |
0x004038ec sw ra, 0x29c(sp) | *(var_29ch) = ra;
0x004038f0 sw fp, 0x298(sp) | *(var_298h) = fp;
0x004038f4 sw s0, 0x294(sp) | *(var_294h) = s0;
0x004038f8 move fp, sp | fp = sp;
0x004038fc sw gp, 0x18(sp) | *(var_18h) = gp;
0x00403900 sw a0, 0x24(fp) | *(arg_24h) = a0;
0x00403904 lw t8, -0x7db0(gp) | t8 = *((gp - 8044));
0x00403908 lw t8, (t8) | t8 = *(t8);
0x0040390c sw t8, 0x28c(fp) | *(arg_28ch) = t8;
0x00403910 addiu v0, fp, 0x18c | v0 = fp + 0x18c;
0x00403914 addiu t8, zero, 0x100 | t8 = 0x100;
0x00403918 move a0, v0 | a0 = v0;
0x0040391c move a1, zero | a1 = 0;
0x00403920 move a2, t8 | a2 = t8;
0x00403924 lw t8, -0x7e38(gp) | t8 = sym.imp.memset;
0x00403928 move t9, t8 | t9 = t8;
0x0040392c jalr t9 | t9 ();
0x00403930 nop |
0x00403934 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403938 addiu t8, fp, 0x18c | t8 = fp + 0x18c;
0x0040393c move a0, t8 | a0 = t8;
0x00403940 addiu a1, zero, 0x100 | a1 = 0x100;
0x00403944 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.ifconfig__s__grep_inet6____tmp_ipv6 */
0x00403948 addiu a2, t8, -0x7f20 | a2 = t8 + -0x7f20;
0x0040394c lw a3, 0x24(fp) | a3 = *(arg_24h);
0x00403950 lw t8, -0x7df4(gp) | t8 = sym.imp.snprintf;
0x00403954 move t9, t8 | t9 = t8;
0x00403958 jalr t9 | t9 ();
0x0040395c nop |
0x00403960 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403964 addiu t8, fp, 0x18c | t8 = fp + 0x18c;
0x00403968 move a0, t8 | a0 = t8;
0x0040396c lw t8, -0x7db8(gp) | t8 = sym.imp.system
0x00403970 move t9, t8 | t9 = t8;
0x00403974 jalr t9 | t9 ();
0x00403978 nop |
0x0040397c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403980 addiu t8, fp, 0x70 | t8 = fp + 0x70;
0x00403984 move a0, t8 | a0 = t8;
0x00403988 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str._tmp_ipv6 */
0x0040398c addiu a1, t8, -0x7ef8 | a1 = t8 + -0x7ef8;
0x00403990 addiu a2, zero, 8 | a2 = 8;
0x00403994 lw t8, -0x7de8(gp) | t8 = *(gp);
0x00403998 move t9, t8 | t9 = t8;
0x0040399c jalr t9 | t9 ();
0x004039a0 nop |
0x004039a4 lw gp, 0x18(fp) | gp = *(arg_18h);
0x004039a8 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x004039ac move a0, t8 | a0 = t8;
0x004039b0 lw t8, -0x7dac(gp) | t8 = *(gp);
0x004039b4 move t9, t8 | t9 = t8;
0x004039b8 jalr t9 | t9 ();
0x004039bc nop |
0x004039c0 lw gp, 0x18(fp) | gp = *(arg_18h);
0x004039c4 addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x004039c8 move a0, t8 | a0 = t8;
0x004039cc lw t8, -0x7fbc(gp) | t8 = *(gp);
0x004039d0 move t9, t8 | t9 = t8;
0x004039d4 jalr t9 | t9 ();
0x004039d8 nop |
0x004039dc lw gp, 0x18(fp) | gp = *(arg_18h);
0x004039e0 addiu t8, fp, 0x30 | t8 = fp + 0x30;
0x004039e4 move a0, t8 | a0 = t8;
0x004039e8 lw t8, -0x7fb8(gp) | t8 = *(gp);
0x004039ec move t9, t8 | t9 = t8;
0x004039f0 jalr t9 | t9 ();
0x004039f4 nop |
0x004039f8 lw gp, 0x18(fp) | gp = *(arg_18h);
0x004039fc addiu t8, fp, 0x70 | t8 = fp + 0x70;
0x00403a00 addiu t8, t8, 0x94 | t8 += 0x94;
0x00403a04 move a0, t8 | a0 = t8;
0x00403a08 lw t8, -0x7e08(gp) | t8 = *(gp);
0x00403a0c move t9, t8 | t9 = t8;
0x00403a10 jalr t9 | t9 ();
0x00403a14 nop |
0x00403a18 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403a1c move t8, v0 | t8 = v0;
| if (t8 != 0) {
0x00403a20 beqz t8, 0x403a34 |
0x00403a24 nop |
0x00403a28 move s0, zero | s0 = 0;
0x00403a2c b 0x403e64 | goto label_0;
0x00403a30 nop |
| }
0x00403a34 b 0x403c88 | goto label_1;
0x00403a38 nop |
| do {
0x00403a3c addiu v0, fp, 0x34 | v0 = fp + 0x34;
0x00403a40 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403a44 move a0, v0 | a0 = v0;
0x00403a48 move a1, t8 | a1 = t8;
0x00403a4c lw t8, -0x7fb4(gp) | t8 = sym.trim_std::string_const_;
0x00403a50 move t9, t8 | t9 = t8;
0x00403a54 jalr t9 | t9 ();
0x00403a58 nop |
0x00403a5c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403a60 addiu v0, fp, 0x2c | v0 = fp + 0x2c;
0x00403a64 addiu t8, fp, 0x34 | t8 = fp + 0x34;
0x00403a68 move a0, v0 | a0 = v0;
0x00403a6c move a1, t8 | a1 = t8;
0x00403a70 lw t8, -0x7e6c(gp) | t8 = *(gp);
0x00403a74 move t9, t8 | t9 = t8;
0x00403a78 jalr t9 | t9 ();
0x00403a7c nop |
0x00403a80 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403a84 addiu t8, fp, 0x34 | t8 = fp + 0x34;
0x00403a88 move a0, t8 | a0 = t8;
0x00403a8c lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403a90 move t9, t8 | t9 = t8;
0x00403a94 jalr t9 | t9 ();
0x00403a98 nop |
0x00403a9c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403aa0 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403aa4 move a0, t8 | a0 = t8;
0x00403aa8 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.Scope:Host */
0x00403aac addiu a1, t8, -0x7eec | a1 = t8 + -0x7eec;
0x00403ab0 move a2, zero | a2 = 0;
0x00403ab4 lw t8, -0x7df0(gp) | t8 = *(gp);
0x00403ab8 move t9, t8 | t9 = t8;
0x00403abc jalr t9 | t9 ();
0x00403ac0 nop |
0x00403ac4 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403ac8 move t8, v0 | t8 = v0;
0x00403acc addiu t8, t8, 1 | t8++;
0x00403ad0 sltu t8, zero, t8 | t8 = (0 < t8) ? 1 : 0;
0x00403ad4 andi t8, t8, 0xff | t8 &= 0xff;
| if (t8 != 0) {
0x00403ad8 beqz t8, 0x403ae8 |
0x00403adc nop |
0x00403ae0 b 0x403c88 | goto label_1;
0x00403ae4 nop |
| }
0x00403ae8 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403aec move a0, t8 | a0 = t8;
0x00403af0 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.Scope:Global */
0x00403af4 addiu a1, t8, -0x7ee0 | a1 = t8 + -0x7ee0;
0x00403af8 move a2, zero | a2 = 0;
0x00403afc lw t8, -0x7df0(gp) | t8 = *(gp);
0x00403b00 move t9, t8 | t9 = t8;
0x00403b04 jalr t9 | t9 ();
0x00403b08 nop |
0x00403b0c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403b10 move t8, v0 | t8 = v0;
0x00403b14 addiu t8, t8, 1 | t8++;
0x00403b18 sltiu t8, t8, 1 | t8 = (t8 < 1) ? 1 : 0;
0x00403b1c andi t8, t8, 0xff | t8 &= 0xff;
| if (t8 != 0) {
0x00403b20 beqz t8, 0x403b30 |
0x00403b24 nop |
0x00403b28 b 0x403c88 | goto label_1;
0x00403b2c nop |
| }
0x00403b30 addiu t8, zero, 5 | t8 = 5;
0x00403b34 sw t8, 0x44(fp) | *(arg_44h) = t8;
0x00403b38 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403b3c move a0, t8 | a0 = t8;
0x00403b40 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.addr: */
0x00403b44 addiu a1, t8, -0x7ed0 | a1 = t8 + -0x7ed0;
0x00403b48 move a2, zero | a2 = 0;
0x00403b4c lw t8, -0x7df0(gp) | t8 = *(gp);
0x00403b50 move t9, t8 | t9 = t8;
0x00403b54 jalr t9 | t9 ();
0x00403b58 nop |
0x00403b5c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403b60 move t8, v0 | t8 = v0;
0x00403b64 sw t8, 0x48(fp) | *(arg_48h) = t8;
0x00403b68 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403b6c move a0, t8 | a0 = t8;
0x00403b70 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.Scope: */
0x00403b74 addiu a1, t8, -0x7ec8 | a1 = t8 + -0x7ec8;
0x00403b78 move a2, zero | a2 = 0;
0x00403b7c lw t8, -0x7df0(gp) | t8 = *(gp);
0x00403b80 move t9, t8 | t9 = t8;
0x00403b84 jalr t9 | t9 ();
0x00403b88 nop |
0x00403b8c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403b90 move t8, v0 | t8 = v0;
0x00403b94 sw t8, 0x4c(fp) | *(arg_4ch) = t8;
0x00403b98 lw v0, 0x48(fp) | v0 = *(arg_48h);
0x00403b9c addiu t8, zero, -1 | t8 = -1;
| if (v0 != t8) {
0x00403ba0 beq v0, t8, 0x403c88 |
0x00403ba4 nop |
0x00403ba8 lw v0, 0x4c(fp) | v0 = *(arg_4ch);
0x00403bac addiu t8, zero, -1 | t8 = -1;
| if (v0 == t8) {
0x00403bb0 beq v0, t8, 0x403c88 | goto label_1;
| }
0x00403bb4 nop |
0x00403bb8 lw v0, 0x44(fp) | v0 = *(arg_44h);
0x00403bbc lw t8, 0x48(fp) | t8 = *(arg_48h);
0x00403bc0 addu v0, v0, t8 | v0 += t8;
0x00403bc4 lw v1, 0x4c(fp) | v1 = *(arg_4ch);
0x00403bc8 lw t8, 0x48(fp) | t8 = *(arg_48h);
0x00403bcc subu v1, v1, t8 | __asm ("subu v1, v1, t8");
0x00403bd0 lw t8, 0x44(fp) | t8 = *(arg_44h);
0x00403bd4 subu t8, v1, t8 | __asm ("subu t8, v1, t8");
0x00403bd8 addiu a0, fp, 0x38 | a0 = fp + 0x38;
0x00403bdc addiu v1, fp, 0x2c | v1 = fp + 0x2c;
0x00403be0 move a1, v1 | a1 = v1;
0x00403be4 move a2, v0 | a2 = v0;
0x00403be8 move a3, t8 | a3 = t8;
0x00403bec lw t8, -0x7e28(gp) | t8 = *(gp);
0x00403bf0 move t9, t8 | t9 = t8;
0x00403bf4 jalr t9 | t9 ();
0x00403bf8 nop |
0x00403bfc lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403c00 addiu v0, fp, 0x3c | v0 = fp + 0x3c;
0x00403c04 addiu t8, fp, 0x38 | t8 = fp + 0x38;
0x00403c08 move a0, v0 | a0 = v0;
0x00403c0c move a1, t8 | a1 = t8;
0x00403c10 lw t8, -0x7fb4(gp) | t8 = sym.trim_std::string_const_;
0x00403c14 move t9, t8 | t9 = t8;
0x00403c18 jalr t9 | t9 ();
0x00403c1c nop |
0x00403c20 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403c24 addiu v1, fp, 0x50 | v1 = fp + 0x50;
0x00403c28 addiu v0, fp, 0x58 | v0 = fp + 0x58;
0x00403c2c addiu t8, fp, 0x3c | t8 = fp + 0x3c;
0x00403c30 move a0, v1 | a0 = v1;
0x00403c34 move a1, v0 | a1 = v0;
0x00403c38 move a2, t8 | a2 = t8;
0x00403c3c lw t8, -0x7fb0(gp) | t8 = *(gp);
0x00403c40 move t9, t8 | t9 = t8;
0x00403c44 jalr t9 | t9 ();
0x00403c48 nop |
0x00403c4c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403c50 addiu t8, fp, 0x3c | t8 = fp + 0x3c;
0x00403c54 move a0, t8 | a0 = t8;
0x00403c58 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403c5c move t9, t8 | t9 = t8;
0x00403c60 jalr t9 | t9 ();
0x00403c64 nop |
0x00403c68 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403c6c addiu t8, fp, 0x38 | t8 = fp + 0x38;
0x00403c70 move a0, t8 | a0 = t8;
0x00403c74 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403c78 move t9, t8 | t9 = t8;
0x00403c7c jalr t9 | t9 ();
0x00403c80 nop |
0x00403c84 lw gp, 0x18(fp) | gp = *(arg_18h);
| }
| label_1:
0x00403c88 addiu v0, fp, 0x70 | v0 = fp + 0x70;
0x00403c8c addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403c90 move a0, v0 | a0 = v0;
0x00403c94 move a1, t8 | a1 = t8;
0x00403c98 lw t8, -0x7dbc(gp) | t8 = *(gp);
0x00403c9c move t9, t8 | t9 = t8;
0x00403ca0 jalr t9 | t9 ();
0x00403ca4 nop |
0x00403ca8 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403cac move t8, v0 | t8 = v0;
0x00403cb0 lw v0, (t8) | v0 = *(t8);
0x00403cb4 addiu v0, v0, -0xc | v0 += -0xc;
0x00403cb8 lw v0, (v0) | v0 = *(v0);
0x00403cbc addu t8, t8, v0 | t8 += v0;
0x00403cc0 move a0, t8 | a0 = t8;
0x00403cc4 lw t8, -0x7db4(gp) | t8 = *(gp);
0x00403cc8 move t9, t8 | t9 = t8;
0x00403ccc jalr t9 | t9 ();
0x00403cd0 nop |
0x00403cd4 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403cd8 move t8, v0 | t8 = v0;
0x00403cdc sltu t8, zero, t8 | t8 = (0 < t8) ? 1 : 0;
0x00403ce0 andi t8, t8, 0xff | t8 &= 0xff;
0x00403ce4 bnez t8, 0x403a3c |
| } while (t8 != 0);
0x00403ce8 nop |
0x00403cec addiu t8, fp, 0x70 | t8 = fp + 0x70;
0x00403cf0 move a0, t8 | a0 = t8;
0x00403cf4 lw t8, -0x7df8(gp) | t8 = *(gp);
0x00403cf8 move t9, t8 | t9 = t8;
0x00403cfc jalr t9 | t9 ();
0x00403d00 nop |
0x00403d04 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403d08 addiu v0, fp, 0x20 | v0 = fp + 0x20;
0x00403d0c addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x00403d10 move a0, v0 | a0 = v0;
0x00403d14 move a1, t8 | a1 = t8;
0x00403d18 lw t8, -0x7fac(gp) | t8 = *(gp);
0x00403d1c move t9, t8 | t9 = t8;
0x00403d20 jalr t9 | t9 ();
0x00403d24 nop |
0x00403d28 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403d2c lw t8, 0x20(fp) | t8 = *(arg_20h);
0x00403d30 sw t8, 0x30(fp) | *(arg_30h) = t8;
0x00403d34 b 0x403df0 | goto label_2;
0x00403d38 nop |
| do {
0x00403d3c addiu t8, fp, 0x30 | t8 = fp + 0x30;
0x00403d40 move a0, t8 | a0 = t8;
0x00403d44 lw t8, -0x7fa8(gp) | t8 = *(gp);
0x00403d48 move t9, t8 | t9 = t8;
0x00403d4c jalr t9 | t9 ();
0x00403d50 nop |
0x00403d54 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403d58 move t8, v0 | t8 = v0;
0x00403d5c move a0, t8 | a0 = t8;
0x00403d60 lw t8, -0x7dc0(gp) | t8 = *(gp);
0x00403d64 move t9, t8 | t9 = t8;
0x00403d68 jalr t9 | t9 ();
0x00403d6c nop |
0x00403d70 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403d74 move t8, v0 | t8 = v0;
0x00403d78 addiu v0, fp, 0x18c | v0 = fp + 0x18c;
0x00403d7c lw v1, 0x24(fp) | v1 = *(arg_24h);
0x00403d80 sw v1, 0x10(sp) | *(var_10h) = v1;
0x00403d84 move a0, v0 | a0 = v0;
0x00403d88 addiu a1, zero, 0x100 | a1 = 0x100;
0x00403d8c lw v0, -0x7fc0(gp) | v0 = *((gp - 8176));
| /* str.ip__6_addr_del__s_dev__s */
0x00403d90 addiu a2, v0, -0x7ec0 | a2 = v0 + -0x7ec0;
0x00403d94 move a3, t8 | a3 = t8;
0x00403d98 lw t8, -0x7df4(gp) | t8 = sym.imp.snprintf;
0x00403d9c move t9, t8 | t9 = t8;
0x00403da0 jalr t9 | t9 ();
0x00403da4 nop |
0x00403da8 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403dac addiu t8, fp, 0x18c | t8 = fp + 0x18c;
0x00403db0 move a0, t8 | a0 = t8;
0x00403db4 lw t8, -0x7db8(gp) | t8 = sym.imp.system
0x00403db8 move t9, t8 | t9 = t8;
0x00403dbc jalr t9 | t9 ();
0x00403dc0 nop |
0x00403dc4 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403dc8 addiu v0, fp, 0x50 | v0 = fp + 0x50;
0x00403dcc addiu t8, fp, 0x30 | t8 = fp + 0x30;
0x00403dd0 move a0, v0 | a0 = v0;
0x00403dd4 move a1, t8 | a1 = t8;
0x00403dd8 move a2, zero | a2 = 0;
0x00403ddc lw t8, -0x7fa4(gp) | t8 = *(gp);
0x00403de0 move t9, t8 | t9 = t8;
0x00403de4 jalr t9 | t9 ();
0x00403de8 nop |
0x00403dec lw gp, 0x18(fp) | gp = *(arg_18h);
| label_2:
0x00403df0 addiu v0, fp, 0x40 | v0 = fp + 0x40;
0x00403df4 addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x00403df8 move a0, v0 | a0 = v0;
0x00403dfc move a1, t8 | a1 = t8;
0x00403e00 lw t8, -0x7fa0(gp) | t8 = *(gp);
0x00403e04 move t9, t8 | t9 = t8;
0x00403e08 jalr t9 | t9 ();
0x00403e0c nop |
0x00403e10 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403e14 addiu v0, fp, 0x30 | v0 = fp + 0x30;
0x00403e18 addiu t8, fp, 0x40 | t8 = fp + 0x40;
0x00403e1c move a0, v0 | a0 = v0;
0x00403e20 move a1, t8 | a1 = t8;
0x00403e24 lw t8, -0x7f9c(gp) | t8 = *(gp);
0x00403e28 move t9, t8 | t9 = t8;
0x00403e2c jalr t9 | t9 ();
0x00403e30 nop |
0x00403e34 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403e38 move t8, v0 | t8 = v0;
0x00403e3c bnez t8, 0x403d3c |
| } while (t8 != 0);
0x00403e40 nop |
0x00403e44 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str._tmp_ipv6 */
0x00403e48 addiu a0, t8, -0x7ef8 | a0 = t8 + -0x7ef8;
0x00403e4c lw t8, -0x7e30(gp) | t8 = sym.imp.unlink;
0x00403e50 move t9, t8 | t9 = t8;
0x00403e54 jalr t9 | t9 ();
0x00403e58 nop |
0x00403e5c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403e60 move s0, zero | s0 = 0;
| label_0:
0x00403e64 addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x00403e68 move a0, t8 | a0 = t8;
0x00403e6c lw t8, -0x7f98(gp) | t8 = *(gp);
0x00403e70 move t9, t8 | t9 = t8;
0x00403e74 jalr t9 | t9 ();
0x00403e78 nop |
0x00403e7c lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403e80 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403e84 move a0, t8 | a0 = t8;
0x00403e88 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403e8c move t9, t8 | t9 = t8;
0x00403e90 jalr t9 | t9 ();
0x00403e94 nop |
0x00403e98 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403e9c addiu t8, fp, 0x70 | t8 = fp + 0x70;
0x00403ea0 move a0, t8 | a0 = t8;
0x00403ea4 lw t8, -0x7e18(gp) | t8 = *(gp);
0x00403ea8 move t9, t8 | t9 = t8;
0x00403eac jalr t9 | t9 ();
0x00403eb0 nop |
0x00403eb4 lw gp, 0x18(fp) | gp = *(arg_18h);
0x00403eb8 move t8, s0 | t8 = s0;
0x00403ebc move v0, t8 | v0 = t8;
0x00403ec0 lw t8, -0x7db0(gp) | t8 = *((gp - 8044));
0x00403ec4 lw v1, 0x28c(fp) | v1 = *(arg_28ch);
0x00403ec8 lw t8, (t8) | t8 = *(t8);
| if (v1 != t8) {
0x00403ecc beq v1, t8, 0x404004 |
0x00403ed0 nop |
0x00403ed4 b 0x403ff4 | goto label_3;
0x00403ed8 nop |
| label_3:
0x00403ff4 lw t8, -0x7e14(gp) | t8 = sym.imp.__stack_chk_fail;
0x00403ff8 move t9, t8 | t9 = t8;
0x00403ffc jalr t9 | t9 ();
0x00404000 nop |
| }
0x00404004 move sp, fp |
0x00404008 lw ra, 0x29c(sp) | ra = *(var_29ch);
0x0040400c lw fp, 0x298(sp) | fp = *(var_298h);
0x00404010 lw s0, 0x294(sp) | s0 = *(var_294h);
0x00404014 addiu sp, sp, 0x2a0 |
0x00404018 jr ra | return v1;
0x0040401c nop |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/DUMP/mtdblock8_unblob_extracted/mtdblock8_extract/0-9650176.squashfs_v4_le_extract/sbin/ipv6_release @ 0x4032d8 */
| #include <stdint.h>
|
; (fcn) sym.release_route_char_ () | void release_route_char_ () {
| /* release_route(char*) */
0x004032d8 lui gp, 2 |
0x004032dc addiu gp, gp, -0x12b8 |
0x004032e0 addu gp, gp, t9 | gp += t9;
0x004032e4 addiu sp, sp, -0x288 |
0x004032e8 sw ra, 0x284(sp) | *(var_284h) = ra;
0x004032ec sw fp, 0x280(sp) | *(var_280h) = fp;
0x004032f0 sw s0, 0x27c(sp) | *(var_27ch) = s0;
0x004032f4 move fp, sp | fp = sp;
0x004032f8 sw gp, 0x10(sp) | *(var_10h) = gp;
0x004032fc sw a0, 0x1c(fp) | *(arg_1ch) = a0;
0x00403300 lw t8, -0x7db0(gp) | t8 = *((gp - 8044));
0x00403304 lw t8, (t8) | t8 = *(t8);
0x00403308 sw t8, 0x274(fp) | *(arg_274h) = t8;
0x0040330c addiu v0, fp, 0x174 | v0 = fp + 0x174;
0x00403310 addiu t8, zero, 0x100 | t8 = 0x100;
0x00403314 move a0, v0 | a0 = v0;
0x00403318 move a1, zero | a1 = 0;
0x0040331c move a2, t8 | a2 = t8;
0x00403320 lw t8, -0x7e38(gp) | t8 = sym.imp.memset;
0x00403324 move t9, t8 | t9 = t8;
0x00403328 jalr t9 | t9 ();
0x0040332c nop |
0x00403330 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403334 addiu t8, fp, 0x174 | t8 = fp + 0x174;
0x00403338 move a0, t8 | a0 = t8;
0x0040333c addiu a1, zero, 0x100 | a1 = 0x100;
0x00403340 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str.ip__6_route_show_dev__s____tmp_route */
0x00403344 addiu a2, t8, -0x7f70 | a2 = t8 + -0x7f70;
0x00403348 lw a3, 0x1c(fp) | a3 = *(arg_1ch);
0x0040334c lw t8, -0x7df4(gp) | t8 = sym.imp.snprintf;
0x00403350 move t9, t8 | t9 = t8;
0x00403354 jalr t9 | t9 ();
0x00403358 nop |
0x0040335c lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403360 addiu t8, fp, 0x174 | t8 = fp + 0x174;
0x00403364 move a0, t8 | a0 = t8;
0x00403368 lw t8, -0x7db8(gp) | t8 = sym.imp.system
0x0040336c move t9, t8 | t9 = t8;
0x00403370 jalr t9 | t9 ();
0x00403374 nop |
0x00403378 lw gp, 0x10(fp) | gp = *(arg_10h);
0x0040337c addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x00403380 move a0, t8 | a0 = t8;
0x00403384 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str._tmp_route */
0x00403388 addiu a1, t8, -0x7f48 | a1 = t8 + -0x7f48;
0x0040338c addiu a2, zero, 8 | a2 = 8;
0x00403390 lw t8, -0x7de8(gp) | t8 = *(gp);
0x00403394 move t9, t8 | t9 = t8;
0x00403398 jalr t9 | t9 ();
0x0040339c nop |
0x004033a0 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004033a4 addiu t8, fp, 0x24 | t8 = fp + 0x24;
0x004033a8 move a0, t8 | a0 = t8;
0x004033ac lw t8, -0x7dac(gp) | t8 = *(gp);
0x004033b0 move t9, t8 | t9 = t8;
0x004033b4 jalr t9 | t9 ();
0x004033b8 nop |
0x004033bc lw gp, 0x10(fp) | gp = *(arg_10h);
0x004033c0 addiu t8, fp, 0x40 | t8 = fp + 0x40;
0x004033c4 move a0, t8 | a0 = t8;
0x004033c8 lw t8, -0x7fbc(gp) | t8 = *(gp);
0x004033cc move t9, t8 | t9 = t8;
0x004033d0 jalr t9 | t9 ();
0x004033d4 nop |
0x004033d8 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004033dc addiu t8, fp, 0x28 | t8 = fp + 0x28;
0x004033e0 move a0, t8 | a0 = t8;
0x004033e4 lw t8, -0x7fb8(gp) | t8 = *(gp);
0x004033e8 move t9, t8 | t9 = t8;
0x004033ec jalr t9 | t9 ();
0x004033f0 nop |
0x004033f4 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004033f8 addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x004033fc addiu t8, t8, 0x94 | t8 += 0x94;
0x00403400 move a0, t8 | a0 = t8;
0x00403404 lw t8, -0x7e08(gp) | t8 = *(gp);
0x00403408 move t9, t8 | t9 = t8;
0x0040340c jalr t9 | t9 ();
0x00403410 nop |
0x00403414 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403418 move t8, v0 | t8 = v0;
| if (t8 != 0) {
0x0040341c beqz t8, 0x403430 |
0x00403420 nop |
0x00403424 move s0, zero | s0 = 0;
0x00403428 b 0x40374c | goto label_0;
0x0040342c nop |
| }
0x00403430 b 0x403578 | goto label_1;
0x00403434 nop |
| do {
0x00403438 addiu t8, fp, 0x24 | t8 = fp + 0x24;
0x0040343c move a0, t8 | a0 = t8;
0x00403440 lw t8, -0x7dc0(gp) | t8 = *(gp);
0x00403444 move t9, t8 | t9 = t8;
0x00403448 jalr t9 | t9 ();
0x0040344c nop |
0x00403450 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403454 move t8, v0 | t8 = v0;
0x00403458 move a0, t8 | a0 = t8;
0x0040345c lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
0x00403460 addiu a1, t8, -0x7f3c | a1 = t8 + -0x7f3c;
0x00403464 addiu a2, zero, 1 | a2 = 1;
0x00403468 lw t8, -0x7e00(gp) | t8 = sym.imp.strncasecmp;
0x0040346c move t9, t8 | t9 = t8;
0x00403470 jalr t9 | t9 ();
0x00403474 nop |
0x00403478 lw gp, 0x10(fp) | gp = *(arg_10h);
0x0040347c move t8, v0 | t8 = v0;
0x00403480 sltiu t8, t8, 1 | t8 = (t8 < 1) ? 1 : 0;
0x00403484 andi t8, t8, 0xff | t8 &= 0xff;
| if (t8 != 0) {
0x00403488 beqz t8, 0x403498 |
0x0040348c nop |
0x00403490 b 0x403578 | goto label_1;
0x00403494 nop |
| }
0x00403498 addiu t8, fp, 0x24 | t8 = fp + 0x24;
0x0040349c move a0, t8 | a0 = t8;
0x004034a0 lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* esilref: 'dev' */
0x004034a4 addiu a1, t8, -0x7f38 | a1 = t8 + -0x7f38;
0x004034a8 move a2, zero | a2 = 0;
0x004034ac lw t8, -0x7df0(gp) | t8 = *(gp);
0x004034b0 move t9, t8 | t9 = t8;
0x004034b4 jalr t9 | t9 ();
0x004034b8 nop |
0x004034bc lw gp, 0x10(fp) | gp = *(arg_10h);
0x004034c0 move t8, v0 | t8 = v0;
0x004034c4 addiu v1, fp, 0x2c | v1 = fp + 0x2c;
0x004034c8 addiu v0, fp, 0x24 | v0 = fp + 0x24;
0x004034cc move a0, v1 | a0 = v1;
0x004034d0 move a1, v0 | a1 = v0;
0x004034d4 move a2, zero | a2 = 0;
0x004034d8 move a3, t8 | a3 = t8;
0x004034dc lw t8, -0x7e28(gp) | t8 = *(gp);
0x004034e0 move t9, t8 | t9 = t8;
0x004034e4 jalr t9 | t9 ();
0x004034e8 nop |
0x004034ec lw gp, 0x10(fp) | gp = *(arg_10h);
0x004034f0 addiu v0, fp, 0x30 | v0 = fp + 0x30;
0x004034f4 addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x004034f8 move a0, v0 | a0 = v0;
0x004034fc move a1, t8 | a1 = t8;
0x00403500 lw t8, -0x7fb4(gp) | t8 = sym.trim_std::string_const_;
0x00403504 move t9, t8 | t9 = t8;
0x00403508 jalr t9 | t9 ();
0x0040350c nop |
0x00403510 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403514 addiu v1, fp, 0x38 | v1 = fp + 0x38;
0x00403518 addiu v0, fp, 0x40 | v0 = fp + 0x40;
0x0040351c addiu t8, fp, 0x30 | t8 = fp + 0x30;
0x00403520 move a0, v1 | a0 = v1;
0x00403524 move a1, v0 | a1 = v0;
0x00403528 move a2, t8 | a2 = t8;
0x0040352c lw t8, -0x7fb0(gp) | t8 = *(gp);
0x00403530 move t9, t8 | t9 = t8;
0x00403534 jalr t9 | t9 ();
0x00403538 nop |
0x0040353c lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403540 addiu t8, fp, 0x30 | t8 = fp + 0x30;
0x00403544 move a0, t8 | a0 = t8;
0x00403548 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x0040354c move t9, t8 | t9 = t8;
0x00403550 jalr t9 | t9 ();
0x00403554 nop |
0x00403558 lw gp, 0x10(fp) | gp = *(arg_10h);
0x0040355c addiu t8, fp, 0x2c | t8 = fp + 0x2c;
0x00403560 move a0, t8 | a0 = t8;
0x00403564 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403568 move t9, t8 | t9 = t8;
0x0040356c jalr t9 | t9 ();
0x00403570 nop |
0x00403574 lw gp, 0x10(fp) | gp = *(arg_10h);
| label_1:
0x00403578 addiu v0, fp, 0x58 | v0 = fp + 0x58;
0x0040357c addiu t8, fp, 0x24 | t8 = fp + 0x24;
0x00403580 move a0, v0 | a0 = v0;
0x00403584 move a1, t8 | a1 = t8;
0x00403588 lw t8, -0x7dbc(gp) | t8 = *(gp);
0x0040358c move t9, t8 | t9 = t8;
0x00403590 jalr t9 | t9 ();
0x00403594 nop |
0x00403598 lw gp, 0x10(fp) | gp = *(arg_10h);
0x0040359c move t8, v0 | t8 = v0;
0x004035a0 lw v0, (t8) | v0 = *(t8);
0x004035a4 addiu v0, v0, -0xc | v0 += -0xc;
0x004035a8 lw v0, (v0) | v0 = *(v0);
0x004035ac addu t8, t8, v0 | t8 += v0;
0x004035b0 move a0, t8 | a0 = t8;
0x004035b4 lw t8, -0x7db4(gp) | t8 = *(gp);
0x004035b8 move t9, t8 | t9 = t8;
0x004035bc jalr t9 | t9 ();
0x004035c0 nop |
0x004035c4 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004035c8 move t8, v0 | t8 = v0;
0x004035cc sltu t8, zero, t8 | t8 = (0 < t8) ? 1 : 0;
0x004035d0 andi t8, t8, 0xff | t8 &= 0xff;
0x004035d4 bnez t8, 0x403438 |
| } while (t8 != 0);
0x004035d8 nop |
0x004035dc addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x004035e0 move a0, t8 | a0 = t8;
0x004035e4 lw t8, -0x7df8(gp) | t8 = *(gp);
0x004035e8 move t9, t8 | t9 = t8;
0x004035ec jalr t9 | t9 ();
0x004035f0 nop |
0x004035f4 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004035f8 addiu v0, fp, 0x18 | v0 = fp + 0x18;
0x004035fc addiu t8, fp, 0x40 | t8 = fp + 0x40;
0x00403600 move a0, v0 | a0 = v0;
0x00403604 move a1, t8 | a1 = t8;
0x00403608 lw t8, -0x7fac(gp) | t8 = *(gp);
0x0040360c move t9, t8 | t9 = t8;
0x00403610 jalr t9 | t9 ();
0x00403614 nop |
0x00403618 lw gp, 0x10(fp) | gp = *(arg_10h);
0x0040361c lw t8, 0x18(fp) | t8 = *(arg_18h);
0x00403620 sw t8, 0x28(fp) | *(arg_28h) = t8;
0x00403624 b 0x4036d8 | goto label_2;
0x00403628 nop |
| do {
0x0040362c addiu t8, fp, 0x28 | t8 = fp + 0x28;
0x00403630 move a0, t8 | a0 = t8;
0x00403634 lw t8, -0x7fa8(gp) | t8 = *(gp);
0x00403638 move t9, t8 | t9 = t8;
0x0040363c jalr t9 | t9 ();
0x00403640 nop |
0x00403644 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403648 move t8, v0 | t8 = v0;
0x0040364c move a0, t8 | a0 = t8;
0x00403650 lw t8, -0x7dc0(gp) | t8 = *(gp);
0x00403654 move t9, t8 | t9 = t8;
0x00403658 jalr t9 | t9 ();
0x0040365c nop |
0x00403660 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403664 move t8, v0 | t8 = v0;
0x00403668 addiu v0, fp, 0x174 | v0 = fp + 0x174;
0x0040366c move a0, v0 | a0 = v0;
0x00403670 addiu a1, zero, 0x100 | a1 = 0x100;
0x00403674 lw v0, -0x7fc0(gp) | v0 = *((gp - 8176));
| /* str.ip__6_route_del__s */
0x00403678 addiu a2, v0, -0x7f34 | a2 = v0 + -0x7f34;
0x0040367c move a3, t8 | a3 = t8;
0x00403680 lw t8, -0x7df4(gp) | t8 = sym.imp.snprintf;
0x00403684 move t9, t8 | t9 = t8;
0x00403688 jalr t9 | t9 ();
0x0040368c nop |
0x00403690 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403694 addiu t8, fp, 0x174 | t8 = fp + 0x174;
0x00403698 move a0, t8 | a0 = t8;
0x0040369c lw t8, -0x7db8(gp) | t8 = sym.imp.system
0x004036a0 move t9, t8 | t9 = t8;
0x004036a4 jalr t9 | t9 ();
0x004036a8 nop |
0x004036ac lw gp, 0x10(fp) | gp = *(arg_10h);
0x004036b0 addiu v0, fp, 0x38 | v0 = fp + 0x38;
0x004036b4 addiu t8, fp, 0x28 | t8 = fp + 0x28;
0x004036b8 move a0, v0 | a0 = v0;
0x004036bc move a1, t8 | a1 = t8;
0x004036c0 move a2, zero | a2 = 0;
0x004036c4 lw t8, -0x7fa4(gp) | t8 = *(gp);
0x004036c8 move t9, t8 | t9 = t8;
0x004036cc jalr t9 | t9 ();
0x004036d0 nop |
0x004036d4 lw gp, 0x10(fp) | gp = *(arg_10h);
| label_2:
0x004036d8 addiu v0, fp, 0x34 | v0 = fp + 0x34;
0x004036dc addiu t8, fp, 0x40 | t8 = fp + 0x40;
0x004036e0 move a0, v0 | a0 = v0;
0x004036e4 move a1, t8 | a1 = t8;
0x004036e8 lw t8, -0x7fa0(gp) | t8 = *(gp);
0x004036ec move t9, t8 | t9 = t8;
0x004036f0 jalr t9 | t9 ();
0x004036f4 nop |
0x004036f8 lw gp, 0x10(fp) | gp = *(arg_10h);
0x004036fc addiu v0, fp, 0x28 | v0 = fp + 0x28;
0x00403700 addiu t8, fp, 0x34 | t8 = fp + 0x34;
0x00403704 move a0, v0 | a0 = v0;
0x00403708 move a1, t8 | a1 = t8;
0x0040370c lw t8, -0x7f9c(gp) | t8 = *(gp);
0x00403710 move t9, t8 | t9 = t8;
0x00403714 jalr t9 | t9 ();
0x00403718 nop |
0x0040371c lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403720 move t8, v0 | t8 = v0;
0x00403724 bnez t8, 0x40362c |
| } while (t8 != 0);
0x00403728 nop |
0x0040372c lw t8, -0x7fc0(gp) | t8 = *((gp - 8176));
| /* str._tmp_route */
0x00403730 addiu a0, t8, -0x7f48 | a0 = t8 + -0x7f48;
0x00403734 lw t8, -0x7e30(gp) | t8 = sym.imp.unlink;
0x00403738 move t9, t8 | t9 = t8;
0x0040373c jalr t9 | t9 ();
0x00403740 nop |
0x00403744 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403748 move s0, zero | s0 = 0;
| label_0:
0x0040374c addiu t8, fp, 0x40 | t8 = fp + 0x40;
0x00403750 move a0, t8 | a0 = t8;
0x00403754 lw t8, -0x7f98(gp) | t8 = *(gp);
0x00403758 move t9, t8 | t9 = t8;
0x0040375c jalr t9 | t9 ();
0x00403760 nop |
0x00403764 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403768 addiu t8, fp, 0x24 | t8 = fp + 0x24;
0x0040376c move a0, t8 | a0 = t8;
0x00403770 lw t8, -0x7dfc(gp) | t8 = *(gp);
0x00403774 move t9, t8 | t9 = t8;
0x00403778 jalr t9 | t9 ();
0x0040377c nop |
0x00403780 lw gp, 0x10(fp) | gp = *(arg_10h);
0x00403784 addiu t8, fp, 0x58 | t8 = fp + 0x58;
0x00403788 move a0, t8 | a0 = t8;
0x0040378c lw t8, -0x7e18(gp) | t8 = *(gp);
0x00403790 move t9, t8 | t9 = t8;
0x00403794 jalr t9 | t9 ();
0x00403798 nop |
0x0040379c lw gp, 0x10(fp) | gp = *(arg_10h);
0x004037a0 move t8, s0 | t8 = s0;
0x004037a4 move v0, t8 | v0 = t8;
0x004037a8 lw t8, -0x7db0(gp) | t8 = *((gp - 8044));
0x004037ac lw v1, 0x274(fp) | v1 = *(arg_274h);
0x004037b0 lw t8, (t8) | t8 = *(t8);
| if (v1 != t8) {
0x004037b4 beq v1, t8, 0x4038c0 |
0x004037b8 nop |
0x004037bc b 0x4038b0 | goto label_3;
0x004037c0 nop |
| label_3:
0x004038b0 lw t8, -0x7e14(gp) | t8 = sym.imp.__stack_chk_fail;
0x004038b4 move t9, t8 | t9 = t8;
0x004038b8 jalr t9 | t9 ();
0x004038bc nop |
| }
0x004038c0 move sp, fp |
0x004038c4 lw ra, 0x284(sp) | ra = *(var_284h);
0x004038c8 lw fp, 0x280(sp) | fp = *(var_280h);
0x004038cc lw s0, 0x27c(sp) | s0 = *(var_27ch);
0x004038d0 addiu sp, sp, 0x288 |
0x004038d4 jr ra | return v1;
0x004038d8 nop |
| }
[*] Function system used 5 times ipv6_release