[*] Binary protection state of wsdd
Full RELRO Canary found NX disabled PIE enabled No RPATH No RUNPATH No Symbols
[*] Function printf tear down of wsdd
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/4325012-58052244.squashfs_v4_le_extract/usr/bin/wsdd @ 0xafa8 */
| #include <stdint.h>
|
; (fcn) sym.build_xaddr_uri () | void build_xaddr_uri () {
0x0000afa8 lui gp, 3 |
0x0000afac addiu gp, gp, 0x6138 |
0x0000afb0 addu gp, gp, t9 | gp += t9;
0x0000afb4 addiu sp, sp, -0x80 |
0x0000afb8 addiu a2, zero, 0xa | a2 = 0xa;
0x0000afbc sw s5, 0x6c(sp) | *(var_6ch) = s5;
0x0000afc0 lw s5, -0x774c(gp) | s5 = *((gp - 7635));
0x0000afc4 sw s1, 0x5c(sp) | *(var_5ch) = s1;
0x0000afc8 lw s1, -0x7fb4(gp) | s1 = *(gp);
0x0000afcc lw v0, (s5) | v0 = *(s5);
0x0000afd0 sw s0, 0x58(sp) | *(var_58h) = s0;
0x0000afd4 move s0, a0 | s0 = a0;
0x0000afd8 lw a0, -0x7fdc(gp) | a0 = *(gp);
0x0000afdc addiu s1, s1, -0x5e50 | s1 += -0x5e50;
0x0000afe0 sw s4, 0x68(sp) | *(var_68h) = s4;
0x0000afe4 addiu s4, sp, 0x3c | s4 = sp + 0x3c;
0x0000afe8 sw ra, 0x7c(sp) | *(var_7ch) = ra;
0x0000afec sw gp, 0x10(sp) | *(var_10h) = gp;
0x0000aff0 move t9, s1 | t9 = s1;
0x0000aff4 sw fp, 0x78(sp) | *(var_78h) = fp;
0x0000aff8 sw s7, 0x74(sp) | *(var_74h) = s7;
0x0000affc sw s6, 0x70(sp) | *(var_70h) = s6;
0x0000b000 sw s3, 0x64(sp) | *(var_64h) = s3;
0x0000b004 sw s2, 0x60(sp) | *(var_60h) = s2;
| /* str.System.BoaPort */
0x0000b008 addiu a0, a0, 0x6a88 | a0 += 0x6a88;
0x0000b00c move s2, a1 | s2 = a1;
0x0000b010 sw v0, 0x54(sp) | *(var_54h) = v0;
0x0000b014 move a1, s4 | a1 = s4;
0x0000b018 bal 0xa1b0 | fcn_0000a1b0 ();
0x0000b01c lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b020 addiu v0, sp, 0x48 | v0 = sp + 0x48;
0x0000b024 move a1, v0 | a1 = v0;
0x0000b028 lw a0, -0x7fdc(gp) | a0 = *(gp);
0x0000b02c sw v0, 0x28(sp) | *(var_28h) = v0;
0x0000b030 move t9, s1 | t9 = s1;
0x0000b034 addiu a2, zero, 0xa | a2 = 0xa;
| /* str.root.HTTPS.Port */
0x0000b038 addiu a0, a0, 0x6a98 | a0 += 0x6a98;
0x0000b03c bal 0xa1b0 | fcn_0000a1b0 ();
0x0000b040 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b044 addiu s3, sp, 0x38 | s3 = sp + 0x38;
0x0000b048 addiu a2, zero, 4 | a2 = 4;
0x0000b04c lw a0, -0x7fdc(gp) | a0 = *(gp);
0x0000b050 move a1, s3 | a1 = s3;
0x0000b054 move t9, s1 | t9 = s1;
| /* str.root.HTTPS.Enabled */
0x0000b058 addiu a0, a0, 0x6aa8 | a0 += 0x6aa8;
0x0000b05c bal 0xa1b0 | fcn_0000a1b0 ();
0x0000b060 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b064 move a0, s3 | a0 = s3;
0x0000b068 move s1, zero | s1 = 0;
0x0000b06c lw a1, -0x7fdc(gp) | a1 = *(gp);
0x0000b070 lw t9, -0x7b14(gp) | t9 = sym.imp.g_strcmp0;
| /* esilref: 'yes' */
0x0000b074 addiu a1, a1, 0x6abc | a1 += 0x6abc;
0x0000b078 jalr t9 | t9 ();
0x0000b07c lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b080 move s3, v0 | s3 = v0;
0x0000b084 sltiu v0, v0, 1 | v0 = (v0 < 1) ? 1 : 0;
0x0000b088 sw v0, 0x20(sp) | *(var_20h) = v0;
0x0000b08c lw v0, -0x7fdc(gp) | v0 = *(gp);
0x0000b090 lw t9, -0x78d8(gp) | t9 = sym.imp.strchr;
| /* str.http:___ */
0x0000b094 addiu v0, v0, 0x6a70 | v0 += 0x6a70;
0x0000b098 sw v0, 0x2c(sp) | *(var_2ch) = v0;
0x0000b09c lw v0, -0x7fdc(gp) | v0 = *(gp);
0x0000b0a0 addiu a1, zero, 0x2e | a1 = 0x2e;
| /* str.https:___ */
0x0000b0a4 addiu v0, v0, 0x6a7c | v0 += 0x6a7c;
0x0000b0a8 sw v0, 0x34(sp) | *(var_34h) = v0;
0x0000b0ac lw v0, -0x7fdc(gp) | v0 = *(gp);
0x0000b0b0 move a0, s2 | a0 = s2;
0x0000b0b4 sw v0, 0x24(sp) | *(var_24h) = v0;
0x0000b0b8 lw v0, -0x7fdc(gp) | v0 = *(gp);
0x0000b0bc lw fp, -0x7fdc(gp) | fp = *(gp);
| /* str.https:__ */
0x0000b0c0 addiu v0, v0, 0x6a64 | v0 += 0x6a64;
0x0000b0c4 sw v0, 0x30(sp) | *(var_30h) = v0;
0x0000b0c8 lw v0, -0x7fdc(gp) | v0 = *(gp);
0x0000b0cc lw s6, -0x7fdc(gp) | s6 = *(gp);
0x0000b0d0 lw s7, -0x7fdc(gp) | s7 = *(gp);
0x0000b0d4 sw v0, 0x1c(sp) | *(var_1ch) = v0;
0x0000b0d8 jalr t9 | t9 ();
0x0000b0dc lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x0000b0e0 beqz v0, 0xb1f8 | goto label_3;
| }
| do {
0x0000b0e4 lw v0, 0x24(sp) | v0 = *(var_24h);
| if (s1 != 0) {
0x0000b0e8 beqz s1, 0xb0f8 |
0x0000b0ec lw a1, 0x30(sp) | a1 = *(var_30h);
| if (s3 == 0) {
0x0000b0f0 beqz s3, 0xb0fc | goto label_0;
| }
0x0000b0f4 lw v0, 0x24(sp) | v0 = *(var_24h);
| }
0x0000b0f8 addiu a1, v0, 0x6a5c | a1 = v0 + 0x6a5c;
| label_0:
0x0000b0fc lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
0x0000b100 move a0, s0 | a0 = s0;
0x0000b104 jalr t9 | t9 ();
0x0000b108 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b10c addiu a1, fp, 0x6668 | a1 = fp + 0x6668;
0x0000b110 lw t9, -0x79b0(gp) | t9 = sym.imp.strcspn;
0x0000b114 move a0, s2 | a0 = s2;
0x0000b118 jalr t9 | t9 ();
0x0000b11c lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b120 move a2, v0 | a2 = v0;
0x0000b124 move a1, s2 | a1 = s2;
0x0000b128 lw t9, -0x7790(gp) | t9 = sym.imp.g_string_append_len;
0x0000b12c move a0, s0 | a0 = s0;
0x0000b130 jalr t9 | t9 ();
0x0000b134 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b138 addiu a1, zero, 0x3a | a1 = 0x3a;
0x0000b13c lw t9, -0x78d8(gp) | t9 = sym.imp.strchr;
0x0000b140 move a0, s2 | a0 = s2;
0x0000b144 jalr t9 | t9 ();
0x0000b148 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x0000b14c beqz v0, 0xb168 |
0x0000b150 lw v0, 0x1c(sp) | v0 = *(var_1ch);
0x0000b154 lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
0x0000b158 addiu a1, v0, 0x6ac0 | a1 = v0 + 0x6ac0;
0x0000b15c move a0, s0 | a0 = s0;
0x0000b160 jalr t9 | t9 ();
0x0000b164 lw gp, 0x10(sp) | gp = *(var_10h);
| }
0x0000b168 lw t9, -0x7b14(gp) | t9 = sym.imp.g_strcmp0;
| if (s1 == 0) {
0x0000b16c beqz s1, 0xb2a4 | goto label_4;
| }
0x0000b170 move a0, s4 | a0 = s4;
| if (s3 == 0) {
0x0000b174 beqz s3, 0xb20c | goto label_5;
| }
0x0000b178 lw a1, -0x7fdc(gp) | a1 = *(gp);
| /* esilref: '80' */
0x0000b17c addiu a1, a1, 0x6acc | a1 += 0x6acc;
0x0000b180 jalr t9 | t9 ();
0x0000b184 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x0000b188 beqz v0, 0xb240 | goto label_6;
| }
0x0000b18c lw a1, -0x7fdc(gp) | a1 = *(gp);
| label_2:
0x0000b190 lw t9, -0x7acc(gp) | t9 = sym.imp.g_string_append_printf
0x0000b194 move a2, s4 | a2 = s4;
| /* esilref: ':&s' */
0x0000b198 addiu a1, a1, 0x6ac8 | a1 += 0x6ac8;
0x0000b19c move a0, s0 | a0 = s0;
0x0000b1a0 jalr t9 | t9 ();
0x0000b1a4 lw gp, 0x10(sp) | gp = *(var_10h);
| label_1:
0x0000b1a8 lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
| /* str._onvif_device_service */
0x0000b1ac addiu a1, s6, 0x6ad0 | a1 = s6 + 0x6ad0;
0x0000b1b0 move a0, s0 | a0 = s0;
0x0000b1b4 jalr t9 | t9 ();
0x0000b1b8 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b1bc addiu a1, s7, 0x623c | a1 = s7 + 0x623c;
0x0000b1c0 lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
0x0000b1c4 move a0, s0 | a0 = s0;
0x0000b1c8 jalr t9 | t9 ();
0x0000b1cc lw v0, 0x20(sp) | v0 = *(var_20h);
0x0000b1d0 slt s1, s1, v0 | s1 = (s1 < v0) ? 1 : 0;
0x0000b1d4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (s1 == 0) {
0x0000b1d8 beqz s1, 0xb268 | goto label_7;
| }
0x0000b1dc lw t9, -0x78d8(gp) | t9 = sym.imp.strchr;
0x0000b1e0 addiu a1, zero, 0x2e | a1 = 0x2e;
0x0000b1e4 move a0, s2 | a0 = s2;
0x0000b1e8 jalr t9 | t9 ();
0x0000b1ec addiu s1, zero, 1 | s1 = 1;
0x0000b1f0 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b1f4 bnez v0, 0xb0e4 |
| } while (v0 != 0);
| label_3:
0x0000b1f8 lw a1, 0x2c(sp) | a1 = *(var_2ch);
| if (s1 == 0) {
0x0000b1fc beqz s1, 0xb0fc | goto label_0;
| }
0x0000b200 lw v0, 0x34(sp) | v0 = *(var_34h);
| if (s3 != 0) {
0x0000b204 movz a1, v0, s3 | a1 = v0;
| }
0x0000b208 b 0xb0fc | goto label_0;
| label_5:
0x0000b20c lw a1, -0x7fdc(gp) | a1 = *(gp);
0x0000b210 lw a0, 0x28(sp) | a0 = *(var_28h);
| /* esilref: '443' */
0x0000b214 addiu a1, a1, 0x6ac4 | a1 += 0x6ac4;
0x0000b218 jalr t9 | t9 ();
0x0000b21c lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x0000b220 beqz v0, 0xb240 |
0x0000b224 lw a1, -0x7fdc(gp) | a1 = *(gp);
0x0000b228 lw t9, -0x7acc(gp) | t9 = sym.imp.g_string_append_printf
0x0000b22c lw a2, 0x28(sp) | a2 = *(var_28h);
| /* esilref: ':&s' */
0x0000b230 addiu a1, a1, 0x6ac8 | a1 += 0x6ac8;
0x0000b234 move a0, s0 | a0 = s0;
0x0000b238 jalr t9 | t9 ();
0x0000b23c lw gp, 0x10(sp) | gp = *(var_10h);
| }
| label_6:
0x0000b240 lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
| /* str._onvif_device_service */
0x0000b244 addiu a1, s6, 0x6ad0 | a1 = s6 + 0x6ad0;
0x0000b248 move a0, s0 | a0 = s0;
0x0000b24c jalr t9 | t9 ();
0x0000b250 lw gp, 0x10(sp) | gp = *(var_10h);
0x0000b254 addiu a1, s7, 0x623c | a1 = s7 + 0x623c;
0x0000b258 lw t9, -0x7aa4(gp) | t9 = sym.imp.g_string_append;
0x0000b25c move a0, s0 | a0 = s0;
0x0000b260 jalr t9 | t9 ();
0x0000b264 lw gp, 0x10(sp) | gp = *(var_10h);
| label_7:
0x0000b268 lw v1, 0x54(sp) | v1 = *(var_54h);
0x0000b26c lw v0, (s5) | v0 = *(s5);
0x0000b270 lw ra, 0x7c(sp) | ra = *(var_7ch);
| if (v1 != v0) {
0x0000b274 bne v1, v0, 0xb2c4 | goto label_8;
| }
0x0000b278 lw fp, 0x78(sp) | fp = *(var_78h);
0x0000b27c lw s7, 0x74(sp) | s7 = *(var_74h);
0x0000b280 lw s6, 0x70(sp) | s6 = *(var_70h);
0x0000b284 lw s5, 0x6c(sp) | s5 = *(var_6ch);
0x0000b288 lw s4, 0x68(sp) | s4 = *(var_68h);
0x0000b28c lw s3, 0x64(sp) | s3 = *(var_64h);
0x0000b290 lw s2, 0x60(sp) | s2 = *(var_60h);
0x0000b294 lw s1, 0x5c(sp) | s1 = *(var_5ch);
0x0000b298 lw s0, 0x58(sp) | s0 = *(var_58h);
0x0000b29c addiu sp, sp, 0x80 |
0x0000b2a0 jr ra | return v0;
| label_4:
0x0000b2a4 lw a1, -0x7fdc(gp) | a1 = *(gp);
0x0000b2a8 move a0, s4 | a0 = s4;
| /* esilref: '80' */
0x0000b2ac addiu a1, a1, 0x6acc | a1 += 0x6acc;
0x0000b2b0 jalr t9 | t9 ();
0x0000b2b4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x0000b2b8 beqz v0, 0xb1a8 | goto label_1;
| }
0x0000b2bc lw a1, -0x7fdc(gp) | a1 = *(gp);
0x0000b2c0 b 0xb190 | goto label_2;
| label_8:
0x0000b2c4 lw t9, -0x7934(gp) | t9 = sym.imp.__stack_chk_fail;
0x0000b2c8 jalr t9 | t9 ();
0x0000b2cc nop |
| }
[*] Function printf used 3 times wsdd