[*] Binary protection state of busybox
Partial RELRO No Canary found NX disabled No PIE No RPATH No RUNPATH No Symbols
[*] Function sprintf tear down of busybox
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x284d4 */
| #include <stdint.h>
|
; (fcn) fcn.000284d4 () | void fcn_000284d4 (int32_t arg_4h, int32_t arg1) {
| char * s;
| int32_t var_8h;
| int32_t var_1ch;
| r0 = arg1;
0x000284d4 push {r0, r1, r2, r3, r4, r5, r6, lr} |
0x000284d8 ldr r1, [pc, 0x54] | r1 = *(0x28530);
0x000284dc mov r2, r0 | r2 = r0;
0x000284e0 mov r0, sp | r0 = sp;
0x000284e4 bl 0x14f48 | sprintf (r0, r1, r2)
0x000284e8 mov r1, 2 | r1 = 2;
0x000284ec mov r0, sp | r0 = sp;
0x000284f0 bl 0x14df8 | r0 = open64 ();
0x000284f4 cmp r0, 0 |
| if (r0 < 0) {
0x000284f8 bge 0x28520 |
0x000284fc ldr r3, [pc, 0x34] |
0x00028500 ldr r3, [r3] | r3 = "_dev_i2c__d";
0x00028504 ldr r1, [r3] | r1 = "_dev_i2c__d";
0x00028508 cmp r1, 2 |
| if (r1 != 2) {
0x0002850c bne 0x28528 | goto label_0;
| }
0x00028510 mov r3, 0x2f | r3 = 0x2f;
0x00028514 mov r0, sp | r0 = sp;
0x00028518 strb r3, [sp, 8] | var_8h = r3;
0x0002851c bl 0x18ab4 | fcn_00018ab4 (r0);
| }
0x00028520 add sp, sp, 0x1c |
0x00028524 pop {pc} |
| label_0:
0x00028528 mov r1, sp | r1 = sp;
0x0002852c ldr r0, [pc, 8] | r0 = *(0x0002853c);
0x00028530 bl 0x17fd8 | fcn_00017fd8 ();
0x00028534 strdeq ip, sp, [fp], -r8 | __asm ("strdeq ip, sp, [fp], -r8");
| if (r1 != 2) {
0x00028538 andeq sp, sp, r4, ror fp |
| }
0x0002853c strheq sb, [fp], -r6 | __asm ("strheq sb, [fp], -r6");
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x2db08 */
| #include <stdint.h>
|
; (fcn) fcn.0002db08 () | void fcn_0002db08 (int32_t arg1, int32_t arg2) {
| r0 = arg1;
| r1 = arg2;
0x0002db08 push {r4, r5, r6, lr} |
0x0002db0c subs r5, r1, 0 | r5 = r1 - 0;
0x0002db10 mov r4, r0 | r4 = r0;
| if (r5 != r1) {
0x0002db14 beq 0x2db60 |
0x0002db18 cmp r0, 0 |
| if (r0 == 0) {
0x0002db1c bne 0x2db2c |
0x0002db20 mov r0, r5 | r0 = r5;
0x0002db24 pop {r4, r5, r6, lr} |
0x0002db28 b 0x189d4 | void (*0x189d4)() ();
| }
0x0002db2c bl 0x1514c | r0 = strlen (r0);
0x0002db30 mov r6, r0 | r6 = r0;
0x0002db34 mov r0, r5 | r0 = r5;
0x0002db38 bl 0x1514c | r0 = strlen (r0);
0x0002db3c add r1, r6, r0 | r1 = r6 + r0;
0x0002db40 add r1, r1, 2 | r1 += 2;
0x0002db44 mov r0, r4 | r0 = r4;
0x0002db48 bl 0x18990 | fcn_00018990 (r0, r1);
0x0002db4c mov r2, r5 | r2 = r5;
0x0002db50 ldr r1, [pc, 0x10] | r1 = *(0x2db64);
0x0002db54 mov r4, r0 | r4 = r0;
0x0002db58 add r0, r0, r6 | r0 += r6;
0x0002db5c bl 0x14f48 | sprintf (r0, r1, r2)
| }
0x0002db60 mov r0, r4 | r0 = r4;
0x0002db64 pop {r4, r5, r6, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x2e730 */
| #include <stdint.h>
|
; (fcn) fcn.0002e730 () | void fcn_0002e730 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_ch;
| r0 = arg1;
| r1 = arg2;
0x0002e730 push {r0, r1, r2, r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0002e734 ldr r8, [pc, 0xb0] | r8 = *(0x2e7e8);
0x0002e738 mov sb, r0 | sb = r0;
0x0002e73c mov r0, 1 | r0 = 1;
0x0002e740 mov sl, r1 | sl = r1;
0x0002e744 bl 0x189b8 | fcn_000189b8 (r0);
0x0002e748 ldr fp, [pc, 0xa0] | fp = "%.*s\"%s\" ";
0x0002e74c mov r7, 0 | r7 = 0;
0x0002e750 mov r5, r0 | r5 = r0;
| do {
0x0002e754 ldr r6, [sb, 4]! | r6 = *((sb += 4));
0x0002e758 cmp r6, 0 |
| if (r6 == 0) {
0x0002e75c bne 0x2e76c |
0x0002e760 mov r0, r5 | r0 = r5;
0x0002e764 add sp, sp, 0xc |
0x0002e768 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x0002e76c mov r0, r6 | r0 = r6;
0x0002e770 bl 0x1514c | strlen (r0);
0x0002e774 add r1, r7, 4 | r1 = r7 + 4;
0x0002e778 add r1, r1, r0 | r1 += r0;
0x0002e77c mov r0, r5 | r0 = r5;
0x0002e780 bl 0x18990 | fcn_00018990 (r0, r1);
0x0002e784 mov r1, 0x3d | r1 = 0x3d;
0x0002e788 mov r5, r0 | r5 = r0;
0x0002e78c mov r0, r6 | r0 = r6;
0x0002e790 bl 0x151e8 | strchrnul ();
0x0002e794 cmp sl, 0 |
0x0002e798 mov r4, r0 | r4 = r0;
| if (sl == 0) {
0x0002e79c beq 0x2e7e4 | goto label_1;
| }
0x0002e7a0 ldrb r3, [r0] | r3 = *(r0);
0x0002e7a4 cmp r3, 0 |
| if (r3 == 0) {
0x0002e7a8 beq 0x2e7e4 | goto label_1;
| }
0x0002e7ac add r4, r0, 1 | r4 = r0 + 1;
0x0002e7b0 mov r1, 0x20 | r1 = 0x20;
0x0002e7b4 mov r0, r4 | r0 = r4;
0x0002e7b8 bl 0x1517c | r0 = strchr (r0, r1);
0x0002e7bc cmp r0, 0 |
| if (r0 != 0) {
0x0002e7c0 moveq r1, r8 | r1 = r8;
| }
| if (r0 == 0) {
0x0002e7c4 movne r1, fp | r1 = fp;
| }
| label_0:
0x0002e7c8 add r0, r5, r7 | r0 = r5 + r7;
0x0002e7cc str r4, [sp] | *(sp) = r4;
0x0002e7d0 mov r3, r6 | r3 = r6;
0x0002e7d4 sub r2, r4, r6 | r2 = r4 - r6;
0x0002e7d8 bl 0x14f48 | r0 = sprintf (r0, r1, r2)
0x0002e7dc add r7, r7, r0 | r7 += r0;
0x0002e7e0 b 0x2e754 |
| } while (1);
| label_1:
0x0002e7e4 mov r1, r8 | r1 = r8;
0x0002e7e8 b 0x2e7c8 | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x34ef4 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.00034ef4 () | void fcn_00034ef4 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_34h;
| int32_t var_3ch;
| int32_t var_40h;
| int32_t var_44h;
| int32_t var_48h;
| char * s1;
| void * var_64h;
| int32_t var_6ch;
| char * s;
| int32_t var_a8h;
| int32_t var_adh;
| int32_t var_b2h;
| int32_t var_b7h;
| int32_t var_b8h;
| void * s2;
| int32_t var_bch;
| int32_t var_c1h;
| int32_t var_c6h;
| int32_t var_cbh;
| int32_t var_d4h;
| r0 = arg1;
| r1 = arg2;
0x00034ef4 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00034ef8 mov r8, r1 | r8 = r1;
0x00034efc mov r1, 2 | r1 = 2;
0x00034f00 sub sp, sp, 0xd4 |
0x00034f04 mov r2, 0 | r2 = 0;
0x00034f08 add r5, r0, 8 | r5 = r0 + 8;
0x00034f0c mov r4, r0 | r4 = r0;
0x00034f10 mov r0, r1 | r0 = r1;
0x00034f14 bl 0x18f88 | fcn_00018f88 (r0, r1);
0x00034f18 mov r1, r5 | r1 = r5;
0x00034f1c mov r7, r0 | r7 = r0;
0x00034f20 add r0, sp, 0xa8 | r0 += var_a8h;
0x00034f24 bl 0x18340 | fcn_00018340 ();
0x00034f28 add r2, sp, 0xa8 | r2 += var_a8h;
0x00034f2c ldr r1, [pc, 0x74c] | r1 = *(0x3567c);
0x00034f30 mov r0, r7 | r0 = r7;
0x00034f34 bl 0x14330 | r0 = ioctl (r0, r1);
0x00034f38 cmp r0, 0 |
| if (r0 < 0) {
0x00034f3c bge 0x34f7c |
0x00034f40 mov r0, r7 | r0 = r7;
0x00034f44 bl 0x15260 | close (r0);
0x00034f48 ldr r3, [pc, 0x734] |
0x00034f4c ldr r3, [r3] | r3 = *(0x35680);
0x00034f50 ldr r0, [r3] | r0 = *(0x35680);
0x00034f54 cmp r0, 0x13 |
| if (r0 != 0x13) {
0x00034f58 ldreq r2, [pc, 0x728] | r2 = "Device not found";
| }
| if (r0 != 0x13) {
0x00034f5c beq 0x34f68 |
0x00034f60 bl 0x143e4 | r0 = strerror (r0);
0x00034f64 mov r2, r0 | r2 = r0;
| }
0x00034f68 ldr r0, [pc, 0x71c] | r0 = "Device not found";
0x00034f6c mov r1, r5 | r1 = r5;
0x00034f70 bl 0x18274 | fcn_00018274 ();
0x00034f74 mvn r0, 0 | r0 = ~0;
0x00034f78 b 0x35160 |
| } else {
0x00034f7c ldrh r3, [sp, 0xb8] | r3 = var_b8h;
0x00034f80 mov r2, 0x78 | r2 = 0x78;
0x00034f84 strh r3, [r4, 0x1a] | *((r4 + 0x1a)) = r3;
0x00034f88 mvn r3, 0 | r3 = ~0;
0x00034f8c str r3, [r4, 0x1c] | *((r4 + 0x1c)) = r3;
0x00034f90 mov r1, 0 | r1 = 0;
0x00034f94 add r0, r4, 0x20 | r0 = r4 + 0x20;
0x00034f98 bl 0x14d98 | memset (r0, r1, r2);
0x00034f9c mov r1, r5 | r1 = r5;
0x00034fa0 add r0, sp, 0xa8 | r0 += var_a8h;
0x00034fa4 bl 0x18340 | fcn_00018340 ();
0x00034fa8 add r2, sp, 0xa8 | r2 += var_a8h;
0x00034fac ldr r1, [pc, 0x6dc] | r1 = "%s: error fetching interface information: %s";
0x00034fb0 mov r0, r7 | r0 = r7;
0x00034fb4 bl 0x14330 | r0 = ioctl (r0, "%s: error fetching interface information: %s");
0x00034fb8 cmp r0, 0 |
| if (r0 >= 0) {
0x00034fbc blt 0x34fd0 |
0x00034fc0 mov r2, 8 | r2 = 8;
0x00034fc4 add r1, sp, 0xba | r1 += s2;
0x00034fc8 add r0, r4, 0x78 | r0 = r4 + 0x78;
0x00034fcc bl 0x14624 | memcpy (r0, r1, r2);
| }
0x00034fd0 ldrh r3, [sp, 0xb8] | r3 = var_b8h;
0x00034fd4 mov r1, r5 | r1 = r5;
0x00034fd8 strh r3, [r4, 0x18] | *((r4 + 0x18)) = r3;
0x00034fdc add r0, sp, 0xa8 | r0 += var_a8h;
0x00034fe0 bl 0x18340 | fcn_00018340 ();
0x00034fe4 add r2, sp, 0xa8 | r2 += var_a8h;
0x00034fe8 ldr r1, [pc, 0x6a4] | r1 = *(0x35690);
0x00034fec mov r0, r7 | r0 = r7;
0x00034ff0 bl 0x14330 | ioctl (r0, r1);
0x00034ff4 mov r1, r5 | r1 = r5;
0x00034ff8 cmp r0, 0 |
| if (r0 < 0) {
0x00034ffc ldrge r3, [sp, 0xb8] | r3 = var_b8h;
| }
0x00035000 add r0, sp, 0xa8 | r0 += var_a8h;
| if (r0 < 0) {
0x00035004 strge r3, [r4, 0x20] | *((r4 + 0x20)) = r3;
| }
0x00035008 bl 0x18340 | fcn_00018340 ();
0x0003500c add r2, sp, 0xa8 | r2 += var_a8h;
0x00035010 ldr r1, [pc, 0x680] | r1 = *(0x35694);
0x00035014 mov r0, r7 | r0 = r7;
0x00035018 bl 0x14330 | ioctl (r0, r1);
0x0003501c mov r1, r5 | r1 = r5;
0x00035020 cmp r0, 0 |
| if (r0 < 0) {
0x00035024 ldrge r3, [sp, 0xb8] | r3 = var_b8h;
| }
0x00035028 add r0, sp, 0xa8 | r0 += var_a8h;
| if (r0 < 0) {
0x0003502c strge r3, [r4, 0x24] | *((r4 + 0x24)) = r3;
| }
0x00035030 bl 0x18340 | fcn_00018340 ();
0x00035034 add r2, sp, 0xa8 | r2 += var_a8h;
0x00035038 ldr r1, [pc, 0x65c] | r1 = *(0x35698);
0x0003503c mov r0, r7 | r0 = r7;
0x00035040 bl 0x14330 | r0 = ioctl (r0, r1);
0x00035044 cmp r0, 0 |
| if (r0 != 0) {
0x00035048 addeq r3, sp, 0xb8 | r3 += var_b8h;
| }
| if (r0 != 0) {
0x0003504c ldmeq r3, {r0, r1, r2, r3} | r0 = *(r3);
| r1 = *((r3 + 4));
| r2 = *((r3 + 8));
| r3 = *((r3 + 12));
| }
| if (r0 != 0) {
0x00035050 addeq ip, r4, 0x28 |
| }
| if (r0 != 0) {
0x00035054 stmeq ip, {r0, r1, r2, r3} | *(ip) = r0;
| *((ip + 4)) = r1;
| *((ip + 8)) = r2;
| *((ip + 12)) = r3;
| }
0x00035058 mov r1, r5 | r1 = r5;
0x0003505c add r0, sp, 0xa8 | r0 += var_a8h;
0x00035060 bl 0x18340 | fcn_00018340 ();
0x00035064 add r2, sp, 0xa8 | r2 += var_a8h;
0x00035068 ldr r1, [pc, 0x630] | r1 = *(0x3569c);
0x0003506c mov r0, r7 | r0 = r7;
0x00035070 bl 0x14330 | ioctl (r0, r1);
0x00035074 mov r1, r5 | r1 = r5;
0x00035078 cmp r0, 0 |
| if (r0 < 0) {
0x0003507c ldrge r3, [sp, 0xb8] | r3 = var_b8h;
| }
0x00035080 add r0, sp, 0xa8 | r0 += var_a8h;
| if (r0 < 0) {
0x00035084 strge r3, [r4, 0x1c] | *((r4 + 0x1c)) = r3;
| }
0x00035088 bl 0x18340 | fcn_00018340 ();
0x0003508c mov r3, 2 | r3 = 2;
0x00035090 add r2, sp, 0xa8 | r2 += var_a8h;
0x00035094 ldr r1, [pc, 0x608] | r1 = *(0x356a0);
0x00035098 mov r0, r7 | r0 = r7;
0x0003509c strh r3, [sp, 0xb8] | var_b8h = r3;
0x000350a0 bl 0x14330 | r0 = ioctl (r0, r1);
0x000350a4 cmp r0, 0 |
| if (r0 == 0) {
0x000350a8 bne 0x35148 |
0x000350ac add r6, sp, 0xb8 | r6 += var_b8h;
0x000350b0 mov r3, 1 | r3 = 1;
0x000350b4 str r3, [r4, 0x98] | *((r4 + 0x98)) = r3;
0x000350b8 ldm r6, {r0, r1, r2, r3} | r0 = *(r6);
| r1 = *((r6 + 4));
| r2 = *((r6 + 8));
| r3 = *((r6 + 12));
0x000350bc add ip, r4, 0x38 |
0x000350c0 stm ip, {r0, r1, r2, r3} | *(ip) = r0;
| *((ip + 4)) = r1;
| *((ip + 8)) = r2;
| *((ip + 12)) = r3;
0x000350c4 mov r1, r5 | r1 = r5;
0x000350c8 add r0, sp, 0xa8 | r0 += var_a8h;
0x000350cc bl 0x18340 | fcn_00018340 ();
0x000350d0 add r2, sp, 0xa8 | r2 += var_a8h;
0x000350d4 ldr r1, [pc, 0x5cc] | r1 = *(0x356a4);
0x000350d8 mov r0, r7 | r0 = r7;
0x000350dc bl 0x14330 | r0 = ioctl (r0, r1);
0x000350e0 cmp r0, 0 |
| if (r0 < 0) {
0x000350e4 ldmge r6, {r0, r1, r2, r3} | r0 = *(r6);
| r1 = *((r6 + 4));
| r2 = *((r6 + 8));
| r3 = *((r6 + 12));
| }
| if (r0 < 0) {
0x000350e8 addge ip, r4, 0x48 |
| }
| if (r0 < 0) {
0x000350ec stmge ip, {r0, r1, r2, r3} | *(ip) = r0;
| *((ip + 4)) = r1;
| *((ip + 8)) = r2;
| *((ip + 12)) = r3;
| }
0x000350f0 mov r1, r5 | r1 = r5;
0x000350f4 add r0, sp, 0xa8 | r0 += var_a8h;
0x000350f8 bl 0x18340 | fcn_00018340 ();
0x000350fc add r2, sp, 0xa8 | r2 += var_a8h;
0x00035100 ldr r1, [pc, 0x5a4] | r1 = *(0x356a8);
0x00035104 mov r0, r7 | r0 = r7;
0x00035108 bl 0x14330 | r0 = ioctl (r0, r1);
0x0003510c cmp r0, 0 |
| if (r0 < 0) {
0x00035110 ldmge r6, {r0, r1, r2, r3} | r0 = *(r6);
| r1 = *((r6 + 4));
| r2 = *((r6 + 8));
| r3 = *((r6 + 12));
| }
| if (r0 < 0) {
0x00035114 addge ip, r4, 0x58 |
| }
| if (r0 < 0) {
0x00035118 stmge ip, {r0, r1, r2, r3} | *(ip) = r0;
| *((ip + 4)) = r1;
| *((ip + 8)) = r2;
| *((ip + 12)) = r3;
| }
0x0003511c mov r1, r5 | r1 = r5;
0x00035120 add r0, sp, 0xa8 | r0 += var_a8h;
0x00035124 bl 0x18340 | fcn_00018340 ();
0x00035128 add r2, sp, 0xa8 | r2 += var_a8h;
0x0003512c ldr r1, [pc, 0x57c] | r1 = *(0x356ac);
0x00035130 mov r0, r7 | r0 = r7;
0x00035134 bl 0x14330 | r0 = ioctl (r0, r1);
0x00035138 cmp r0, 0 |
| if (r0 < 0) {
0x0003513c ldmge r6, {r0, r1, r2, r3} | r0 = *(r6);
| r1 = *((r6 + 4));
| r2 = *((r6 + 8));
| r3 = *((r6 + 12));
| }
| if (r0 < 0) {
0x00035140 addge ip, r4, 0x68 |
| }
| if (r0 >= 0) {
0x00035144 stmge ip, {r0, r1, r2, r3} | *(ip) = r0;
| *((ip + 4)) = r1;
| *((ip + 8)) = r2;
| *((ip + 12)) = r3;
| goto label_5;
| }
| }
| label_5:
0x00035148 mov r0, r7 | r0 = r7;
0x0003514c bl 0x15260 | close (r0);
0x00035150 ldrh r0, [r4, 0x1a] | r0 = *((r4 + 0x1a));
0x00035154 and r0, r0, 1 | r0 &= 1;
0x00035158 orrs r0, r0, r8 | r0 |= r8;
| if (r0 != r0) {
0x0003515c bne 0x35168 | goto label_6;
| }
| }
| label_1:
0x00035160 add sp, sp, 0xd4 |
0x00035164 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_6:
0x00035168 ldr r3, [pc, 0x544] | r3 = *(0x356b0);
0x0003516c ldrh r1, [r4, 0x38] | r1 = *((r4 + 0x38));
0x00035170 mov r2, r3 | r2 = r3;
| label_0:
0x00035174 ldr r6, [r2, 4]! | r6 = *((r2 += 4));
0x00035178 cmp r6, 0 |
| if (r6 != 0) {
0x0003517c bne 0x3519c | goto label_7;
| }
| do {
0x00035180 ldr r6, [r3, 4]! | r6 = *((r3 += 4));
0x00035184 cmp r6, 0 |
| if (r6 == 0) {
0x00035188 beq 0x351a8 | goto label_8;
| }
0x0003518c ldr r2, [r6, 8] | r2 = *((r6 + 8));
0x00035190 cmp r2, 0 |
| if (r2 == 0) {
0x00035194 beq 0x351a8 | goto label_8;
| }
0x00035198 b 0x35180 |
| } while (1);
| label_7:
0x0003519c ldr r0, [r6, 8] | r0 = *((r6 + 8));
0x000351a0 cmp r1, r0 |
| if (r1 != r0) {
0x000351a4 bne 0x35174 | goto label_0;
| }
| label_8:
0x000351a8 ldrsh r0, [r4, 0x18] | r0 = *((r4 + 0x18));
0x000351ac bic r3, r0, 2 | r3 = BIT_MASK (r0, 2);
0x000351b0 str r3, [sp, 0x34] | var_34h = r3;
0x000351b4 bl 0x34ecc | r0 = fcn_00034ecc (r0);
0x000351b8 subs r7, r0, 0 | r7 = r0 - 0;
| if (r7 == r0) {
0x000351bc bne 0x351cc |
0x000351c0 mvn r0, 0 | r0 = ~0;
0x000351c4 bl 0x34ecc | r0 = fcn_00034ecc (r0);
0x000351c8 mov r7, r0 | r7 = r0;
| }
0x000351cc ldr r2, [r7, 4] | r2 = *((r7 + 4));
0x000351d0 mov r1, r5 | r1 = r5;
0x000351d4 ldr r0, [pc, 0x4dc] | r0 = *(0x356b4);
0x000351d8 bl 0x1436c | printf (r0, r1, r2);
0x000351dc ldr r2, [r7, 0x10] | r2 = *((r7 + 0x10));
0x000351e0 cmp r2, 0 |
| if (r2 == 0) {
0x000351e4 addne r0, r4, 0x78 | r0 = r4 + 0x78;
| }
| if (r2 == 0) {
0x000351e8 ldrne ip, [r7, 0xc] | ip = *((r7 + 0xc));
| }
| if (r2 == 0) {
0x000351ec movne r3, r0 | r3 = r0;
| }
| if (r2 != 0) {
0x000351f0 bne 0x35524 | goto label_9;
| }
| label_2:
0x000351f4 ldrh r3, [r4, 0x1a] | r3 = *((r4 + 0x1a));
0x000351f8 tst r3, 0x2000 |
| if ((r3 & 0x2000) != 0) {
0x000351fc beq 0x35228 |
0x00035200 ldr r3, [pc, 0x4b4] | r3 = "__9s_Link_encap:_s__";
0x00035204 ldrb r2, [r4, 0x34] | r2 = *((r4 + 0x34));
0x00035208 ldr r0, [pc, 0x4b0] | r0 = "unknown";
0x0003520c ldr r1, [r3, r2, lsl 2] | r1 = "__9s_Link_encap:_s__";
0x00035210 bl 0x1436c | printf ("unknown", "__9s_Link_encap:_s__", r2, "__9s_Link_encap:_s__");
0x00035214 ldrh r3, [r4, 0x1a] | r3 = *((r4 + 0x1a));
0x00035218 tst r3, 0x4000 |
| if ((r3 & 0x4000) == 0) {
0x0003521c beq 0x35228 | goto label_10;
| }
0x00035220 ldr r0, [pc, 0x49c] | r0 = "Media:%s";
0x00035224 bl 0x1436c | printf ("Media:%s");
| }
| label_10:
0x00035228 mov r0, 0xa | r0 = 0xa;
0x0003522c bl 0x18ce4 | fcn_00018ce4 (r0);
0x00035230 ldr r3, [r4, 0x98] | r3 = *((r4 + 0x98));
0x00035234 cmp r3, 0 |
| if (r3 != 0) {
0x00035238 beq 0x352cc |
0x0003523c ldr r3, [r6, 0x14] | r3 = *((r6 + 0x14));
0x00035240 mov r1, 1 | r1 = 1;
0x00035244 add r0, r4, 0x38 | r0 = r4 + 0x38;
0x00035248 ldr r7, [r6] | r7 = *(r6);
0x0003524c blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x00035250 mov r1, r7 | r1 = r7;
0x00035254 mov r2, r0 | r2 = r0;
0x00035258 ldr r0, [pc, 0x468] | r0 = "_auto_";
0x0003525c bl 0x1436c | printf ("_auto_", r1, r2);
0x00035260 ldrh r3, [r4, 0x1a] | r3 = *((r4 + 0x1a));
0x00035264 tst r3, 0x10 |
| if ((r3 & 0x10) != 0) {
0x00035268 beq 0x35288 |
0x0003526c mov r1, 1 | r1 = 1;
0x00035270 ldr r3, [r6, 0x14] | r3 = *((r6 + 0x14));
0x00035274 add r0, r4, 0x48 | r0 = r4 + 0x48;
0x00035278 blx r3 | r0 = uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x0003527c mov r1, r0 | r1 = r0;
0x00035280 ldr r0, [pc, 0x444] | r0 = " %s addr:%s ";
0x00035284 bl 0x1436c | printf (" %s addr:%s ", r1);
| }
0x00035288 ldrh r2, [r4, 0x1a] | r2 = *((r4 + 0x1a));
0x0003528c ldr r3, [r6, 0x14] | r3 = *((r6 + 0x14));
0x00035290 tst r2, 2 |
| if ((r2 & 2) != 0) {
0x00035294 beq 0x352b0 |
0x00035298 mov r1, 1 | r1 = 1;
0x0003529c add r0, r4, 0x58 | r0 = r4 + 0x58;
0x000352a0 blx r3 | r0 = uint32_t (*r3)(uint32_t, uint32_t) (r0, r1);
0x000352a4 mov r1, r0 | r1 = r0;
0x000352a8 ldr r0, [pc, 0x420] | r0 = " P-t-P:%s ";
0x000352ac bl 0x1436c | printf (" P-t-P:%s ", r1);
| }
0x000352b0 mov r1, 1 | r1 = 1;
0x000352b4 ldr r3, [r6, 0x14] | r3 = *((r6 + 0x14));
0x000352b8 add r0, r4, 0x68 | r0 = r4 + 0x68;
0x000352bc blx r3 | r0 = uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000352c0 mov r1, r0 | r1 = r0;
0x000352c4 ldr r0, [pc, 0x408] | r0 = "Bcast:_s_";
0x000352c8 bl 0x1436c | printf ("Bcast:_s_", r1);
| }
0x000352cc ldr r0, [pc, 0x404] | r0 = " Mask:%s\n";
0x000352d0 bl 0xa5630 | r0 = fcn_000a5630 ();
0x000352d4 subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 != r0) {
0x000352d8 beq 0x35358 |
| label_3:
0x000352dc add r3, sp, 0x44 | r3 += var_44h;
0x000352e0 str r3, [sp, 0x24] | var_24h = r3;
0x000352e4 add r3, sp, 0x40 | r3 += var_40h;
0x000352e8 str r3, [sp, 0x20] | var_20h = r3;
0x000352ec add r3, sp, 0x3c | r3 += var_3ch;
0x000352f0 str r3, [sp, 0x1c] | var_1ch = r3;
0x000352f4 add r3, sp, 0x48 | r3 += var_48h;
0x000352f8 str r3, [sp, 0x18] | var_18h = r3;
0x000352fc add r3, sp, 0xb7 | r3 += var_b7h;
0x00035300 str r3, [sp, 4] | var_4h = r3;
0x00035304 add fp, sp, 0x4c |
0x00035308 add r3, sp, 0xb2 | r3 += var_b2h;
0x0003530c add sl, sp, 0xcb | sl += var_cbh;
0x00035310 add sb, sp, 0xc6 | sb += var_c6h;
0x00035314 add r8, sp, 0xc1 | r8 += var_c1h;
0x00035318 add r7, sp, 0xbc | r7 += var_bch;
0x0003531c str r3, [sp] | *(sp) = r3;
0x00035320 str fp, [sp, 0x28] | var_28h = fp;
0x00035324 str sl, [sp, 0x14] | var_14h = sl;
0x00035328 str sb, [sp, 0x10] | var_10h = sb;
0x0003532c str r8, [sp, 0xc] | var_ch = r8;
0x00035330 str r7, [sp, 8] | var_8h = r7;
0x00035334 add r3, sp, 0xad | r3 += var_adh;
0x00035338 add r2, sp, 0xa8 | r2 += var_a8h;
0x0003533c ldr r1, [pc, 0x398] | r1 = "/proc/net/if_inet6";
0x00035340 mov r0, r6 | r0 = r6;
0x00035344 bl 0x145c4 | r0 = fscanf (r0, "/proc/net/if_inet6", r2, r3);
0x00035348 cmn r0, 1 |
| if (r0 != 1) {
0x0003534c bne 0x35550 | goto label_11;
| }
0x00035350 mov r0, r6 | r0 = r6;
0x00035354 bl 0x14dec | fclose (r0);
| }
0x00035358 ldr r0, [pc, 0x380] | r0 = "_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s";
0x0003535c bl 0x1436c | printf ("_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s");
0x00035360 ldrsh r3, [r4, 0x1a] | r3 = *((r4 + 0x1a));
0x00035364 cmp r3, 0 |
| if (r3 != 0) {
0x00035368 bne 0x3563c | goto label_12;
| }
0x0003536c ldr r0, [pc, 0x370] | r0 = " ";
0x00035370 bl 0x1436c | printf (" ");
| label_4:
0x00035374 ldr r2, [r4, 0x20] | r2 = *((r4 + 0x20));
0x00035378 ldr r1, [r4, 0x24] | r1 = *((r4 + 0x24));
0x0003537c cmp r2, 0 |
| if (r2 != 0) {
0x00035380 moveq r2, 1 | r2 = 1;
| }
0x00035384 ldr r0, [pc, 0x35c] | r0 = "_NO_FLAGS__";
0x00035388 bl 0x1436c | printf ("_NO_FLAGS__", r1, r2);
0x0003538c mov r0, 0xa | r0 = 0xa;
0x00035390 bl 0x18ce4 | fcn_00018ce4 (r0);
0x00035394 ldr r3, [r4, 0x9c] | r3 = *((r4 + 0x9c));
0x00035398 cmp r3, 0 |
| if (r3 != 0) {
0x0003539c beq 0x35480 |
0x000353a0 ldr r0, [pc, 0x338] | r0 = "_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s";
0x000353a4 bl 0x1436c | printf ("_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s");
0x000353a8 ldr r3, [r4, 0xec] | r3 = *((r4 + 0xec));
0x000353ac ldr r0, [pc, 0x338] | r0 = "MTU:_d__Metric:_d";
0x000353b0 str r3, [sp, 0xc] | var_ch = r3;
0x000353b4 ldr r3, [r4, 0xf0] | r3 = *((r4 + 0xf0));
0x000353b8 str r3, [sp, 8] | var_8h = r3;
0x000353bc ldr r3, [r4, 0xc8] | r3 = *((r4 + 0xc8));
0x000353c0 str r3, [sp, 4] | var_4h = r3;
0x000353c4 ldr r3, [r4, 0xc0] | r3 = *((r4 + 0xc0));
0x000353c8 str r3, [sp] | *(sp) = r3;
0x000353cc ldrd r2, r3, [r4, 0xa0] | __asm ("ldrd r2, r3, [r4, 0xa0]");
0x000353d0 bl 0x1436c | printf ("MTU:_d__Metric:_d", r1, r2, r3);
0x000353d4 ldr r3, [pc, 0x314] | r3 = "RX packets:%llu errors:%lu dropped:%lu overruns:%lu frame:%lu\n";
0x000353d8 ldr r2, [sp, 0x34] | r2 = var_34h;
0x000353dc cmp r2, r3 |
| if (r2 == r3) {
0x000353e0 bne 0x353f0 |
0x000353e4 ldr r1, [r4, 0xd4] | r1 = *((r4 + 0xd4));
0x000353e8 ldr r0, [pc, 0x304] | r0 = *(0x356f0);
0x000353ec bl 0x1436c | printf (r0, r1);
| }
0x000353f0 ldr r0, [pc, 0x2e8] | r0 = "_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s";
0x000353f4 bl 0x1436c | printf ("_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s");
0x000353f8 ldr r3, [r4, 0xfc] | r3 = *((r4 + 0xfc));
0x000353fc ldr r0, [pc, 0x2f4] | r0 = "compressed:_lu";
0x00035400 str r3, [sp, 0xc] | var_ch = r3;
0x00035404 ldr r3, [r4, 0x100] | r3 = *((r4 + 0x100));
0x00035408 str r3, [sp, 8] | var_8h = r3;
0x0003540c ldr r3, [r4, 0xcc] | r3 = *((r4 + 0xcc));
0x00035410 str r3, [sp, 4] | var_4h = r3;
0x00035414 ldr r3, [r4, 0xc4] | r3 = *((r4 + 0xc4));
0x00035418 str r3, [sp] | *(sp) = r3;
0x0003541c ldrd r2, r3, [r4, 0xa8] | __asm ("ldrd r2, r3, [r4, 0xa8]");
0x00035420 bl 0x1436c | printf ("compressed:_lu", r1, r2, r3);
0x00035424 ldr r1, [r4, 0xdc] | r1 = *((r4 + 0xdc));
0x00035428 ldr r0, [pc, 0x2cc] | r0 = "TX packets:%llu errors:%lu dropped:%lu overruns:%lu carrier:%lu\n";
0x0003542c bl 0x1436c | printf ("TX packets:%llu errors:%lu dropped:%lu overruns:%lu carrier:%lu\n", r1);
0x00035430 ldr r3, [pc, 0x2b8] | r3 = "RX packets:%llu errors:%lu dropped:%lu overruns:%lu frame:%lu\n";
0x00035434 ldr r2, [sp, 0x34] | r2 = var_34h;
0x00035438 cmp r2, r3 |
| if (r2 == r3) {
0x0003543c bne 0x3544c |
0x00035440 ldr r1, [r4, 0xd8] | r1 = *((r4 + 0xd8));
0x00035444 ldr r0, [pc, 0x2b4] | r0 = "collisions:_lu_";
0x00035448 bl 0x1436c | printf ("collisions:_lu_", r1);
| }
0x0003544c ldr r1, [r4, 0x1c] | r1 = *((r4 + 0x1c));
0x00035450 cmn r1, 1 |
| if (r1 != 1) {
0x00035454 beq 0x35460 |
0x00035458 ldr r0, [pc, 0x2a4] | r0 = "compressed:_lu_";
0x0003545c bl 0x1436c | printf ("compressed:_lu_");
| }
0x00035460 ldr r0, [pc, 0x2a0] | r0 = "txqueuelen:_d_";
0x00035464 bl 0x1436c | printf ("txqueuelen:_d_");
0x00035468 ldr r2, [pc, 0x29c] | r2 = "\n R";
0x0003546c ldrd r0, r1, [r4, 0xb0] | __asm ("ldrd r0, r1, [r4, 0xb0]");
0x00035470 bl 0x34d9c | fcn_00034d9c (r0, r1);
0x00035474 ldr r2, [pc, 0x294] | r2 = "T";
0x00035478 ldrd r0, r1, [r4, 0xb8] | __asm ("ldrd r0, r1, [r4, 0xb8]");
0x0003547c bl 0x34d9c | fcn_00034d9c (r0, r1);
| }
0x00035480 ldrb r3, [r4, 0x32] | r3 = *((r4 + 0x32));
0x00035484 cmp r3, 0 |
| if (r3 == 0) {
0x00035488 bne 0x354a4 |
0x0003548c ldr r3, [r4, 0x28] | r3 = *((r4 + 0x28));
0x00035490 cmp r3, 0 |
| if (r3 != 0) {
0x00035494 bne 0x354a4 | goto label_13;
| }
0x00035498 ldr r3, [r4, 0x30] | r3 = *((r4 + 0x30));
0x0003549c bics r3, r3, 0xff0000 | __asm ("bics r3, r3, 0xff0000");
| if (r3 == 0) {
0x000354a0 beq 0x35508 | goto label_14;
| }
| }
| label_13:
0x000354a4 ldr r0, [pc, 0x234] | r0 = "_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s";
0x000354a8 bl 0x1436c | printf ("_4s_4s_4s_4s_4s_4s_4s_4s__08x__02x__02x__02x__20s");
0x000354ac ldrb r1, [r4, 0x32] | r1 = *((r4 + 0x32));
0x000354b0 cmp r1, 0 |
| if (r1 != 0) {
0x000354b4 beq 0x354c0 |
0x000354b8 ldr r0, [pc, 0x254] | r0 = *(0x35710);
0x000354bc bl 0x1436c | printf (r0);
| }
0x000354c0 ldrh r1, [r4, 0x30] | r1 = *((r4 + 0x30));
0x000354c4 cmp r1, 0xff |
| if (r1 >= 0xff) {
0x000354c8 bls 0x354d4 |
0x000354cc ldr r0, [pc, 0x244] | r0 = "Interrupt:_d_";
0x000354d0 bl 0x1436c | printf ("Interrupt:_d_");
| }
0x000354d4 ldr r1, [r4, 0x28] | r1 = *((r4 + 0x28));
0x000354d8 cmp r1, 0 |
| if (r1 != 0) {
0x000354dc beq 0x354ec |
0x000354e0 ldr r2, [r4, 0x2c] | r2 = *((r4 + 0x2c));
0x000354e4 ldr r0, [pc, 0x230] | r0 = "Base_address:0x_lx_";
0x000354e8 bl 0x1436c | printf ("Base_address:0x_lx_", r1, r2);
| }
0x000354ec ldrb r1, [r4, 0x33] | r1 = *((r4 + 0x33));
0x000354f0 cmp r1, 0 |
| if (r1 != 0) {
0x000354f4 beq 0x35500 |
0x000354f8 ldr r0, [pc, 0x220] | r0 = "Memory:_lx__lx_";
0x000354fc bl 0x1436c | printf ("Memory:_lx__lx_");
| }
0x00035500 mov r0, 0xa | r0 = 0xa;
0x00035504 bl 0x18ce4 | fcn_00018ce4 (r0);
| label_14:
0x00035508 mov r0, 0xa | r0 = 0xa;
0x0003550c bl 0x18ce4 | fcn_00018ce4 (r0);
0x00035510 mov r0, 0 | r0 = 0;
0x00035514 b 0x35160 | goto label_1;
| do {
0x00035518 ldrb r1, [r3], 1 | r1 = *(r3);
| r3++;
0x0003551c cmp r1, 0 |
| if (r1 != 0) {
0x00035520 bne 0x3553c | goto label_15;
| }
| label_9:
0x00035524 sub r1, r3, r0 | r1 = r3 - r0;
0x00035528 cmp ip, r1 |
0x0003552c bgt 0x35518 |
| } while (ip > r1);
0x00035530 ldr r3, [r7, 0x1c] | r3 = *((r7 + 0x1c));
0x00035534 cmp r3, 0 |
| if (r3 != 0) {
0x00035538 bne 0x351f4 | goto label_2;
| }
| label_15:
0x0003553c blx r2 | r0 = uint32_t (*r2)() ();
0x00035540 mov r1, r0 | r1 = r0;
0x00035544 ldr r0, [pc, 0x1d8] | r0 = "DMA_chan:_x_";
0x00035548 bl 0x1436c | printf ("DMA_chan:_x_", r1);
0x0003554c b 0x351f4 | goto label_2;
| label_11:
0x00035550 mov r0, fp | r0 = fp;
0x00035554 mov r1, r5 | r1 = r5;
0x00035558 bl 0x14ed0 | strcmp (r0, r1);
0x0003555c subs fp, r0, 0 |
| if (fp != s1) {
0x00035560 bne 0x352dc | goto label_3;
| }
0x00035564 add r3, sp, 0xb7 | r3 += var_b7h;
0x00035568 str r3, [sp, 4] | var_4h = r3;
0x0003556c add r3, sp, 0xb2 | r3 += var_b2h;
0x00035570 str r3, [sp] | *(sp) = r3;
0x00035574 add r2, sp, 0xa8 | r2 += var_a8h;
0x00035578 add r3, sp, 0xad | r3 += var_adh;
0x0003557c ldr r1, [pc, 0x1a4] | r1 = "HWaddr %s ";
0x00035580 str sl, [sp, 0x14] | var_14h = sl;
0x00035584 str sb, [sp, 0x10] | var_10h = sb;
0x00035588 str r8, [sp, 0xc] | var_ch = r8;
0x0003558c str r7, [sp, 8] | var_8h = r7;
0x00035590 add r0, sp, 0x80 | r0 += s;
0x00035594 bl 0x14f48 | sprintf (r0, r1, r2)
0x00035598 mov r2, 0x1c | r2 = 0x1c;
0x0003559c mov r1, fp | r1 = fp;
0x000355a0 add r0, sp, 0x64 | r0 += var_64h;
0x000355a4 bl 0x14d98 | memset (r0, r1, r2);
0x000355a8 add r2, sp, 0x6c | r2 += var_6ch;
0x000355ac add r1, sp, 0x80 | r1 += s;
0x000355b0 mov r0, 0xa | r0 = 0xa;
0x000355b4 bl 0x14414 | inet_pton ();
0x000355b8 mov r3, 0xa | r3 = 0xa;
0x000355bc mov r1, 1 | r1 = 1;
0x000355c0 add r0, sp, 0x64 | r0 += var_64h;
0x000355c4 strh r3, [sp, 0x64] | var_64h = r3;
0x000355c8 bl 0x34a40 | fcn_00034a40 (r0, r1);
0x000355cc ldr r2, [sp, 0x3c] | r2 = var_3ch;
0x000355d0 mov r1, r0 | r1 = r0;
0x000355d4 ldr r0, [pc, 0x150] | r0 = "_s:_s:_s:_s:_s:_s:_s:_s";
0x000355d8 bl 0x1436c | printf ("_s:_s:_s:_s:_s:_s:_s:_s", r1, r2);
0x000355dc ldr r0, [pc, 0x14c] | r0 = "inet6_addr:__s__d";
0x000355e0 bl 0x1436c | printf ("inet6_addr:__s__d");
0x000355e4 ldr r3, [sp, 0x40] | r3 = var_40h;
0x000355e8 and r3, r3, 0xf0 | r3 &= 0xf0;
0x000355ec cmp r3, 0x20 |
| if (r3 != 0x20) {
0x000355f0 ldreq r0, [pc, 0x13c] | r0 = *((pc + 0x13c));
| }
| if (r3 == 0x20) {
0x000355f4 beq 0x35634 | goto label_16;
| }
| if (r3 > 0x20) {
0x000355f8 bhi 0x3561c | goto label_17;
| }
0x000355fc cmp r3, 0 |
| if (r3 != 0) {
0x00035600 ldreq r0, [pc, 0x130] | r0 = "Global";
| }
| if (r3 == 0) {
0x00035604 beq 0x35634 | goto label_16;
| }
0x00035608 cmp r3, 0x10 |
| if (r3 != 0x10) {
0x0003560c ldreq r0, [pc, 0x128] | r0 = "Host";
| }
| if (r3 == 0x10) {
0x00035610 beq 0x35634 | goto label_16;
| }
| do {
0x00035614 ldr r0, [pc, 0x124] | r0 = "Host";
0x00035618 b 0x35634 | goto label_16;
| label_17:
0x0003561c cmp r3, 0x40 |
| if (r3 != 0x40) {
0x00035620 ldreq r0, [pc, 0x11c] | r0 = "Site";
| }
| if (r3 == 0x40) {
0x00035624 beq 0x35634 | goto label_16;
| }
0x00035628 cmp r3, 0x80 |
| if (r3 != 0x80) {
0x0003562c ldreq r0, [pc, 0x114] | r0 = "Compat";
| }
0x00035630 bne 0x35614 |
| } while (r3 != 0x80);
| label_16:
0x00035634 bl 0x14660 | puts (r0);
0x00035638 b 0x352dc | goto label_3;
| label_12:
0x0003563c ldr r6, [pc, 0x108] | r6 = "Compat";
0x00035640 ldr r5, [pc, 0x108] | r5 = *(0x3574c);
0x00035644 ldr r7, [pc, 0x108] | r7 = "UP";
| do {
0x00035648 ldrsh r2, [r4, 0x1a] | r2 = *((r4 + 0x1a));
0x0003564c ldrh r3, [r6, 2]! | r3 = *((r6 += 2));
0x00035650 tst r2, r3 |
| if ((r2 & r3) != 0) {
0x00035654 beq 0x35664 |
0x00035658 mov r1, r5 | r1 = r5;
0x0003565c mov r0, r7 | r0 = r7;
0x00035660 bl 0x1436c | printf (r0, r1);
| }
0x00035664 mov r0, r5 | r0 = r5;
0x00035668 bl 0x1514c | r0 = strlen (r0);
0x0003566c add r0, r0, 1 | r0++;
0x00035670 ldrb r3, [r5, r0]! | r3 = *((r5 += r0));
0x00035674 cmp r3, 0 |
0x00035678 bne 0x35648 |
| } while (r3 != 0);
0x0003567c b 0x35374 | goto label_4;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x3d208 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.0003d208 () | void fcn_0003d208 (int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| void * s2;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| char * dest;
| void * s1;
| int32_t var_ach;
| r1 = arg2;
0x0003d208 ldrh r0, [r1, 4] | r0 = *((r1 + 4));
0x0003d20c push {r4, r5, r6, r7, lr} |
0x0003d210 ldr r3, [r1] | r3 = *(r1);
0x0003d214 sub r2, r0, 0x14 | r2 = r0 - 0x14;
0x0003d218 cmp r2, 1 |
0x0003d21c sub sp, sp, 0xac |
| if (r2 < 1) {
0x0003d220 bls 0x3d234 | goto label_9;
| }
| label_0:
0x0003d224 mov r6, 0 | r6 = 0;
| do {
| label_1:
0x0003d228 mov r0, r6 | r0 = r6;
0x0003d22c add sp, sp, 0xac |
0x0003d230 pop {r4, r5, r6, r7, pc} |
| label_9:
0x0003d234 subs r3, r3, 0x18 | r3 -= 0x18;
0x0003d238 mov r5, r1 | r5 = r1;
| if (r3 >= r3) {
0x0003d23c bpl 0x3d254 | goto label_10;
| }
0x0003d240 mov r1, r3 | r1 = r3;
0x0003d244 ldr r0, [pc, 0x5f0] | r0 = *(0x3d838);
0x0003d248 bl 0x18274 | fcn_00018274 ();
| label_4:
0x0003d24c mvn r6, 0 | r6 = ~0;
0x0003d250 b 0x3d228 |
| } while (1);
| label_10:
0x0003d254 ldr r4, [pc, 0x5e4] | r4 = *(0x3d83c);
0x0003d258 ldrb r1, [r4, 5] | r1 = *((r4 + 5));
0x0003d25c ldrb r2, [r4, 4] | r2 = *((r4 + 4));
0x0003d260 orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x0003d264 ldrb r1, [r4, 6] | r1 = *((r4 + 6));
0x0003d268 orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x0003d26c ldrb r1, [r4, 7] | r1 = *((r4 + 7));
0x0003d270 orrs r2, r2, r1, lsl 24 | r2 |= (r1 << 24);
| if (r2 == r2) {
0x0003d274 movne r2, 1 | r2 = 1;
| }
| if (r2 != r2) {
0x0003d278 moveq r2, 0 | r2 = 0;
| }
0x0003d27c cmp r0, 0x14 |
| if (r0 != 0x14) {
0x0003d280 moveq r2, 0 | r2 = 0;
| }
| if (r0 == 0x14) {
0x0003d284 andne r2, r2, 1 | r2 &= 1;
| }
0x0003d288 cmp r2, 0 |
| if (r2 != 0) {
0x0003d28c bne 0x3d224 | goto label_0;
| }
0x0003d290 add r2, r5, 0x18 | r2 = r5 + 0x18;
0x0003d294 mov r1, 9 | r1 = 9;
0x0003d298 mov r0, sp | r0 = sp;
0x0003d29c bl 0x4395c | fcn_0004395c (r0, r1);
0x0003d2a0 ldr r3, [sp, 8] | r3 = s2;
0x0003d2a4 cmp r3, 0 |
0x0003d2a8 ldr r3, [sp, 4] | r3 = var_4h;
| if (r3 != 0) {
0x0003d2ac streq r3, [sp, 8] | s2 = r3;
| }
0x0003d2b0 cmp r3, 0 |
| if (r3 != 0) {
0x0003d2b4 ldreq r3, [sp, 8] | r3 = s2;
| }
| if (r3 != 0) {
0x0003d2b8 streq r3, [sp, 4] | var_4h = r3;
| }
0x0003d2bc ldrb r2, [r4, 0x25] | r2 = *((r4 + 0x25));
0x0003d2c0 ldrb r3, [r4, 0x24] | r3 = *((r4 + 0x24));
0x0003d2c4 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d2c8 ldrb r2, [r4, 0x26] | r2 = *((r4 + 0x26));
0x0003d2cc orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d2d0 ldrb r2, [r4, 0x27] | r2 = *((r4 + 0x27));
0x0003d2d4 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 == r3) {
0x0003d2d8 beq 0x3d2e8 | goto label_11;
| }
0x0003d2dc ldr r2, [r5, 0x14] | r2 = *((r5 + 0x14));
0x0003d2e0 cmp r3, r2 |
| if (r3 != r2) {
0x0003d2e4 bne 0x3d224 | goto label_0;
| }
| label_11:
0x0003d2e8 ldrb r2, [r4, 0xd] | r2 = *((r4 + 0xd));
0x0003d2ec ldrb r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x0003d2f0 ldrb r1, [r4, 0x11] | r1 = *((r4 + 0x11));
0x0003d2f4 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d2f8 ldrb r2, [r4, 0xe] | r2 = *((r4 + 0xe));
0x0003d2fc orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d300 ldrb r2, [r4, 0xf] | r2 = *((r4 + 0xf));
0x0003d304 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x0003d308 ldrb r2, [r5, 0x13] | r2 = *((r5 + 0x13));
0x0003d30c eor r3, r3, r2 | r3 ^= r2;
0x0003d310 ldrb r2, [r4, 0x10] | r2 = *((r4 + 0x10));
0x0003d314 orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x0003d318 ldrb r1, [r4, 0x12] | r1 = *((r4 + 0x12));
0x0003d31c orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x0003d320 ldrb r1, [r4, 0x13] | r1 = *((r4 + 0x13));
0x0003d324 orr r2, r2, r1, lsl 24 | r2 |= (r1 << 24);
0x0003d328 tst r3, r2 |
| if ((r3 & r2) != 0) {
0x0003d32c bne 0x3d224 | goto label_0;
| }
0x0003d330 ldrb r3, [r4, 0x15] | r3 = *((r4 + 0x15));
0x0003d334 ldrb r6, [r4, 0x14] | r6 = *((r4 + 0x14));
0x0003d338 ldrb r2, [r4, 0x19] | r2 = *((r4 + 0x19));
0x0003d33c orr r6, r6, r3, lsl 8 | r6 |= (r3 << 8);
0x0003d340 ldrb r3, [r4, 0x16] | r3 = *((r4 + 0x16));
0x0003d344 orr r6, r6, r3, lsl 16 | r6 |= (r3 << 16);
0x0003d348 ldrb r3, [r4, 0x17] | r3 = *((r4 + 0x17));
0x0003d34c orr r6, r6, r3, lsl 24 | r6 |= (r3 << 24);
0x0003d350 ldrb r3, [r5, 0x12] | r3 = *((r5 + 0x12));
0x0003d354 eor r6, r6, r3 | r6 ^= r3;
0x0003d358 ldrb r3, [r4, 0x18] | r3 = *((r4 + 0x18));
0x0003d35c orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d360 ldrb r2, [r4, 0x1a] | r2 = *((r4 + 0x1a));
0x0003d364 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d368 ldrb r2, [r4, 0x1b] | r2 = *((r4 + 0x1b));
0x0003d36c orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x0003d370 ands r6, r6, r3 | r6 &= r3;
| if (r6 != r6) {
0x0003d374 bne 0x3d224 | goto label_0;
| }
0x0003d378 ldrb r2, [r4, 1] | r2 = *((r4 + 1));
0x0003d37c ldrb r3, [r4] | r3 = *(r4);
0x0003d380 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d384 ldrb r2, [r4, 2] | r2 = *((r4 + 2));
0x0003d388 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d38c ldrb r2, [r4, 3] | r2 = *((r4 + 3));
0x0003d390 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 == r3) {
0x0003d394 bne 0x3d4fc |
| label_2:
0x0003d398 ldrb r3, [r4, 0x3c] | r3 = *((r4 + 0x3c));
0x0003d39c cmp r3, 0 |
| if (r3 != 0) {
0x0003d3a0 bne 0x3d548 | goto label_12;
| }
| label_3:
0x0003d3a4 ldrb r2, [r4, 5] | r2 = *((r4 + 5));
0x0003d3a8 ldrb r3, [r4, 4] | r3 = *((r4 + 4));
0x0003d3ac orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d3b0 ldrb r2, [r4, 6] | r2 = *((r4 + 6));
0x0003d3b4 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d3b8 ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0003d3bc orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 == r3) {
0x0003d3c0 beq 0x3d5bc | goto label_13;
| }
0x0003d3c4 ldrb r2, [r4, 0x1d] | r2 = *((r4 + 0x1d));
0x0003d3c8 ldrb r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x0003d3cc ldrb r1, [r4, 0x21] | r1 = *((r4 + 0x21));
0x0003d3d0 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d3d4 ldrb r2, [r4, 0x1e] | r2 = *((r4 + 0x1e));
0x0003d3d8 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d3dc ldrb r2, [r4, 0x1f] | r2 = *((r4 + 0x1f));
0x0003d3e0 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x0003d3e4 ldr r2, [r5] | r2 = *(r5);
0x0003d3e8 add r3, r3, 3 | r3 += 3;
0x0003d3ec bic r3, r3, 3 | r3 = BIT_MASK (r3, 3);
0x0003d3f0 add r3, r3, r2 | r3 += r2;
0x0003d3f4 ldrb r2, [r4, 0x20] | r2 = *((r4 + 0x20));
0x0003d3f8 orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x0003d3fc ldrb r1, [r4, 0x22] | r1 = *((r4 + 0x22));
0x0003d400 orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x0003d404 ldrb r1, [r4, 0x23] | r1 = *((r4 + 0x23));
0x0003d408 orr r2, r2, r1, lsl 24 | r2 |= (r1 << 24);
0x0003d40c cmp r3, r2 |
| if (r3 > r2) {
0x0003d410 bhi 0x3d5ac | goto label_14;
| }
| label_5:
0x0003d414 ldrb r2, [r4, 5] | r2 = *((r4 + 5));
0x0003d418 ldrb r3, [r4, 4] | r3 = *((r4 + 4));
0x0003d41c ldrb r1, [r4, 0x1d] | r1 = *((r4 + 0x1d));
0x0003d420 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d424 ldrb r2, [r4, 6] | r2 = *((r4 + 6));
0x0003d428 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d42c ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0003d430 orr r2, r3, r2, lsl 24 | r2 = r3 | (r2 << 24);
0x0003d434 ldrb r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x0003d438 orr r3, r3, r1, lsl 8 | r3 |= (r1 << 8);
0x0003d43c ldrb r1, [r4, 0x1e] | r1 = *((r4 + 0x1e));
0x0003d440 orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x0003d444 ldrb r1, [r4, 0x1f] | r1 = *((r4 + 0x1f));
0x0003d448 orr r3, r3, r1, lsl 24 | r3 |= (r1 << 24);
0x0003d44c add r3, r3, 3 | r3 += 3;
0x0003d450 bic r3, r3, 3 | r3 = BIT_MASK (r3, 3);
0x0003d454 add r3, r2, r3 | r3 = r2 + r3;
0x0003d458 mov r1, r5 | r1 = r5;
0x0003d45c ldr r2, [r5] | r2 = *(r5);
0x0003d460 mov r0, r3 | r0 = r3;
0x0003d464 bl 0x14624 | memcpy (r0, r1, r2);
0x0003d468 ldr r2, [pc, 0x3d4] | r2 = *(0x3d840);
0x0003d46c str r2, [r0, 4] | *((r0 + 4)) = r2;
0x0003d470 ldrb r1, [r4, 9] | r1 = *((r4 + 9));
0x0003d474 ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0003d478 orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x0003d47c ldrb r1, [r4, 0xa] | r1 = *((r4 + 0xa));
0x0003d480 orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x0003d484 ldrb r1, [r4, 0xb] | r1 = *((r4 + 0xb));
0x0003d488 orr r2, r2, r1, lsl 24 | r2 |= (r1 << 24);
0x0003d48c ldr r1, [r2, 0x1c] | r1 = stdout;
0x0003d490 add r1, r1, 1 | r1++;
0x0003d494 str r1, [r2, 0x1c] | *((r2 + 0x1c)) = r1;
0x0003d498 ldr r2, [r5] | r2 = *(r5);
0x0003d49c str r1, [r0, 8] | *((r0 + 8)) = r1;
0x0003d4a0 add r3, r0, r2 | r3 = r0 + r2;
0x0003d4a4 ldrb r1, [r4, 5] | r1 = *((r4 + 5));
0x0003d4a8 ldrb r2, [r4, 4] | r2 = *((r4 + 4));
0x0003d4ac orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x0003d4b0 ldrb r1, [r4, 6] | r1 = *((r4 + 6));
0x0003d4b4 orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x0003d4b8 ldrb r1, [r4, 7] | r1 = *((r4 + 7));
0x0003d4bc orr r2, r2, r1, lsl 24 | r2 |= (r1 << 24);
0x0003d4c0 sub r3, r3, r2 | r3 -= r2;
0x0003d4c4 lsr r1, r3, 8 | r1 = r3 >> 8;
0x0003d4c8 strb r3, [r4, 0x1c] | *((r4 + 0x1c)) = r3;
0x0003d4cc strb r1, [r4, 0x1d] | *((r4 + 0x1d)) = r1;
0x0003d4d0 lsr r1, r3, 0x10 | r1 = r3 >> 0x10;
0x0003d4d4 lsr r3, r3, 0x18 | r3 >>= 0x18;
0x0003d4d8 mov r2, 0 | r2 = 0;
0x0003d4dc strb r3, [r4, 0x1f] | *((r4 + 0x1f)) = r3;
0x0003d4e0 mov r3, 1 | r3 = 1;
0x0003d4e4 strb r1, [r4, 0x1e] | *((r4 + 0x1e)) = r1;
0x0003d4e8 strb r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
0x0003d4ec strb r2, [r4, 0x39] | *((r4 + 0x39)) = r2;
0x0003d4f0 strb r2, [r4, 0x3a] | *((r4 + 0x3a)) = r2;
0x0003d4f4 strb r2, [r4, 0x3b] | *((r4 + 0x3b)) = r2;
0x0003d4f8 b 0x3d228 | goto label_1;
| }
0x0003d4fc ldr r1, [sp, 0xc] | r1 = var_ch;
0x0003d500 cmp r1, 0 |
| if (r1 == 0) {
0x0003d504 addne r1, r1, 4 | r1 += 4;
| }
| if (r1 == 0) {
0x0003d508 bne 0x3d518 |
0x0003d50c ldr r0, [r5, 0x14] | r0 = *((r5 + 0x14));
0x0003d510 bl 0x43d04 | r0 = fcn_00043d04 (r0);
0x0003d514 mov r1, r0 | r1 = r0;
| }
0x0003d518 ldrb r0, [r4, 1] | r0 = *((r4 + 1));
0x0003d51c ldrb r3, [r4] | r3 = *(r4);
0x0003d520 mov r2, 0 | r2 = 0;
0x0003d524 orr r3, r3, r0, lsl 8 | r3 |= (r0 << 8);
0x0003d528 ldrb r0, [r4, 2] | r0 = *((r4 + 2));
0x0003d52c orr r3, r3, r0, lsl 16 | r3 |= (r0 << 16);
0x0003d530 ldrb r0, [r4, 3] | r0 = *((r4 + 3));
0x0003d534 orr r0, r3, r0, lsl 24 | r0 = r3 | (r0 << 24);
0x0003d538 bl 0x14da4 | r0 = fnmatch ();
0x0003d53c cmp r0, 0 |
| if (r0 != 0) {
0x0003d540 bne 0x3d224 | goto label_0;
| }
0x0003d544 b 0x3d398 | goto label_2;
| label_12:
0x0003d548 ldr r7, [sp, 8] | r7 = s2;
0x0003d54c cmp r7, 0 |
| if (r7 == 0) {
0x0003d550 beq 0x3d3a4 | goto label_3;
| }
0x0003d554 mov r2, 0x14 | r2 = 0x14;
0x0003d558 mov r1, 0 | r1 = 0;
0x0003d55c add r0, sp, 0x28 | r0 += dest;
0x0003d560 bl 0x14d98 | memset (r0, r1, r2);
0x0003d564 ldrb r3, [r5, 0x10] | r3 = *((r5 + 0x10));
0x0003d568 mov r1, r7 | r1 = r7;
0x0003d56c strb r3, [sp, 0x28] | dest = r3;
0x0003d570 ldrh r2, [r1], 4 | r2 = *(r1);
| r1 += 4;
0x0003d574 add r0, sp, 0x2c | r0 += s1;
0x0003d578 sub r2, r2, 4 | r2 -= 4;
0x0003d57c bl 0x14624 | memcpy (r0, r1, r2);
0x0003d580 ldrb r2, [r4, 0x3e] | r2 = *((r4 + 0x3e));
0x0003d584 ldrb r3, [r4, 0x3f] | r3 = *((r4 + 0x3f));
0x0003d588 ldr r1, [pc, 0x2b8] | r1 = *(0x3d844);
0x0003d58c orr r2, r2, r3, lsl 8 | r2 |= (r3 << 8);
0x0003d590 lsl r2, r2, 0x10 | r2 <<= 0x10;
0x0003d594 asr r2, r2, 0x10 | r2 >>= 0x10;
0x0003d598 add r0, sp, 0x28 | r0 += dest;
0x0003d59c bl 0x44bbc | r0 = fcn_00044bbc (r0, r1);
0x0003d5a0 cmp r0, 0 |
| if (r0 != 0) {
0x0003d5a4 bne 0x3d228 | goto label_1;
| }
0x0003d5a8 b 0x3d3a4 | goto label_3;
| label_14:
0x0003d5ac bl 0x3d170 | r0 = fcn_0003d170 ();
0x0003d5b0 cmp r0, 0 |
| if (r0 != 0) {
0x0003d5b4 bne 0x3d24c | goto label_4;
| }
0x0003d5b8 b 0x3d414 | goto label_5;
| label_13:
0x0003d5bc ldrh r3, [r5, 4] | r3 = *((r5 + 4));
0x0003d5c0 cmp r3, 0x15 |
| if (r3 == 0x15) {
0x0003d5c4 bne 0x3d5d0 |
0x0003d5c8 ldr r0, [pc, 0x27c] | r0 = *(0x3d848);
0x0003d5cc bl 0x1436c | printf (r0);
| }
0x0003d5d0 ldrb r2, [r4, 0x31] | r2 = *((r4 + 0x31));
0x0003d5d4 ldrb r3, [r4, 0x30] | r3 = *((r4 + 0x30));
0x0003d5d8 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x0003d5dc ldrb r2, [r4, 0x32] | r2 = *((r4 + 0x32));
0x0003d5e0 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0003d5e4 ldrb r2, [r4, 0x33] | r2 = *((r4 + 0x33));
0x0003d5e8 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 != r3) {
0x0003d5ec beq 0x3d60c |
0x0003d5f0 ldr r4, [r5, 0x14] | r4 = *((r5 + 0x14));
0x0003d5f4 mov r0, r4 | r0 = r4;
0x0003d5f8 bl 0x43d04 | fcn_00043d04 (r0);
0x0003d5fc mov r1, r4 | r1 = r4;
0x0003d600 mov r2, r0 | r2 = r0;
0x0003d604 ldr r0, [pc, 0x244] | r0 = "Deleted ";
0x0003d608 bl 0x1436c | printf ("Deleted ", r1, r2);
| }
0x0003d60c ldrb r1, [r5, 0x10] | r1 = *((r5 + 0x10));
0x0003d610 cmp r1, 2 |
| if (r1 != 2) {
0x0003d614 ldreq r0, [pc, 0x238] | r0 = " inet ";
| }
| if (r1 != 2) {
0x0003d618 beq 0x3d628 |
0x0003d61c cmp r1, 0xa |
| if (r1 != 0xa) {
0x0003d620 bne 0x3d7f0 | goto label_15;
| }
0x0003d624 ldr r0, [pc, 0x22c] | r0 = " inet ";
| }
0x0003d628 bl 0x1436c | printf (" inet ");
| do {
0x0003d62c ldr r1, [sp, 8] | r1 = s2;
0x0003d630 cmp r1, 0 |
| if (r1 != 0) {
0x0003d634 beq 0x3d688 |
0x0003d638 add r1, r1, 4 | r1 += 4;
0x0003d63c ldrb r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0003d640 bl 0x44c28 | fcn_00044c28 (r0, r1);
0x0003d644 ldr r3, [pc, 0x210] | r3 = " inet6 ";
0x0003d648 ldr r1, [r3] | r1 = " inet6 ";
0x0003d64c bl 0x149d8 | fputs_unlocked ();
0x0003d650 ldr r4, [sp, 4] | r4 = var_4h;
0x0003d654 cmp r4, 0 |
| if (r4 != 0) {
0x0003d658 beq 0x3d67c |
0x0003d65c ldr r1, [sp, 8] | r1 = s2;
0x0003d660 mov r2, 4 | r2 = 4;
0x0003d664 add r4, r4, 4 | r4 += 4;
0x0003d668 add r1, r1, r2 | r1 += r2;
0x0003d66c mov r0, r4 | r0 = r4;
0x0003d670 bl 0x14c60 | r0 = memcmp (r0, r1, r2);
0x0003d674 cmp r0, 0 |
| if (r0 != 0) {
0x0003d678 bne 0x3d7fc | goto label_16;
| }
| }
0x0003d67c ldrb r1, [r5, 0x11] | r1 = *((r5 + 0x11));
0x0003d680 ldr r0, [pc, 0x1d8] | r0 = stdout;
0x0003d684 bl 0x1436c | printf (r0, r1);
| }
| label_6:
0x0003d688 ldr r1, [sp, 0x10] | r1 = var_10h;
0x0003d68c cmp r1, 0 |
| if (r1 != 0) {
0x0003d690 beq 0x3d6ac |
0x0003d694 add r1, r1, 4 | r1 += 4;
0x0003d698 ldrb r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0003d69c bl 0x44c28 | r0 = fcn_00044c28 (r0, r1);
0x0003d6a0 mov r1, r0 | r1 = r0;
0x0003d6a4 ldr r0, [pc, 0x1b8] | r0 = *(0x3d860);
0x0003d6a8 bl 0x1436c | printf (r0, r1);
| }
0x0003d6ac ldr r1, [sp, 0x14] | r1 = var_14h;
0x0003d6b0 cmp r1, 0 |
| if (r1 != 0) {
0x0003d6b4 beq 0x3d6d0 |
0x0003d6b8 add r1, r1, 4 | r1 += 4;
0x0003d6bc ldrb r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0003d6c0 bl 0x44c28 | r0 = fcn_00044c28 (r0, r1);
0x0003d6c4 mov r1, r0 | r1 = r0;
0x0003d6c8 ldr r0, [pc, 0x198] | r0 = "brd__s_";
0x0003d6cc bl 0x1436c | printf ("brd__s_", r1);
| }
0x0003d6d0 ldrb r0, [r5, 0x13] | r0 = *((r5 + 0x13));
0x0003d6d4 bl 0x44220 | r0 = fcn_00044220 (r0);
0x0003d6d8 mov r1, r0 | r1 = r0;
0x0003d6dc ldr r0, [pc, 0x188] | r0 = "any__s_";
0x0003d6e0 bl 0x1436c | printf ("any__s_", r1);
0x0003d6e4 ldrb r3, [r5, 0x12] | r3 = *((r5 + 0x12));
0x0003d6e8 tst r3, 1 |
| if ((r3 & 1) != 0) {
0x0003d6ec beq 0x3d700 |
0x0003d6f0 bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x0003d6f4 strb r3, [r5, 0x12] | *((r5 + 0x12)) = r3;
0x0003d6f8 ldr r0, [pc, 0x170] | r0 = "scope__s_";
0x0003d6fc bl 0x1436c | printf ("scope__s_", r1, r2, r3);
| }
0x0003d700 ldrb r3, [r5, 0x12] | r3 = *((r5 + 0x12));
0x0003d704 tst r3, 0x40 |
| if ((r3 & 0x40) != 0) {
0x0003d708 beq 0x3d71c |
0x0003d70c bic r3, r3, 0x40 | r3 = BIT_MASK (r3, 0x40);
0x0003d710 strb r3, [r5, 0x12] | *((r5 + 0x12)) = r3;
0x0003d714 ldr r0, [pc, 0x158] | r0 = "secondary_";
0x0003d718 bl 0x1436c | printf ("secondary_", r1, r2, r3);
| }
0x0003d71c ldrb r3, [r5, 0x12] | r3 = *((r5 + 0x12));
0x0003d720 tst r3, 0x20 |
| if ((r3 & 0x20) != 0) {
0x0003d724 beq 0x3d738 |
0x0003d728 bic r3, r3, 0x20 | r3 = BIT_MASK (r3, 0x20);
0x0003d72c strb r3, [r5, 0x12] | *((r5 + 0x12)) = r3;
0x0003d730 ldr r0, [pc, 0x140] | r0 = "tentative ";
0x0003d734 bl 0x1436c | printf ("tentative ", r1, r2, r3);
| }
0x0003d738 ldrb r3, [r5, 0x12] | r3 = *((r5 + 0x12));
0x0003d73c tst r3, 0x80 |
| if ((r3 & 0x80) == 0) {
0x0003d740 andne r3, r3, 0x7f | r3 &= 0x7f;
| }
| if ((r3 & 0x80) == 0) {
0x0003d744 strbne r3, [r5, 0x12] | *((r5 + 0x12)) = r3;
| }
| if ((r3 & 0x80) == 0) {
0x0003d748 bne 0x3d754 |
0x0003d74c ldr r0, [pc, 0x128] | r0 = "deprecated_";
0x0003d750 bl 0x1436c | printf ("deprecated_");
| }
0x0003d754 ldrb r1, [r5, 0x12] | r1 = *((r5 + 0x12));
0x0003d758 cmp r1, 0 |
| if (r1 != 0) {
0x0003d75c beq 0x3d768 |
0x0003d760 ldr r0, [pc, 0x118] | r0 = "dynamic_";
0x0003d764 bl 0x1436c | printf ("dynamic_");
| }
0x0003d768 ldr r0, [sp, 0xc] | r0 = var_ch;
0x0003d76c cmp r0, 0 |
| if (r0 != 0) {
0x0003d770 beq 0x3d784 |
0x0003d774 ldr r3, [pc, 0xe0] | r3 = " inet6 ";
0x0003d778 add r0, r0, 4 | r0 += 4;
0x0003d77c ldr r1, [r3] | r1 = " inet6 ";
0x0003d780 bl 0x149d8 | fputs_unlocked ();
| }
0x0003d784 ldr r4, [sp, 0x18] | r4 = var_18h;
0x0003d788 cmp r4, 0 |
| if (r4 != 0) {
0x0003d78c beq 0x3d7e4 |
0x0003d790 ldr r3, [pc, 0xec] | r3 = "flags %02x ";
0x0003d794 ldrb r0, [r3] | r0 = *(r3);
0x0003d798 bl 0x18ce4 | fcn_00018ce4 (r0);
0x0003d79c ldr r2, [r4, 8] | r2 = *((r4 + 8));
0x0003d7a0 cmn r2, 1 |
| if (r2 != 1) {
0x0003d7a4 bne 0x3d81c | goto label_17;
| }
0x0003d7a8 ldr r1, [pc, 0xd8] | r1 = *(0x3d884);
0x0003d7ac add r0, sp, 0x28 | r0 += dest;
0x0003d7b0 bl 0x142f4 | strcpy (r0, r1);
| label_7:
0x0003d7b4 add r0, sp, 0x28 | r0 += dest;
0x0003d7b8 bl 0x1514c | strlen (r0);
0x0003d7bc ldr r4, [r4, 4] | r4 = *((r4 + 4));
0x0003d7c0 add r3, sp, 0x28 | r3 += dest;
0x0003d7c4 cmn r4, 1 |
0x0003d7c8 add r0, r3, r0 | r0 = r3 + r0;
| if (r4 != 1) {
0x0003d7cc bne 0x3d82c | goto label_18;
| }
0x0003d7d0 ldr r1, [pc, 0xb4] | r1 = "valid_lft forever";
0x0003d7d4 bl 0x142f4 | strcpy (r0, "valid_lft forever");
| label_8:
0x0003d7d8 add r1, sp, 0x28 | r1 += dest;
0x0003d7dc ldr r0, [pc, 0xac] | r0 = " preferred_lft forever";
0x0003d7e0 bl 0x1436c | printf (" preferred_lft forever", r1);
| }
0x0003d7e4 mov r0, 0xa | r0 = 0xa;
0x0003d7e8 bl 0x18ce4 | fcn_00018ce4 (r0);
0x0003d7ec b 0x3d228 | goto label_1;
| label_15:
0x0003d7f0 ldr r0, [pc, 0x9c] | r0 = " %s";
0x0003d7f4 bl 0x1436c | printf (" %s");
0x0003d7f8 b 0x3d62c |
| } while (1);
| label_16:
0x0003d7fc mov r1, r4 | r1 = r4;
0x0003d800 ldrb r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0003d804 bl 0x44c28 | fcn_00044c28 (r0, r1);
0x0003d808 ldrb r2, [r5, 0x11] | r2 = *((r5 + 0x11));
0x0003d80c mov r1, r0 | r1 = r0;
0x0003d810 ldr r0, [pc, 0x80] | r0 = "family__d_";
0x0003d814 bl 0x1436c | printf ("family__d_", r1, r2);
0x0003d818 b 0x3d688 | goto label_6;
| label_17:
0x0003d81c ldr r1, [pc, 0x78] | r1 = " peer %s/%d ";
0x0003d820 add r0, sp, 0x28 | r0 += dest;
0x0003d824 bl 0x14f48 | sprintf (r0, " peer %s/%d ", r2)
0x0003d828 b 0x3d7b4 | goto label_7;
| label_18:
0x0003d82c mov r2, r4 | r2 = r4;
0x0003d830 ldr r1, [pc, 0x68] | r1 = "valid_lft %dsec";
0x0003d834 bl 0x14f48 | sprintf (r0, "valid_lft %dsec", r2)
0x0003d838 b 0x3d7d8 | goto label_8;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x43e78 */
| #include <stdint.h>
|
; (fcn) fcn.00043e78 () | void fcn_00043e78 (int32_t arg1, void * arg2) {
| r0 = arg1;
| r1 = arg2;
0x00043e78 push {r4, r5, r6, r7, r8, lr} |
0x00043e7c ldr r5, [pc, 0x4c] | r5 = *(0x43ecc);
0x00043e80 ldr r4, [pc, 0x4c] | r4 = *(0x43ed0);
0x00043e84 mov r7, r0 | r7 = r0;
0x00043e88 mov r6, r1 | r6 = r1;
0x00043e8c add r8, r5, 0x26 | r8 = r5 + 0x26;
| do {
0x00043e90 ldrh r3, [r5, 2]! | r3 = *((r5 += 2));
0x00043e94 cmp r3, r7 |
| if (r3 == r7) {
0x00043e98 beq 0x43ec8 | goto label_0;
| }
0x00043e9c mov r0, r4 | r0 = r4;
0x00043ea0 bl 0x1514c | strlen (r0);
0x00043ea4 cmp r5, r8 |
0x00043ea8 add r0, r0, 1 | r0++;
0x00043eac add r4, r4, r0 | r4 += r0;
0x00043eb0 bne 0x43e90 |
| } while (r5 != r8);
0x00043eb4 mov r2, r7 | r2 = r7;
0x00043eb8 ldr r1, [pc, 0x18] | r1 = "generic";
0x00043ebc mov r0, r6 | r0 = r6;
0x00043ec0 bl 0x14f48 | sprintf (r0, "generic", r2)
0x00043ec4 mov r4, r6 | r4 = r6;
| label_0:
0x00043ec8 mov r0, r4 | r0 = r4;
0x00043ecc pop {r4, r5, r6, r7, r8, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x43edc */
| #include <stdint.h>
|
; (fcn) fcn.00043edc () | void fcn_00043edc (int32_t arg1, int32_t arg2) {
| int32_t var_4h;
| int32_t var_8h;
| char * s;
| r0 = arg1;
| r1 = arg2;
0x00043edc push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x00043ee0 ldr r8, [pc, 0x98] | r8 = *(0x43f7c);
0x00043ee4 sub sp, sp, 0x30 |
0x00043ee8 mov r2, r0 | r2 = r0;
0x00043eec mov r5, r0 | r5 = r0;
0x00043ef0 mov sb, r1 | sb = r1;
0x00043ef4 add r0, sp, 0xc | r0 += s;
0x00043ef8 ldr r1, [pc, 0x84] | r1 = *(0x43f80);
0x00043efc bl 0x14f48 | sprintf (r0, r1, r2)
0x00043f00 ldr r1, [pc, 0x80] | r1 = "/etc/iproute2/rt_%s";
0x00043f04 add r0, sp, 0xc | r0 += s;
0x00043f08 bl 0xa0ab8 | fcn_000a0ab8 (r0);
0x00043f0c ldr r7, [pc, 0x78] | r7 = *(0x43f88);
0x00043f10 ldr sl, [pc, 0x78] | sl = *(0x00043f90);
0x00043f14 mov r4, r0 | r4 = r0;
| do {
0x00043f18 mov r3, r8 | r3 = r8;
0x00043f1c mov r2, r7 | r2 = r7;
0x00043f20 add r1, sp, 4 | r1 += var_4h;
0x00043f24 mov r0, r4 | r0 = r4;
0x00043f28 bl 0xa0b1c | r0 = fcn_000a0b1c (r0, r1, r2);
0x00043f2c cmp r0, 0 |
| if (r0 != 0) {
0x00043f30 beq 0x43f60 |
0x00043f34 mov r2, 0 | r2 = 0;
0x00043f38 mov r1, r2 | r1 = r2;
0x00043f3c ldr r0, [sp, 4] | r0 = var_4h;
0x00043f40 bl 0x1a0ec | r0 = fcn_0001a0ec (r0, r1);
0x00043f44 cmp r0, sl |
0x00043f48 mov r6, r0 | r6 = r0;
| if (r0 < sl) {
0x00043f4c bls 0x43f70 | goto label_0;
| }
0x00043f50 ldr r2, [r4, 0x18] | r2 = *((r4 + 0x18));
0x00043f54 mov r1, r5 | r1 = r5;
0x00043f58 ldr r0, [pc, 0x34] | r0 = *(0x43f90);
0x00043f5c bl 0x18274 | fcn_00018274 ();
| }
0x00043f60 mov r0, r4 | r0 = r4;
0x00043f64 bl 0xa0aec | fcn_000a0aec (r0);
0x00043f68 add sp, sp, 0x30 |
0x00043f6c pop {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_0:
0x00043f70 ldr r0, [sp, 8] | r0 = var_8h;
0x00043f74 bl 0x189d4 | fcn_000189d4 (r0);
0x00043f78 str r0, [sb, r6, lsl 2] | offset_0 = r6 << 2;
| *((sb + offset_0)) = r0;
0x00043f7c b 0x43f18 |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x45338 */
| #include <stdint.h>
|
; (fcn) fcn.00045338 () | void fcn_00045338 (int32_t arg2, char * s) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_14h;
| r1 = arg2;
| r0 = s;
0x00045338 push {r0, r1, r2, r3, r4, lr} |
0x0004533c ldrb ip, [r2, 3] | ip = *((r2 + 3));
0x00045340 ldrb r3, [r2] | r3 = *(r2);
0x00045344 str ip, [sp, 8] | var_8h = ip;
0x00045348 ldrb ip, [r2, 2] | ip = *((r2 + 2));
0x0004534c str ip, [sp, 4] | var_4h = ip;
0x00045350 ldrb r2, [r2, 1] | r2 = *((r2 + 1));
0x00045354 str r2, [sp] | *(sp) = r2;
0x00045358 mov r2, r1 | r2 = r1;
0x0004535c ldr r1, [pc, 8] | r1 = "_s_u._u._u._u";
0x00045360 bl 0x14f48 | sprintf (r0, "_s_u._u._u._u", r2)
0x00045364 add sp, sp, 0x14 |
0x00045368 pop {pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x45468 */
| #include <stdint.h>
|
; (fcn) fcn.00045468 () | void fcn_00045468 (int32_t arg_1h, int32_t arg_2h, int32_t arg_12h, int32_t arg1, int32_t arg2) {
| int32_t var_4h;
| void * s1;
| int32_t var_14h;
| r0 = arg1;
| r1 = arg2;
0x00045468 ldr r3, [pc, 0x358] | r3 = *(0x457c4);
0x0004546c push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00045470 ldrb r5, [r0, -1] | r5 = *((r0 - 1));
0x00045474 and r8, r1, 0xf | r8 &= arg_1hxf;
0x00045478 ldrb r7, [r3, r8] | r7 = *((r3 + r8));
0x0004547c sub sp, sp, 0x14 |
0x00045480 mov r1, r7 | r1 = r7;
0x00045484 mov r6, r0 | r6 = r0;
0x00045488 add r0, r5, r7 | r0 = r5 + r7;
0x0004548c mov sl, r2 | sl = r2;
0x00045490 bl 0xa65d4 | fcn_000a65d4 (r0, r1);
0x00045494 ldr r3, [pc, 0x330] | r3 = *(0x457c8);
0x00045498 add r6, r6, 4 | r6 += 4;
0x0004549c ldrb r4, [r3, r8] | r4 = *((r3 + r8));
0x000454a0 mul sb, r0, r4 | sb = r0 * r4;
0x000454a4 mov r0, sl | r0 = sl;
0x000454a8 bl 0x1514c | strlen (r0);
0x000454ac add r4, sb, 2 | r4 = sb + 2;
0x000454b0 add r0, r4, r0 | r0 = r4 + r0;
0x000454b4 bl 0x18968 | fcn_00018968 (r0);
0x000454b8 mov r2, sl | r2 = sl;
0x000454bc ldr r1, [pc, 0x30c] | r1 = *(0x457cc);
0x000454c0 ldr sl, [pc, 0x30c] | sl = "_u";
0x000454c4 mov sb, r0 | sb = r0;
0x000454c8 bl 0x14f48 | sprintf (r0, r1, r2)
0x000454cc ldr r3, [pc, 0x304] | r3 = "_u";
0x000454d0 ldr r2, [pc, 0x304] | r2 = *(0x457d8);
0x000454d4 cmp r8, 7 |
| if (r8 == 7) {
0x000454d8 movne r2, r3 | r2 = r3;
| }
0x000454dc str r2, [sp, 4] | var_4h = r2;
0x000454e0 add r4, sb, r0 | r4 = sb + r0;
| do {
0x000454e4 cmp r7, r5 |
0x000454e8 sub fp, r6, 4 |
| if (r7 > r5) {
0x000454ec bgt 0x457bc | goto label_6;
| }
0x000454f0 sub r2, r8, 1 | r2 = r8 - 1;
0x000454f4 cmp r2, 0xa |
| if (r2 > 0xa) {
| /* switch table (11 cases) at 0x45500 */
0x000454f8 ldrls pc, [pc, r2, lsl 2] | offset_0 = r2 << 2;
| pc = *((pc + offset_0));
| }
0x000454fc b 0x4555c | goto label_7;
0x0004552c mov r0, r4 | r0 = r4;
0x00045530 mov r2, fp | r2 = fp;
0x00045534 ldr r1, [pc, 0x2a4] | r1 = *(0x457dc);
0x00045538 bl 0x45338 | fcn_00045338 (r0, r1);
0x0004553c cmp r8, 1 |
0x00045540 add r4, r4, r0 | r4 += r0;
| if (r8 != 1) {
0x00045544 beq 0x4555c |
0x00045548 mov r2, r6 | r2 = r6;
0x0004554c ldr r1, [pc, 0x290] | r1 = *(0x457e0);
0x00045550 mov r0, r4 | r0 = r4;
0x00045554 bl 0x45338 | r0 = fcn_00045338 (r0, r1);
| label_0:
0x00045558 add r4, r4, r0 | r4 += r0;
| }
| label_7:
0x0004555c sub r5, r5, r7 | r5 -= r7;
0x00045560 cmp r7, r5 |
0x00045564 add r6, r6, r7 | r6 += r7;
| if (r7 > r5) {
0x00045568 bgt 0x457bc | goto label_6;
| }
0x0004556c mov r3, 0x20 | r3 = 0x20;
0x00045570 strb r3, [r4] | *(r4) = r3;
0x00045574 mov r3, 0 | r3 = 0;
0x00045578 strb r3, [r4, 1] | *((r4 + 1)) = r3;
0x0004557c add r4, r4, 1 | r4++;
0x00045580 b 0x454e4 |
| } while (1);
0x00045584 ldrb r2, [r6, -4] | r2 = *((r6 - 4));
| do {
0x00045588 mov r1, sl | r1 = sl;
| label_1:
0x0004558c mov r0, r4 | r0 = r4;
0x00045590 bl 0x14f48 | sprintf (r0, r1, r2)
0x00045594 b 0x45558 | goto label_0;
0x00045598 mov r2, 2 | r2 = 2;
0x0004559c mov r1, fp | r1 = fp;
0x000455a0 add r0, sp, 0xc | r0 += s1;
0x000455a4 bl 0x14624 | memcpy (r0, r1, r2);
0x000455a8 ldrh r3, [sp, 0xc] | r3 = s1;
0x000455ac lsr r2, r3, 8 | r2 = r3 >> 8;
0x000455b0 orr r2, r2, r3, lsl 8 | r2 |= (r3 << 8);
0x000455b4 lsl r2, r2, 0x10 | r2 <<= 0x10;
0x000455b8 lsr r2, r2, 0x10 | r2 >>= 0x10;
0x000455bc b 0x45588 |
| } while (1);
0x000455c0 mov r2, 4 | r2 = 4;
0x000455c4 mov r1, fp | r1 = fp;
0x000455c8 add r0, sp, 0xc | r0 += s1;
0x000455cc bl 0x14624 | memcpy (r0, r1, r2);
0x000455d0 ldr r0, [sp, 0xc] | r0 = s1;
0x000455d4 bl 0xa780c | fcn_000a780c (r0);
0x000455d8 ldr r1, [sp, 4] | r1 = var_4h;
0x000455dc mov r2, r0 | r2 = r0;
0x000455e0 b 0x4558c | goto label_1;
0x000455e4 mov r2, r5 | r2 = r5;
0x000455e8 mov r1, fp | r1 = fp;
0x000455ec mov r0, r4 | r0 = r4;
0x000455f0 bl 0x14624 | memcpy (r0, r1, r2);
0x000455f4 mov r3, 0 | r3 = 0;
0x000455f8 cmp r8, 4 |
0x000455fc strb r3, [r4, r5] | *((r4 + r5)) = r3;
| if (r8 != 4) {
0x00045600 bne 0x457bc | goto label_6;
| }
0x00045604 mov r3, r4 | r3 = r4;
| label_5:
0x00045608 ldrb r2, [r3] | r2 = *(r3);
0x0004560c cmp r2, 0x2d |
| if (r2 == 0x2d) {
0x00045610 beq 0x45654 | goto label_8;
| }
0x00045614 mov r2, r3 | r2 = r3;
| do {
| label_2:
0x00045618 mov r0, r2 | r0 = r2;
0x0004561c ldrb r3, [r2], 1 | r3 = *(r2);
| r2++;
0x00045620 orr r1, r3, 0x20 | r1 = r3 | 0x20;
0x00045624 sub r1, r1, 0x61 | r1 -= 0x61;
0x00045628 cmp r1, 0x19 |
0x0004562c bls 0x45618 |
| } while (r1 < 0x19);
0x00045630 sub r1, r3, 0x30 | r1 = r3 - 0x30;
0x00045634 cmp r1, 9 |
| if (r1 < 9) {
0x00045638 bls 0x45618 | goto label_2;
| }
0x0004563c cmp r3, 0x2e |
0x00045640 cmpne r3, 0 | __asm ("cmpne r3, 0");
| if (r3 == 0x2e) {
0x00045644 beq 0x457a4 | goto label_9;
| }
0x00045648 cmp r3, 0x2d |
0x0004564c cmpne r3, 0x5f | __asm ("cmpne r3, 0x5f");
| if (r3 == 0x2d) {
0x00045650 beq 0x45618 | goto label_2;
| }
| label_8:
0x00045654 mov r2, r5 | r2 = r5;
0x00045658 ldr r1, [pc, 0x188] | r1 = *(0x457e4);
0x0004565c mov r0, r4 | r0 = r4;
0x00045660 bl 0xa40f4 | fcn_000a40f4 (r0);
0x00045664 b 0x457bc | goto label_6;
| do {
0x00045668 ldrb sl, [fp] | sl = *(fp);
0x0004566c add r6, fp, 1 | r6 += arg_1h;
0x00045670 cmp sl, 0x20 |
| if (sl > 0x20) {
0x00045674 bhi 0x457bc | goto label_6;
| }
0x00045678 add r2, sl, 7 | r2 = sl + 7;
0x0004567c mov r0, 0 | r0 = 0;
0x00045680 sub r5, r5, 1 | r5--;
0x00045684 lsr r2, r2, 3 | r2 >>= 3;
0x00045688 mov r3, r6 | r3 = r6;
0x0004568c str r0, [sp, 0xc] | s1 = r0;
| label_3:
0x00045690 cmp r2, r0 |
| if (r2 != r0) {
0x00045694 bne 0x456f8 | goto label_10;
| }
0x00045698 sub r5, r5, r2 | r5 -= r2;
0x0004569c cmp r5, 3 |
0x000456a0 add r6, r6, r2 | r6 += r2;
| if (r5 <= 3) {
0x000456a4 ble 0x457bc | goto label_6;
| }
0x000456a8 mov r2, r8 | r2 = r8;
0x000456ac mov r0, r4 | r0 = r4;
0x000456b0 bl 0x45338 | fcn_00045338 (r0, r1);
0x000456b4 mov r2, sl | r2 = sl;
0x000456b8 mov r1, r7 | r1 = r7;
0x000456bc add fp, r6, 4 |
0x000456c0 sub r5, r5, 4 | r5 -= 4;
0x000456c4 add r4, r4, r0 | r4 += r0;
0x000456c8 mov r0, r4 | r0 = r4;
0x000456cc bl 0x14f48 | sprintf (r0, r1, r2)
0x000456d0 ldr r1, [pc, 0x108] | r1 = *(0x457dc);
0x000456d4 mov r2, r6 | r2 = r6;
0x000456d8 add r4, r4, r0 | r4 += r0;
0x000456dc mov r0, r4 | r0 = r4;
0x000456e0 bl 0x45338 | fcn_00045338 (r0, r1);
0x000456e4 ldr r1, [pc, 0x100] | r1 = *(0x457e8);
0x000456e8 add r4, r4, r0 | r4 += r0;
| label_4:
0x000456ec cmp r5, 4 |
0x000456f0 bgt 0x45668 |
| } while (r5 > 4);
0x000456f4 b 0x457bc | goto label_6;
| label_10:
0x000456f8 ldrb ip, [r3], 1 | ip = *(r3);
| r3++;
0x000456fc strb ip, [r0, r8] | *((r0 + r8)) = ip;
0x00045700 add r0, r0, 1 | r0++;
0x00045704 b 0x45690 | goto label_3;
0x00045708 ldr r1, [pc, 0xd0] | r1 = *(0x457dc);
0x0004570c add r8, sp, 0xc | r8 += s1;
0x00045710 ldr r7, [pc, 0xd8] | r7 = *(0x457ec);
0x00045714 b 0x456ec | goto label_4;
0x00045718 cmp r5, 0x15 |
| if (r5 <= 0x15) {
0x0004571c ble 0x457bc | goto label_6;
| }
0x00045720 ldrb r2, [fp] | r2 = *(fp);
0x00045724 cmp r2, 0x20 |
| if (r2 > 0x20) {
0x00045728 bhi 0x457bc | goto label_6;
| }
0x0004572c ldrb r1, [fp, 1] | r1 = *(arg_1h);
0x00045730 add r1, r1, 0x20 | r1 += 0x20;
0x00045734 sub r1, r1, r2 | r1 -= r2;
0x00045738 cmp r1, 0x80 |
| if (r1 > 0x80) {
0x0004573c bgt 0x457bc | goto label_6;
| }
0x00045740 ldr r1, [pc, 0xac] | r1 = *(0x457f0);
0x00045744 mov r0, r4 | r0 = r4;
0x00045748 bl 0x14f48 | sprintf (r0, r1, r2)
0x0004574c ldrb r2, [fp, 1] | r2 = *(arg_1h);
0x00045750 ldr r1, [pc, 0x9c] | r1 = *(0x457f0);
0x00045754 ldr r7, [pc, 0x90] | r7 = *(0x457e8);
0x00045758 sub r5, r5, 0x16 | r5 -= 0x16;
0x0004575c add r4, r4, r0 | r4 += r0;
0x00045760 mov r0, r4 | r0 = r4;
0x00045764 bl 0x14f48 | sprintf (r0, r1, r2)
0x00045768 add r1, fp, 2 | r1 += arg_2h;
0x0004576c add r4, r4, r0 | r4 += r0;
0x00045770 mov r0, r4 | r0 = r4;
0x00045774 bl 0x478e0 | fcn_000478e0 (r0);
0x00045778 add r3, fp, 0x12 | r3 += arg_12h;
0x0004577c add r6, r3, r5 | r6 = r3 + r5;
0x00045780 add r4, r4, r0 | r4 += r0;
| do {
0x00045784 sub r2, r6, r5 | r2 = r6 - r5;
0x00045788 mov r0, r4 | r0 = r4;
0x0004578c mov r1, r7 | r1 = r7;
0x00045790 bl 0x45338 | fcn_00045338 (r0, r1);
0x00045794 subs r5, r5, 4 | r5 -= 4;
0x00045798 add r4, r4, r0 | r4 += r0;
| if (r5 < r5) {
0x0004579c bmi 0x457bc | goto label_6;
| }
0x000457a0 b 0x45784 |
| } while (1);
| label_9:
0x000457a4 cmp r3, 0 |
| if (r3 == 0) {
0x000457a8 beq 0x457bc | goto label_6;
| }
0x000457ac ldrb r2, [r0, 1] | r2 = *((r0 + 1));
0x000457b0 add r3, r0, 1 | r3 = r0 + 1;
0x000457b4 cmp r2, 0 |
| if (r2 != 0) {
0x000457b8 bne 0x45608 | goto label_5;
| }
| label_6:
0x000457bc mov r0, sb | r0 = sb;
0x000457c0 add sp, sp, 0x14 |
0x000457c4 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x457f8 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.000457f8 () | void fcn_000457f8 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| void * s1;
| void * s;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_20h_2;
| int32_t var_38h;
| int32_t var_3ch;
| int32_t var_0h_2;
| r0 = arg1;
| r1 = arg2;
0x000457f8 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000457fc sub sp, sp, 0x3c |
0x00045800 mov r4, r0 | r4 = r0;
0x00045804 str r1, [sp] | *(sp) = r1;
0x00045808 mov r2, 0x20 | r2 = 0x20;
0x0004580c mov r1, 0 | r1 = 0;
0x00045810 add r0, sp, 0x18 | r0 += s;
0x00045814 bl 0x14d98 | memset (r0, r1, r2);
0x00045818 cmp r4, 0 |
| if (r4 != 0) {
0x0004581c moveq r8, r4 | r8 = r4;
| }
| if (r4 != 0) {
0x00045820 moveq r6, 6 | r6 = 6;
| }
| if (r4 == 0) {
0x00045824 beq 0x45894 | goto label_2;
| }
0x00045828 mov r5, 1 | r5 = 1;
0x0004582c mov r6, 6 | r6 = 6;
0x00045830 mov r8, 0 | r8 = 0;
0x00045834 mov r7, r5 | r7 = r5;
| do {
0x00045838 mov r1, r5 | r1 = r5;
0x0004583c mov r0, r4 | r0 = r4;
0x00045840 bl 0x471ec | r0 = fcn_000471ec (r0, r1);
0x00045844 cmp r0, 0 |
| if (r0 != 0) {
0x00045848 beq 0x45888 |
0x0004584c cmp r5, 0x34 |
0x00045850 add r3, r6, 1 | r3 = r6 + 1;
| if (r5 != 0x34) {
0x00045854 ldrbeq r3, [r0] | r3 = *(r0);
| }
| if (r5 != 0x34) {
0x00045858 orreq r8, r8, r3 | r8 |= r3;
| }
| if (r5 != 0x34) {
0x0004585c beq 0x45868 |
0x00045860 cmp r5, 1 |
| if (r5 == 1) {
0x00045864 moveq r6, r3 | r6 = r3;
| goto label_3;
| }
| }
| label_3:
0x00045868 add r2, sp, 0x38 | r2 += var_38h;
0x0004586c lsr r3, r5, 5 | r3 = r5 >> 5;
0x00045870 add r3, r2, r3, lsl 2 | r3 = r2 + (r3 << 2);
0x00045874 ldr r1, [r3, -0x20] | r1 = s;
0x00045878 and r2, r5, 0x1f | r2 = r5 & 0x1f;
0x0004587c orr r2, r1, r7, lsl r2 | r2 = r1 | (r7 << r2);
0x00045880 add r6, r6, 1 | r6++;
0x00045884 str r2, [r3, -0x20] | s = r2;
| }
0x00045888 add r5, r5, 1 | r5++;
0x0004588c cmp r5, 0xff |
0x00045890 bne 0x45838 |
| } while (r5 != 0xff);
| label_2:
0x00045894 lsl r0, r6, 2 | r0 = r6 << 2;
0x00045898 bl 0x189b8 | fcn_000189b8 (r0);
0x0004589c ldr r6, [pc, 0x2c8] | r6 = *(0x45b68);
0x000458a0 ldrb r1, [r6, 0x22d] | r1 = *((r6 + 0x22d));
0x000458a4 ldrb r3, [r6, 0x22c] | r3 = *((r6 + 0x22c));
0x000458a8 orr r3, r3, r1, lsl 8 | r3 |= (r1 << 8);
0x000458ac ldrb r1, [r6, 0x22e] | r1 = *((r6 + 0x22e));
0x000458b0 orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x000458b4 ldrb r1, [r6, 0x22f] | r1 = *((r6 + 0x22f));
0x000458b8 orr r1, r3, r1, lsl 24 | r1 = r3 | (r1 << 24);
0x000458bc mov r7, r0 | r7 = r0;
0x000458c0 ldr r0, [pc, 0x2a8] | r0 = *(0x45b6c);
0x000458c4 bl 0x18d1c | fcn_00018d1c ();
0x000458c8 str r0, [r7] | *(r7) = r0;
0x000458cc bl 0x14804 | putenv ();
0x000458d0 cmp r4, 0 |
| if (r4 == 0) {
0x000458d4 beq 0x45a40 | goto label_4;
| }
0x000458d8 mov r0, 0x13 | r0 = 0x13;
0x000458dc bl 0x18968 | fcn_00018968 (r0);
0x000458e0 add r2, r4, 0x10 | r2 = r4 + 0x10;
0x000458e4 ldr r1, [pc, 0x288] | r1 = "interface_s";
0x000458e8 add r5, r7, 8 | r5 = r7 + 8;
0x000458ec mov sb, r0 | sb = r0;
0x000458f0 str r0, [r7, 4] | *((r7 + 4)) = r0;
0x000458f4 bl 0x45338 | fcn_00045338 (r0, r1);
0x000458f8 mov r0, sb | r0 = sb;
0x000458fc bl 0x14804 | putenv ();
0x00045900 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x00045904 cmp r3, 0 |
| if (r3 != 0) {
0x00045908 beq 0x45934 |
0x0004590c mov r0, 0x17 | r0 = 0x17;
0x00045910 bl 0x18968 | fcn_00018968 (r0);
0x00045914 add r2, r4, 0x14 | r2 = r4 + 0x14;
0x00045918 ldr r1, [pc, 0x258] | r1 = "ip";
0x0004591c add r5, r7, 0xc | r5 = r7 + 0xc;
0x00045920 mov sb, r0 | sb = r0;
0x00045924 str r0, [r7, 8] | *((r7 + 8)) = r0;
0x00045928 bl 0x45338 | fcn_00045338 (r0, r1);
0x0004592c mov r0, sb | r0 = sb;
0x00045930 bl 0x14804 | putenv ();
| }
0x00045934 tst r8, 1 |
| if ((r8 & 1) == 0) {
0x00045938 bne 0x4595c |
0x0004593c ldrb r3, [r4, 0x6c] | r3 = *((r4 + 0x6c));
0x00045940 cmp r3, 0 |
| if (r3 == 0) {
0x00045944 beq 0x4595c | goto label_5;
| }
0x00045948 add r1, r4, 0x6c | r1 = r4 + 0x6c;
0x0004594c ldr r0, [pc, 0x228] | r0 = "siaddr=";
0x00045950 bl 0x18d1c | fcn_00018d1c ();
0x00045954 str r0, [r5], 4 | *(r5) = r0;
| r5 += 4;
0x00045958 bl 0x14804 | putenv ();
| }
| label_5:
0x0004595c tst r8, 2 |
| if ((r8 & 2) == 0) {
0x00045960 bne 0x45984 |
0x00045964 ldrb r3, [r4, 0x2c] | r3 = *((r4 + 0x2c));
0x00045968 cmp r3, 0 |
| if (r3 == 0) {
0x0004596c beq 0x45984 | goto label_6;
| }
0x00045970 add r1, r4, 0x2c | r1 = r4 + 0x2c;
0x00045974 ldr r0, [pc, 0x204] | r0 = "boot_file=%.128s";
0x00045978 bl 0x18d1c | fcn_00018d1c ();
0x0004597c str r0, [r5], 4 | *(r5) = r0;
| r5 += 4;
0x00045980 bl 0x14804 | putenv ();
| }
| label_6:
0x00045984 ldr sb, [pc, 0x1f8] | sb = "sname_.64s";
0x00045988 ldr r8, [pc, 0x1f8] | r8 = *(0x45b84);
0x0004598c ldr fp, [pc, 0x1f8] | fp = "mask_u";
| label_0:
0x00045990 ldrb r3, [r8] | r3 = *(r8);
0x00045994 cmp r3, 0 |
| if (r3 != 0) {
0x00045998 bne 0x45a98 | goto label_7;
| }
0x0004599c ldr fp, [pc, 0x1ec] | fp = "opt_u";
0x000459a0 mov r8, r3 | r8 = r3;
| do {
0x000459a4 lsr r3, r8, 5 | r3 = r8 >> 5;
0x000459a8 add r2, sp, 0x38 | r2 += var_38h;
0x000459ac add r3, r2, r3, lsl 2 | r3 = r2 + (r3 << 2);
0x000459b0 ldr r3, [r3, -0x20] | r3 = var_20h_2;
0x000459b4 cmp r3, 0 |
| if (r3 != 0) {
0x000459b8 addeq r8, r8, 0x20 | r8 += 0x20;
| }
| if (r3 != 0) {
0x000459bc beq 0x45a38 |
0x000459c0 and r2, r8, 0x1f | r2 = r8 & 0x1f;
0x000459c4 mov r1, 1 | r1 = 1;
0x000459c8 ands r3, r3, r1, lsl r2 | r3 &= (r1 << r2);
| if (r3 != r3) {
0x000459cc beq 0x45a34 |
0x000459d0 mov r1, r8 | r1 = r8;
0x000459d4 mov r0, r4 | r0 = r4;
0x000459d8 bl 0x471ec | fcn_000471ec (r0, r1);
0x000459dc mov r2, 2 | r2 = 2;
0x000459e0 ldrb r3, [r0, -1] | r3 = *((r0 - 1));
0x000459e4 mov sl, r0 | sl = r0;
0x000459e8 mov r0, 9 | r0 = 9;
0x000459ec mla r2, r3, r2, r0 | __asm ("mla r2, r3, r2, r0");
0x000459f0 str r3, [sp, 4] | var_4h = r3;
0x000459f4 mov r0, r2 | r0 = r2;
0x000459f8 bl 0x18968 | fcn_00018968 (r0);
0x000459fc mov r2, r8 | r2 = r8;
0x00045a00 mov r1, fp | r1 = fp;
0x00045a04 str r0, [r5], 4 | *(r5) = r0;
| r5 += 4;
0x00045a08 mov sb, r0 | sb = r0;
0x00045a0c bl 0x14f48 | sprintf (r0, r1, r2)
0x00045a10 ldr r3, [sp, 4] | r3 = var_4h;
0x00045a14 mov r1, sl | r1 = sl;
0x00045a18 mov r2, r3 | r2 = r3;
0x00045a1c add r0, sb, r0 | r0 = sb + r0;
0x00045a20 bl 0x18450 | fcn_00018450 (r0, r1);
0x00045a24 mov r3, 0 | r3 = 0;
0x00045a28 strb r3, [r0] | *(r0) = r3;
0x00045a2c mov r0, sb | r0 = sb;
0x00045a30 bl 0x14804 | putenv ();
| }
0x00045a34 add r8, r8, 1 | r8++;
| }
0x00045a38 cmp r8, 0xff |
0x00045a3c ble 0x459a4 |
| } while (r8 <= 0xff);
| label_4:
0x00045a40 ldrb r2, [r6, 0x235] | r2 = *((r6 + 0x235));
0x00045a44 ldrb r3, [r6, 0x234] | r3 = *((r6 + 0x234));
0x00045a48 add r0, sp, 0x18 | r0 += s;
0x00045a4c orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00045a50 ldrb r2, [r6, 0x236] | r2 = *((r6 + 0x236));
0x00045a54 sub r4, r7, 4 | r4 = r7 - 4;
0x00045a58 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00045a5c ldrb r2, [r6, 0x237] | r2 = *((r6 + 0x237));
0x00045a60 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x00045a64 str r3, [sp, 0x18] | s = r3;
0x00045a68 ldr r3, [sp] | r3 = *(sp);
0x00045a6c str r3, [sp, 0x1c] | var_1ch = r3;
0x00045a70 mov r3, 0 | r3 = 0;
0x00045a74 str r3, [sp, 0x20] | var_20h = r3;
0x00045a78 bl 0xa54b8 | fcn_000a54b8 ();
| label_1:
0x00045a7c ldr r0, [r4, 4]! | r0 = *((r4 += 4));
0x00045a80 cmp r0, 0 |
| if (r0 != 0) {
0x00045a84 bne 0x45b64 | goto label_8;
| }
0x00045a88 mov r0, r7 | r0 = r7;
0x00045a8c add sp, sp, 0x3c |
0x00045a90 pop {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00045a94 b 0x152a8 | void (*0x152a8)() ();
| label_7:
0x00045a98 ldrb sl, [sb] | sl = *(sb);
0x00045a9c mov r1, 1 | r1 = 1;
0x00045aa0 and r2, sl, 0x1f | r2 = sl & 0x1f;
0x00045aa4 lsl r1, r1, r2 | r1 <<= r2;
0x00045aa8 lsr r3, sl, 5 | r3 = sl >> 5;
0x00045aac add r2, sp, 0x38 | r2 += var_38h;
0x00045ab0 add r3, r2, r3, lsl 2 | r3 = r2 + (r3 << 2);
0x00045ab4 ldr r2, [r3, -0x20] | r2 = s;
0x00045ab8 tst r1, r2 |
| if ((r1 & r2) == 0) {
0x00045abc beq 0x45b40 | goto label_9;
| }
0x00045ac0 bic r2, r2, r1 | r2 = BIT_MASK (r2, r1);
0x00045ac4 mov r0, r4 | r0 = r4;
0x00045ac8 mov r1, sl | r1 = sl;
0x00045acc str r2, [r3, -0x20] | s = r2;
0x00045ad0 bl 0x471ec | fcn_000471ec (r0, r1);
0x00045ad4 mov r2, r8 | r2 = r8;
0x00045ad8 ldrb r1, [sb, -1] | r1 = *((sb - 1));
0x00045adc str r0, [sp, 8] | var_8h = r0;
0x00045ae0 bl 0x45468 | fcn_00045468 (r0, r1, r2, r3, r4);
0x00045ae4 mov r2, r5 | r2 = r5;
0x00045ae8 str r0, [r2], 4 | *(r2) = r0;
| r2 += 4;
0x00045aec str r2, [sp, 4] | var_4h = r2;
0x00045af0 str r2, [sp, 0xc] | var_ch = r2;
0x00045af4 bl 0x14804 | putenv ();
0x00045af8 ldmib sp, {r2, r3} | __asm ("ldmib sp, {r2, r3}");
0x00045afc cmp sl, 1 |
| if (sl == 1) {
0x00045b00 movne r5, r2 | r5 = r2;
| }
| if (sl != 1) {
0x00045b04 bne 0x45b40 | goto label_9;
| }
0x00045b08 mov r1, r3 | r1 = r3;
0x00045b0c mov r2, 4 | r2 = 4;
0x00045b10 add r0, sp, 0x14 | r0 += s1;
0x00045b14 bl 0x14624 | memcpy (r0, r1, r2);
0x00045b18 ldr r0, [sp, 0x14] | r0 = s1;
0x00045b1c bl 0xa780c | fcn_000a780c (r0);
0x00045b20 mov r1, 0 | r1 = 0;
| do {
0x00045b24 cmp r0, 0 |
| if (r0 == 0) {
0x00045b28 bne 0x45b58 |
0x00045b2c mov r0, fp | r0 = fp;
0x00045b30 bl 0x18d1c | fcn_00018d1c ();
0x00045b34 add r5, r5, 8 | r5 += 8;
0x00045b38 str r0, [r5, -4] | *((r5 - 4)) = r0;
0x00045b3c bl 0x14804 | putenv ();
| label_9:
0x00045b40 mov r0, r8 | r0 = r8;
0x00045b44 bl 0x1514c | strlen (r0);
0x00045b48 add sb, sb, 2 | sb += 2;
0x00045b4c add r0, r0, 1 | r0++;
0x00045b50 add r8, r8, r0 | r8 += r0;
0x00045b54 b 0x45990 | goto label_0;
| }
0x00045b58 add r1, r1, 1 | r1++;
0x00045b5c lsl r0, r0, 1 | r0 <<= 1;
0x00045b60 b 0x45b24 |
| } while (1);
| label_8:
0x00045b64 bl 0x18de0 | fcn_00018de0 (r0);
0x00045b68 b 0x45a7c | goto label_1;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x478e0 */
| #include <stdint.h>
|
; (fcn) fcn.000478e0 () | void fcn_000478e0 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_30h;
| int32_t var_34h;
| int32_t var_38h;
| r0 = arg1;
0x000478e0 push {r4, lr} |
0x000478e4 sub sp, sp, 0x38 |
0x000478e8 mov r4, r0 | r4 = r0;
0x000478ec mov r2, 0x10 | r2 = 0x10;
0x000478f0 add r0, sp, 0x18 | r0 += var_18h;
0x000478f4 bl 0x18450 | fcn_00018450 (r0, r1);
0x000478f8 add r3, sp, 0x34 | r3 += var_34h;
0x000478fc str r3, [sp, 0x14] | var_14h = r3;
0x00047900 add r3, sp, 0x30 | r3 += var_30h;
0x00047904 str r3, [sp, 0x10] | var_10h = r3;
0x00047908 add r3, sp, 0x2c | r3 += var_2ch;
0x0004790c str r3, [sp, 0xc] | var_ch = r3;
0x00047910 add r3, sp, 0x28 | r3 += var_28h;
0x00047914 str r3, [sp, 8] | var_8h = r3;
0x00047918 add r3, sp, 0x24 | r3 += var_24h;
0x0004791c str r3, [sp, 4] | var_4h = r3;
0x00047920 add r3, sp, 0x20 | r3 += var_20h;
0x00047924 str r3, [sp] | *(sp) = r3;
0x00047928 add r2, sp, 0x18 | r2 += var_18h;
0x0004792c add r3, sp, 0x1c | r3 += var_1ch;
0x00047930 ldr r1, [pc, 0xc] | r1 = *(0x47940);
0x00047934 mov r0, r4 | r0 = r4;
0x00047938 bl 0x14f48 | sprintf (r0, r1, r2)
0x0004793c add sp, sp, 0x38 |
0x00047940 pop {r4, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x48c28 */
| #include <stdint.h>
|
; (fcn) fcn.00048c28 () | void fcn_00048c28 (int32_t arg1) {
| char * s;
| int32_t var_5ch;
| r0 = arg1;
0x00048c28 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00048c2c ldr r6, [pc, 0x78] | r6 = *(0x48ca8);
0x00048c30 sub sp, sp, 0x5c |
0x00048c34 ldr sl, [pc, 0x74] | sl = "_.6s_";
0x00048c38 mov r4, sp | r4 = sp;
0x00048c3c mov r7, r0 | r7 = r0;
0x00048c40 mov r5, 0 | r5 = 0;
0x00048c44 mov sb, r4 | sb = r4;
0x00048c48 add fp, r6, 2 |
| do {
0x00048c4c add r8, fp, r5 | r8 = fp + r5;
0x00048c50 mov r2, 6 | r2 = 6;
0x00048c54 mov r1, r8 | r1 = r8;
0x00048c58 mov r0, r7 | r0 = r7;
0x00048c5c bl 0x14b94 | r0 = strncmp (r0, r1, r2);
0x00048c60 cmp r0, 0 |
| if (r0 == 0) {
0x00048c64 beq 0x48ca0 | goto label_0;
| }
0x00048c68 mov r0, r4 | r0 = r4;
0x00048c6c mov r2, r8 | r2 = r8;
0x00048c70 mov r1, sl | r1 = sl;
0x00048c74 bl 0x14f48 | sprintf (r0, r1, r2)
0x00048c78 add r5, r5, 0x14 | r5 += 0x14;
0x00048c7c cmp r5, 0xf0 |
0x00048c80 add r4, r4, r0 | r4 += r0;
0x00048c84 bne 0x48c4c |
| } while (r5 != 0xf0);
0x00048c88 mov r3, 0 | r3 = 0;
0x00048c8c mov r2, sb | r2 = sb;
0x00048c90 mov r1, r7 | r1 = r7;
0x00048c94 ldr r0, [pc, 0x18] | r0 = "_.6s_";
0x00048c98 strb r3, [r4, -1] | *((r4 - 1)) = r3;
0x00048c9c bl 0x18254 | fcn_00018254 ();
| label_0:
0x00048ca0 add r0, r6, r5 | r0 = r6 + r5;
0x00048ca4 add sp, sp, 0x5c |
0x00048ca8 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x5105c */
| #include <stdint.h>
|
; (fcn) fcn.0005105c () | void fcn_0005105c (int32_t arg1) {
| char * s;
| int32_t var_10h_2;
| char * var_10h;
| r0 = arg1;
0x0005105c ldr r3, [pc, 0x7c] | r3 = *(0x510dc);
0x00051060 str lr, [sp, -4]! |
0x00051064 ldr r1, [r3] | r1 = *(0x510dc);
0x00051068 ldr r3, [pc, 0x74] | r3 = *(0x510e0);
0x0005106c cmp r1, 3 |
0x00051070 sub sp, sp, 0x54 |
0x00051074 mov r6, r0 | r6 = r0;
0x00051078 ldr r2, [r3, r1, lsl 2] | r2 = *(0x510e0);
0x0005107c mov r4, r3 | r4 = r3;
| if (r1 > 3) {
0x00051080 ble 0x51094 |
0x00051084 ldr r1, [pc, 0x5c] | r1 = "end_of_file";
0x00051088 mov r0, sp | r0 = sp;
0x0005108c bl 0x14f48 | sprintf (r0, "end_of_file", r2)
0x00051090 mov r2, sp | r2 = sp;
| }
0x00051094 ldr r1, [pc, 0x50] | r1 = *(0x510e8);
0x00051098 add r0, sp, 0x10 | r0 += var_10h;
0x0005109c bl 0x14f48 | sprintf (r0, r1, r2)
0x000510a0 cmn r6, 1 |
| if (r6 != 1) {
0x000510a4 beq 0x510d8 |
0x000510a8 add r3, sp, 0x10 | r3 += var_10h;
0x000510ac cmp r6, 3 |
0x000510b0 add r5, r3, r0 | r5 = r3 + r0;
0x000510b4 ldr r2, [r4, r6, lsl 2] | offset_0 = r6 << 2;
| r2 = *((r4 + offset_0));
| if (r6 > 3) {
0x000510b8 ble 0x510cc |
0x000510bc ldr r1, [pc, 0x24] | r1 = "end_of_file";
0x000510c0 mov r0, sp | r0 = sp;
0x000510c4 bl 0x14f48 | sprintf (r0, "end_of_file", r2)
0x000510c8 mov r2, sp | r2 = sp;
| }
0x000510cc ldr r1, [pc, 0x1c] | r1 = "unexpected__s";
0x000510d0 mov r0, r5 | r0 = r5;
0x000510d4 bl 0x14f48 | sprintf (r0, "unexpected__s", r2)
| }
0x000510d8 add r0, sp, 0x10 | r0 += var_10h;
0x000510dc bl 0x4d9cc | fcn_0004d9cc (r0);
0x000510e0 ldrdeq sp, lr, [sp], -r0 | __asm ("ldrdeq sp, lr, [sp], -r0");
| if (r6 != 3) {
0x000510e4 andeq r8, sl, r4, ror fp | r8 = sl & (r4 >>> fp);
| }
| if (r6 != 3) {
0x000510e8 andeq lr, fp, r3, lsl sp | lr = fp & (r3 << sp);
| }
| if (r6 != 3) {
0x000510ec andeq r3, ip, r0, lsr 7 | r3 = ip & (r0 >> 7);
| }
| /* Beware that this jump is a conditional jump.
| * r2dec transformed it as a return, due being the
| * last instruction. Please, check 'pdda' output
| * for more hints. */
0x000510f0 andeq r3, ip, lr, lsr 7 | return r3 = ip & (lr >> 7);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x58f0c */
| #include <stdint.h>
|
; (fcn) fcn.00058f0c () | void fcn_00058f0c (int32_t arg1, int32_t arg2) {
| int32_t var_30h;
| int32_t var_20h;
| int32_t var_18h;
| int32_t var_10h;
| int32_t var_8h;
| int32_t var_0h;
| int32_t var_4h;
| char * s;
| int32_t var_2ch;
| r0 = arg1;
| r1 = arg2;
0x00058f0c push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00058f10 ldr fp, [r3] | fp = *(r3);
0x00058f14 sub sp, sp, 0x2c |
0x00058f18 cmp fp, r2 |
0x00058f1c bne 0x58f28 |
| while (r3 == 0) {
| label_1:
0x00058f20 ldr r8, [pc, 0x500] | r8 = *(0x59424);
0x00058f24 b 0x5905c | goto label_2;
0x00058f28 sub r7, fp, 0x18 | r7 = fp - 0x18;
0x00058f2c mov r6, r1 | r6 = r1;
0x00058f30 mov r1, r7 | r1 = r7;
0x00058f34 str r3, [sp] | *(sp) = r3;
0x00058f38 mov sl, r0 | sl = r0;
0x00058f3c mov sb, r2 | sb = r2;
0x00058f40 bl 0x597b0 | fcn_000597b0 (r0, r1);
0x00058f44 ldr r3, [sp] | r3 = *(sp);
0x00058f48 subs r8, r0, 0 | r8 = r0 - 0;
| if (r8 != r0) {
0x00058f4c bne 0x5905c | goto label_2;
| }
0x00058f50 cmp r6, 0x11 |
0x00058f54 ldrd r4, r5, [fp, -0x18] | __asm ("ldrd r4, r5, [var_18h]");
| if (r6 != 0x11) {
0x00058f58 bne 0x58fd0 | goto label_11;
| }
0x00058f5c rsbs r4, r4, 0 | r4 -= ;
0x00058f60 rsc r5, r5, 0 | __asm ("rsc r5, r5, 0");
| label_0:
0x00058f64 and r3, r6, 0x1f | r3 = r6 & 0x1f;
0x00058f68 cmp r3, 3 |
| if (r3 != 3) {
0x00058f6c moveq r3, 2 | r3 = 2;
| }
0x00058f70 sub r2, r3, 0x12 | r2 = r3 - 0x12;
0x00058f74 cmp r3, 2 |
0x00058f78 cmpne r2, 1 | __asm ("cmpne r2, 1");
| if (r3 > 2) {
0x00058f7c bhi 0x58fc0 | goto label_8;
| }
0x00058f80 ldr r3, [r7, 0x14] | r3 = *((r7 + 0x14));
0x00058f84 cmp r3, 0 |
0x00058f88 beq 0x58f20 |
| }
0x00058f8c mov r2, r4 | r2 = r4;
0x00058f90 mov r3, r5 | r3 = r5;
0x00058f94 ldr r1, [pc, 0x490] | r1 = *(0x59428);
0x00058f98 add r0, sp, 0xc | r0 += s;
0x00058f9c bl 0x14f48 | sprintf (r0, r1, r2)
0x00058fa0 ldr r3, [sl, 8] | r3 = *((sl + 8));
0x00058fa4 add r1, sp, 0xc | r1 += s;
0x00058fa8 ldr r0, [r7, 0x14] | r0 = *((r7 + 0x14));
0x00058fac blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x00058fb0 cmp r6, 0x13 |
| if (r6 != 0x13) {
0x00058fb4 bne 0x593b4 | goto label_12;
| }
0x00058fb8 subs r4, r4, 1 | r4--;
0x00058fbc sbc r5, r5, 0 | __asm ("sbc r5, r5, 0");
| label_8:
0x00058fc0 mov r3, 0 | r3 = 0;
0x00058fc4 strd r4, r5, [r7] | __asm ("strd r4, r5, [r7]");
0x00058fc8 str r3, [r7, 0x14] | *((r7 + 0x14)) = r3;
0x00058fcc b 0x5905c | goto label_2;
| label_11:
0x00058fd0 cmp r6, 0x30 |
| if (r6 == 0x30) {
0x00058fd4 bne 0x58ff0 |
0x00058fd8 orrs r3, r4, r5 | r3 = r4 | r5;
| if (r3 != r4) {
0x00058fdc moveq r4, 1 | r4 = 1;
| }
| if (r3 == r4) {
0x00058fe0 movne r4, 0 | r4 = 0;
| }
| label_4:
0x00058fe4 and r4, r4, 0xff | r4 &= 0xff;
0x00058fe8 mov r5, 0 | r5 = 0;
0x00058fec b 0x58f64 | goto label_0;
| }
0x00058ff0 cmp r6, 0x10 |
| if (r6 != 0x10) {
0x00058ff4 mvneq r4, r4 | r4 = ~r4;
| }
| if (r6 == 0x10) {
0x00058ff8 mvneq r5, r5 | r5 = ~r5;
| goto label_13;
| }
| if (r6 == 0x10) {
| label_13:
0x00058ffc beq 0x58f64 | goto label_0;
| }
0x00059000 sub r2, r6, 0x12 | r2 = r6 - 0x12;
0x00059004 cmp r2, 1 |
| if (r2 <= 1) {
0x00059008 bhi 0x59018 |
0x0005900c adds r4, r4, 1 | r4++;
0x00059010 adc r5, r5, 0 | __asm ("adc r5, r5, 0");
0x00059014 b 0x58f64 | goto label_0;
| }
0x00059018 sub r2, r6, 0x32 | r2 = r6 - 0x32;
0x0005901c cmp r2, 1 |
| if (r2 <= 1) {
0x00059020 bhi 0x59030 |
0x00059024 subs r4, r4, 1 | r4--;
0x00059028 sbc r5, r5, 0 | __asm ("sbc r5, r5, 0");
0x0005902c b 0x58f64 | goto label_0;
| }
0x00059030 cmp r6, 0x31 |
| if (r6 == 0x31) {
0x00059034 beq 0x58f64 | goto label_0;
| }
0x00059038 cmp sb, r7 |
| if (sb == r7) {
0x0005903c beq 0x58f20 | goto label_1;
| }
0x00059040 cmp r6, 4 |
0x00059044 str r7, [r3] | *(r3) = r7;
0x00059048 ldrb r3, [fp, -8] | r3 = var_8h;
| if (r6 != 4) {
0x0005904c bne 0x59068 | goto label_14;
| }
0x00059050 cmp r3, 0 |
| if (r3 != 0) {
0x00059054 bne 0x593c8 | goto label_15;
| }
| do {
| label_3:
0x00059058 ldr r8, [pc, 0x3d0] | r8 = "%lld";
| label_2:
0x0005905c mov r0, r8 | r0 = r8;
0x00059060 add sp, sp, 0x2c |
0x00059064 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_14:
0x00059068 cmp r3, 0 |
0x0005906c bne 0x59058 |
| } while (r3 != 0);
0x00059070 cmp r6, 2 |
0x00059074 sub r7, fp, 0x30 | r7 = fp - 0x30;
| if (r6 == 2) {
0x00059078 beq 0x59094 | goto label_16;
| }
| label_9:
0x0005907c mov r1, r7 | r1 = r7;
0x00059080 mov r0, sl | r0 = sl;
0x00059084 bl 0x597b0 | r0 = fcn_000597b0 (r0, r1);
0x00059088 cmp r0, 0 |
| if (r0 != 0) {
0x0005908c movne r8, r0 | r8 = r0;
| goto label_17;
| }
| if (r0 != 0) {
| label_17:
0x00059090 bne 0x5905c | goto label_2;
| }
| label_16:
0x00059094 ldrd r2, r3, [fp, -0x30] | __asm ("ldrd r2, r3, [var_30h]");
0x00059098 cmp r6, 4 |
0x0005909c strd r2, r3, [sp] | __asm ("strd r2, r3, [sp]");
| if (r6 == 4) {
0x000590a0 bne 0x590b0 |
0x000590a4 orrs r3, r2, r3 | r3 = r2 | r3;
0x000590a8 ldrdeq r4, r5, [fp, -0x10] | __asm ("ldrdeq r4, r5, [var_10h]");
0x000590ac b 0x58f64 | goto label_0;
| }
0x000590b0 cmp r6, 0x24 |
| if (r6 != 0x24) {
0x000590b4 bne 0x590d0 | goto label_18;
| }
0x000590b8 cmp sb, r7 |
| if (sb == r7) {
0x000590bc beq 0x59058 | goto label_3;
| }
0x000590c0 strb r6, [fp, -0x20] | var_20h = r6;
0x000590c4 strd r4, r5, [fp, -0x28] | __asm ("strd r4, r5, [fp, -0x28]");
| label_7:
0x000590c8 ldrd r4, r5, [sp] | __asm ("ldrd r4, r5, [sp]");
0x000590cc b 0x58f64 | goto label_0;
| label_18:
0x000590d0 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x000590d4 cmp r6, 0x42 |
0x000590d8 cmpne r6, 7 | __asm ("cmpne r6, 7");
0x000590dc orr r2, r2, r4 | r2 |= r4;
0x000590e0 orr r3, r3, r5 | r3 |= r5;
| if (r6 == 0x42) {
0x000590e4 beq 0x5913c | goto label_6;
| }
0x000590e8 cmp r6, 5 |
| if (r6 != 5) {
0x000590ec bne 0x5910c | goto label_19;
| }
0x000590f0 ldrd r0, r1, [sp] | __asm ("ldrd r0, r1, [sp]");
0x000590f4 orr r0, r0, r4 | r0 |= r4;
0x000590f8 orr r1, r1, r5 | r1 |= r5;
0x000590fc orrs r3, r0, r1 | r3 = r0 | r1;
0x00059100 movne r4, 1 | r4 = 1;
| while (1) {
| if (r3 != r0) {
0x00059104 moveq r4, 0 | r4 = 0;
| }
0x00059108 b 0x58fe4 | goto label_4;
| label_19:
0x0005910c ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x00059110 cmp r6, 0x22 |
0x00059114 cmpne r6, 9 | __asm ("cmpne r6, 9");
0x00059118 and r2, r2, r4 | r2 &= r4;
0x0005911c and r3, r3, r5 | r3 &= r5;
| if (r6 != 0x22) {
0x00059120 beq 0x5913c |
0x00059124 cmp r6, 0x62 |
0x00059128 cmpne r6, 8 | __asm ("cmpne r6, 8");
| if (r6 != 0x62) {
0x0005912c bne 0x59148 | goto label_20;
| }
0x00059130 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x00059134 eor r2, r2, r4 | r2 ^= r4;
0x00059138 eor r3, r3, r5 | r3 ^= r5;
| }
| label_6:
0x0005913c mov r4, r2 | r4 = r2;
0x00059140 mov r5, r3 | r5 = r3;
0x00059144 b 0x58f64 | goto label_0;
| label_20:
0x00059148 cmp r6, 6 |
| if (r6 != 6) {
0x0005914c bne 0x59170 | goto label_21;
| }
0x00059150 ldr r3, [sp] | r3 = *(sp);
0x00059154 ldr r2, [sp, 4] | r2 = var_4h;
0x00059158 orrs r3, r3, r2 | r3 |= r2;
| if (r3 == r3) {
0x0005915c movne r0, 1 | r0 = 1;
| }
| if (r3 != r3) {
0x00059160 moveq r0, 0 | r0 = 0;
| }
0x00059164 orrs r3, r4, r5 | r3 = r4 | r5;
| if (r3 == r4) {
0x00059168 movne r4, r0 | r4 = r0;
| }
0x0005916c b 0x59104 |
| }
| label_21:
0x00059170 cmp r6, 0xa |
| if (r6 == 0xa) {
0x00059174 bne 0x59190 |
0x00059178 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x0005917c cmp r5, r3 |
0x00059180 cmpeq r4, r2 | __asm ("cmpeq r4, r2");
| if (r5 != r3) {
0x00059184 moveq r4, 1 | r4 = 1;
| }
| if (r5 == r3) {
0x00059188 movne r4, 0 | r4 = 0;
| }
0x0005918c b 0x58fe4 | goto label_4;
| }
0x00059190 cmp r6, 0x2a |
| if (r6 == 0x2a) {
0x00059194 bne 0x591b0 |
0x00059198 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x0005919c cmp r5, r3 |
0x000591a0 cmpeq r4, r2 | __asm ("cmpeq r4, r2");
| if (r5 == r3) {
0x000591a4 movne r4, 1 | r4 = 1;
| }
| if (r5 != r3) {
0x000591a8 moveq r4, 0 | r4 = 0;
| }
0x000591ac b 0x58fe4 | goto label_4;
| }
0x000591b0 cmp r6, 0x4b |
| if (r6 == 0x4b) {
0x000591b4 bne 0x591d0 |
0x000591b8 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x000591bc cmp r2, r4 |
0x000591c0 sbcs r3, r3, r5 | __asm ("sbcs r3, r3, r5");
| if (r2 < r4) {
| label_5:
0x000591c4 movge r4, 1 | r4 = 1;
| }
| if (r2 >= r4) {
0x000591c8 movlt r4, 0 | r4 = 0;
| }
0x000591cc b 0x58fe4 | goto label_4;
| }
0x000591d0 cmp r6, 0xe2 |
0x000591d4 cmpne r6, 0x2c | __asm ("cmpne r6, 0x2c");
| if (r6 == 0xe2) {
0x000591d8 bne 0x59208 |
0x000591dc ldr r1, [sp] | r1 = *(sp);
0x000591e0 subs r2, r4, 0x20 | r2 = r4 - 0x20;
0x000591e4 mov r3, r4 | r3 = r4;
0x000591e8 rsb ip, r4, 0x20 |
0x000591ec lsr r4, r1, r4 | r4 = r1 >> r4;
0x000591f0 ldr r1, [sp, 4] | r1 = var_4h;
0x000591f4 orr r4, r4, r1, lsl ip | r4 |= (r1 << ip);
| if (r2 < r4) {
0x000591f8 orrpl r4, r4, r1, asr r2 | r4 |= (r1 >> r2);
| }
0x000591fc ldr r2, [sp, 4] | r2 = var_4h;
0x00059200 asr r5, r2, r3 | r5 = r2 >> r3;
0x00059204 b 0x58f64 | goto label_0;
| }
0x00059208 cmp r6, 0xc2 |
0x0005920c cmpne r6, 0xc | __asm ("cmpne r6, 0xc");
| if (r6 == 0xc2) {
0x00059210 bne 0x59238 |
0x00059214 ldr r1, [sp, 4] | r1 = var_4h;
0x00059218 sub ip, r4, 0x20 |
0x0005921c lsl r5, r1, r4 | r5 = r1 << r4;
0x00059220 ldr r1, [sp] | r1 = *(sp);
0x00059224 rsb r2, r4, 0x20 | r2 = 0x20 - r4;
0x00059228 orr r5, r5, r1, lsl ip | r5 |= (r1 << ip);
0x0005922c lsl r4, r1, r4 | r4 = r1 << r4;
0x00059230 orr r5, r5, r1, lsr r2 | r5 |= (r1 >> r2);
0x00059234 b 0x58f64 | goto label_0;
| }
0x00059238 cmp r6, 0x2b |
| if (r6 != 0x2b) {
0x0005923c bne 0x59258 | goto label_22;
| }
0x00059240 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x00059244 cmp r4, r2 |
0x00059248 sbcs r3, r5, r3 | __asm ("sbcs r3, r5, r3");
| if (r4 >= r2) {
| do {
0x0005924c movlt r4, 1 | r4 = 1;
| }
| if (r4 < r2) {
0x00059250 movge r4, 0 | r4 = 0;
| }
0x00059254 b 0x58fe4 | goto label_4;
| label_22:
0x00059258 cmp r6, 0xb |
| if (r6 != 0xb) {
0x0005925c bne 0x59270 | goto label_23;
| }
0x00059260 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x00059264 cmp r2, r4 |
0x00059268 sbcs r3, r3, r5 | __asm ("sbcs r3, r3, r5");
0x0005926c b 0x5924c |
| } while (1);
| label_23:
0x00059270 cmp r6, 0x6b |
| if (r6 == 0x6b) {
0x00059274 bne 0x59288 |
0x00059278 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x0005927c cmp r4, r2 |
0x00059280 sbcs r3, r5, r3 | __asm ("sbcs r3, r5, r3");
0x00059284 b 0x591c4 | goto label_5;
| }
0x00059288 cmp r6, 3 |
0x0005928c cmpne r6, 0xe | __asm ("cmpne r6, 0xe");
| if (r6 == 3) {
0x00059290 bne 0x592b8 |
0x00059294 ldr r2, [sp, 4] | r2 = var_4h;
0x00059298 ldr r3, [sp] | r3 = *(sp);
0x0005929c mul r2, r4, r2 | r2 = r4 * r2;
0x000592a0 ldr r1, [sp] | r1 = *(sp);
0x000592a4 mla r3, r5, r3, r2 | __asm ("mla r3, r5, r3, r2");
0x000592a8 mov r2, r4 | r2 = r4;
0x000592ac umull r4, r5, r2, r1 | r4:r5 = r2 * r1;
0x000592b0 add r5, r3, r5 | r5 = r3 + r5;
0x000592b4 b 0x58f64 | goto label_0;
| }
0x000592b8 cmp r6, 0x82 |
0x000592bc cmpne r6, 0xd | __asm ("cmpne r6, 0xd");
| if (r6 == 0x82) {
0x000592c0 bne 0x592d4 |
0x000592c4 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x000592c8 adds r2, r2, r4 | r2 += r4;
0x000592cc adc r3, r3, r5 | __asm ("adc r3, r3, r5");
0x000592d0 b 0x5913c | goto label_6;
| }
0x000592d4 cmp r6, 0xa2 |
0x000592d8 cmpne r6, 0x2d | __asm ("cmpne r6, 0x2d");
| if (r6 == 0xa2) {
0x000592dc bne 0x592f0 |
0x000592e0 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x000592e4 subs r2, r2, r4 | r2 -= r4;
0x000592e8 sbc r3, r3, r5 | __asm ("sbc r3, r3, r5");
0x000592ec b 0x5913c | goto label_6;
| }
0x000592f0 sub r3, r6, 1 | r3 = r6 - 1;
0x000592f4 cmp r3, 1 |
| if (r3 < 1) {
0x000592f8 bls 0x58f64 | goto label_0;
| }
0x000592fc cmp r6, 0x2f |
| if (r6 != 0x2f) {
0x00059300 bne 0x59360 | goto label_24;
| }
0x00059304 cmp r4, 0 |
0x00059308 sbcs r3, r5, 0 | __asm ("sbcs r3, r5, 0");
| if (r4 < 0) {
0x0005930c movge r2, 1 | r2 = 1;
| }
| if (r4 < 0) {
0x00059310 movge r3, 0 | r3 = 0;
| }
| if (r4 >= 0) {
0x00059314 bge 0x59340 | goto label_25;
| }
0x00059318 ldr r8, [pc, 0x114] | r8 = "malformed__:_operator";
0x0005931c b 0x5905c | goto label_2;
| do {
0x00059320 ldr r1, [sp, 4] | r1 = var_4h;
0x00059324 ldr ip, [sp] | ip = *(sp);
0x00059328 mul r1, r2, r1 | r1 = r2 * r1;
0x0005932c ldr r0, [sp] | r0 = *(sp);
0x00059330 mla ip, r3, ip, r1 | __asm ("mla ip, r3, ip, r1");
0x00059334 mov r1, r2 | r1 = r2;
0x00059338 umull r2, r3, r1, r0 | r2:r3 = r1 * r0;
0x0005933c add r3, ip, r3 | r3 = ip + r3;
| label_25:
0x00059340 subs r4, r4, 1 | r4--;
0x00059344 sbc r5, r5, 0 | __asm ("sbc r5, r5, 0");
0x00059348 mvn r1, 0 | r1 = ~0;
0x0005934c mvn r0, 0 | r0 = ~0;
0x00059350 cmp r5, r1 |
0x00059354 cmpeq r4, r0 | __asm ("cmpeq r4, r0");
0x00059358 bne 0x59320 |
| } while (r5 != r1);
0x0005935c b 0x5913c | goto label_6;
| label_24:
0x00059360 orrs r3, r4, r5 | r3 = r4 | r5;
| if (r3 == r4) {
0x00059364 ldreq r8, [pc, 0xcc] | r8 = "divide_by_zero";
| goto label_26;
| }
| if (r3 == r4) {
| label_26:
0x00059368 beq 0x5905c | goto label_2;
| }
0x0005936c cmp r6, 0x23 |
0x00059370 cmpne r6, 0x2e | __asm ("cmpne r6, 0x2e");
| if (r6 != 0x23) {
0x00059374 moveq ip, 1 |
| }
| if (r6 == 0x23) {
0x00059378 movne ip, 0 |
| }
| if (r6 == 0x23) {
0x0005937c beq 0x593d0 | goto label_27;
| }
0x00059380 cmp r6, 0x43 |
0x00059384 cmpne r6, 0x4e | __asm ("cmpne r6, 0x4e");
| if (r6 != 0x43) {
0x00059388 bne 0x590c8 | goto label_7;
| }
0x0005938c mvn r3, 0 | r3 = ~0;
0x00059390 mvn r2, 0 | r2 = ~0;
0x00059394 cmp r5, r3 |
0x00059398 cmpeq r4, r2 | __asm ("cmpeq r4, r2");
| if (r5 == r3) {
0x0005939c beq 0x593e4 | goto label_28;
| }
| label_10:
0x000593a0 mov r2, r4 | r2 = r4;
0x000593a4 mov r3, r5 | r3 = r5;
0x000593a8 ldrd r0, r1, [sp] | __asm ("ldrd r0, r1, [sp]");
0x000593ac bl 0xa76ec | fcn_000a76ec (r0, r1);
0x000593b0 b 0x5913c | goto label_6;
| label_12:
0x000593b4 cmp r6, 0x33 |
| if (r6 != 0x33) {
0x000593b8 bne 0x58fc0 | goto label_8;
| }
0x000593bc adds r4, r4, 1 | r4++;
0x000593c0 adc r5, r5, 0 | __asm ("adc r5, r5, 0");
0x000593c4 b 0x58fc0 | goto label_8;
| label_15:
0x000593c8 sub r7, fp, 0x30 | r7 = fp - 0x30;
0x000593cc b 0x5907c | goto label_9;
| label_27:
0x000593d0 mvn r3, 0 | r3 = ~0;
0x000593d4 mvn r2, 0 | r2 = ~0;
0x000593d8 cmp r5, r3 |
0x000593dc cmpeq r4, r2 | __asm ("cmpeq r4, r2");
| if (r5 != r3) {
0x000593e0 bne 0x5940c | goto label_29;
| }
| label_28:
0x000593e4 ldrd r2, r3, [sp] | __asm ("ldrd r2, r3, [sp]");
0x000593e8 adds r2, r2, r2 | r2 += r2;
0x000593ec adc r3, r3, r3 | __asm ("adc r3, r3, r3");
0x000593f0 orrs r3, r2, r3 | r3 = r2 | r3;
| if (r3 != r2) {
0x000593f4 moveq r4, 1 | r4 = 1;
| }
| if (r3 != r2) {
0x000593f8 moveq r5, 0 | r5 = 0;
| }
| if (r3 == r2) {
0x000593fc mvnne r4, 0 | r4 = ~0;
| }
| if (r3 == r2) {
0x00059400 mvnne r5, 0 | r5 = ~0;
| }
0x00059404 cmp ip, 0 |
| if (ip == 0) {
0x00059408 beq 0x593a0 | goto label_10;
| }
| label_29:
0x0005940c mov r2, r4 | r2 = r4;
0x00059410 mov r3, r5 | r3 = r5;
0x00059414 ldrd r0, r1, [sp] | __asm ("ldrd r0, r1, [sp]");
0x00059418 bl 0xa76ec | r0 = fcn_000a76ec (r0, r1);
0x0005941c mov r4, r0 | r4 = r0;
0x00059420 mov r5, r1 | r5 = r1;
0x00059424 b 0x58f64 | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x5a538 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.0005a538 () | void fcn_0005a538 (int32_t arg1, int32_t arg2) {
| int32_t var_98h;
| time_t * timer;
| char * s;
| int32_t var_7ch;
| int32_t var_5ch;
| char * oldpath;
| int32_t var_4h;
| int32_t var_8h;
| r0 = arg1;
| r1 = arg2;
0x0005a538 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0005a53c ldr sb, [pc, 0x344] | sb = *(0x0005a888);
0x0005a540 add fp, sp, 0x20 |
0x0005a544 cmp r2, 0xf |
0x0005a548 sub sp, sp, 0x84 |
0x0005a54c mov r7, r0 | r7 = r0;
0x0005a550 mov r5, r1 | r5 = r1;
| if (r2 > 0xf) {
0x0005a554 ble 0x5a5ac |
0x0005a558 ldrb r3, [r1, 3] | r3 = *((r1 + 3));
0x0005a55c cmp r3, 0x20 |
| if (r3 != 0x20) {
0x0005a560 bne 0x5a5ac | goto label_5;
| }
0x0005a564 ldrb r3, [r1, 6] | r3 = *((r1 + 6));
0x0005a568 cmp r3, 0x20 |
| if (r3 != 0x20) {
0x0005a56c bne 0x5a5ac | goto label_5;
| }
0x0005a570 ldrb r3, [r1, 9] | r3 = *((r1 + 9));
0x0005a574 cmp r3, 0x3a |
| if (r3 != 0x3a) {
0x0005a578 bne 0x5a5ac | goto label_5;
| }
0x0005a57c ldrb r3, [r1, 0xc] | r3 = *((r1 + 0xc));
0x0005a580 cmp r3, 0x3a |
| if (r3 != 0x3a) {
0x0005a584 bne 0x5a5ac | goto label_5;
| }
0x0005a588 ldrb r3, [r1, 0xf] | r3 = *((r1 + 0xf));
0x0005a58c cmp r3, 0x20 |
| if (r3 != 0x20) {
0x0005a590 bne 0x5a5ac | goto label_5;
| }
0x0005a594 ldr r3, [sb] | r3 = *(sb);
0x0005a598 add r8, r1, 0x10 | r8 = r1 + 0x10;
0x0005a59c ands r3, r3, 0x20 | r3 &= 0x20;
| if (r3 != r3) {
0x0005a5a0 streq r3, [fp, -0x90] | timer = r3;
| }
| if (r3 == r3) {
0x0005a5a4 beq 0x5a5c4 | goto label_6;
| }
0x0005a5a8 mov r5, r8 | r5 = r8;
| }
| label_5:
0x0005a5ac sub r0, fp, 0x90 | r0 = fp - 0x90;
0x0005a5b0 bl 0x14e40 | time (r0);
0x0005a5b4 sub r0, fp, 0x90 | r0 = fp - 0x90;
0x0005a5b8 bl 0x149e4 | ctime (r0);
0x0005a5bc mov r8, r5 | r8 = r5;
0x0005a5c0 add r5, r0, 4 | r5 += timer;
| label_6:
0x0005a5c4 mov r3, 0 | r3 = 0;
0x0005a5c8 strb r3, [r5, 0xf] | *((r5 + 0xf)) = r3;
0x0005a5cc ldr r3, [pc, 0x2b8] | r3 = *(0x5a888);
0x0005a5d0 ldr r4, [r3] | r4 = *(0x5a888);
0x0005a5d4 ldr r3, [sb] | r3 = *(sb);
0x0005a5d8 add r6, r4, 0x328 | r6 = r4 + 0x328;
0x0005a5dc tst r3, 0x10 |
| if ((r3 & 0x10) == 0) {
0x0005a5e0 beq 0x5a6e8 | goto label_7;
| }
0x0005a5e4 mov r3, r8 | r3 = r8;
0x0005a5e8 mov r2, r5 | r2 = r5;
0x0005a5ec ldr r1, [pc, 0x29c] | r1 = *(0x5a88c);
0x0005a5f0 mov r0, r6 | r0 = r6;
0x0005a5f4 bl 0x14f48 | sprintf (r0, r1, r2)
| label_0:
0x0005a5f8 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x0005a5fc and r7, r7, 7 | r7 &= 7;
0x0005a600 cmp r7, r3 |
| if (r7 >= r3) {
0x0005a604 bge 0x5a7ec | goto label_3;
| }
0x0005a608 mov r0, r6 | r0 = r6;
0x0005a60c bl 0x1514c | strlen (r0);
0x0005a610 ldr r3, [r4, 4] | r3 = *((r4 + 4));
0x0005a614 ldr r5, [fp, -0x90] | r5 = timer;
0x0005a618 cmp r3, 1 |
0x0005a61c mov r8, r0 | r8 = r0;
| if (r3 <= 1) {
0x0005a620 ble 0x5a770 | goto label_8;
| }
0x0005a624 cmp r5, 0 |
| if (r5 == 0) {
0x0005a628 bne 0x5a638 |
0x0005a62c mov r0, r5 | r0 = r5;
0x0005a630 bl 0x14e40 | r0 = time (r0);
0x0005a634 mov r5, r0 | r5 = r0;
| }
0x0005a638 ldr r3, [r4, 8] | r3 = *((r4 + 8));
0x0005a63c cmp r3, r5 |
| if (r3 == r5) {
0x0005a640 strne r5, [r4, 8] | *((r4 + 8)) = r5;
| }
| if (r3 != r5) {
0x0005a644 bne 0x5a840 | goto label_9;
| }
| label_2:
0x0005a648 ldr r3, [r4, 0x18] | r3 = *((r4 + 0x18));
0x0005a64c cmp r3, 0 |
| if (r3 == 0) {
0x0005a650 beq 0x5a84c | goto label_10;
| }
0x0005a654 ldrb r2, [r4, 0x10] | r2 = *((r4 + 0x10));
0x0005a658 cmp r2, 0 |
| if (r2 == 0) {
0x0005a65c beq 0x5a84c | goto label_10;
| }
0x0005a660 ldr r2, [r4, 0xc] | r2 = *((r4 + 0xc));
0x0005a664 cmp r3, r2 |
| if (r3 >= r2) {
0x0005a668 bhs 0x5a84c | goto label_10;
| }
0x0005a66c ldr r5, [r4, 0x1c] | r5 = *((r4 + 0x1c));
0x0005a670 ldr r0, [r4] | r0 = *(r4);
0x0005a674 cmp r5, 0 |
| if (r5 == 0) {
0x0005a678 beq 0x5a838 | goto label_11;
| }
0x0005a67c str sp, [fp, -0x98] | var_98h = sp;
0x0005a680 bl 0x1514c | strlen (r0);
0x0005a684 ldr sl, [pc, 0x208] | sl = "_s._d";
0x0005a688 sub r5, r5, 1 | r5--;
0x0005a68c add r0, r0, 0xb | r0 += 0xb;
0x0005a690 bic r0, r0, 7 | r0 = BIT_MASK (r0, 7);
0x0005a694 sub sp, sp, r0 |
0x0005a698 add sb, sp, 8 | sb += var_8h;
0x0005a69c sub sp, sp, r0 |
0x0005a6a0 add r7, sp, 8 | r7 += var_8h;
| do {
0x0005a6a4 mov r3, r5 | r3 = r5;
0x0005a6a8 ldr r2, [r4] | r2 = *(r4);
0x0005a6ac mov r1, sl | r1 = sl;
0x0005a6b0 mov r0, r7 | r0 = r7;
0x0005a6b4 bl 0x14f48 | sprintf (r0, r1, r2)
0x0005a6b8 cmp r5, 0 |
| if (r5 == 0) {
0x0005a6bc beq 0x5a828 | goto label_12;
| }
0x0005a6c0 sub r5, r5, 1 | r5--;
0x0005a6c4 mov r1, sl | r1 = sl;
0x0005a6c8 mov r3, r5 | r3 = r5;
0x0005a6cc ldr r2, [r4] | r2 = *(r4);
0x0005a6d0 mov r0, sb | r0 = sb;
0x0005a6d4 bl 0x14f48 | sprintf (r0, r1, r2)
0x0005a6d8 mov r1, r7 | r1 = r7;
0x0005a6dc mov r0, sb | r0 = sb;
0x0005a6e0 bl 0x14960 | rename (r0, r1);
0x0005a6e4 b 0x5a6a4 |
| } while (1);
| label_7:
0x0005a6e8 ldr r2, [pc, 0x1a8] | r2 = "_s._d";
0x0005a6ec and r1, r7, 0x3f8 | r1 = r7 & 0x3f8;
| do {
0x0005a6f0 ldr r3, [r2, -8] | r3 = *((r2 - 8));
0x0005a6f4 cmp r3, 0 |
| if (r3 == 0) {
0x0005a6f8 bne 0x5a734 |
| label_1:
0x0005a6fc mov r3, r7 | r3 = r7;
0x0005a700 ldr r2, [pc, 0x194] | r2 = "authpriv";
0x0005a704 mov r1, 0x14 | r1 = 0x14;
0x0005a708 sub r0, fp, 0x8c | r0 -= timer;
0x0005a70c bl 0x14450 | snprintf (r0, r1, "authpriv", r3);
| label_4:
0x0005a710 sub r3, fp, 0x8c | r3 -= timer;
0x0005a714 str r8, [sp, 4] | var_4h = r8;
0x0005a718 str r3, [sp] | *(sp) = r3;
0x0005a71c mov r2, r5 | r2 = r5;
0x0005a720 ldr r3, [r4, 0x24] | r3 = *((r4 + 0x24));
0x0005a724 ldr r1, [pc, 0x174] | r1 = "__d_";
0x0005a728 mov r0, r6 | r0 = r6;
0x0005a72c bl 0x14f48 | sprintf (r0, "__d_", r2)
0x0005a730 b 0x5a5f8 | goto label_0;
| }
0x0005a734 add r2, r2, 8 | r2 += 8;
0x0005a738 ldr r0, [r2, -0xc] | r0 = *((r2 - 0xc));
0x0005a73c cmp r1, r0 |
0x0005a740 bne 0x5a6f0 |
| } while (r1 != r0);
0x0005a744 and r0, r7, 7 | r0 = r7 & 7;
0x0005a748 ldr r2, [pc, 0x154] | r2 = "%s %.64s %s %s\n";
0x0005a74c b 0x5a760 |
| while (r1 != 0) {
0x0005a750 add r2, r2, 8 | r2 += 8;
0x0005a754 ldr ip, [r2, -0xc] | ip = *((r2 - 0xc));
0x0005a758 cmp r0, ip |
| if (r0 == ip) {
0x0005a75c beq 0x5a870 | goto label_13;
| }
0x0005a760 ldr r1, [r2, -8] | r1 = *((r2 - 8));
0x0005a764 cmp r1, 0 |
0x0005a768 bne 0x5a750 |
| }
0x0005a76c b 0x5a6fc | goto label_1;
| if (r1 == 0) {
| label_8:
0x0005a770 beq 0x5a648 | goto label_2;
| }
0x0005a774 ldr r3, [r4] | r3 = *(r4);
0x0005a778 ldrb r2, [r3] | r2 = *(r3);
0x0005a77c cmp r2, 0x2d |
| if (r2 != 0x2d) {
0x0005a780 bne 0x5a798 | goto label_14;
| }
0x0005a784 ldrb r3, [r3, 1] | r3 = *((r3 + 1));
0x0005a788 cmp r3, 0 |
| if (r3 != 0) {
0x0005a78c moveq r3, 1 | r3 = 1;
| }
| if (r3 == 0) {
0x0005a790 streq r3, [r4, 4] | *((r4 + 4)) = r3;
| goto label_15;
| }
| if (r3 == 0) {
| label_15:
0x0005a794 beq 0x5a648 | goto label_2;
| }
| do {
| label_14:
0x0005a798 ldr r2, [pc, 0x108] | r2 = "crit";
0x0005a79c ldr r1, [pc, 0x108] | r1 = *(0x5a8a8);
0x0005a7a0 ldr r0, [r4] | r0 = *(r4);
0x0005a7a4 bl 0x14df8 | r0 = open64 ();
0x0005a7a8 cmp r0, 0 |
0x0005a7ac str r0, [r4, 4] | *((r4 + 4)) = r0;
| if (r0 < 0) {
0x0005a7b0 bge 0x5a7f4 |
0x0005a7b4 ldr r1, [pc, 0xf4] | r1 = *(0x5a8ac);
0x0005a7b8 ldr r0, [pc, 0xf4] | r0 = *(0x5a8b0);
0x0005a7bc bl 0x9958c | fcn_0009958c (r0, r1);
0x0005a7c0 mov r2, r8 | r2 = r8;
0x0005a7c4 mov r1, r6 | r1 = r6;
0x0005a7c8 cmp r0, 0 |
| if (r0 < 0) {
0x0005a7cc movge r4, r0 | r4 = r0;
| }
| if (r0 >= 0) {
0x0005a7d0 movlt r4, 2 | r4 = 2;
| }
0x0005a7d4 mov r0, r4 | r0 = r4;
0x0005a7d8 bl 0x19630 | fcn_00019630 (r0, r1);
0x0005a7dc cmp r4, 2 |
| if (r4 != 2) {
0x0005a7e0 beq 0x5a7ec |
0x0005a7e4 mov r0, r4 | r0 = r4;
0x0005a7e8 bl 0x15260 | close (r0);
| }
| label_3:
0x0005a7ec sub sp, fp, 0x20 |
0x0005a7f0 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x0005a7f4 sub r1, fp, 0x8c | r1 -= timer;
0x0005a7f8 bl 0x148ac | r0 = fstat64 ();
0x0005a7fc cmp r0, 0 |
| if (r0 != 0) {
0x0005a800 ldreq r3, [fp, -0x7c] | r3 = var_7ch;
| }
| if (r0 == 0) {
0x0005a804 movne r3, 0 | r3 = 0;
| }
| if (r0 != 0) {
0x0005a808 andeq r3, r3, 0xf000 | r3 &= 0xf000;
| }
| if (r0 != 0) {
0x0005a80c subeq r3, r3, 0x8000 | r3 -= 0x8000;
| }
0x0005a810 clzeq r3, r3 | __asm ("clzeq r3, r3");
| if (r0 != 0) {
0x0005a814 lsreq r3, r3, 5 | r3 >>= 5;
| }
0x0005a818 strb r3, [r4, 0x10] | *((r4 + 0x10)) = r3;
0x0005a81c ldr r3, [fp, -0x5c] | r3 = var_5ch;
0x0005a820 str r3, [r4, 0xc] | *((r4 + 0xc)) = r3;
0x0005a824 b 0x5a648 | goto label_2;
| label_12:
0x0005a828 mov r1, r7 | r1 = r7;
0x0005a82c ldr r0, [r4] | r0 = *(r4);
0x0005a830 bl 0x14960 | rename (r0, r1);
0x0005a834 ldr sp, [fp, -0x98] | sp = var_98h;
| label_11:
0x0005a838 ldr r0, [r4] | r0 = *(r4);
0x0005a83c bl 0x14bdc | unlink (r0);
| label_9:
0x0005a840 ldr r0, [r4, 4] | r0 = *((r4 + 4));
0x0005a844 bl 0x15260 | close (r0);
0x0005a848 b 0x5a798 |
| } while (1);
| label_10:
0x0005a84c mov r2, r8 | r2 = r8;
0x0005a850 mov r1, r6 | r1 = r6;
0x0005a854 ldr r0, [r4, 4] | r0 = *((r4 + 4));
0x0005a858 bl 0x19630 | r0 = fcn_00019630 (r0, r1);
0x0005a85c cmp r0, 0 |
| if (r0 <= 0) {
0x0005a860 ldrgt r3, [r4, 0xc] | r3 = *((r4 + 0xc));
| }
| if (r0 <= 0) {
0x0005a864 addgt r0, r3, r0 | r0 = r3 + r0;
| }
| if (r0 <= 0) {
0x0005a868 strgt r0, [r4, 0xc] | *((r4 + 0xc)) = r0;
| }
0x0005a86c b 0x5a7ec | goto label_3;
| label_13:
0x0005a870 str r1, [sp] | *(sp) = r1;
0x0005a874 ldr r2, [pc, 0x3c] | r2 = "/dev/console";
0x0005a878 mov r1, 0x14 | r1 = 0x14;
0x0005a87c sub r0, fp, 0x8c | r0 -= timer;
0x0005a880 bl 0x14450 | snprintf (r0, r1, "/dev/console", r3);
0x0005a884 b 0x5a710 | goto label_4;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x5c6ec */
| #include <stdint.h>
|
; (fcn) fcn.0005c6ec () | void fcn_0005c6ec (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_ch;
| r0 = arg1;
| r1 = arg2;
0x0005c6ec push {r0, r1, r2, r4, r5, r6, r7, lr} |
0x0005c6f0 mov r6, r0 | r6 = r0;
0x0005c6f4 mov r0, 0x24 | r0 = 0x24;
0x0005c6f8 mov r7, r1 | r7 = r1;
0x0005c6fc mov r4, r2 | r4 = r2;
0x0005c700 bl 0x189b8 | r0 = fcn_000189b8 (r0);
0x0005c704 bl 0x98560 | fcn_00098560 (r0);
0x0005c708 lsl r2, r4, 2 | r2 = r4 << 2;
0x0005c70c and r2, r2, 0x300 | r2 &= 0x300;
0x0005c710 and r4, r4, 0x3f | r4 &= 0x3f;
0x0005c714 str r4, [sp] | *(sp) = r4;
0x0005c718 mov r3, r7 | r3 = r7;
0x0005c71c orr r2, r2, r6 | r2 |= r6;
0x0005c720 ldr r1, [pc, 0x10] | r1 = *(0x5c734);
0x0005c724 mov r5, r0 | r5 = r0;
0x0005c728 bl 0x14f48 | sprintf (r0, r1, r2)
0x0005c72c mov r0, r5 | r0 = r5;
0x0005c730 add sp, sp, 0xc |
0x0005c734 pop {r4, r5, r6, r7, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x5d400 */
| #include <stdint.h>
|
; (fcn) fcn.0005d400 () | void fcn_0005d400 (int32_t arg_2h, int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_30h;
| int32_t var_3ch;
| int32_t var_40h;
| int32_t var_44h;
| int32_t var_48h;
| int32_t var_4ch;
| char * s;
| int32_t var_51h;
| int32_t var_58h;
| int32_t var_80h;
| int32_t var_84h;
| r0 = arg1;
0x0005d400 ldr r3, [pc, 0x490] | r3 = *(0x5d894);
0x0005d404 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0005d408 ldr r6, [r3] | r6 = *(0x5d894);
0x0005d40c sub sp, sp, 0x84 |
0x0005d410 ldr r2, [r6, 0x28] | r2 = "Number Start (sector) End (sector) Size Name";
0x0005d414 str r3, [sp, 0x44] | var_44h = r3;
0x0005d418 cmp r2, 5 |
| if (r2 != 5) {
0x0005d41c bne 0x5d62c | goto label_3;
| }
0x0005d420 ldr ip, [r6, 0x10] | ip = *((r6 + 0x10));
0x0005d424 ldr r1, [r6, 0x60] | r1 = *((r6 + 0x60));
0x0005d428 mov r4, 0 | r4 = 0;
0x0005d42c add r7, sp, 0x50 | r7 += s;
0x0005d430 mul r0, r1, ip | r0 = r1 * ip;
0x0005d434 ldr r3, [pc, 0x460] | r3 = *(0x5d898);
0x0005d438 mov r2, r7 | r2 = r7;
0x0005d43c mov r1, r4 | r1 = r4;
0x0005d440 bl 0x171d0 | fcn_000171d0 (r0, r1);
0x0005d444 ldr r5, [pc, 0x454] | r5 = "KMGTPEZY";
0x0005d448 mov r3, r4 | r3 = r4;
0x0005d44c strb r4, [r0] | *(r0) = r4;
0x0005d450 ldr r0, [pc, 0x44c] | r0 = *(0x5d8a0);
0x0005d454 ldr r2, [r6, 0x60] | r2 = *((r6 + 0x60));
0x0005d458 str r7, [sp] | *(sp) = r7;
0x0005d45c ldr r1, [r6, 4] | r1 = *((r6 + 4));
0x0005d460 bl 0x1436c | printf (r0, r1, r2, r3, r4, "KMGTPEZY");
0x0005d464 ldr r1, [r6, 0x10] | r1 = *((r6 + 0x10));
0x0005d468 ldr r0, [pc, 0x438] | r0 = "Disk__s:__llu_sectors___s";
0x0005d46c bl 0x1436c | printf ("Disk__s:__llu_sectors___s", r1);
0x0005d470 ldr r0, [pc, 0x434] | r0 = "Logical sector size: %u\n";
0x0005d474 bl 0x1436c | printf ("Logical sector size: %u\n");
0x0005d478 ldr r0, [r5] | r0 = "KMGTPEZY";
0x0005d47c ldrb ip, [r0, 0x47] | ip = *((r0 + 0x47));
0x0005d480 ldrb r2, [r0, 0x3a] | r2 = *((r0 + 0x3a));
0x0005d484 ldrb r3, [r0, 0x39] | r3 = *((r0 + 0x39));
0x0005d488 ldrb r1, [r0, 0x3b] | r1 = *((r0 + 0x3b));
0x0005d48c str ip, [sp, 0x30] | var_30h = ip;
0x0005d490 ldrb ip, [r0, 0x46] | ip = *((r0 + 0x46));
0x0005d494 str ip, [sp, 0x2c] | var_2ch = ip;
0x0005d498 ldrb ip, [r0, 0x45] | ip = *((r0 + 0x45));
0x0005d49c str ip, [sp, 0x28] | var_28h = ip;
0x0005d4a0 ldrb ip, [r0, 0x44] | ip = *((r0 + 0x44));
0x0005d4a4 str ip, [sp, 0x24] | var_24h = ip;
0x0005d4a8 ldrb ip, [r0, 0x43] | ip = *((r0 + 0x43));
0x0005d4ac str ip, [sp, 0x20] | var_20h = ip;
0x0005d4b0 ldrb ip, [r0, 0x42] | ip = *((r0 + 0x42));
0x0005d4b4 str ip, [sp, 0x1c] | var_1ch = ip;
0x0005d4b8 ldrb ip, [r0, 0x41] | ip = *((r0 + 0x41));
0x0005d4bc str ip, [sp, 0x18] | var_18h = ip;
0x0005d4c0 ldrb ip, [r0, 0x40] | ip = *((r0 + 0x40));
0x0005d4c4 str ip, [sp, 0x14] | var_14h = ip;
0x0005d4c8 ldrb ip, [r0, 0x3e] | ip = *((r0 + 0x3e));
0x0005d4cc str ip, [sp, 0x10] | var_10h = ip;
0x0005d4d0 ldrb ip, [r0, 0x3f] | ip = *((r0 + 0x3f));
0x0005d4d4 str ip, [sp, 0xc] | var_ch = ip;
0x0005d4d8 ldrb ip, [r0, 0x3c] | ip = *((r0 + 0x3c));
0x0005d4dc str ip, [sp, 8] | var_8h = ip;
0x0005d4e0 ldrb ip, [r0, 0x3d] | ip = *((r0 + 0x3d));
0x0005d4e4 str ip, [sp, 4] | var_4h = ip;
0x0005d4e8 ldrb r0, [r0, 0x38] | r0 = *((r0 + 0x38));
0x0005d4ec str r0, [sp] | *(sp) = r0;
0x0005d4f0 ldr r0, [pc, 0x3b8] | r0 = "Disk_identifier__GUID_:_";
0x0005d4f4 bl 0x1436c | printf ("KMGTPEZY", r1, r2, r3);
0x0005d4f8 ldr r3, [r5] | r3 = "KMGTPEZY";
0x0005d4fc ldr r0, [pc, 0x3b0] | r0 = "%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x";
0x0005d500 ldr r1, [r3, 0x50] | r1 = "disc";
0x0005d504 bl 0x1436c | printf ("%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", "disc", r2, "KMGTPEZY");
0x0005d508 ldr r3, [r5] | r3 = "KMGTPEZY";
0x0005d50c ldrd r8, sb, [r3, 0x28] | __asm ("ldrd r8, sb, [r3, 0x28]");
0x0005d510 ldrd r0, r1, [r3, 0x30] | __asm ("ldrd r0, r1, [r3, 0x30]");
0x0005d514 mov r2, r8 | r2 = r8;
0x0005d518 strd r0, r1, [sp] | __asm ("strd r0, r1, [sp]");
0x0005d51c ldr r0, [pc, 0x394] | r0 = "Partition_table_holds_up_to__u_entries";
0x0005d520 mov r3, sb | r3 = sb;
0x0005d524 bl 0x1436c | printf (r0, r1, r2, "KMGTPEZY");
0x0005d528 ldr r0, [pc, 0x38c] | r0 = "First usable sector is %llu, last usable sector is %llu\n\n";
0x0005d52c bl 0x14660 | puts ("First usable sector is %llu, last usable sector is %llu\n\n");
0x0005d530 ldr r8, [pc, 0x388] | r8 = "Number Start (sector) End (sector) Size Name";
0x0005d534 ldr sb, [pc, 0x388] | sb = *(0x0005d8c4);
| do {
| label_0:
0x0005d538 ldr r3, [r8] | r3 = *(r8);
0x0005d53c cmp r4, r3 |
| if (r4 > r3) {
0x0005d540 blo 0x5d54c |
| label_1:
0x0005d544 add sp, sp, 0x84 |
0x0005d548 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x0005d54c ldr r3, [pc, 0x374] | r3 = *(0x5d8c4);
0x0005d550 ldr fp, [r3] | fp = *(0x5d8c4);
0x0005d554 ldr r3, [sb] | r3 = *(sb);
0x0005d558 mla r2, r4, fp, r3 | __asm ("mla r2, r4, fp, r3");
0x0005d55c add r4, r4, 1 | r4++;
0x0005d560 ldrd r0, r1, [r2, 0x20] | __asm ("ldrd r0, r1, [r2, 0x20]");
0x0005d564 str r2, [sp, 0x3c] | var_3ch = r2;
0x0005d568 orrs r3, r0, r1 | r3 = r0 | r1;
0x0005d56c beq 0x5d538 |
| } while (r3 == r0);
0x0005d570 ldrd r2, r3, [r2, 0x28] | __asm ("ldrd r2, r3, [r2, 0x28]");
0x0005d574 ldr ip, [r6, 0x10] | ip = *((r6 + 0x10));
0x0005d578 adds sl, r2, 1 | sl = r2 + 1;
0x0005d57c adc fp, r3, 0 | __asm ("adc fp, r3, 0");
0x0005d580 subs r2, sl, r0 | r2 = sl - r0;
0x0005d584 sbc r3, fp, r1 | __asm ("sbc r3, fp, r1");
0x0005d588 umull r0, r1, r2, ip | r0:r1 = r2 * ip;
0x0005d58c mov r2, r7 | r2 = r7;
0x0005d590 mla lr, ip, r3, r1 | __asm ("mla lr, ip, r3, r1");
0x0005d594 ldr r3, [pc, 0x300] | r3 = *(0x5d898);
0x0005d598 mov r1, lr | r1 = lr;
0x0005d59c bl 0x171d0 | fcn_000171d0 (r0, r1);
0x0005d5a0 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0005d5a4 ldr r1, [sp, 0x3c] | r1 = var_3ch;
0x0005d5a8 mov r5, 0 | r5 = 0;
0x0005d5ac strb r5, [r0] | *(r0) = r5;
0x0005d5b0 ldrd r2, r3, [r3, 0x20] | __asm ("ldrd r2, r3, [r3, 0x20]");
0x0005d5b4 str r7, [sp, 8] | var_8h = r7;
0x0005d5b8 ldrd r0, r1, [r1, 0x28] | __asm ("ldrd r0, r1, [r1, 0x28]");
0x0005d5bc strd r0, r1, [sp] | __asm ("strd r0, r1, [sp]");
0x0005d5c0 ldr r0, [pc, 0x304] | r0 = *(0x5d8c8);
0x0005d5c4 mov r1, r4 | r1 = r4;
0x0005d5c8 bl 0x1436c | printf (r0, r1, r2, r3, r4, r5);
0x0005d5cc ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0005d5d0 add r0, sp, 0x58 | r0 += var_58h;
0x0005d5d4 add fp, r3, 0x36 |
0x0005d5d8 mov r3, r5 | r3 = r5;
| do {
0x0005d5dc ldrh r2, [fp, 2]! | r2 = *(arg_2h);
0x0005d5e0 cmp r2, 0 |
| if (r2 == 0) {
0x0005d5e4 beq 0x5d604 | goto label_4;
| }
0x0005d5e8 sub r1, r2, 0x20 | r1 = r2 - 0x20;
0x0005d5ec cmp r1, 0x5e |
| if (r1 <= 0x5e) {
0x0005d5f0 movhi r2, 0x3f | r2 = 0x3f;
| }
0x0005d5f4 strb r2, [r0, r3] | *((r0 + r3)) = r2;
0x0005d5f8 add r3, r3, 1 | r3++;
0x0005d5fc cmp r3, 0x24 |
0x0005d600 bne 0x5d5dc |
| } while (r3 != 0x24);
| label_4:
0x0005d604 add r2, sp, 0x80 | r2 += var_80h;
0x0005d608 add r3, r2, r3 | r3 = r2 + r3;
0x0005d60c mov r2, 0 | r2 = 0;
0x0005d610 strb r2, [r3, -0x28] | var_58h = r2;
0x0005d614 ldr r3, [pc, 0x2b4] | r3 = "%6u %15llu %15llu %s ";
0x0005d618 ldr r1, [r3] | r1 = "%6u %15llu %15llu %s ";
0x0005d61c bl 0x149d8 | fputs_unlocked ();
0x0005d620 mov r0, 0xa | r0 = 0xa;
0x0005d624 bl 0x18ce4 | fcn_00018ce4 (r0);
0x0005d628 b 0x5d538 | goto label_0;
| label_3:
0x0005d62c bl 0x5c0cc | fcn_0005c0cc ();
0x0005d630 ldr r4, [r6, 4] | r4 = *((r6 + 4));
0x0005d634 mov r0, r4 | r0 = r4;
0x0005d638 bl 0x1514c | r0 = strlen (r0);
0x0005d63c cmp r0, 0 |
| if (r0 != 0) {
0x0005d640 moveq r5, 7 | r5 = 7;
| }
| if (r0 != 0) {
0x0005d644 beq 0x5d668 |
0x0005d648 add r4, r4, r0 | r4 += r0;
0x0005d64c ldrb r3, [r4, -1] | r3 = *((r4 - 1));
0x0005d650 sub r3, r3, 0x30 | r3 -= 0x30;
0x0005d654 cmp r3, 9 |
| if (r3 > 9) {
0x0005d658 addls r0, r0, 1 | r0++;
| }
0x0005d65c cmp r0, 7 |
| if (r0 < 7) {
0x0005d660 movge r5, r0 | r5 = r0;
| }
| if (r0 < 7) {
0x0005d664 movlt r5, 7 | r5 = 7;
| goto label_5;
| }
| }
| label_5:
0x0005d668 ldr r2, [pc, 0x264] | r2 = stdout;
0x0005d66c sub r1, r5, 1 | r1 = r5 - 1;
0x0005d670 ldr r0, [pc, 0x260] | r0 = "Device";
0x0005d674 bl 0x1436c | printf (r0, r1, r2, r3, r4, r5);
0x0005d678 mov r6, 0 | r6 = 0;
| label_2:
0x0005d67c ldr r3, [sp, 0x44] | r3 = var_44h;
0x0005d680 ldr r7, [r3] | r7 = *(r3);
0x0005d684 ldr r3, [r7, 8] | r3 = *((r7 + 8));
0x0005d688 cmp r6, r3 |
| if (r6 < r3) {
0x0005d68c blt 0x5d6b4 | goto label_6;
| }
0x0005d690 ldr r0, [r7, 0x28] | r0 = *((r7 + 0x28));
0x0005d694 cmp r0, 0 |
| if (r0 != 0) {
0x0005d698 bne 0x5d544 | goto label_1;
| }
0x0005d69c bl 0x5c4cc | r0 = fcn_0005c4cc (r0);
0x0005d6a0 cmp r0, 0 |
| if (r0 == 0) {
0x0005d6a4 beq 0x5d544 | goto label_1;
| }
0x0005d6a8 ldr r0, [pc, 0x22c] | r0 = "__s_Boot_StartCHS____EndCHS________StartLBA_____EndLBA____Sectors__Size_Id_Type";
0x0005d6ac bl 0x14660 | puts ("__s_Boot_StartCHS____EndCHS________StartLBA_____EndLBA____Sectors__Size_Id_Type");
0x0005d6b0 b 0x5d544 | goto label_1;
| label_6:
0x0005d6b4 mov r3, 0x14 | r3 = 0x14;
0x0005d6b8 mul r2, r6, r3 | r2 = r6 * r3;
0x0005d6bc add r3, r7, r2 | r3 = r7 + r2;
0x0005d6c0 ldr r4, [r3, 0x9c8] | r4 = *((r3 + 0x9c8));
0x0005d6c4 add r8, r2, 0x9c0 | r8 = r2 + 0x9c0;
0x0005d6c8 add r8, r8, 8 | r8 += 8;
0x0005d6cc cmp r4, 0 |
0x0005d6d0 add r8, r7, r8 | r8 = r7 + r8;
| if (r4 != 0) {
0x0005d6d4 beq 0x5d890 |
0x0005d6d8 mov r0, r4 | r0 = r4;
0x0005d6dc bl 0x5bf64 | r0 = fcn_0005bf64 (r0);
0x0005d6e0 cmp r0, 0 |
| if (r0 != 0) {
0x0005d6e4 bne 0x5d890 | goto label_7;
| }
0x0005d6e8 ldrb r2, [r4] | r2 = *(r4);
0x0005d6ec ldr r1, [pc, 0x1ec] | r1 = "\nPartition table entries are not in disk order";
0x0005d6f0 add r0, sp, 0x50 | r0 += s;
0x0005d6f4 bl 0x14f48 | sprintf (r0, "\nPartition table entries are not in disk order", r2)
0x0005d6f8 ldrb r3, [r4] | r3 = *(r4);
0x0005d6fc tst r3, 0x7f |
| if ((r3 & 0x7f) == 0) {
0x0005d700 bne 0x5d71c |
0x0005d704 cmp r3, 0 |
| if (r3 != 0) {
0x0005d708 moveq r3, 0x20 | r3 = 0x20;
| }
| if (r3 == 0) {
0x0005d70c movne r3, 0x2a | r3 = 0x2a;
| }
0x0005d710 strb r3, [sp, 0x50] | s = r3;
0x0005d714 mov r3, 0x20 | r3 = 0x20;
0x0005d718 strb r3, [sp, 0x51] | var_51h = r3;
| }
0x0005d71c mov r0, r8 | r0 = r8;
0x0005d720 bl 0x5c4b4 | fcn_0005c4b4 (r0);
0x0005d724 str r0, [sp, 0x3c] | var_3ch = r0;
0x0005d728 mov r0, r4 | r0 = r4;
0x0005d72c bl 0x5c560 | fcn_0005c560 (r0);
0x0005d730 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0005d734 add r2, sp, 0x58 | r2 += var_58h;
0x0005d738 subs sl, r0, 0 | sl = r0 - 0;
0x0005d73c ldr r0, [r7, 0x10] | r0 = *((r7 + 0x10));
| if (sl == r0) {
0x0005d740 addne r3, r3, sl | r3 += sl;
| }
0x0005d744 umull r8, sb, sl, r0 | r8:sb = sl * r0;
| if (sl == r0) {
0x0005d748 subne r3, r3, 1 | r3--;
| }
0x0005d74c mov r1, sb | r1 = sb;
0x0005d750 str r3, [sp, 0x40] | var_40h = r3;
0x0005d754 mov r0, r8 | r0 = r8;
0x0005d758 ldr r3, [pc, 0x13c] | r3 = *(0x5d898);
0x0005d75c bl 0x171d0 | fcn_000171d0 (r0, r1);
0x0005d760 mov r3, 0 | r3 = 0;
0x0005d764 strb r3, [r0] | *(r0) = r3;
0x0005d768 mov r0, 0x50 | r0 = 0x50;
0x0005d76c ldr r8, [r7, 4] | r8 = *((r7 + 4));
0x0005d770 bl 0x189b8 | r0 = fcn_000189b8 (r0);
0x0005d774 bl 0x98560 | r0 = fcn_00098560 (r0);
0x0005d778 mov fp, r0 |
0x0005d77c mov r0, r8 | r0 = r8;
0x0005d780 bl 0x1514c | strlen (r0);
0x0005d784 ldr r1, [pc, 0x158] | r1 = *(0x5d8e0);
0x0005d788 add r3, r8, r0 | r3 = r8 + r0;
0x0005d78c ldrb r7, [r3, -1] | r7 = *((r3 - 1));
0x0005d790 str r0, [sp, 0x4c] | var_4ch = r0;
0x0005d794 sub r3, r7, 0x30 | r3 = r7 - 0x30;
0x0005d798 cmp r3, 9 |
0x0005d79c sub r3, r0, 4 | r3 = r0 - 4;
0x0005d7a0 ldr r7, [pc, 0x140] | r7 = *(0x5d8e4);
0x0005d7a4 add r0, r8, r3 | r0 = r8 + r3;
| if (r3 > 9) {
0x0005d7a8 movls r7, r1 | r7 = r1;
| }
0x0005d7ac ldr r1, [pc, 0x138] | r1 = *(0x5d8e8);
0x0005d7b0 str r3, [sp, 0x48] | var_48h = r3;
0x0005d7b4 bl 0x14ed0 | strcmp (r0, r1);
0x0005d7b8 ldr r3, [sp, 0x48] | r3 = var_48h;
0x0005d7bc ldr r2, [sp, 0x4c] | r2 = var_4ch;
0x0005d7c0 cmp r0, 0 |
| if (r0 != 0) {
0x0005d7c4 moveq r2, r3 | r2 = r3;
| }
0x0005d7c8 ldr r3, [pc, 0x120] | r3 = "disc";
0x0005d7cc str r2, [sp, 0x48] | var_48h = r2;
| if (r0 != 0) {
0x0005d7d0 moveq r7, r3 | r7 = r3;
| }
0x0005d7d4 mov r0, r7 | r0 = r7;
0x0005d7d8 bl 0x1514c | strlen (r0);
0x0005d7dc ldr r2, [sp, 0x48] | r2 = var_48h;
0x0005d7e0 add r3, r5, 2 | r3 = r5 + 2;
0x0005d7e4 add r1, r6, 1 | r1 = r6 + 1;
0x0005d7e8 str r1, [sp, 0xc] | var_ch = r1;
0x0005d7ec str r7, [sp, 8] | var_8h = r7;
0x0005d7f0 str r8, [sp, 4] | var_4h = r8;
0x0005d7f4 str r2, [sp] | *(sp) = r2;
0x0005d7f8 mov r1, 0x50 | r1 = 0x50;
0x0005d7fc ldr r2, [pc, 0xf0] | r2 = "part";
0x0005d800 sub r3, r3, r0 | r3 -= r0;
0x0005d804 sub r3, r3, 2 | r3 -= 2;
0x0005d808 mov r0, fp | r0 = fp;
0x0005d80c bl 0x14450 | snprintf (r0, r1, "part", r3);
0x0005d810 ldrb r2, [r4, 2] | r2 = *((r4 + 2));
0x0005d814 ldrb r1, [r4, 1] | r1 = *((r4 + 1));
0x0005d818 ldrb r0, [r4, 3] | r0 = *((r4 + 3));
0x0005d81c bl 0x5c6ec | fcn_0005c6ec (r0, r1);
0x0005d820 ldrb r2, [r4, 6] | r2 = *((r4 + 6));
0x0005d824 ldrb r1, [r4, 5] | r1 = *((r4 + 5));
0x0005d828 mov r7, r0 | r7 = r0;
0x0005d82c ldrb r0, [r4, 7] | r0 = *((r4 + 7));
0x0005d830 bl 0x5c6ec | fcn_0005c6ec (r0, r1);
0x0005d834 ldrb r8, [r4, 4] | r8 = *((r4 + 4));
0x0005d838 str r0, [sp, 0x48] | var_48h = r0;
0x0005d83c mov r0, r8 | r0 = r8;
0x0005d840 bl 0x5bf30 | fcn_0005bf30 (r0);
0x0005d844 add r3, sp, 0x58 | r3 += var_58h;
0x0005d848 str r3, [sp, 0x10] | var_10h = r3;
0x0005d84c ldr r3, [sp, 0x40] | r3 = var_40h;
0x0005d850 mov r1, fp | r1 = fp;
0x0005d854 str r3, [sp, 8] | var_8h = r3;
0x0005d858 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0005d85c str r8, [sp, 0x14] | var_14h = r8;
0x0005d860 str r3, [sp, 4] | var_4h = r3;
0x0005d864 ldr r3, [sp, 0x48] | r3 = var_48h;
0x0005d868 str sl, [sp, 0xc] | var_ch = sl;
0x0005d86c str r3, [sp] | *(sp) = r3;
0x0005d870 add r2, sp, 0x50 | r2 += s;
0x0005d874 mov r3, r7 | r3 = r7;
0x0005d878 str r0, [sp, 0x18] | var_18h = r0;
0x0005d87c ldr r0, [pc, 0x74] | r0 = "_.s_s__2u";
0x0005d880 bl 0x1436c | printf (r0, r1, r2, r3);
0x0005d884 mov r1, r6 | r1 = r6;
0x0005d888 mov r0, r4 | r0 = r4;
0x0005d88c bl 0x5cd00 | fcn_0005cd00 (r0, r1);
| }
| label_7:
0x0005d890 add r6, r6, 1 | r6++;
0x0005d894 b 0x5d67c | goto label_2;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x5dd24 */
| #include <stdint.h>
|
; (fcn) fcn.0005dd24 () | void fcn_0005dd24 () {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| char * s;
| int32_t var_84h;
| char * fildes;
| int32_t var_160h;
| int32_t var_164h;
0x0005dd24 push {r4, r5, r6, r7, r8, sb, lr} |
0x0005dd28 ldr r1, [pc, 0xf4] | r1 = *(0x5de20);
0x0005dd2c sub sp, sp, 0x164 |
0x0005dd30 ldr r0, [pc, 0xf0] | r0 = *(0x5de24);
0x0005dd34 bl 0xa560c | fcn_000a560c (r0);
0x0005dd38 ldr r5, [pc, 0xec] | r5 = "_proc_partitions";
0x0005dd3c ldr r6, [pc, 0xec] | r6 = " %u %u %u %[^\n ]";
0x0005dd40 ldr r7, [pc, 0xec] | r7 = "/dev/%s";
0x0005dd44 mov r4, r0 | r4 = r0;
| do {
| label_0:
0x0005dd48 mov r2, r4 | r2 = r4;
0x0005dd4c mov r1, 0x64 | r1 = 0x64;
0x0005dd50 add r0, sp, 0x20 | r0 += s;
0x0005dd54 bl 0x150f8 | r0 = fgets_unlocked ();
0x0005dd58 cmp r0, 0 |
| if (r0 == 0) {
0x0005dd5c bne 0x5dd68 |
0x0005dd60 add sp, sp, 0x164 |
0x0005dd64 pop {r4, r5, r6, r7, r8, sb, pc} |
| }
0x0005dd68 add r3, sp, 0x14 | r3 += var_14h;
0x0005dd6c add r8, sp, 0x84 | r8 += var_84h;
0x0005dd70 str r3, [sp] | *(sp) = r3;
0x0005dd74 str r8, [sp, 4] | var_4h = r8;
0x0005dd78 add r3, sp, 0x10 | r3 += var_10h;
0x0005dd7c add r2, sp, 0xc | r2 += var_ch;
0x0005dd80 mov r1, r5 | r1 = r5;
0x0005dd84 add r0, sp, 0x20 | r0 += s;
0x0005dd88 bl 0x14c9c | r0 = sscanf (r0, r1, r2);
0x0005dd8c cmp r0, 4 |
0x0005dd90 bne 0x5dd48 |
| } while (r0 != 4);
0x0005dd94 mov r2, r8 | r2 = r8;
0x0005dd98 mov r1, r6 | r1 = r6;
0x0005dd9c add r0, sp, 0xe8 | r0 += fildes;
0x0005dda0 bl 0x14f48 | sprintf (r0, r1, r2)
0x0005dda4 mov r1, 0 | r1 = 0;
0x0005dda8 add r0, sp, 0xe8 | r0 += fildes;
0x0005ddac bl 0x14df8 | r0 = open64 ();
0x0005ddb0 cmn r0, 1 |
0x0005ddb4 mov r8, r0 | r8 = r0;
| if (r0 == 1) {
0x0005ddb8 beq 0x5ddf8 | goto label_2;
| }
0x0005ddbc add r2, sp, 0x18 | r2 += var_18h;
0x0005ddc0 mov r1, r7 | r1 = r7;
0x0005ddc4 bl 0x14330 | r0 = ioctl (r0, r1);
0x0005ddc8 mov sb, r0 | sb = r0;
0x0005ddcc mov r0, r8 | r0 = r8;
0x0005ddd0 bl 0x15260 | close (r0);
0x0005ddd4 cmp sb, 0 |
| if (sb != 0) {
0x0005ddd8 bne 0x5ddf8 | goto label_2;
| }
0x0005dddc ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0005dde0 cmp r3, 0 |
| if (r3 != 0) {
0x0005dde4 bne 0x5dd48 | goto label_0;
| }
| do {
| label_1:
0x0005dde8 mov r1, 0 | r1 = 0;
0x0005ddec add r0, sp, 0xe8 | r0 += fildes;
0x0005ddf0 bl 0x5db70 | fcn_0005db70 ();
0x0005ddf4 b 0x5dd48 | goto label_0;
| label_2:
0x0005ddf8 add r0, sp, 0xe8 | r0 += fildes;
0x0005ddfc bl 0x1514c | r0 = strlen (r0);
0x0005de00 cmp r0, 0 |
0x0005de04 beq 0x5dde8 |
| } while (r0 == 0);
0x0005de08 add r3, sp, 0x160 | r3 += var_160h;
0x0005de0c add r0, r3, r0 | r0 = r3 + r0;
0x0005de10 ldrb r3, [r0, -0x79] | r3 = *((r0 - 0x79));
0x0005de14 sub r3, r3, 0x30 | r3 -= 0x30;
0x0005de18 cmp r3, 9 |
| if (r3 > 9) {
0x0005de1c bhi 0x5dde8 | goto label_1;
| }
0x0005de20 b 0x5dd48 | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x6294c */
| #include <stdint.h>
|
; (fcn) fcn.0006294c () | void fcn_0006294c () {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
0x0006294c push {r0, r1, r4, lr} |
0x00062950 ldr r4, [pc, 0x30] | r4 = *(0x62984);
0x00062954 mov r1, 0 | r1 = 0;
0x00062958 mov r0, sp | r0 = sp;
0x0006295c bl 0x14d74 | gettimeofday ();
0x00062960 mov r2, sp | r2 = sp;
0x00062964 mov r1, 0x10 | r1 = 0x10;
0x00062968 mov r0, r4 | r0 = r4;
0x0006296c bl 0x19e78 | fcn_00019e78 (r0, r1);
0x00062970 ldr r2, [sp, 4] | r2 = var_4h;
0x00062974 ldr r1, [pc, 0x10] | r1 = *(0x62988);
0x00062978 bl 0x14f48 | sprintf (r0, r1, r2)
0x0006297c mov r0, r4 | r0 = r4;
0x00062980 add sp, sp, 8 |
0x00062984 pop {r4, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x68370 */
| #include <stdint.h>
|
; (fcn) fcn.00068370 () | void fcn_00068370 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h_2;
| int32_t var_0h_2;
| int32_t var_4h_2;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_30h;
| int32_t var_34h;
| r0 = arg1;
| r1 = arg2;
0x00068370 cmp r2, 3 |
0x00068374 push {r4, r5, lr} |
| if (r2 == 3) {
0x00068378 movne r4, 4 | r4 = 4;
| }
| if (r2 == 3) {
0x0006837c lslne r4, r4, r2 | r4 <<= r2;
| }
| if (r2 != 3) {
0x00068380 moveq r4, 0x24 | r4 = 0x24;
| }
0x00068384 sub sp, sp, 0x3c |
0x00068388 mov r3, r1 | r3 = r1;
0x0006838c add ip, r4, r1 |
| do {
0x00068390 cmp ip, r3 |
| if (ip == r3) {
0x00068394 bne 0x683a0 |
| label_0:
0x00068398 add sp, sp, 0x3c |
0x0006839c pop {r4, r5, pc} |
| }
0x000683a0 ldrb lr, [r3], 1 |
0x000683a4 cmp lr, 0 |
0x000683a8 beq 0x68390 |
| } while (lr == 0);
0x000683ac mov r5, r0 | r5 = r0;
0x000683b0 cmp r2, 3 |
| if (r2 > 3) {
| /* switch table (4 cases) at 0x683bc */
0x000683b4 ldrls pc, [pc, r2, lsl 2] | offset_0 = r2 << 2;
| pc = *((pc + offset_0));
| }
0x000683b8 b 0x68398 | goto label_0;
0x000683cc ldrb r0, [r1] | r0 = *(r1);
0x000683d0 ldrb r3, [r1, 2] | r3 = *((r1 + 2));
0x000683d4 ldrb r2, [r1, 3] | r2 = *((r1 + 3));
0x000683d8 str r0, [sp, 4] | var_4h = r0;
0x000683dc ldrb r1, [r1, 1] | r1 = *((r1 + 1));
0x000683e0 add r0, r5, 0x61 | r0 = r5 + 0x61;
0x000683e4 str r1, [sp] | *(sp) = r1;
0x000683e8 ldr r1, [pc, 0xf0] | r1 = *(0x684dc);
0x000683ec bl 0x14f48 | sprintf (r0, r1, r2)
0x000683f0 b 0x68398 | goto label_0;
0x000683f4 ldrb r0, [r1] | r0 = *(r1);
0x000683f8 ldrb r3, [r1, 6] | r3 = *((r1 + 6));
0x000683fc ldrb r2, [r1, 7] | r2 = *((r1 + 7));
0x00068400 str r0, [sp, 0x14] | var_14h = r0;
0x00068404 ldrb r0, [r1, 1] | r0 = *((r1 + 1));
0x00068408 str r0, [sp, 0x10] | var_10h = r0;
0x0006840c ldrb r0, [r1, 2] | r0 = *((r1 + 2));
0x00068410 str r0, [sp, 0xc] | var_ch = r0;
0x00068414 ldrb r0, [r1, 3] | r0 = *((r1 + 3));
0x00068418 str r0, [sp, 8] | var_8h = r0;
0x0006841c ldrb r0, [r1, 4] | r0 = *((r1 + 4));
0x00068420 str r0, [sp, 4] | var_4h = r0;
0x00068424 ldrb r1, [r1, 5] | r1 = *((r1 + 5));
0x00068428 add r0, r5, 0x61 | r0 = r5 + 0x61;
0x0006842c str r1, [sp] | *(sp) = r1;
0x00068430 ldr r1, [pc, 0xac] | r1 = "%02X%02X-%02X%02X";
0x00068434 bl 0x14f48 | sprintf (r0, r1, r2)
0x00068438 b 0x68398 | goto label_0;
0x0006843c ldrb r0, [r1, 0xf] | r0 = *((r1 + 0xf));
0x00068440 ldrb r3, [r1, 1] | r3 = *((r1 + 1));
0x00068444 ldrb r2, [r1] | r2 = *(r1);
0x00068448 str r0, [sp, 0x34] | var_34h = r0;
0x0006844c ldrb r0, [r1, 0xe] | r0 = *((r1 + 0xe));
0x00068450 str r0, [sp, 0x30] | var_30h = r0;
0x00068454 ldrb r0, [r1, 0xd] | r0 = *((r1 + 0xd));
0x00068458 str r0, [sp, 0x2c] | var_2ch = r0;
0x0006845c ldrb r0, [r1, 0xc] | r0 = *((r1 + 0xc));
0x00068460 str r0, [sp, 0x28] | var_28h = r0;
0x00068464 ldrb r0, [r1, 0xb] | r0 = *((r1 + 0xb));
0x00068468 str r0, [sp, 0x24] | var_24h = r0;
0x0006846c ldrb r0, [r1, 0xa] | r0 = *((r1 + 0xa));
0x00068470 str r0, [sp, 0x20] | var_14h = r0;
0x00068474 ldrb r0, [r1, 9] | r0 = *((r1 + 9));
0x00068478 str r0, [sp, 0x1c] | var_10h = r0;
0x0006847c ldrb r0, [r1, 8] | r0 = *((r1 + 8));
0x00068480 str r0, [sp, 0x18] | var_ch = r0;
0x00068484 ldrb r0, [r1, 7] | r0 = *((r1 + 7));
0x00068488 str r0, [sp, 0x14] | var_14h = r0;
0x0006848c ldrb r0, [r1, 6] | r0 = *((r1 + 6));
0x00068490 str r0, [sp, 0x10] | var_10h = r0;
0x00068494 ldrb r0, [r1, 5] | r0 = *((r1 + 5));
0x00068498 str r0, [sp, 0xc] | var_ch = r0;
0x0006849c ldrb r0, [r1, 4] | r0 = *((r1 + 4));
0x000684a0 str r0, [sp, 8] | var_8h = r0;
0x000684a4 ldrb r0, [r1, 3] | r0 = *((r1 + 3));
0x000684a8 str r0, [sp, 4] | var_4h = r0;
0x000684ac ldrb r1, [r1, 2] | r1 = *((r1 + 2));
0x000684b0 add r0, r5, 0x61 | r0 = r5 + 0x61;
0x000684b4 str r1, [sp] | *(sp) = r1;
0x000684b8 ldr r1, [pc, 0x28] | r1 = "%02X%02X%02X%02X%02X%02X%02X%02X";
0x000684bc bl 0x14f48 | sprintf (r0, r1, r2)
0x000684c0 b 0x68398 | goto label_0;
0x000684c4 mov r2, r4 | r2 = r4;
0x000684c8 add r0, r0, 0x61 | r0 += 0x61;
0x000684cc bl 0x14624 | memcpy (r0, r1, r2);
0x000684d0 add r0, r5, r4 | r0 = r5 + r4;
0x000684d4 mov r3, 0 | r3 = 0;
0x000684d8 strb r3, [r0, 0x61] | *((r0 + 0x61)) = r3;
0x000684dc b 0x68398 | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x6bfb4 */
| #include <stdint.h>
|
; (fcn) fcn.0006bfb4 () | void fcn_0006bfb4 (void * arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_0h_2;
| char * s;
| void * s2;
| int32_t var_28h;
| r0 = arg1;
| r1 = arg2;
0x0006bfb4 push {r4, r5, r6, lr} |
0x0006bfb8 sub sp, sp, 0x28 |
0x0006bfbc add r5, sp, 0xc | r5 += s;
0x0006bfc0 mov r4, r1 | r4 = r1;
0x0006bfc4 strd r2, r3, [sp] | __asm ("strd r2, r3, [sp]");
0x0006bfc8 mov r6, r0 | r6 = r0;
0x0006bfcc mov r2, r1 | r2 = r1;
0x0006bfd0 mov r0, r5 | r0 = r5;
0x0006bfd4 ldr r1, [pc, 0x28] | r1 = *(0x6c000);
0x0006bfd8 bl 0x14f48 | sprintf (r0, r1, r2)
0x0006bfdc mov r2, r4 | r2 = r4;
0x0006bfe0 sub r0, r0, r4 | r0 -= r4;
0x0006bfe4 ldrb r3, [r5, r0] | r3 = *((r5 + r0));
0x0006bfe8 add r1, r5, r0 | r1 = r5 + r0;
0x0006bfec cmp r3, 0x30 |
| if (r3 != 0x30) {
0x0006bff0 addeq r1, r1, 1 | r1++;
| }
0x0006bff4 mov r0, r6 | r0 = r6;
0x0006bff8 bl 0x14624 | memcpy (r0, r1, r2);
0x0006bffc add sp, sp, 0x28 |
0x0006c000 pop {r4, r5, r6, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x6cc28 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.0006cc28 () | void fcn_0006cc28 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_30h;
| char * dest;
| int32_t var_39h;
| int32_t var_3ch;
| int32_t var_3eh;
| int32_t var_40h;
| char * format;
| int32_t var_44h;
| int32_t var_46h;
| int32_t var_48h;
| int32_t var_4ah;
| int32_t var_4ch;
| int32_t var_4eh;
| int32_t var_50h;
| int32_t var_52h;
| int32_t var_54h;
| char * s;
| int32_t var_60h;
| int32_t var_64h;
| int32_t var_66h;
| int32_t var_68h;
| int32_t var_6ah;
| int32_t var_6ch;
| int32_t var_6eh;
| int32_t var_70h;
| int32_t var_72h;
| int32_t var_74h;
| int32_t var_78h;
| int32_t var_7ch;
| int32_t var_7eh;
| int32_t var_80h;
| int32_t var_84h;
| int32_t var_88h;
| int32_t var_90h;
| int32_t var_e4h;
| r0 = arg1;
0x0006cc28 push {r4, lr} |
0x0006cc2c mov r4, r0 | r4 = r0;
0x0006cc30 bl 0x18cdc | fcn_00018cdc ();
0x0006cc34 ldr r3, [pc, 0x1c] | r3 = *(0x6cc54);
0x0006cc38 mov r1, 0x50 | r1 = 0x50;
0x0006cc3c ldr r2, [r3] | r2 = *(0x6cc54);
0x0006cc40 mov r0, r4 | r0 = r4;
0x0006cc44 bl 0x150f8 | r0 = fgets_unlocked ();
0x0006cc48 cmp r0, 0 |
0x0006cc4c popne {r4, pc} |
0x0006cc50 ldr r0, [pc, 4] | r0 = "cant_read_standard_input";
0x0006cc54 bl 0x17fd8 | fcn_00017fd8 ();
| if (r0 != 0) {
0x0006cc58 andeq sp, sp, ip, lsr 11 |
| }
| if (r0 != 0) {
0x0006cc5c andeq r7, ip, r2, asr fp | r7 = ip & (r2 >> fp);
| }
0x0006cc60 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0006cc64 ldr fp, [pc, 0xba4] | fp = "_d:lnopqxjv";
0x0006cc68 ldr r8, [pc, 0xba4] | r8 = "_d:lnopqxjv";
0x0006cc6c mov r5, 0 | r5 = 0;
0x0006cc70 sub sp, sp, 0xe4 |
0x0006cc74 mov sb, r0 | sb = r0;
0x0006cc78 mov sl, r1 | sl = r1;
0x0006cc7c mov r7, r5 | r7 = r5;
0x0006cc80 mvn r6, 0 | r6 = ~0;
0x0006cc84 mov r4, r5 | r4 = r5;
0x0006cc88 str r5, [sp, 0x28] | var_28h = r5;
0x0006cc8c str r5, [sp, 0x2c] | var_2ch = r5;
0x0006cc90 str r5, [sp, 0x30] | var_30h = r5;
0x0006cc94 str r5, [sp, 0x10] | var_10h = r5;
0x0006cc98 str r5, [sp, 0x18] | var_18h = r5;
0x0006cc9c str r5, [sp, 0x14] | var_14h = r5;
| label_0:
0x0006cca0 mov r2, fp | r2 = fp;
0x0006cca4 mov r1, sl | r1 = sl;
0x0006cca8 mov r0, sb | r0 = sb;
0x0006ccac bl 0x14d80 | r0 = getopt (r0, r1, r2);
0x0006ccb0 cmn r0, 1 |
| if (r0 != 1) {
0x0006ccb4 bne 0x6ce3c | goto label_19;
| }
0x0006ccb8 cmp r7, 0 |
| if (r7 == 0) {
0x0006ccbc beq 0x6ce5c | goto label_1;
| }
0x0006ccc0 ldrb r3, [r7] | r3 = *(r7);
0x0006ccc4 cmp r3, 0x2d |
| if (r3 != 0x2d) {
0x0006ccc8 bne 0x6cf34 | goto label_20;
| }
0x0006cccc ldrb r0, [r7, 1] | r0 = *((r7 + 1));
0x0006ccd0 cmp r0, 0 |
| if (r0 != 0) {
0x0006ccd4 bne 0x6cf34 | goto label_20;
| }
0x0006ccd8 mov r1, 3 | r1 = 3;
0x0006ccdc bl 0x18b6c | fcn_00018b6c (r0);
0x0006cce0 ldr r3, [sp, 0x10] | r3 = var_10h;
0x0006cce4 cmp r3, 0 |
| if (r3 != 0) {
0x0006cce8 moveq r3, 1 | r3 = 1;
| }
0x0006ccec str r3, [sp, 0x10] | var_10h = r3;
| label_3:
0x0006ccf0 cmp r5, 0 |
| if (r5 != 0) {
0x0006ccf4 beq 0x6cd00 |
0x0006ccf8 mov r0, r5 | r0 = r5;
0x0006ccfc bl 0x18ec4 | fcn_00018ec4 (r0);
| }
0x0006cd00 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006cd04 cmp r3, 1 |
| if (r3 <= 1) {
0x0006cd08 bgt 0x6cd48 |
0x0006cd0c cmp r3, 0 |
| if (r3 == 0) {
0x0006cd10 bne 0x6cd28 |
0x0006cd14 mov r0, r7 | r0 = r7;
0x0006cd18 bl 0xa14d4 | r0 = fcn_000a14d4 (r0);
0x0006cd1c mov r1, r0 | r1 = r0;
0x0006cd20 ldr r0, [pc, 0xaf0] | r0 = optarg;
0x0006cd24 bl 0x1436c | printf (r0, r1);
| }
0x0006cd28 tst r4, 1 |
| if ((r4 & 1) == 0) {
0x0006cd2c beq 0x6cd48 | goto label_21;
| }
0x0006cd30 ldr r2, [sp, 0x18] | r2 = var_18h;
0x0006cd34 ldr r3, [pc, 0xae0] | r3 = "Archive:___s";
0x0006cd38 cmp r2, 0 |
0x0006cd3c ldr r0, [pc, 0xadc] | r0 = "Length___Method____Size__Cmpr____Date____Time___CRC_32___Name______________________________________________________________";
| if (r2 == 0) {
0x0006cd40 movne r0, r3 | r0 = r3;
| }
0x0006cd44 bl 0x14660 | puts (r0);
| }
| label_21:
0x0006cd48 mov r3, 2 | r3 = 2;
0x0006cd4c str r3, [sp] | *(sp) = r3;
0x0006cd50 mov r2, 0 | r2 = 0;
0x0006cd54 mov r3, 0 | r3 = 0;
0x0006cd58 mov r0, 3 | r0 = 3;
0x0006cd5c bl 0x15158 | lseek64 ();
0x0006cd60 mvn r3, 0 | r3 = ~0;
0x0006cd64 mvn r2, 0 | r2 = ~0;
0x0006cd68 cmp r1, r3 |
0x0006cd6c cmpeq r0, r2 | __asm ("cmpeq r0, r2");
| if (r1 != r3) {
0x0006cd70 mvneq fp, 0 |
| }
| if (r1 != r3) {
0x0006cd74 beq 0x6cde4 |
0x0006cd78 subs r8, r0, 0x10000 | r8 = r0 - 0x10000;
0x0006cd7c sbc sb, r1, 0 | __asm ("sbc sb, r1, 0");
0x0006cd80 cmp r8, 0 |
0x0006cd84 sbcs r3, sb, 0 | __asm ("sbcs r3, sb, 0");
| if (r8 >= 0) {
0x0006cd88 movlt r8, 0 | r8 = 0;
| }
| if (r8 >= 0) {
0x0006cd8c movlt sb, 0 | sb = 0;
| }
0x0006cd90 mov r3, 0 | r3 = 0;
0x0006cd94 mov r2, r8 | r2 = r8;
0x0006cd98 str r3, [sp] | *(sp) = r3;
0x0006cd9c mov r0, 3 | r0 = 3;
0x0006cda0 mov r3, sb | r3 = sb;
0x0006cda4 bl 0x18c28 | fcn_00018c28 (r0);
0x0006cda8 mov r0, 0x10000 | r0 = 0x10000;
0x0006cdac bl 0x189b8 | fcn_000189b8 (r0);
0x0006cdb0 mov r2, 0x10000 | r2 = 0x10000;
0x0006cdb4 mvn fp, 0 |
0x0006cdb8 mov r5, r0 | r5 = r0;
0x0006cdbc mov r1, r0 | r1 = r0;
0x0006cdc0 add r7, r5, 0xff00 | r7 = r5 + 0xff00;
0x0006cdc4 mov r0, 3 | r0 = 3;
0x0006cdc8 bl 0x196c8 | fcn_000196c8 (r0, r1);
0x0006cdcc add r7, r7, 0xec | r7 += 0xec;
0x0006cdd0 mov r3, r5 | r3 = r5;
| label_4:
0x0006cdd4 cmp r3, r7 |
| if (r3 < r7) {
0x0006cdd8 bls 0x6cf9c | goto label_22;
| }
0x0006cddc mov r0, r5 | r0 = r5;
0x0006cde0 bl 0x152a8 | free (r0);
| }
0x0006cde4 mov r5, 0 | r5 = 0;
0x0006cde8 mov sl, r5 | sl = r5;
0x0006cdec str r5, [sp, 0x1c] | var_1ch = r5;
0x0006cdf0 str r5, [sp, 0x20] | var_20h = r5;
| label_13:
0x0006cdf4 cmn fp, 1 |
| if (fp != 1) {
0x0006cdf8 bne 0x6d050 | goto label_23;
| }
| do {
0x0006cdfc add r1, sp, 0x58 | r1 += s;
0x0006ce00 mov r2, 4 | r2 = 4;
0x0006ce04 mov r0, 3 | r0 = 3;
0x0006ce08 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006ce0c ldr r1, [sp, 0x58] | r1 = s;
0x0006ce10 ldr r3, [pc, 0xa0c] | r3 = "Length______Date____Time____Name__________________________________";
0x0006ce14 cmp r1, r3 |
| if (r1 == r3) {
0x0006ce18 beq 0x6d758 | goto label_24;
| }
0x0006ce1c add r3, r3, 0x6000000 | r3 += 0x6000000;
0x0006ce20 add r3, r3, 0x60000 | r3 += 0x60000;
0x0006ce24 cmp r1, r3 |
| if (r1 != r3) {
0x0006ce28 bne 0x6d018 | goto label_25;
| }
0x0006ce2c mov r0, 0xc | r0 = 0xc;
0x0006ce30 mov r1, 0 | r1 = 0;
0x0006ce34 bl 0x6cbc4 | fcn_0006cbc4 (r0, r1);
0x0006ce38 b 0x6cdfc |
| } while (1);
| label_19:
0x0006ce3c cmp r0, 0x6e |
| if (r0 == 0x6e) {
0x0006ce40 beq 0x6cf20 | goto label_26;
| }
| if (r0 > 0x6e) {
0x0006ce44 bgt 0x6ce78 | goto label_27;
| }
0x0006ce48 cmp r0, 0x64 |
| if (r0 == 0x64) {
0x0006ce4c beq 0x6cec0 | goto label_28;
| }
| if (r0 > 0x64) {
0x0006ce50 bgt 0x6ce60 | goto label_29;
| }
0x0006ce54 cmp r0, 1 |
| if (r0 == 1) {
0x0006ce58 beq 0x6cee0 | goto label_30;
| }
| do {
| label_1:
0x0006ce5c bl 0x175e8 | r0 = fcn_000175e8 ();
| label_29:
0x0006ce60 cmp r0, 0x6a |
| if (r0 == 0x6a) {
0x0006ce64 beq 0x6ced8 | goto label_31;
| }
0x0006ce68 cmp r0, 0x6c |
0x0006ce6c bne 0x6ce5c |
| } while (r0 != 0x6c);
| label_2:
0x0006ce70 orr r4, r4, 1 | r4 |= 1;
0x0006ce74 b 0x6cca0 | goto label_0;
| label_27:
0x0006ce78 cmp r0, 0x71 |
| if (r0 == 0x71) {
0x0006ce7c beq 0x6ce98 | goto label_32;
| }
| if (r0 > 0x71) {
0x0006ce80 bgt 0x6cea8 | goto label_33;
| }
0x0006ce84 cmp r0, 0x6f |
| if (r0 == 0x6f) {
0x0006ce88 beq 0x6cf2c | goto label_34;
| }
0x0006ce8c cmp r0, 0x70 |
| if (r0 != 0x70) {
0x0006ce90 bne 0x6ce5c | goto label_1;
| }
0x0006ce94 mov r6, 1 | r6 = 1;
| label_32:
0x0006ce98 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006ce9c add r3, r3, 1 | r3++;
0x0006cea0 str r3, [sp, 0x14] | var_14h = r3;
0x0006cea4 b 0x6cca0 | goto label_0;
| label_33:
0x0006cea8 cmp r0, 0x76 |
| if (r0 == 0x76) {
0x0006ceac beq 0x6cec8 | goto label_35;
| }
0x0006ceb0 cmp r0, 0x78 |
| if (r0 != 0x78) {
0x0006ceb4 bne 0x6ce5c | goto label_1;
| }
0x0006ceb8 orr r4, r4, 2 | r4 |= 2;
0x0006cebc b 0x6cca0 | goto label_0;
| label_28:
0x0006cec0 ldr r5, [r8] | r5 = *(r8);
0x0006cec4 b 0x6cca0 | goto label_0;
| label_35:
0x0006cec8 ldr r3, [sp, 0x18] | r3 = var_18h;
0x0006cecc add r3, r3, 1 | r3++;
0x0006ced0 str r3, [sp, 0x18] | var_18h = r3;
0x0006ced4 b 0x6ce70 | goto label_2;
| label_31:
0x0006ced8 orr r4, r4, 4 | r4 |= 4;
0x0006cedc b 0x6cca0 | goto label_0;
| label_30:
0x0006cee0 cmp r7, 0 |
0x0006cee4 ldr r1, [r8] | r1 = *(r8);
| if (r7 == 0) {
0x0006cee8 bne 0x6cf0c |
0x0006ceec mov r0, r1 | r0 = r1;
0x0006cef0 bl 0x1514c | r0 = strlen (r0);
0x0006cef4 add r0, r0, 5 | r0 += 5;
0x0006cef8 bl 0x18968 | fcn_00018968 (r0);
0x0006cefc ldr r1, [r8] | r1 = *(r8);
0x0006cf00 mov r7, r0 | r7 = r0;
0x0006cf04 bl 0x142f4 | strcpy (r0, r1);
0x0006cf08 b 0x6cca0 | goto label_0;
| }
0x0006cf0c tst r4, 2 |
| if ((r4 & 2) != 0) {
0x0006cf10 addeq r0, sp, 0x28 | r0 += var_28h;
| }
| if ((r4 & 2) == 0) {
0x0006cf14 addne r0, sp, 0x2c | r0 += var_2ch;
| }
0x0006cf18 bl 0x9fe10 | fcn_0009fe10 (r0, r1);
0x0006cf1c b 0x6cca0 | goto label_0;
| label_26:
0x0006cf20 mov r3, 1 | r3 = 1;
| do {
0x0006cf24 str r3, [sp, 0x10] | var_10h = r3;
0x0006cf28 b 0x6cca0 | goto label_0;
| label_34:
0x0006cf2c mov r3, 2 | r3 = 2;
0x0006cf30 b 0x6cf24 |
| } while (1);
| label_20:
0x0006cf34 mov r0, r7 | r0 = r7;
0x0006cf38 bl 0x1514c | strlen (r0);
0x0006cf3c ldr sb, [pc, 0x8e4] | sb = *(0x6d824);
0x0006cf40 mov sl, 0 | sl = 0;
0x0006cf44 add r8, r7, r0 | r8 = r7 + r0;
| do {
0x0006cf48 mov r1, 0 | r1 = 0;
0x0006cf4c mov r0, r7 | r0 = r7;
0x0006cf50 bl 0x14df8 | r0 = open64 ();
0x0006cf54 cmp r0, 0 |
| if (r0 >= 0) {
0x0006cf58 bge 0x6cf90 | goto label_36;
| }
0x0006cf5c add sl, sl, 1 | sl++;
0x0006cf60 cmp sl, 3 |
| if (sl == 3) {
0x0006cf64 bne 0x6cf7c |
0x0006cf68 ldr r0, [pc, 0x8bc] | r0 = *(0x6d828);
0x0006cf6c mov r3, 0 | r3 = 0;
0x0006cf70 mov r1, r7 | r1 = r7;
0x0006cf74 strb r3, [r8] | *(r8) = r3;
| label_5:
0x0006cf78 bl 0x18254 | fcn_00018254 ();
| }
0x0006cf7c add r1, sl, sl, lsl 2 | r1 = sl + (sl << 2);
0x0006cf80 add r1, sb, r1 | r1 = sb + r1;
0x0006cf84 mov r0, r8 | r0 = r8;
0x0006cf88 bl 0x142f4 | strcpy (r0, r1);
0x0006cf8c b 0x6cf48 |
| } while (1);
| label_36:
0x0006cf90 mov r1, 3 | r1 = 3;
0x0006cf94 bl 0x18b8c | fcn_00018b8c (r0, r1);
0x0006cf98 b 0x6ccf0 | goto label_3;
| label_22:
0x0006cf9c ldrb r2, [r3] | r2 = *(r3);
0x0006cfa0 add lr, r3, 1 | lr = r3 + 1;
0x0006cfa4 cmp r2, 0x50 |
| if (r2 == 0x50) {
0x0006cfa8 bne 0x6d010 |
0x0006cfac ldrb r2, [r3, 1] | r2 = *((r3 + 1));
0x0006cfb0 cmp r2, 0x4b |
| if (r2 != 0x4b) {
0x0006cfb4 bne 0x6d010 | goto label_37;
| }
0x0006cfb8 ldrb r2, [r3, 2] | r2 = *((r3 + 2));
0x0006cfbc add lr, r3, 2 | lr = r3 + 2;
0x0006cfc0 cmp r2, 5 |
| if (r2 != 5) {
0x0006cfc4 bne 0x6d010 | goto label_37;
| }
0x0006cfc8 ldrb r2, [r3, 3] | r2 = *((r3 + 3));
0x0006cfcc add lr, r3, 3 | lr = r3 + 3;
0x0006cfd0 cmp r2, 6 |
| if (r2 != 6) {
0x0006cfd4 bne 0x6d010 | goto label_37;
| }
0x0006cfd8 ldrb r2, [r3, 0x11] | r2 = *((r3 + 0x11));
0x0006cfdc ldrb ip, [r3, 0x10] | ip = *((r3 + 0x10));
0x0006cfe0 sub sl, lr, r5 | sl = lr - r5;
0x0006cfe4 orr ip, ip, r2, lsl 8 |
0x0006cfe8 ldrb r2, [r3, 0x12] | r2 = *((r3 + 0x12));
0x0006cfec ldrb r3, [r3, 0x13] | r3 = *((r3 + 0x13));
0x0006cff0 orr ip, ip, r2, lsl 16 |
0x0006cff4 orr ip, ip, r3, lsl 24 |
0x0006cff8 adds r2, r8, sl | r2 = r8 + sl;
0x0006cffc adc r3, sb, sl, asr 31 | __asm ("adc r3, sb, sl, asr 31");
0x0006d000 mov r1, 0 | r1 = 0;
0x0006d004 cmp ip, r2 |
0x0006d008 sbcs r3, r1, r3 | __asm ("sbcs r3, r1, r3");
| if (ip < r2) {
0x0006d00c movlt fp, ip | goto label_37;
| }
| }
| label_37:
0x0006d010 mov r3, lr | r3 = lr;
0x0006d014 b 0x6cdd4 | goto label_4;
| label_25:
0x0006d018 ldr r3, [pc, 0x810] | r3 = "cant_open__s_.zip_";
0x0006d01c cmp r1, r3 |
| if (r1 != r3) {
0x0006d020 ldrne r0, [pc, 0x80c] | r0 = "invalid_zip_magic__08X";
| goto label_38;
| }
| if (r1 != r3) {
| label_38:
0x0006d024 bne 0x6cf78 | goto label_5;
| }
0x0006d028 mov r2, 0x1a | r2 = 0x1a;
0x0006d02c add r1, sp, 0x3c | r1 += var_3ch;
0x0006d030 mov r0, 3 | r0 = 3;
0x0006d034 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d038 ldrh r3, [sp, 0x3e] | r3 = var_3eh;
0x0006d03c tst r3, 8 |
| if ((r3 & 8) == 0) {
0x0006d040 beq 0x6d13c | goto label_39;
| }
0x0006d044 ldr r1, [pc, 0x7ec] | r1 = "invalid_zip_magic__08X";
| do {
0x0006d048 ldr r0, [pc, 0x7ec] | r0 = "8 (streaming)";
0x0006d04c b 0x6cf78 | goto label_5;
| label_23:
0x0006d050 mov r7, 0 | r7 = 0;
0x0006d054 mov r3, r7 | r3 = r7;
0x0006d058 mov r2, fp | r2 = fp;
0x0006d05c str r7, [sp] | *(sp) = r7;
0x0006d060 mov r0, 3 | r0 = 3;
0x0006d064 bl 0x18c28 | fcn_00018c28 (r0);
0x0006d068 mov r2, 4 | r2 = 4;
0x0006d06c add r1, sp, 0x3c | r1 += var_3ch;
0x0006d070 mov r0, 3 | r0 = 3;
0x0006d074 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d078 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0006d07c ldr r2, [pc, 0x7bc] | r2 = "zip flag %s is not supported";
0x0006d080 cmp r3, r2 |
| if (r3 == r2) {
0x0006d084 beq 0x6d758 | goto label_24;
| }
0x0006d088 mov r2, 0x2a | r2 = 0x2a;
0x0006d08c add r1, sp, 0x58 | r1 += s;
0x0006d090 mov r0, 3 | r0 = 3;
0x0006d094 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d098 ldrh r3, [sp, 0x70] | r3 = var_70h;
0x0006d09c ldrh r2, [sp, 0x72] | r2 = var_72h;
0x0006d0a0 add r3, r3, 0x2e | r3 += 0x2e;
0x0006d0a4 add r3, r3, r2 | r3 += r2;
0x0006d0a8 ldrh r2, [sp, 0x74] | r2 = var_74h;
0x0006d0ac add r3, r3, r2 | r3 += r2;
0x0006d0b0 adds fp, fp, r3 |
| if (fp == fp) {
0x0006d0b4 beq 0x6d758 | goto label_24;
| }
0x0006d0b8 ldrh r3, [sp, 0x80] | r3 = var_80h;
0x0006d0bc ldrh r2, [sp, 0x7e] | r2 = var_7eh;
0x0006d0c0 str r7, [sp] | *(sp) = r7;
0x0006d0c4 orr r2, r2, r3, lsl 16 | r2 |= (r3 << 16);
0x0006d0c8 add r2, r2, 4 | r2 += 4;
0x0006d0cc mov r3, r7 | r3 = r7;
0x0006d0d0 mov r0, 3 | r0 = 3;
0x0006d0d4 bl 0x18c28 | fcn_00018c28 (r0);
0x0006d0d8 mov r2, 0x1a | r2 = 0x1a;
0x0006d0dc add r1, sp, 0x3c | r1 += var_3ch;
0x0006d0e0 mov r0, 3 | r0 = 3;
0x0006d0e4 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d0e8 ldrh r3, [sp, 0x3e] | r3 = var_3eh;
0x0006d0ec tst r3, 8 |
| if ((r3 & 8) != 0) {
0x0006d0f0 beq 0x6d124 |
0x0006d0f4 ldrh r3, [sp, 0x64] | r3 = var_64h;
0x0006d0f8 strh r3, [sp, 0x46] | var_46h = r3;
0x0006d0fc ldrh r3, [sp, 0x66] | r3 = var_66h;
0x0006d100 strh r3, [sp, 0x48] | var_48h = r3;
0x0006d104 ldrh r3, [sp, 0x68] | r3 = var_68h;
0x0006d108 strh r3, [sp, 0x4a] | var_4ah = r3;
0x0006d10c ldrh r3, [sp, 0x6a] | r3 = var_6ah;
0x0006d110 strh r3, [sp, 0x4c] | var_4ch = r3;
0x0006d114 ldrh r3, [sp, 0x6c] | r3 = var_6ch;
0x0006d118 strh r3, [sp, 0x4e] | var_4eh = r3;
0x0006d11c ldrh r3, [sp, 0x6e] | r3 = var_6eh;
0x0006d120 strh r3, [sp, 0x50] | var_50h = r3;
| }
0x0006d124 ldrh r3, [sp, 0x58] | r3 = s;
0x0006d128 lsr r3, r3, 8 | r3 >>= 8;
0x0006d12c cmp r3, 3 |
0x0006d130 ldrheq r8, [sp, 0x7c] | __asm ("ldrheq r8, [var_7ch]");
| if (r3 != 3) {
0x0006d134 moveq r7, r8 | r7 = r8;
| }
| if (r3 != 3) {
0x0006d138 beq 0x6d144 |
| label_39:
0x0006d13c ldr r7, [pc, 0x700] | r7 = *(0x6d840);
0x0006d140 ldr r8, [pc, 0x700] | r8 = *(0x6d844);
| }
0x0006d144 ldrh sb, [sp, 0x3e] | sb = var_3eh;
0x0006d148 ands sb, sb, 1 | sb &= 1;
| if (sb == sb) {
0x0006d14c ldrne r1, [pc, 0x6f8] | r1 = "1 (encryption)";
| }
0x0006d150 bne 0x6d048 |
| } while (sb != sb);
0x0006d154 mov r0, r5 | r0 = r5;
0x0006d158 bl 0x152a8 | free (r0);
0x0006d15c ldrh r0, [sp, 0x52] | r0 = var_52h;
0x0006d160 ldr r3, [pc, 0x6e8] | r3 = "1 (encryption)";
0x0006d164 cmp r0, r3 |
| if (r0 >= r3) {
0x0006d168 bls 0x6d174 |
| label_12:
0x0006d16c ldr r0, [pc, 0x6e0] | r0 = *(0x6d850);
| label_14:
0x0006d170 bl 0x18254 | r0 = fcn_00018254 ();
| }
0x0006d174 add r0, r0, 1 | r0++;
0x0006d178 bl 0x189b8 | fcn_000189b8 (r0);
0x0006d17c ldrh r2, [sp, 0x52] | r2 = var_52h;
0x0006d180 mov r5, r0 | r5 = r0;
0x0006d184 mov r1, r0 | r1 = r0;
0x0006d188 mov r0, 3 | r0 = 3;
0x0006d18c bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d190 mov r1, sb | r1 = sb;
0x0006d194 ldrh r0, [sp, 0x54] | r0 = var_54h;
0x0006d198 bl 0x6cbc4 | fcn_0006cbc4 (r0, r1);
0x0006d19c mov r0, r5 | r0 = r5;
0x0006d1a0 bl 0x74690 | r0 = fcn_00074690 (r0);
0x0006d1a4 mov r1, r0 | r1 = r0;
0x0006d1a8 mov r0, r5 | r0 = r5;
0x0006d1ac bl 0xa410c | fcn_000a410c (r0, r1);
0x0006d1b0 mov r1, r5 | r1 = r5;
0x0006d1b4 ldr r0, [sp, 0x2c] | r0 = var_2ch;
0x0006d1b8 bl 0x728b0 | r0 = fcn_000728b0 (r0, r1);
0x0006d1bc cmp r0, 0 |
| if (r0 != 0) {
0x0006d1c0 bne 0x6d26c | goto label_8;
| }
0x0006d1c4 ldr r0, [sp, 0x28] | r0 = var_28h;
0x0006d1c8 cmp r0, 0 |
0x0006d1cc bne 0x6d25c |
| while (r0 != 0) {
0x0006d1d0 tst r4, 1 |
| if ((r4 & 1) != 0) {
0x0006d1d4 bne 0x6d284 | goto label_40;
| }
0x0006d1d8 cmp r6, 1 |
| if (r6 == 1) {
0x0006d1dc beq 0x6d58c | goto label_41;
| }
0x0006d1e0 tst r4, 4 |
| if ((r4 & 4) != 0) {
0x0006d1e4 beq 0x6d1fc |
0x0006d1e8 mov r0, r5 | r0 = r5;
0x0006d1ec bl 0x17e94 | r0 = fcn_00017e94 (r0);
0x0006d1f0 mov r1, r0 | r1 = r0;
0x0006d1f4 mov r0, r5 | r0 = r5;
0x0006d1f8 bl 0xa410c | fcn_000a410c (r0, r1);
| }
0x0006d1fc ldrb r3, [r5] | r3 = *(r5);
0x0006d200 cmp r3, 0 |
| if (r3 == 0) {
0x0006d204 beq 0x6d26c | goto label_8;
| }
0x0006d208 mov r1, 0x2f | r1 = 0x2f;
0x0006d20c mov r0, r5 | r0 = r5;
0x0006d210 bl 0x17f40 | r0 = fcn_00017f40 (r0, r1);
0x0006d214 cmp r0, 0 |
| if (r0 != 0) {
0x0006d218 bne 0x6d40c | goto label_42;
| }
0x0006d21c ldr sb, [pc, 0x634] | sb = "replace__s___y_es___n_o___A_ll___N_one___r_ename:_";
0x0006d220 ldr r8, [pc, 0x634] | r8 = "replace__s___y_es___n_o___A_ll___N_one___r_ename:_";
| label_10:
0x0006d224 mov r0, r5 | r0 = r5;
0x0006d228 bl 0x6cb40 | r0 = fcn_0006cb40 (r0);
0x0006d22c cmn r0, 1 |
| if (r0 == 1) {
0x0006d230 beq 0x6d4fc | goto label_43;
| }
0x0006d234 ldr r3, [sp, 0x10] | r3 = var_10h;
0x0006d238 cmp r3, 1 |
| if (r3 == 1) {
0x0006d23c beq 0x6d26c | goto label_8;
| }
0x0006d240 and r0, r0, 0xf000 | r0 &= 0xf000;
0x0006d244 cmp r0, 0x8000 |
| if (r0 == 0x8000) {
0x0006d248 beq 0x6d484 | goto label_44;
| }
| label_9:
0x0006d24c mov r0, r5 | r0 = r5;
0x0006d250 bl 0xa14d4 | fcn_000a14d4 (r0);
0x0006d254 ldr r2, [pc, 0x604] | r2 = "new_name:_";
0x0006d258 b 0x6d478 | goto label_45;
0x0006d25c mov r1, r5 | r1 = r5;
0x0006d260 bl 0x728b0 | r0 = fcn_000728b0 (r0, r1);
0x0006d264 cmp r0, 0 |
0x0006d268 bne 0x6d1d0 |
| }
| do {
| label_8:
0x0006d26c ldrh r3, [sp, 0x4a] | r3 = var_4ah;
0x0006d270 ldrh r0, [sp, 0x4c] | r0 = var_4ch;
0x0006d274 mov r1, 0 | r1 = 0;
0x0006d278 orr r0, r3, r0, lsl 16 | r0 = r3 | (r0 << 16);
0x0006d27c bl 0x6cbc4 | fcn_0006cbc4 (r0, r1);
0x0006d280 b 0x6d620 | goto label_46;
| label_40:
0x0006d284 ldrh r1, [sp, 0x42] | r1 = format;
0x0006d288 ldrh r3, [sp, 0x44] | r3 = var_44h;
0x0006d28c lsr r0, r1, 5 | r0 = r1 >> 5;
0x0006d290 lsr r1, r1, 0xb | r1 >>= 0xb;
0x0006d294 str r1, [sp, 4] | var_4h = r1;
0x0006d298 lsr r1, r3, 9 | r1 = r3 >> 9;
0x0006d29c add r1, r1, 0x7b0 | r1 += 0x7b0;
0x0006d2a0 lsr r2, r3, 5 | r2 = r3 >> 5;
0x0006d2a4 and r0, r0, 0x3f | r0 &= 0x3f;
0x0006d2a8 add r1, r1, 0xc | r1 += 0xc;
0x0006d2ac str r0, [sp, 8] | var_8h = r0;
0x0006d2b0 str r1, [sp] | *(sp) = r1;
0x0006d2b4 and r3, r3, 0x1f | r3 &= 0x1f;
0x0006d2b8 and r2, r2, 0xf | r2 &= 0xf;
0x0006d2bc ldr r1, [pc, 0x5a0] | r1 = "regular_file";
0x0006d2c0 add r0, sp, 0x58 | r0 += s;
0x0006d2c4 bl 0x14f48 | sprintf (r0, "regular_file", r2)
0x0006d2c8 ldr r3, [sp, 0x18] | r3 = var_18h;
0x0006d2cc cmp r3, 0 |
| if (r3 != 0) {
0x0006d2d0 bne 0x6d310 | goto label_47;
| }
0x0006d2d4 ldrh r1, [sp, 0x50] | r1 = var_50h;
0x0006d2d8 ldrh r7, [sp, 0x4e] | r7 = var_4eh;
0x0006d2dc mov r0, r5 | r0 = r5;
0x0006d2e0 orr r7, r7, r1, lsl 16 | r7 |= (r1 << 16);
0x0006d2e4 bl 0xa14d4 | fcn_000a14d4 (r0);
0x0006d2e8 add r2, sp, 0x58 | r2 += s;
0x0006d2ec mov r1, r7 | r1 = r7;
0x0006d2f0 mov r3, r0 | r3 = r0;
0x0006d2f4 ldr r0, [pc, 0x56c] | r0 = "%02u-%02u-%04u %02u:%02u";
0x0006d2f8 bl 0x1436c | printf ("%02u-%02u-%04u %02u:%02u", r1, r2, r3);
| label_6:
0x0006d2fc ldrh r3, [sp, 0x4e] | r3 = var_4eh;
0x0006d300 ldrh r2, [sp, 0x50] | r2 = var_50h;
0x0006d304 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0006d308 add sl, sl, r3 | sl += r3;
0x0006d30c b 0x6d26c |
| } while (1);
| label_47:
0x0006d310 ldrh r2, [sp, 0x40] | r2 = var_40h;
0x0006d314 ldr r1, [pc, 0x550] | r1 = "_9u___s____s";
0x0006d318 add r0, sp, 0x34 | r0 += dest;
0x0006d31c bl 0x14f48 | sprintf (r0, "_9u___s____s", r2)
0x0006d320 ldrh r3, [sp, 0x40] | r3 = var_40h;
0x0006d324 cmp r3, 0 |
| if (r3 != 0) {
0x0006d328 bne 0x6d3dc | goto label_48;
| }
0x0006d32c ldr r1, [pc, 0x53c] | r1 = "_6u";
0x0006d330 add r0, sp, 0x34 | r0 += dest;
0x0006d334 bl 0x142f4 | strcpy (r0, "_6u");
| do {
| label_7:
0x0006d338 ldrh r3, [sp, 0x50] | r3 = var_50h;
0x0006d33c ldrh r7, [sp, 0x4e] | r7 = var_4eh;
0x0006d340 ldrh r8, [sp, 0x4a] | r8 = var_4ah;
0x0006d344 orr r7, r7, r3, lsl 16 | r7 |= (r3 << 16);
0x0006d348 ldrh r3, [sp, 0x4c] | r3 = var_4ch;
0x0006d34c cmp r7, 0 |
0x0006d350 orr r8, r8, r3, lsl 16 | r8 |= (r3 << 16);
0x0006d354 sub sb, r7, r8 | sb = r7 - r8;
0x0006d358 bic sb, sb, sb, asr 31 | sb = BIT_MASK (sb, sb);
0x0006d35c mov r3, 0x64 | r3 = 0x64;
0x0006d360 mul r2, r3, sb | r2 = r3 * sb;
0x0006d364 mov sb, r2 | sb = r2;
| if (r7 != 0) {
0x0006d368 beq 0x6d37c |
0x0006d36c mov r1, r7 | r1 = r7;
0x0006d370 mov r0, r2 | r0 = r2;
0x0006d374 bl 0xa65d4 | r0 = fcn_000a65d4 (r0, r1);
0x0006d378 mov sb, r0 | sb = r0;
| }
0x0006d37c ldrh r2, [sp, 0x48] | r2 = var_48h;
0x0006d380 ldrh r3, [sp, 0x46] | r3 = var_46h;
0x0006d384 mov r0, r5 | r0 = r5;
0x0006d388 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0006d38c str r3, [sp, 0x24] | var_24h = r3;
0x0006d390 bl 0xa14d4 | fcn_000a14d4 (r0);
0x0006d394 ldr r3, [sp, 0x24] | r3 = var_24h;
0x0006d398 add r2, sp, 0x34 | r2 += dest;
0x0006d39c str r3, [sp, 8] | var_8h = r3;
0x0006d3a0 add r3, sp, 0x58 | r3 += s;
0x0006d3a4 str r3, [sp, 4] | var_4h = r3;
0x0006d3a8 str sb, [sp] | *(sp) = sb;
0x0006d3ac mov r3, r8 | r3 = r8;
0x0006d3b0 mov r1, r7 | r1 = r7;
0x0006d3b4 str r0, [sp, 0xc] | var_ch = r0;
0x0006d3b8 ldr r0, [pc, 0x4b4] | r0 = "Stored";
0x0006d3bc bl 0x1436c | printf (r0, r1, r2, r3);
0x0006d3c0 ldrh r2, [sp, 0x4c] | r2 = var_4ch;
0x0006d3c4 ldrh r3, [sp, 0x4a] | r3 = var_4ah;
0x0006d3c8 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0006d3cc ldr r2, [sp, 0x20] | r2 = var_20h;
0x0006d3d0 add r3, r2, r3 | r3 = r2 + r3;
0x0006d3d4 str r3, [sp, 0x20] | var_20h = r3;
0x0006d3d8 b 0x6d2fc | goto label_6;
| label_48:
0x0006d3dc cmp r3, 8 |
0x0006d3e0 bne 0x6d338 |
| } while (r3 != 8);
0x0006d3e4 ldr r1, [pc, 0x48c] | r1 = "_8u___s_9u_4u____s__08x___s";
0x0006d3e8 add r0, sp, 0x34 | r0 += dest;
0x0006d3ec bl 0x142f4 | strcpy (r0, "_8u___s_9u_4u____s__08x___s");
0x0006d3f0 ldrh r3, [sp, 0x3e] | r3 = var_3eh;
0x0006d3f4 ldr r2, [pc, 0x480] | r2 = "Defl:N";
0x0006d3f8 lsl r3, r3, 0xf | r3 <<= 0xf;
0x0006d3fc and r3, r3, 0x30000 | r3 &= 0x30000;
0x0006d400 ldrb r3, [r2, r3, lsr 16] | offset_0 = r3 >> 16;
| r3 = *((r2 + offset_0));
0x0006d404 strb r3, [sp, 0x39] | var_39h = r3;
0x0006d408 b 0x6d338 | goto label_7;
| label_42:
0x0006d40c mov r0, r5 | r0 = r5;
0x0006d410 bl 0x6cb40 | r0 = fcn_0006cb40 (r0);
0x0006d414 cmn r0, 1 |
| if (r0 != 1) {
0x0006d418 bne 0x6d460 | goto label_49;
| }
0x0006d41c ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006d420 cmp r3, 0 |
| if (r3 == 0) {
0x0006d424 bne 0x6d43c |
0x0006d428 mov r0, r5 | r0 = r5;
0x0006d42c bl 0xa14d4 | r0 = fcn_000a14d4 (r0);
0x0006d430 mov r1, r0 | r1 = r0;
0x0006d434 ldr r0, [pc, 0x444] | r0 = "NXFS";
0x0006d438 bl 0x1436c | printf ("NXFS", r1);
| }
0x0006d43c mov r0, r5 | r0 = r5;
0x0006d440 bl 0x6cb90 | fcn_0006cb90 (r0);
0x0006d444 mov r2, 0x80000000 | r2 = 0x80000000;
0x0006d448 mov r1, r8 | r1 = r8;
0x0006d44c mov r0, r5 | r0 = r5;
0x0006d450 bl 0xa0518 | r0 = fcn_000a0518 (r0, r1, r2);
0x0006d454 cmp r0, 0 |
| if (r0 == 0) {
0x0006d458 beq 0x6d26c | goto label_8;
| }
0x0006d45c bl 0x182a0 | r0 = fcn_000182a0 ();
| label_49:
0x0006d460 and r0, r0, 0xf000 | r0 &= 0xf000;
0x0006d464 cmp r0, 0x4000 |
| if (r0 == 0x4000) {
0x0006d468 beq 0x6d26c | goto label_8;
| }
0x0006d46c mov r0, r5 | r0 = r5;
0x0006d470 bl 0xa14d4 | fcn_000a14d4 (r0);
0x0006d474 ldr r2, [pc, 0x408] | r2 = " creating: %s\n";
| label_45:
0x0006d478 mov r1, r0 | r1 = r0;
0x0006d47c ldr r0, [pc, 0x404] | r0 = *(0x6d884);
0x0006d480 bl 0x18254 | fcn_00018254 ();
| label_44:
0x0006d484 ldr r3, [sp, 0x10] | r3 = var_10h;
0x0006d488 cmp r3, 2 |
| if (r3 == 2) {
0x0006d48c beq 0x6d4fc | goto label_43;
| }
0x0006d490 mov r0, r5 | r0 = r5;
0x0006d494 bl 0xa14d4 | r0 = fcn_000a14d4 (r0);
0x0006d498 mov r1, r0 | r1 = r0;
0x0006d49c mov r0, sb | r0 = sb;
0x0006d4a0 bl 0x1436c | printf (r0, r1);
0x0006d4a4 add r0, sp, 0x90 | r0 += var_90h;
0x0006d4a8 bl 0x6cc28 | fcn_0006cc28 (r0);
0x0006d4ac mov r0, r5 | r0 = r5;
0x0006d4b0 bl 0x6cb40 | r0 = fcn_0006cb40 (r0);
0x0006d4b4 and r0, r0, 0xf000 | r0 &= 0xf000;
0x0006d4b8 cmp r0, 0x8000 |
| if (r0 != 0x8000) {
0x0006d4bc bne 0x6d24c | goto label_9;
| }
0x0006d4c0 ldrb r1, [sp, 0x90] | r1 = var_90h;
0x0006d4c4 cmp r1, 0x6e |
| if (r1 == 0x6e) {
0x0006d4c8 beq 0x6d26c | goto label_8;
| }
| if (r1 > 0x6e) {
0x0006d4cc bhi 0x6d4ec | goto label_50;
| }
0x0006d4d0 cmp r1, 0x41 |
| if (r1 == 0x41) {
0x0006d4d4 beq 0x6d580 | goto label_51;
| }
0x0006d4d8 cmp r1, 0x4e |
| if (r1 == 0x4e) {
0x0006d4dc beq 0x6d574 | goto label_52;
| }
| do {
0x0006d4e0 ldr r0, [pc, 0x3a4] | r0 = "__s_exists_but_is_not_a__s";
0x0006d4e4 bl 0x1436c | printf ("__s_exists_but_is_not_a__s");
0x0006d4e8 b 0x6d224 | goto label_10;
| label_50:
0x0006d4ec cmp r1, 0x72 |
| if (r1 == 0x72) {
0x0006d4f0 beq 0x6d72c | goto label_53;
| }
0x0006d4f4 cmp r1, 0x79 |
0x0006d4f8 bne 0x6d4e0 |
| } while (r1 != 0x79);
| do {
| label_43:
0x0006d4fc mov r0, r5 | r0 = r5;
0x0006d500 bl 0x6cb90 | fcn_0006cb90 (r0);
0x0006d504 and r3, r7, 0xf000 | r3 = r7 & 0xf000;
0x0006d508 cmp r3, 0xa000 |
| if (r3 == 0xa000) {
0x0006d50c beq 0x6d7fc | goto label_54;
| }
0x0006d510 mov r2, r7 | r2 = r7;
0x0006d514 ldr r1, [pc, 0x374] | r1 = "error: invalid response [%c]\n";
0x0006d518 mov r0, r5 | r0 = r5;
0x0006d51c bl 0x18a90 | fcn_00018a90 (r0);
0x0006d520 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006d524 cmp r3, 0 |
0x0006d528 mov r6, r0 | r6 = r0;
| if (r3 == 0) {
0x0006d52c beq 0x6d598 | goto label_17;
| }
| label_11:
0x0006d530 ldrh r3, [sp, 0x40] | r3 = var_40h;
0x0006d534 cmp r3, 0 |
| if (r3 != 0) {
0x0006d538 bne 0x6d638 | goto label_55;
| }
0x0006d53c ldrh r3, [sp, 0x50] | r3 = var_50h;
0x0006d540 ldrh r2, [sp, 0x4e] | r2 = var_4eh;
0x0006d544 orr r2, r2, r3, lsl 16 | r2 |= (r3 << 16);
0x0006d548 mov r3, 0 | r3 = 0;
0x0006d54c orrs r1, r2, r3 | r1 = r2 | r3;
| if (r1 != r2) {
0x0006d550 beq 0x6d560 |
0x0006d554 mov r1, r6 | r1 = r6;
0x0006d558 mov r0, 3 | r0 = 3;
0x0006d55c bl 0x195d0 | fcn_000195d0 (r0, r1);
| }
| label_15:
0x0006d560 cmp r6, 1 |
| if (r6 == 1) {
0x0006d564 beq 0x6d620 | goto label_46;
| }
0x0006d568 mov r0, r6 | r0 = r6;
0x0006d56c bl 0x15260 | close (r0);
0x0006d570 b 0x6d620 | goto label_46;
| label_52:
0x0006d574 mov r3, 1 | r3 = 1;
0x0006d578 str r3, [sp, 0x10] | var_10h = r3;
0x0006d57c b 0x6d26c | goto label_8;
| label_51:
0x0006d580 mov r3, 2 | r3 = 2;
0x0006d584 str r3, [sp, 0x10] | var_10h = r3;
0x0006d588 b 0x6d4fc |
| } while (1);
| label_41:
0x0006d58c ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006d590 cmp r3, 0 |
| if (r3 == 0) {
0x0006d594 bne 0x6d5ac |
| label_17:
0x0006d598 mov r0, r5 | r0 = r5;
0x0006d59c bl 0xa14d4 | r0 = fcn_000a14d4 (r0);
0x0006d5a0 mov r1, r0 | r1 = r0;
0x0006d5a4 ldr r0, [pc, 0x2e8] | r0 = *(0x6d890);
0x0006d5a8 bl 0x1436c | printf (r0, r1);
| }
0x0006d5ac and r7, r7, 0xf000 | r7 &= 0xf000;
0x0006d5b0 cmp r7, 0xa000 |
| if (r7 != 0xa000) {
0x0006d5b4 bne 0x6d530 | goto label_11;
| }
0x0006d5b8 cmp r6, 1 |
| if (r6 == 1) {
0x0006d5bc beq 0x6d620 | goto label_46;
| }
| label_18:
0x0006d5c0 ldrh r0, [sp, 0x4e] | r0 = var_4eh;
0x0006d5c4 ldrh r3, [sp, 0x50] | r3 = var_50h;
0x0006d5c8 orr r0, r0, r3, lsl 16 | r0 |= (r3 << 16);
0x0006d5cc cmp r0, 0x1000 |
| if (r0 >= 0x1000) {
0x0006d5d0 bhs 0x6d16c | goto label_12;
| }
0x0006d5d4 ldrh r8, [sp, 0x40] | r8 = var_40h;
0x0006d5d8 cmp r8, 0 |
| if (r8 == 0) {
0x0006d5dc bne 0x6d630 |
0x0006d5e0 add r0, r0, 1 | r0++;
0x0006d5e4 bl 0x189b8 | fcn_000189b8 (r0);
0x0006d5e8 ldrh r3, [sp, 0x4e] | r3 = var_4eh;
0x0006d5ec ldrh r2, [sp, 0x50] | r2 = var_50h;
0x0006d5f0 orr r2, r3, r2, lsl 16 | r2 = r3 | (r2 << 16);
0x0006d5f4 mov r7, r0 | r7 = r0;
0x0006d5f8 mov r1, r0 | r1 = r0;
0x0006d5fc mov r0, 3 | r0 = 3;
0x0006d600 bl 0xa3804 | fcn_000a3804 (r0, r1);
0x0006d604 add r0, sp, 0x30 | r0 += var_30h;
0x0006d608 mov r3, r8 | r3 = r8;
0x0006d60c mov r2, r5 | r2 = r5;
0x0006d610 mov r1, r7 | r1 = r7;
0x0006d614 bl 0x74728 | fcn_00074728 (r0, r1);
0x0006d618 mov r0, r7 | r0 = r7;
0x0006d61c bl 0x152a8 | free (r0);
| label_46:
0x0006d620 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0006d624 add r3, r3, 1 | r3++;
0x0006d628 str r3, [sp, 0x1c] | var_1ch = r3;
0x0006d62c b 0x6cdf4 | goto label_13;
| }
0x0006d630 ldr r0, [pc, 0x260] | r0 = " inflating: %s\n";
0x0006d634 b 0x6d170 | goto label_14;
| label_55:
0x0006d638 add r0, sp, 0x58 | r0 += s;
0x0006d63c bl 0x74474 | fcn_00074474 ();
0x0006d640 ldrh r3, [sp, 0x4a] | r3 = var_4ah;
0x0006d644 ldrh r2, [sp, 0x4c] | r2 = var_4ch;
0x0006d648 ldrh r1, [sp, 0x40] | r1 = var_40h;
0x0006d64c orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x0006d650 str r3, [sp, 0x80] | var_80h = r3;
0x0006d654 mov r3, 0 | r3 = 0;
0x0006d658 str r3, [sp, 0x84] | var_84h = r3;
0x0006d65c cmp r1, 8 |
0x0006d660 mov r3, 3 | r3 = 3;
0x0006d664 str r3, [sp, 0x60] | var_60h = r3;
0x0006d668 str r6, [sp, 0x64] | var_64h = r6;
| if (r1 != 8) {
0x0006d66c bne 0x6d6b0 | goto label_56;
| }
0x0006d670 add r0, sp, 0x58 | r0 += s;
0x0006d674 bl 0x6fe04 | r0 = fcn_0006fe04 (r0);
0x0006d678 cmp r0, 0 |
0x0006d67c sbcs r3, r1, 0 | __asm ("sbcs r3, r1, 0");
0x0006d680 bge 0x6d68c |
| while (r0 < 0) {
0x0006d684 ldr r0, [pc, 0x210] | r0 = "compressed_symlink_is_not_supported";
0x0006d688 b 0x6d170 | goto label_14;
0x0006d68c ldrh r3, [sp, 0x48] | r3 = var_48h;
0x0006d690 ldrh r2, [sp, 0x46] | r2 = var_46h;
0x0006d694 orr r2, r2, r3, lsl 16 | r2 |= (r3 << 16);
0x0006d698 ldr r3, [sp, 0x88] | r3 = var_88h;
0x0006d69c mvn r3, r3 | r3 = ~r3;
0x0006d6a0 cmp r2, r3 |
| if (r2 == r3) {
0x0006d6a4 beq 0x6d6d0 | goto label_57;
| }
0x0006d6a8 ldr r0, [pc, 0x1f0] | r0 = "inflate_error";
0x0006d6ac b 0x6d170 | goto label_14;
| label_56:
0x0006d6b0 cmp r1, 0xc |
| if (r1 != 0xc) {
0x0006d6b4 bne 0x6d6fc | goto label_58;
| }
0x0006d6b8 add r0, sp, 0x58 | r0 += s;
0x0006d6bc bl 0x6e858 | r0 = fcn_0006e858 (r0);
| label_16:
0x0006d6c0 cmp r0, 0 |
0x0006d6c4 sbcs r3, r1, 0 | __asm ("sbcs r3, r1, 0");
0x0006d6c8 strd r0, r1, [sp, 0x78] | __asm ("strd r0, r1, [var_7ch]");
0x0006d6cc blt 0x6d684 |
| }
| label_57:
0x0006d6d0 ldrh r3, [sp, 0x50] | r3 = var_50h;
0x0006d6d4 ldrh r0, [sp, 0x4e] | r0 = var_4eh;
0x0006d6d8 mov r1, 0 | r1 = 0;
0x0006d6dc orr r0, r0, r3, lsl 16 | r0 |= (r3 << 16);
0x0006d6e0 ldrd r2, r3, [sp, 0x78] | __asm ("ldrd r2, r3, [var_7ch]");
0x0006d6e4 cmp r1, r3 |
0x0006d6e8 cmpeq r0, r2 | __asm ("cmpeq r0, r2");
| if (r1 == r3) {
0x0006d6ec beq 0x6d560 | goto label_15;
| }
0x0006d6f0 ldr r0, [pc, 0x1ac] | r0 = "crc_error";
0x0006d6f4 bl 0x18274 | fcn_00018274 ();
0x0006d6f8 b 0x6d560 | goto label_15;
| label_58:
0x0006d6fc cmp r1, 0xe |
| if (r1 == 0xe) {
0x0006d700 bne 0x6d710 |
0x0006d704 add r0, sp, 0x58 | r0 += s;
0x0006d708 bl 0x70238 | fcn_00070238 (r0, r1);
0x0006d70c b 0x6d6c0 | goto label_16;
| }
0x0006d710 cmp r1, 0x5f |
| if (r1 == 0x5f) {
0x0006d714 bne 0x6d724 |
0x0006d718 add r0, sp, 0x58 | r0 += s;
0x0006d71c bl 0x71e0c | fcn_00071e0c (r0, r1);
0x0006d720 b 0x6d6c0 | goto label_16;
| }
0x0006d724 ldr r0, [pc, 0x17c] | r0 = "bad_length";
0x0006d728 b 0x6cf78 | goto label_5;
| label_53:
0x0006d72c mov r0, r8 | r0 = r8;
0x0006d730 bl 0x1436c | printf (r0);
0x0006d734 add r0, sp, 0x90 | r0 += var_90h;
0x0006d738 bl 0x6cc28 | fcn_0006cc28 (r0);
0x0006d73c mov r0, r5 | r0 = r5;
0x0006d740 bl 0x152a8 | free (r0);
0x0006d744 add r0, sp, 0x90 | r0 += var_90h;
0x0006d748 bl 0x189d4 | r0 = fcn_000189d4 (r0);
0x0006d74c mov r5, r0 | r5 = r0;
0x0006d750 bl 0x98be4 | fcn_00098be4 (r0);
0x0006d754 b 0x6d224 | goto label_10;
| label_24:
0x0006d758 ldr r0, [sp, 0x30] | r0 = var_30h;
0x0006d75c bl 0x747cc | fcn_000747cc (r0);
0x0006d760 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006d764 cmp r3, 1 |
| if (r3 <= 1) {
0x0006d768 movgt r4, 0 | r4 = 0;
| }
| if (r3 > 1) {
0x0006d76c andle r4, r4, 1 | r4 &= 1;
| }
0x0006d770 cmp r4, 0 |
| if (r4 == 0) {
0x0006d774 beq 0x6d7a0 | goto label_59;
| }
0x0006d778 ldr r3, [sp, 0x18] | r3 = var_18h;
0x0006d77c cmp r3, 0 |
| if (r3 != 0) {
0x0006d780 bne 0x6d7ac | goto label_60;
| }
0x0006d784 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0006d788 mov r2, sl | r2 = sl;
0x0006d78c str r3, [sp] | *(sp) = r3;
0x0006d790 ldr r3, [pc, 0x114] | r3 = "unsupported_method__u";
0x0006d794 ldr r0, [pc, 0x114] | r0 = *(0x6d8ac);
0x0006d798 mov r1, r3 | r1 = r3;
0x0006d79c bl 0x1436c | printf (r0, r1, r2, r3);
| do {
| label_59:
0x0006d7a0 mov r0, 0 | r0 = 0;
0x0006d7a4 add sp, sp, 0xe4 |
0x0006d7a8 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_60:
0x0006d7ac ldr r3, [sp, 0x20] | r3 = var_20h;
0x0006d7b0 cmp sl, 0 |
0x0006d7b4 sub r0, sl, r3 | r0 = sl - r3;
0x0006d7b8 bic r0, r0, r0, asr 31 | r0 = BIT_MASK (r0, r0);
0x0006d7bc mov r3, 0x64 | r3 = 0x64;
0x0006d7c0 mul r2, r3, r0 | r2 = r3 * r0;
| if (sl != 0) {
0x0006d7c4 beq 0x6d7d8 |
0x0006d7c8 mov r0, r2 | r0 = r2;
0x0006d7cc mov r1, sl | r1 = sl;
0x0006d7d0 bl 0xa65d4 | r0 = fcn_000a65d4 (r0, r1);
0x0006d7d4 mov r2, r0 | r2 = r0;
| }
0x0006d7d8 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0006d7dc ldr r1, [pc, 0xc8] | r1 = "unsupported_method__u";
0x0006d7e0 str r2, [sp] | *(sp) = r2;
0x0006d7e4 stmib sp, {r1, r3} | __asm ("stmib sp, {r1, r3}");
0x0006d7e8 ldr r0, [pc, 0xc4] | r0 = " --------%21s-------\n%9lu%21s%u files\n";
0x0006d7ec ldr r3, [sp, 0x20] | r3 = var_20h;
0x0006d7f0 mov r2, sl | r2 = sl;
0x0006d7f4 bl 0x1436c | printf (" --------%21s-------\n%9lu%21s%u files\n", "unsupported_method__u", r2, r3);
0x0006d7f8 b 0x6d7a0 |
| } while (1);
| label_54:
0x0006d7fc ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006d800 mvn r6, 0 | r6 = ~0;
0x0006d804 cmp r3, 0 |
| if (r3 == 0) {
0x0006d808 beq 0x6d598 | goto label_17;
| }
0x0006d80c b 0x6d5c0 | goto label_18;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x83dfc */
| #include <stdint.h>
|
; (fcn) fcn.00083dfc () | void fcn_00083dfc (int32_t arg1) {
| char * s;
| int32_t var_3h;
| char * ptr;
| char * s1;
| int32_t var_30h;
| int32_t var_37h;
| int32_t var_80h;
| r0 = arg1;
0x00083dfc push {r4, r5, r6, r7, r8, lr} |
0x00083e00 ldr r4, [pc, 0x2c4] | r4 = *(0x840c8);
0x00083e04 sub sp, sp, 0x80 |
0x00083e08 ldrb r2, [r4, 0xd] | r2 = *((r4 + 0xd));
0x00083e0c ldrb r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x00083e10 mov r5, r0 | r5 = r0;
0x00083e14 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00083e18 ldrb r2, [r4, 0xe] | r2 = *((r4 + 0xe));
0x00083e1c orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00083e20 ldrb r2, [r4, 0xf] | r2 = *((r4 + 0xf));
0x00083e24 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 != r3) {
0x00083e28 beq 0x83f50 |
0x00083e2c mov r2, r0 | r2 = r0;
0x00083e30 ldr r1, [pc, 0x298] | r1 = *(0x840cc);
0x00083e34 add r0, sp, 0x18 | r0 += ptr;
0x00083e38 bl 0x14f48 | sprintf (r0, r1, r2)
0x00083e3c add r3, sp, 0x18 | r3 += ptr;
0x00083e40 sub r0, r0, 3 | r0 -= var_3h;
0x00083e44 add r7, r3, r0 | r7 = r3 + r0;
0x00083e48 mov r0, r3 | r0 = r3;
0x00083e4c bl 0x19208 | fcn_00019208 (r0);
0x00083e50 subs r8, r0, 0 | r8 -= ptr;
| if (r8 != ptr) {
0x00083e54 moveq r6, r8 | r6 = r8;
| }
| if (r8 != ptr) {
0x00083e58 beq 0x83e88 |
0x00083e5c ldrb r0, [r4, 0xd] | r0 = *((r4 + 0xd));
0x00083e60 ldrb r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x00083e64 mov r1, r8 | r1 = r8;
0x00083e68 orr r3, r3, r0, lsl 8 | r3 |= (r0 << 8);
0x00083e6c ldrb r0, [r4, 0xe] | r0 = *((r4 + 0xe));
0x00083e70 orr r3, r3, r0, lsl 16 | r3 |= (r0 << 16);
0x00083e74 ldrb r0, [r4, 0xf] | r0 = *((r4 + 0xf));
0x00083e78 orr r0, r3, r0, lsl 24 | r0 = r3 | (r0 << 24);
0x00083e7c bl 0x14ed0 | r0 = strcmp (r0, r1);
0x00083e80 clz r6, r0 | r6 &= r0;
0x00083e84 lsr r6, r6, 5 | r6 >>= 5;
| }
0x00083e88 mov r0, r8 | r0 = r8;
0x00083e8c bl 0x152a8 | free (r0);
0x00083e90 cmp r6, 0 |
| if (r6 != 0) {
0x00083e94 bne 0x83f50 | goto label_2;
| }
0x00083e98 ldr r1, [pc, 0x234] | r1 = "/proc/%u/exe";
0x00083e9c mov r0, r7 | r0 = r7;
0x00083ea0 bl 0x142f4 | strcpy (r0, "/proc/%u/exe");
0x00083ea4 ldrb r3, [r4, 0x19] | r3 = *((r4 + 0x19));
0x00083ea8 ldrb r2, [r4, 0x18] | r2 = *((r4 + 0x18));
0x00083eac ldrb r1, [r4, 0x15] | r1 = *((r4 + 0x15));
0x00083eb0 orr r2, r2, r3, lsl 8 | r2 |= (r3 << 8);
0x00083eb4 ldrb r3, [r4, 0x1a] | r3 = *((r4 + 0x1a));
0x00083eb8 ldrb r0, [r4, 0x1b] | r0 = *((r4 + 0x1b));
0x00083ebc orr r2, r2, r3, lsl 16 | r2 |= (r3 << 16);
0x00083ec0 ldrb r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x00083ec4 orr r2, r2, r0, lsl 24 | r2 |= (r0 << 24);
0x00083ec8 orr r3, r3, r1, lsl 8 | r3 |= (r1 << 8);
0x00083ecc ldrb r1, [r4, 0x16] | r1 = *((r4 + 0x16));
0x00083ed0 add r0, sp, 0x18 | r0 += ptr;
0x00083ed4 orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x00083ed8 ldrb r1, [r4, 0x17] | r1 = *((r4 + 0x17));
0x00083edc orr r1, r3, r1, lsl 24 | r1 = r3 | (r1 << 24);
0x00083ee0 bl 0x19740 | r0 = fcn_00019740 (r0);
0x00083ee4 cmp r0, 0 |
| if (r0 <= 0) {
0x00083ee8 ble 0x84074 | goto label_1;
| }
0x00083eec ldrb r2, [r4, 0x15] | r2 = *((r4 + 0x15));
0x00083ef0 ldrb r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x00083ef4 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00083ef8 ldrb r2, [r4, 0x16] | r2 = *((r4 + 0x16));
0x00083efc orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00083f00 ldrb r2, [r4, 0x17] | r2 = *((r4 + 0x17));
0x00083f04 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x00083f08 strb r6, [r3, r0] | *((r3 + r0)) = r6;
0x00083f0c ldrb r1, [r4, 0x15] | r1 = *((r4 + 0x15));
0x00083f10 ldrb r0, [r4, 0xd] | r0 = *((r4 + 0xd));
0x00083f14 ldrb r2, [r4, 0x14] | r2 = *((r4 + 0x14));
0x00083f18 ldrb r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x00083f1c orr r2, r2, r1, lsl 8 | r2 |= (r1 << 8);
0x00083f20 orr r3, r3, r0, lsl 8 | r3 |= (r0 << 8);
0x00083f24 ldrb r1, [r4, 0x16] | r1 = *((r4 + 0x16));
0x00083f28 ldrb r0, [r4, 0xe] | r0 = *((r4 + 0xe));
0x00083f2c orr r2, r2, r1, lsl 16 | r2 |= (r1 << 16);
0x00083f30 orr r3, r3, r0, lsl 16 | r3 |= (r0 << 16);
0x00083f34 ldrb r1, [r4, 0x17] | r1 = *((r4 + 0x17));
0x00083f38 ldrb r0, [r4, 0xf] | r0 = *((r4 + 0xf));
0x00083f3c orr r1, r2, r1, lsl 24 | r1 = r2 | (r1 << 24);
0x00083f40 orr r0, r3, r0, lsl 24 | r0 = r3 | (r0 << 24);
0x00083f44 bl 0x14ed0 | r0 = strcmp (r0, r1);
0x00083f48 cmp r0, 0 |
| if (r0 != 0) {
0x00083f4c bne 0x84074 | goto label_1;
| }
| }
| label_2:
0x00083f50 ldrb r2, [r4, 9] | r2 = *((r4 + 9));
0x00083f54 ldrb r3, [r4, 8] | r3 = *((r4 + 8));
0x00083f58 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00083f5c ldrb r2, [r4, 0xa] | r2 = *((r4 + 0xa));
0x00083f60 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00083f64 ldrb r2, [r4, 0xb] | r2 = *((r4 + 0xb));
0x00083f68 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x00083f6c bne 0x83fd8 |
| while (r0 == r7) {
0x00083f70 ldrb r2, [r4, 5] | r2 = *((r4 + 5));
0x00083f74 ldrb r3, [r4, 4] | r3 = *((r4 + 4));
0x00083f78 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00083f7c ldrb r2, [r4, 6] | r2 = *((r4 + 6));
0x00083f80 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00083f84 ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x00083f88 orrs r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
| if (r3 != r3) {
0x00083f8c bne 0x8407c | goto label_3;
| }
| label_0:
0x00083f90 mov r0, 8 | r0 = 8;
0x00083f94 bl 0x18968 | fcn_00018968 (r0);
0x00083f98 ldrb r2, [r4, 1] | r2 = *((r4 + 1));
0x00083f9c ldrb r3, [r4] | r3 = *(r4);
0x00083fa0 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x00083fa4 ldrb r2, [r4, 2] | r2 = *((r4 + 2));
0x00083fa8 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x00083fac ldrb r2, [r4, 3] | r2 = *((r4 + 3));
0x00083fb0 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x00083fb4 stm r0, {r3, r5} | *(r0) = r3;
| *((r0 + 4)) = r5;
0x00083fb8 lsr r3, r0, 8 | r3 = r0 >> 8;
0x00083fbc strb r0, [r4] | *(r4) = r0;
0x00083fc0 strb r3, [r4, 1] | *((r4 + 1)) = r3;
0x00083fc4 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x00083fc8 lsr r0, r0, 0x18 | r0 >>= 0x18;
0x00083fcc strb r3, [r4, 2] | *((r4 + 2)) = r3;
0x00083fd0 strb r0, [r4, 3] | *((r4 + 3)) = r0;
0x00083fd4 b 0x84074 | goto label_1;
0x00083fd8 mov r2, r5 | r2 = r5;
0x00083fdc ldr r1, [pc, 0xf4] | r1 = *(0x840d4);
0x00083fe0 add r0, sp, 0x18 | r0 += ptr;
0x00083fe4 bl 0x14f48 | sprintf (r0, r1, r2)
0x00083fe8 add r1, sp, 0x18 | r1 += ptr;
0x00083fec mov r2, 0x1f | r2 = 0x1f;
0x00083ff0 mov r0, r1 | r0 = r1;
0x00083ff4 bl 0x19740 | r0 = fcn_00019740 (r0);
0x00083ff8 cmp r0, 0 |
| if (r0 < 0) {
0x00083ffc blt 0x84074 | goto label_1;
| }
0x00084000 mov r7, 0 | r7 = 0;
0x00084004 mov r1, 0x28 | r1 = 0x28;
0x00084008 add r0, sp, 0x18 | r0 += ptr;
0x0008400c strb r7, [sp, 0x37] | var_37h = r7;
0x00084010 bl 0x1517c | r0 = strchr (r0, r1);
0x00084014 cmp r0, 0 |
| if (r0 == 0) {
0x00084018 beq 0x84074 | goto label_1;
| }
0x0008401c add r6, r0, 1 | r6 += s1;
0x00084020 mov r1, 0x29 | r1 = 0x29;
0x00084024 mov r0, r6 | r0 = r6;
0x00084028 bl 0x1496c | r0 = strrchr (r0, r1);
0x0008402c cmp r0, 0 |
| if (r0 == 0) {
0x00084030 beq 0x84074 | goto label_1;
| }
0x00084034 strb r7, [r0] | *(r0) = r7;
0x00084038 mov r0, r6 | r0 = r6;
0x0008403c bl 0x1514c | r0 = strlen (r0);
0x00084040 cmp r0, 0xe |
| if (r0 > 0xe) {
0x00084044 bhi 0x84074 | goto label_1;
| }
0x00084048 ldrb r1, [r4, 9] | r1 = *((r4 + 9));
0x0008404c ldrb r3, [r4, 8] | r3 = *((r4 + 8));
0x00084050 mov r0, r6 | r0 = r6;
0x00084054 orr r3, r3, r1, lsl 8 | r3 |= (r1 << 8);
0x00084058 ldrb r1, [r4, 0xa] | r1 = *((r4 + 0xa));
0x0008405c orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x00084060 ldrb r1, [r4, 0xb] | r1 = *((r4 + 0xb));
0x00084064 orr r1, r3, r1, lsl 24 | r1 = r3 | (r1 << 24);
0x00084068 bl 0x14ed0 | r0 = strcmp (r0, r1);
0x0008406c cmp r0, r7 |
0x00084070 beq 0x83f70 |
| }
| do {
| label_1:
0x00084074 add sp, sp, 0x80 |
0x00084078 pop {r4, r5, r6, r7, r8, pc} |
| label_3:
0x0008407c mov r2, r5 | r2 = r5;
0x00084080 ldr r1, [pc, 0x54] | r1 = "_proc__u_stat";
0x00084084 add r0, sp, 4 | r0 += s;
0x00084088 bl 0x14f48 | sprintf (r0, "_proc__u_stat", r2)
0x0008408c add r1, sp, 0x18 | r1 += ptr;
0x00084090 add r0, sp, 4 | r0 += s;
0x00084094 bl 0x14420 | r0 = stat64 ();
0x00084098 cmp r0, 0 |
0x0008409c bne 0x84074 |
| } while (r0 != 0);
0x000840a0 ldrb r2, [r4, 0x1d] | r2 = *((r4 + 0x1d));
0x000840a4 ldrb r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x000840a8 orr r3, r3, r2, lsl 8 | r3 |= (r2 << 8);
0x000840ac ldrb r2, [r4, 0x1e] | r2 = *((r4 + 0x1e));
0x000840b0 orr r3, r3, r2, lsl 16 | r3 |= (r2 << 16);
0x000840b4 ldrb r2, [r4, 0x1f] | r2 = *((r4 + 0x1f));
0x000840b8 orr r3, r3, r2, lsl 24 | r3 |= (r2 << 24);
0x000840bc ldr r2, [sp, 0x30] | r2 = var_30h;
0x000840c0 cmp r2, r3 |
| if (r2 == r3) {
0x000840c4 beq 0x83f90 | goto label_0;
| }
0x000840c8 b 0x84074 | goto label_1;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x8a5ec */
| #include <stdint.h>
|
; (fcn) fcn.0008a5ec () | void fcn_0008a5ec (void * arg1) {
| int32_t var_0h;
| int32_t var_0h_2;
| int32_t var_8h;
| int32_t var_10h;
| void * var_14h;
| int32_t var_18h;
| void * ptr;
| int8_t var_1h;
| int32_t var_1h_2;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| r0 = arg1;
0x0008a5ec push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0008a5f0 sub sp, sp, 0x2c |
0x0008a5f4 add r4, sp, 0x28 | r4 += var_28h;
0x0008a5f8 str r0, [r4, -0xc]! | *((r4 -= 0xc)) = r0;
0x0008a5fc mov r0, 1 | r0 = 1;
0x0008a600 bl 0x86b54 | r0 = fcn_00086b54 (r0);
0x0008a604 mov sb, r0 | sb = r0;
0x0008a608 mov r0, r4 | r0 = r4;
0x0008a60c bl 0x86a88 | fcn_00086a88 (r0);
0x0008a610 mov r1, sb | r1 = sb;
0x0008a614 bl 0x88d88 | r0 = fcn_00088d88 (r0, r1, r2, r3, r4, r5, r6);
0x0008a618 bl 0x87498 | r0 = fcn_00087498 (r0);
0x0008a61c bl 0x189d4 | fcn_000189d4 (r0);
0x0008a620 mov r4, 0 | r4 = 0;
0x0008a624 mov r6, r4 | r6 = r4;
0x0008a628 mov sl, r0 | sl = r0;
0x0008a62c mov r7, r0 | r7 = r0;
| label_1:
0x0008a630 ldrb r5, [r7] | r5 = *(r7);
0x0008a634 cmp r5, 0 |
| if (r5 != 0) {
0x0008a638 bne 0x8a770 | goto label_6;
| }
0x0008a63c mov r0, sl | r0 = sl;
0x0008a640 bl 0x152a8 | free (r0);
0x0008a644 mov r0, sb | r0 = sb;
0x0008a648 bl 0x8815c | fcn_0008815c (r0);
0x0008a64c add r1, r4, 1 | r1 = r4 + 1;
0x0008a650 mov r0, r6 | r0 = r6;
0x0008a654 bl 0x18990 | fcn_00018990 (r0, r1);
0x0008a658 strb r5, [r0, r4] | *((r0 + r4)) = r5;
0x0008a65c add sp, sp, 0x2c |
0x0008a660 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_0:
0x0008a664 mov r5, r3 | r5 = r3;
| do {
0x0008a668 add r5, r5, 1 | r5 += var_1h;
| label_2:
0x0008a66c ldrb r2, [r5] | r2 = *(r5);
0x0008a670 cmp r2, 0 |
| if (r2 == 0) {
0x0008a674 beq 0x8a6b0 | goto label_7;
| }
0x0008a678 mov r3, r5 | r3 = r5;
0x0008a67c cmp r2, 0x25 |
0x0008a680 ldrb r1, [r3, 1]! | r1 = var_1h;
0x0008a684 bne 0x8a668 |
| } while (r2 != 0x25);
0x0008a688 cmp r1, 0x25 |
| if (r1 == 0x25) {
0x0008a68c beq 0x8a664 | goto label_0;
| }
| do {
0x0008a690 mov r5, r3 | r5 = r3;
0x0008a694 ldrb r1, [r3], 1 | r1 = *(r3);
| r3++;
0x0008a698 cmp r1, 0 |
| if (r1 != 0) {
0x0008a69c beq 0x8a6b0 |
0x0008a6a0 orr r2, r1, 0x20 | r2 = r1 | 0x20;
0x0008a6a4 sub r2, r2, 0x61 | r2 -= 0x61;
0x0008a6a8 cmp r2, 0x19 |
| if (r2 > 0x19) {
0x0008a6ac bhi 0x8a778 | goto label_8;
| }
| }
| label_7:
0x0008a6b0 sub r3, r5, r7 | r3 = r5 - r7;
0x0008a6b4 add r3, r3, 0xf0 | r3 += 0xf0;
0x0008a6b8 add fp, r4, r3 |
0x0008a6bc add r2, sp, 0x24 | r2 += var_24h;
0x0008a6c0 mov r1, fp | r1 = fp;
0x0008a6c4 mov r0, r6 | r0 = r6;
0x0008a6c8 str r3, [sp, 0x10] | var_10h = r3;
0x0008a6cc bl 0x86c18 | fcn_00086c18 (r0, r1);
0x0008a6d0 ldrb r8, [r5] | r8 = *(r5);
0x0008a6d4 cmp r8, 0 |
| if (r8 == 0) {
0x0008a6d8 addne r5, r5, 1 | r5++;
| }
0x0008a6dc ldrb r3, [r5] | r3 = *(r5);
0x0008a6e0 str r3, [sp, 0x14] | var_14h = r3;
0x0008a6e4 mov r3, 0 | r3 = 0;
0x0008a6e8 strb r3, [r5] | *(r5) = r3;
0x0008a6ec mov r6, r0 | r6 = r0;
0x0008a6f0 add r0, sp, 0x1c | r0 += ptr;
0x0008a6f4 bl 0x86a88 | fcn_00086a88 (r0);
0x0008a6f8 mov r1, sb | r1 = sb;
0x0008a6fc bl 0x88d88 | fcn_00088d88 (r0, r1, r2, r3, r4, r5, r6);
0x0008a700 cmp r8, 0 |
0x0008a704 cmpne r8, 0x63 | __asm ("cmpne r8, 0x63");
| if (r8 != 0) {
0x0008a708 moveq r2, 1 | r2 = 1;
| }
| if (r8 == 0) {
0x0008a70c movne r2, 0 | r2 = 0;
| }
| if (r8 != 0) {
0x0008a710 bne 0x8a794 | goto label_9;
| }
0x0008a714 str r0, [sp, 0x10] | var_10h = r0;
0x0008a718 bl 0x86f20 | fcn_00086f20 (r0);
0x0008a71c ldr r3, [sp, 0x10] | r3 = var_10h;
0x0008a720 ldr r1, [pc, 0xd0] | r1 = *(0x8a7f4);
0x0008a724 ldr r2, [r3] | r2 = *(r3);
0x0008a728 add r8, r6, r4 | r8 = r6 + r4;
0x0008a72c eor r2, r2, 0x4000 | r2 ^= 0x4000;
0x0008a730 tst r2, r1 |
0x0008a734 mov r0, r3 | r0 = r3;
| if ((r2 & r1) == 0) {
0x0008a738 beq 0x8a788 | goto label_10;
| }
0x0008a73c bl 0x86f20 | r0 = fcn_00086f20 (r0);
0x0008a740 bl 0xa7150 | r0 = fcn_000a7150 (r0, r1);
0x0008a744 and r2, r0, 0xff | r2 = r0 & 0xff;
| label_3:
0x0008a748 mov r1, r7 | r1 = r7;
0x0008a74c mov r0, r8 | r0 = r8;
| label_4:
0x0008a750 bl 0x14f48 | sprintf (r0, r1, r2)
| label_5:
0x0008a754 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0008a758 add r0, r4, r0 | r0 = r4 + r0;
0x0008a75c cmp r4, r0 |
0x0008a760 strb r3, [r5] | *(r5) = r3;
| if (r4 >= r0) {
0x0008a764 movlt r4, r0 | r4 = r0;
| }
0x0008a768 mov r7, r5 | r7 = r5;
0x0008a76c b 0x8a630 | goto label_1;
| label_6:
0x0008a770 mov r5, r7 | r5 = r7;
0x0008a774 b 0x8a66c | goto label_2;
| label_8:
0x0008a778 cmp r1, 0x2a |
0x0008a77c bne 0x8a690 |
| } while (r1 != 0x2a);
0x0008a780 ldr r0, [pc, 0x74] | r0 = *(0x8a7f8);
0x0008a784 bl 0x87374 | r0 = fcn_00087374 (r0);
| label_10:
0x0008a788 bl 0x87498 | r0 = fcn_00087498 (r0);
0x0008a78c ldrb r2, [r0] | r2 = *(r0);
0x0008a790 b 0x8a748 | goto label_3;
| label_9:
0x0008a794 cmp r8, 0x73 |
| if (r8 == 0x73) {
0x0008a798 bne 0x8a7cc |
0x0008a79c bl 0x87498 | r0 = fcn_00087498 (r0);
0x0008a7a0 mov r8, r0 | r8 = r0;
0x0008a7a4 bl 0x1514c | strlen (r0);
0x0008a7a8 add r2, sp, 0x24 | r2 += var_24h;
0x0008a7ac add r1, fp, r0 | r1 = fp + r0;
0x0008a7b0 mov r0, r6 | r0 = r6;
0x0008a7b4 bl 0x86c18 | fcn_00086c18 (r0, r1);
0x0008a7b8 mov r2, r8 | r2 = r8;
0x0008a7bc mov r1, r7 | r1 = r7;
0x0008a7c0 mov r6, r0 | r6 = r0;
0x0008a7c4 add r0, r0, r4 | r0 += r4;
0x0008a7c8 b 0x8a750 | goto label_4;
| }
0x0008a7cc str r2, [sp, 0x18] | var_18h = r2;
0x0008a7d0 bl 0x86f20 | fcn_00086f20 (r0);
0x0008a7d4 ldr r2, [sp, 0x18] | r2 = var_18h;
0x0008a7d8 add r8, r6, r4 | r8 = r6 + r4;
0x0008a7dc str r2, [sp, 8] | var_8h = r2;
0x0008a7e0 mov r2, r7 | r2 = r7;
0x0008a7e4 strd r0, r1, [sp] | __asm ("strd r0, r1, [sp]");
0x0008a7e8 ldr r1, [sp, 0x10] | r1 = var_10h;
0x0008a7ec mov r0, r8 | r0 = r8;
0x0008a7f0 bl 0x8739c | fcn_0008739c (r0, r1, r2);
0x0008a7f4 b 0x8a754 | goto label_5;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x90a84 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.00090a84 () | void fcn_00090a84 (int32_t arg1, int32_t arg2) {
| int32_t var_4h_2;
| char * s;
| int32_t var_2ch;
| r0 = arg1;
| r1 = arg2;
0x00090a84 ldr r3, [pc, 0x4c] | r3 = *(0x90ad4);
0x00090a88 bic r2, r0, r0, asr 31 | r2 = BIT_MASK (r0, r0);
0x00090a8c ldr r0, [r3] | r0 = *(0x90ad4);
0x00090a90 str lr, [sp, -4]! |
0x00090a94 ldr r3, [r0, 0x30] | r3 = *(0x90b04);
0x00090a98 sub sp, sp, 0x2c |
0x00090a9c cmp r3, r2 |
| if (r3 > r2) {
0x00090aa0 subls r2, r3, 1 | r2 = r3 - 1;
| }
0x00090aa4 bic r3, r1, r1, asr 31 | r3 = BIT_MASK (r1, r1);
0x00090aa8 ldr r1, [r0, 0x34] | r1 = *(0x90b08);
0x00090aac add r2, r2, 1 | r2++;
0x00090ab0 cmp r1, r3 |
| if (r1 > r3) {
0x00090ab4 subls r3, r1, 1 | r3 = r1 - 1;
| }
0x00090ab8 add r3, r3, 1 | r3++;
0x00090abc ldr r1, [pc, 0x18] | r1 = *(0x90ad8);
0x00090ac0 add r0, sp, 4 | r0 += s;
0x00090ac4 bl 0x14f48 | sprintf (r0, r1, r2)
0x00090ac8 add r0, sp, 4 | r0 += s;
0x00090acc bl 0x90a74 | fcn_00090a74 ();
0x00090ad0 add sp, sp, 0x2c |
0x00090ad4 pop {pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x940d0 */
| #include <stdint.h>
|
; (fcn) fcn.000940d0 () | void fcn_000940d0 (int32_t arg1) {
| r0 = arg1;
0x000940d0 push {r3, r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000940d4 ldr r3, [pc, 0x2e8] | r3 = *(0x943c0);
0x000940d8 mov r6, 0x18 | r6 = 0x18;
0x000940dc ldr r4, [r3] | r4 = *(0x943c0);
0x000940e0 mov r3, 1 | r3 = 1;
0x000940e4 str r3, [r4, 0x18] | *((r4 + 0x18)) = r3;
0x000940e8 mov r7, 0x50 | r7 = 0x50;
0x000940ec mov r5, r0 | r5 = r0;
0x000940f0 bl 0x8fa84 | fcn_0008fa84 ();
0x000940f4 strd r6, r7, [r4, 0x30] | __asm ("strd r6, r7, [r4, 0x30]");
0x000940f8 bl 0x8fab0 | r0 = fcn_0008fab0 ();
0x000940fc cmp r0, 0 |
0x00094100 str r0, [r4, 0x38] | *((r4 + 0x38)) = r0;
| if (r0 != 0) {
0x00094104 beq 0x9415c |
0x00094108 ldr r0, [pc, 0x2b8] | r0 = *(0x943c4);
0x0009410c bl 0x90a74 | fcn_00090a74 ();
0x00094110 bl 0x18cdc | fcn_00018cdc ();
0x00094114 mov r2, 0x64 | r2 = 0x64;
0x00094118 add r1, r4, 0x2d8 | r1 = r4 + 0x2d8;
0x0009411c mov r0, 0 | r0 = 0;
0x00094120 bl 0xa32d0 | r0 = fcn_000a32d0 (r0, r1);
0x00094124 cmn r0, 0x100 |
| if (r0 != 0x100) {
0x00094128 bne 0x9415c | goto label_6;
| }
0x0009412c lsl r3, r1, 0x11 | r3 = r1 << 0x11;
0x00094130 lsr r3, r3, 0x11 | r3 >>= 0x11;
0x00094134 cmp r3, 0x1000 |
0x00094138 str r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
| if (r3 <= 0x1000) {
0x0009413c movhi r3, 0x1000 | r3 = 0x1000;
| }
| if (r3 <= 0x1000) {
0x00094140 strhi r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
| }
0x00094144 ldr r3, [pc, 0x280] | r3 = *(0x943c8);
0x00094148 and r1, r3, r1, lsr 16 | r1 = r3 & (r1 >> 16);
0x0009414c cmp r1, 0x1000 |
| if (r1 <= 0x1000) {
0x00094150 movhi r3, 0x1000 | r3 = 0x1000;
| }
0x00094154 str r1, [r4, 0x30] | *((r4 + 0x30)) = r1;
| if (r1 > 0x1000) {
0x00094158 strhi r3, [r4, 0x30] | *((r4 + 0x30)) = r3;
| goto label_6;
| }
| }
| label_6:
0x0009415c ldrd r0, r1, [r4, 0x30] | __asm ("ldrd r0, r1, [r4, 0x30]");
0x00094160 bl 0x8fb10 | fcn_0008fb10 (r0, r1);
0x00094164 mov r0, r5 | r0 = r5;
0x00094168 bl 0x9192c | fcn_0009192c (r0);
0x0009416c ldr r3, [r4] | r3 = *(r4);
0x00094170 mov r0, 0x1a | r0 = 0x1a;
0x00094174 str r3, [r4, 0x174] | *((r4 + 0x174)) = r3;
0x00094178 str r3, [r4, 0x170] | *((r4 + 0x170)) = r3;
0x0009417c mov r1, 0x1b | r1 = 0x1b;
0x00094180 mov r3, 0 | r3 = 0;
0x00094184 strd r0, r1, [r4, 0x90] | __asm ("strd r0, r1, [r4, 0x90]");
0x00094188 ldr r1, [pc, 0x240] | r1 = *(0x943cc);
0x0009418c strb r3, [r4, 0x69] | *((r4 + 0x69)) = r3;
0x00094190 str r3, [r4, 0x64] | *((r4 + 0x64)) = r3;
0x00094194 str r3, [r4, 0x3c] | *((r4 + 0x3c)) = r3;
0x00094198 str r3, [r4, 0x40] | *((r4 + 0x40)) = r3;
0x0009419c mov r0, 2 | r0 = 2;
0x000941a0 bl 0x14b4c | signal (r0);
0x000941a4 ldr r1, [pc, 0x228] | r1 = *(0x943d0);
0x000941a8 mov r0, 0x1c | r0 = 0x1c;
0x000941ac bl 0x14b4c | signal (r0);
0x000941b0 ldr r1, [pc, 0x220] | r1 = *(0x943d4);
0x000941b4 mov r0, 0x14 | r0 = 0x14;
0x000941b8 bl 0x14b4c | signal (r0);
0x000941bc mov r1, 1 | r1 = 1;
0x000941c0 add r0, r4, 0x180 | r0 = r4 + 0x180;
0x000941c4 bl 0x148dc | sigsetjmp ();
0x000941c8 ldr r3, [pc, 0x1f4] | r3 = *(0x943c0);
0x000941cc mov r5, 0 | r5 = 0;
0x000941d0 ldr r4, [r3] | r4 = *(0x943c0);
0x000941d4 str r5, [r4, 0x1c] | *((r4 + 0x1c)) = r5;
0x000941d8 str r5, [r4, 0x2c] | *((r4 + 0x2c)) = r5;
0x000941dc str r5, [r4, 0x44] | *((r4 + 0x44)) = r5;
0x000941e0 add r8, r4, 0x2c8 | r8 = r4 + 0x2c8;
0x000941e4 cmp r0, 0 |
| if (r0 == 0) {
0x000941e8 ldrne r3, [r4] | r3 = *(r4);
| }
0x000941ec ldr r0, [r4, 0x78] | r0 = *(0x94438);
| if (r0 == 0) {
0x000941f0 strne r3, [r4, 8] | *((r4 + 8)) = r3;
| }
| if (r0 == 0) {
0x000941f4 strne r3, [r4, 0x54] | *((r4 + 0x54)) = r3;
| }
0x000941f8 mov r3, 8 | r3 = 8;
0x000941fc str r3, [r4, 0x60] | *((r4 + 0x60)) = r3;
0x00094200 bl 0x152a8 | free (r0);
0x00094204 str r5, [r4, 0x78] | *((r4 + 0x78)) = r5;
0x00094208 str r5, [r4, 0x74] | *((r4 + 0x74)) = r5;
0x0009420c str r5, [r4, 0x70] | *((r4 + 0x70)) = r5;
0x00094210 str r5, [r4, 0x6c] | *((r4 + 0x6c)) = r5;
| label_0:
0x00094214 add r8, r8, 4 | r8 += 4;
0x00094218 ldr r6, [r8] | r6 = *(r8);
0x0009421c mov sb, r8 | sb = r8;
0x00094220 cmp r6, 0 |
| if (r6 == 0) {
0x00094224 beq 0x94298 | goto label_7;
| }
0x00094228 mov sl, 0xa | sl = 0xa;
0x0009422c b 0x94234 |
| while (r7 != 0) {
0x00094230 mov r6, r7 | r6 = r7;
0x00094234 mov r1, sl | r1 = sl;
0x00094238 mov r0, r6 | r0 = r6;
0x0009423c bl 0x1517c | r0 = strchr (r0, r1);
0x00094240 subs r7, r0, 0 | r7 = r0 - 0;
| if (r7 == r0) {
0x00094244 movne r3, r7 | r3 = r7;
| }
| if (r7 != r0) {
0x00094248 bne 0x94274 | goto label_8;
| }
| label_1:
0x0009424c ldrb r3, [r6] | r3 = *(r6);
0x00094250 cmp r3, 0 |
| if (r3 != 0) {
0x00094254 bne 0x9428c | goto label_9;
| }
| label_2:
0x00094258 cmp r7, 0 |
0x0009425c bne 0x94230 |
| }
0x00094260 ldr r0, [sb] | r0 = *(sb);
0x00094264 bl 0x152a8 | free (r0);
0x00094268 str r7, [sb] | *(sb) = r7;
0x0009426c b 0x94214 | goto label_0;
| do {
0x00094270 strb r5, [r3, -1] | *((r3 - 1)) = r5;
| label_8:
0x00094274 mov r7, r3 | r7 = r3;
0x00094278 ldrb r2, [r7] | r2 = *(r7);
0x0009427c add r3, r3, 1 | r3++;
0x00094280 cmp r2, 0xa |
0x00094284 beq 0x94270 |
| } while (r2 == 0xa);
0x00094288 b 0x9424c | goto label_1;
| label_9:
0x0009428c mov r0, r6 | r0 = r6;
0x00094290 bl 0x919ec | fcn_000919ec (r0);
0x00094294 b 0x94258 | goto label_2;
| label_7:
0x00094298 mov r0, r6 | r0 = r6;
0x0009429c bl 0x91344 | fcn_00091344 (r0);
0x000942a0 ldr r7, [pc, 0x11c] | r7 = *(0x943c0);
0x000942a4 ldr sb, [pc, 0x130] | sb = "cCdDJoOpPrRxX<>~";
| label_3:
0x000942a8 ldr r8, [pc, 0x130] | r8 = "cCdDJoOpPrRxX<>~";
| do {
0x000942ac ldr r3, [r4, 0x18] | r3 = *((r4 + 0x18));
0x000942b0 cmp r3, 0 |
| if (r3 <= 0) {
0x000942b4 bgt 0x942c4 |
0x000942b8 bl 0x90ae0 | fcn_00090ae0 ();
0x000942bc bl 0x90a54 | fcn_00090a54 ();
0x000942c0 pop {r3, r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x000942c4 bl 0x90bc4 | fcn_00090bc4 ();
0x000942c8 ldr r5, [r4, 8] | r5 = *((r4 + 8));
0x000942cc and sl, r0, 0xff | sl = r0 & 0xff;
0x000942d0 mov r6, r0 | r6 = r0;
0x000942d4 strb sl, [r4, 0x69] | *((r4 + 0x69)) = sl;
0x000942d8 mov r0, r5 | r0 = r5;
0x000942dc bl 0x904a4 | fcn_000904a4 (r0);
0x000942e0 ldr r3, [r4, 0x84] | r3 = *((r4 + 0x84));
0x000942e4 cmp r3, r0 |
| if (r3 != r0) {
0x000942e8 bne 0x94324 | goto label_10;
| }
| label_4:
0x000942ec ldr r3, [r4, 0x6c] | r3 = *((r4 + 0x6c));
0x000942f0 cmp r3, 0 |
| if (r3 == 0) {
0x000942f4 beq 0x94350 | goto label_11;
| }
| label_5:
0x000942f8 mov r0, r6 | r0 = r6;
0x000942fc bl 0x926e4 | fcn_000926e4 (r0);
0x00094300 ldrb r0, [r4, 0x2d8] | r0 = *((r4 + 0x2d8));
0x00094304 cmp r0, 0 |
0x00094308 bne 0x942ac |
| } while (r0 != 0);
0x0009430c bl 0x90a10 | r0 = fcn_00090a10 (r0);
0x00094310 cmp r0, 0 |
| if (r0 != 0) {
0x00094314 bne 0x942a8 | goto label_3;
| }
0x00094318 bl 0x90f60 | r0 = fcn_00090f60 (r0);
0x0009431c bl 0x913d0 | fcn_000913d0 ();
0x00094320 b 0x942a8 | goto label_3;
| label_10:
0x00094324 str r0, [r4, 0x84] | *((r4 + 0x84)) = r0;
0x00094328 mov r0, r5 | r0 = r5;
0x0009432c bl 0x904a4 | r0 = fcn_000904a4 (r0);
0x00094330 mov fp, r0 |
0x00094334 mov r0, r5 | r0 = r5;
0x00094338 bl 0x905e0 | fcn_000905e0 (r0);
0x0009433c ldr r2, [r4, 0x94] | r2 = *((r4 + 0x94));
0x00094340 mov r1, r0 | r1 = r0;
0x00094344 mov r0, fp | r0 = fp;
0x00094348 bl 0x8f984 | fcn_0008f984 (r0, r1);
0x0009434c b 0x942ec | goto label_4;
| label_11:
0x00094350 ldr r3, [r4, 0x78] | r3 = *((r4 + 0x78));
0x00094354 cmp r3, 0 |
| if (r3 != 0) {
0x00094358 bne 0x942f8 | goto label_5;
| }
0x0009435c ldr r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x00094360 cmp r3, 0 |
| if (r3 != 0) {
0x00094364 bne 0x942f8 | goto label_5;
| }
0x00094368 sub r3, r6, 1 | r3 = r6 - 1;
0x0009436c cmp r3, 0x7d |
| if (r3 > 0x7d) {
0x00094370 bhi 0x942f8 | goto label_5;
| }
0x00094374 mov r1, r6 | r1 = r6;
0x00094378 mov r0, sb | r0 = sb;
0x0009437c bl 0x1517c | r0 = strchr (r0, r1);
0x00094380 cmp r0, 0 |
| if (r0 == 0) {
0x00094384 beq 0x942f8 | goto label_5;
| }
0x00094388 ldr r5, [r7] | r5 = *(r7);
0x0009438c ldr r2, [r5, 0x2c] | r2 = *((r5 + 0x2c));
0x00094390 cmp r2, 0 |
| if (r2 > 0) {
0x00094394 movle r3, 1 | r3 = 1;
| }
| if (r2 > 0) {
0x00094398 strble sl, [r5, 0x3b0] | *((r5 + 0x3b0)) = sl;
| }
| if (r2 > 0) {
0x0009439c strle r3, [r5, 0x70] | *((r5 + 0x70)) = r3;
| }
| if (r2 > 0) {
0x000943a0 ble 0x943b8 |
0x000943a4 mov r3, r6 | r3 = r6;
0x000943a8 mov r1, r8 | r1 = r8;
0x000943ac add r0, r5, 0x3b0 | r0 = r5 + 0x3b0;
0x000943b0 bl 0x14f48 | sprintf (r0, r1, r2)
0x000943b4 str r0, [r5, 0x70] | *((r5 + 0x70)) = r0;
| }
0x000943b8 mov r3, 1 | r3 = 1;
0x000943bc str r3, [r5, 0x6c] | *((r5 + 0x6c)) = r3;
0x000943c0 b 0x942f8 | goto label_5;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x97bec */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.00097bec () | void fcn_00097bec (int32_t arg1) {
| int32_t var_24h;
| int32_t var_4h;
| int32_t var_20h_2;
| int32_t var_20h;
| r0 = arg1;
0x00097bec push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00097bf0 add fp, sp, 0x20 |
0x00097bf4 sub sp, sp, 0xc |
0x00097bf8 mov r7, r0 | r7 = r0;
0x00097bfc bl 0x1514c | strlen (r0);
0x00097c00 ldrb sb, [r7] | sb = *(r7);
0x00097c04 ldr r1, [pc, 0x100] | r1 = *(0x97d08);
0x00097c08 sub r4, sb, 0x2d | r4 = sb - 0x2d;
0x00097c0c clz r4, r4 | r4 &= r4;
0x00097c10 lsr r4, r4, 5 | r4 >>= 5;
0x00097c14 add sl, r7, r4 | sl = r7 + r4;
0x00097c18 add r3, r0, 8 | r3 = r0 + 8;
0x00097c1c lsr r3, r3, 1 | r3 >>= 1;
0x00097c20 add r0, r0, 0xf | r0 += 0xf;
0x00097c24 lsl r3, r3, 2 | r3 <<= 2;
0x00097c28 bic r0, r0, 7 | r0 = BIT_MASK (r0, 7);
0x00097c2c add r3, r3, 0xa | r3 += 0xa;
0x00097c30 sub sp, sp, r0 |
0x00097c34 bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x00097c38 mov r8, sp | r8 = sp;
0x00097c3c mov r0, sl | r0 = sl;
0x00097c40 sub sp, sp, r3 |
0x00097c44 bl 0x15278 | strpbrk (r0, r1);
0x00097c48 mov r5, sp | r5 = sp;
0x00097c4c subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 == r0) {
0x00097c50 beq 0x97cc4 | goto label_1;
| }
0x00097c54 mov r2, sl | r2 = sl;
0x00097c58 ldr r1, [pc, 0xb0] | r1 = "~`!$^&*()=|\\{}[];\"'<>?";
0x00097c5c mov r0, r8 | r0 = r8;
0x00097c60 bl 0x14f48 | sprintf (r0, "~`!$^&*()=|\\{}[];\"'<>?", r2)
0x00097c64 ldr r3, [pc, 0xa8] | r3 = "exec__s";
0x00097c68 cmp sb, 0x2d |
0x00097c6c add r4, r3, 1 | r4 = r3 + 1;
| if (sb == 0x2d) {
0x00097c70 movne r3, r4 | r3 = r4;
| }
0x00097c74 str r3, [r5] | *(r5) = r3;
0x00097c78 ldr r3, [pc, 0x98] | r3 = "__bin_sh";
0x00097c7c stmib r5, {r3, r8} | __asm ("stmib r5, {r3, r8}");
0x00097c80 mov r3, 0 | r3 = 0;
0x00097c84 str r3, [r5, 0xc] | *((r5 + 0xc)) = r3;
| do {
0x00097c88 cmp sb, 0x2d |
| if (sb == 0x2d) {
0x00097c8c bne 0x97ca0 |
0x00097c90 mov r2, 0 | r2 = 0;
0x00097c94 ldr r1, [pc, 0x80] | r1 = "_c";
0x00097c98 mov r0, r2 | r0 = r2;
0x00097c9c bl 0x14330 | ioctl (r0, "_c");
| }
0x00097ca0 mov r1, r5 | r1 = r5;
0x00097ca4 mov r0, r4 | r0 = r4;
0x00097ca8 bl 0x15194 | execvp ();
0x00097cac mov r2, r4 | r2 = r4;
0x00097cb0 ldr r1, [pc, 0x68] | r1 = *(0x97d1c);
0x00097cb4 mov r0, 3 | r0 = 3;
0x00097cb8 bl 0x978f4 | fcn_000978f4 (r0);
0x00097cbc sub sp, fp, 0x20 |
0x00097cc0 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_1:
0x00097cc4 mov r1, r7 | r1 = r7;
0x00097cc8 mov r0, r8 | r0 = r8;
0x00097ccc bl 0x142f4 | strcpy (r0, r1);
0x00097cd0 ldr r8, [pc, 0x4c] | r8 = "cant_run__s:__m";
0x00097cd4 sub r7, fp, 0x24 | r7 -= var_24h;
0x00097cd8 add r4, r0, r4 | r4 = r0 + r4;
0x00097cdc str r0, [r7, -4]! | *((r7 -= 4)) = r0;
| label_0:
0x00097ce0 mov r1, r8 | r1 = r8;
0x00097ce4 mov r0, r7 | r0 = r7;
0x00097ce8 bl 0x14fb4 | r0 = strsep ();
0x00097cec cmp r0, 0 |
| if (r0 != 0) {
0x00097cf0 streq r0, [r5, r6, lsl 2] | offset_0 = r6 << 2;
| *((r5 + offset_0)) = r0;
| }
0x00097cf4 beq 0x97c88 |
| } while (r0 == 0);
0x00097cf8 ldrb r3, [r0] | r3 = *(r0);
0x00097cfc cmp r3, 0 |
| if (r3 == 0) {
0x00097d00 strne r0, [r5, r6, lsl 2] | offset_1 = r6 << 2;
| *((r5 + offset_1)) = r0;
| }
| if (r3 == 0) {
0x00097d04 addne r6, r6, 1 | r6++;
| }
0x00097d08 b 0x97ce0 | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x99d68 */
| #include <stdint.h>
|
; (fcn) fcn.00099d68 () | void fcn_00099d68 (int32_t arg_0h, int32_t arg_4h, int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_8h_2;
| int32_t var_10h;
| int32_t var_14h;
| char * s1;
| int32_t var_18h_2;
| int32_t var_24h;
| r0 = arg1;
| r1 = arg2;
0x00099d68 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00099d6c ldr r5, [r0, 0x10] | r5 = *(arg_0hx10);
0x00099d70 sub sp, sp, 0x24 |
0x00099d74 mov r4, r0 | r4 = r0;
0x00099d78 mov r8, r1 | r8 = r1;
0x00099d7c mov r6, r5 | r6 = r5;
0x00099d80 mov r7, 0 | r7 = 0;
| do {
0x00099d84 cmp r6, 0 |
| if (r6 == 0) {
0x00099d88 bne 0x99e78 |
0x00099d8c str r7, [r4, 0x38] | *((r4 + 0x38)) = r7;
| label_0:
0x00099d90 cmp r5, 0 |
| if (r5 != 0) {
0x00099d94 bne 0x99e94 | goto label_19;
| }
0x00099d98 str r8, [r4, 0x18] | *((r4 + 0x18)) = r8;
0x00099d9c str r5, [sp, 4] | var_4h = r5;
| label_12:
0x00099da0 ldr r3, [r4, 0x48] | r3 = *((r4 + 0x48));
0x00099da4 ldr r5, [r4, 0x38] | r5 = *((r4 + 0x38));
0x00099da8 cmp r3, 0 |
| if (r3 != 0) {
0x00099dac bne 0x9a208 | goto label_20;
| }
0x00099db0 mov r2, 0 | r2 = 0;
0x00099db4 mov r3, 0 | r3 = 0;
0x00099db8 strd r2, r3, [r4, 0x30] | __asm ("strd r2, r3, [r4, 0x30]");
0x00099dbc mov r0, r5 | r0 = r5;
0x00099dc0 bl 0x18968 | fcn_00018968 (r0);
0x00099dc4 str r0, [r4, 0x48] | *((r4 + 0x48)) = r0;
0x00099dc8 mov r0, r5 | r0 = r5;
0x00099dcc bl 0x189b8 | fcn_000189b8 (r0);
0x00099dd0 str r0, [r4, 0x4c] | *((r4 + 0x4c)) = r0;
| label_8:
0x00099dd4 ldr sl, [pc, 0x60c] | sl = obj.stdin;
0x00099dd8 ldr fp, [pc, 0x60c] | fp = *(0x0009a3ec);
0x00099ddc mov r7, r5 | r7 = r5;
0x00099de0 mov r6, 0 | r6 = 0;
0x00099de4 mov r8, r5 | r8 = r5;
0x00099de8 asr sb, r5, 0x1f | sb = r5 >> 0x1f;
| label_10:
0x00099dec ldr r3, [r4, 8] | r3 = *((r4 + 8));
0x00099df0 cmp r3, 0 |
| if (r3 != 0) {
0x00099df4 bne 0x9a228 | goto label_21;
| }
| label_9:
0x00099df8 cmp r5, r7 |
| if (r5 != r7) {
0x00099dfc beq 0x99e38 |
0x00099e00 ldr r8, [r4, 0xc] | r8 = *((r4 + 0xc));
0x00099e04 ldr r5, [r4, 0x48] | r5 = *((r4 + 0x48));
0x00099e08 bics r3, r8, 2 | __asm ("bics r3, r8, 2");
| if (r5 == r7) {
0x00099e0c beq 0x9a2a0 | goto label_22;
| }
0x00099e10 mov r2, r6 | r2 = r6;
0x00099e14 ldr r1, [r4, 0x4c] | r1 = *((r4 + 0x4c));
0x00099e18 mov r0, r5 | r0 = r5;
0x00099e1c bl 0x14c60 | r0 = memcmp (r0, r1, r2);
0x00099e20 cmp r0, 0 |
| if (r0 != 0) {
0x00099e24 bne 0x9a2a0 | goto label_22;
| }
0x00099e28 cmp r8, 1 |
| if (r8 == 1) {
0x00099e2c beq 0x99e38 | goto label_11;
| }
0x00099e30 ldr r0, [pc, 0x5b4] | r0 = stdin;
0x00099e34 bl 0x14660 | puts (r0);
| }
| label_11:
0x00099e38 ldr r3, [r4, 0x1c] | r3 = *((r4 + 0x1c));
0x00099e3c cmp r3, 0 |
| if (r3 != 0) {
0x00099e40 beq 0x99e6c |
0x00099e44 ldrd r0, r1, [r4, 0x28] | __asm ("ldrd r0, r1, [r4, 0x28]");
0x00099e48 orrs r2, r0, r1 | r2 = r0 | r1;
| if (r2 == r0) {
0x00099e4c bne 0x99e60 |
0x00099e50 ldrd r0, r1, [r4, 0x30] | __asm ("ldrd r0, r1, [r4, 0x30]");
0x00099e54 orrs r2, r0, r1 | r2 = r0 | r1;
| if (r2 == r0) {
0x00099e58 beq 0x99e6c | goto label_23;
| }
0x00099e5c strd r0, r1, [r4, 0x28] | __asm ("strd r0, r1, [r4, 0x28]");
| }
0x00099e60 ldr r5, [r3, 4] | r5 = *((r3 + 4));
| label_16:
0x00099e64 cmp r5, 0 |
| if (r5 != 0) {
0x00099e68 bne 0x9a3a8 | goto label_24;
| }
| }
| label_23:
0x00099e6c ldr r0, [r4, 0x3c] | r0 = *((r4 + 0x3c));
0x00099e70 add sp, sp, 0x24 |
0x00099e74 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x00099e78 ldr r0, [r6, 4] | r0 = *((r6 + 4));
0x00099e7c bl 0x99bfc | r0 = fcn_00099bfc (r0);
0x00099e80 cmp r7, r0 |
0x00099e84 str r0, [r6, 8] | *((r6 + 8)) = r0;
| if (r7 >= r0) {
0x00099e88 movlt r7, r0 | r7 = r0;
| }
0x00099e8c ldr r6, [r6] | r6 = *(r6);
0x00099e90 b 0x99d84 |
| } while (1);
| label_19:
0x00099e94 mov r1, r5 | r1 = r5;
0x00099e98 mov r0, r4 | r0 = r4;
0x00099e9c bl 0x995e0 | fcn_000995e0 (r0, r1);
0x00099ea0 ldr r5, [r5] | r5 = *(r5);
0x00099ea4 b 0x99d90 | goto label_0;
| label_13:
0x00099ea8 ldr r3, [sp] | r3 = *(sp);
0x00099eac ldr r3, [r3, 8] | r3 = *((r3 + 8));
0x00099eb0 tst r3, 1 |
| if ((r3 & 1) != 0) {
0x00099eb4 bne 0x9a2f8 | goto label_25;
| }
0x00099eb8 ldr r3, [sp] | r3 = *(sp);
0x00099ebc ldr sl, [r3, 0xc] | sl = *((r3 + 0xc));
| do {
0x00099ec0 cmp sl, 0 |
0x00099ec4 ldr r3, [sp] | r3 = *(sp);
| if (sl != 0) {
0x00099ec8 ldreq r3, [r3] | r3 = *(r3);
| }
| if (sl != 0) {
0x00099ecc streq r3, [sp] | *(sp) = r3;
| }
| if (sl == 0) {
0x00099ed0 beq 0x9a2ec | goto label_26;
| }
0x00099ed4 ldr r5, [r3, 4] | r5 = *((r3 + 4));
| label_1:
0x00099ed8 cmp r5, 0 |
| if (r5 != 0) {
0x00099edc subeq sl, sl, 1 | sl--;
| }
0x00099ee0 beq 0x99ec0 |
| } while (r5 == 0);
0x00099ee4 ldrd r0, r1, [r4, 0x28] | __asm ("ldrd r0, r1, [r4, 0x28]");
0x00099ee8 orrs r3, r0, r1 | r3 = r0 | r1;
| if (r3 == r0) {
0x00099eec beq 0x99f7c | goto label_18;
| }
0x00099ef0 ldrd r2, r3, [r4, 0x30] | __asm ("ldrd r2, r3, [r4, 0x30]");
0x00099ef4 cmp r2, r0 |
0x00099ef8 sbcs r3, r3, r1 | __asm ("sbcs r3, r3, r1");
| if (r2 < r0) {
0x00099efc blt 0x99f7c | goto label_18;
| }
0x00099f00 ldr r3, [r5, 4] | r3 = *((r5 + 4));
0x00099f04 ldr r2, [pc, 0x4e4] | r2 = *(0x9a3ec);
0x00099f08 tst r2, r3 |
| if ((r2 & r3) != 0) {
0x00099f0c bne 0x99f7c | goto label_18;
| }
0x00099f10 mov r3, 2 | r3 = 2;
0x00099f14 str r3, [r5, 4] | *((r5 + 4)) = r3;
0x00099f18 ldr r3, [r5, 0xc] | r3 = *((r5 + 0xc));
0x00099f1c mov r2, 0x73 | r2 = 0x73;
0x00099f20 strb r2, [r3] | *(r3) = r2;
0x00099f24 ldr r8, [r5, 0x10] | r8 = *((r5 + 0x10));
| label_2:
0x00099f28 ldrb r2, [r8] | r2 = *(r8);
0x00099f2c add r3, r8, 1 | r3 = r8 + 1;
0x00099f30 cmp r2, 0x25 |
| if (r2 != 0x25) {
0x00099f34 bne 0x9a008 | goto label_27;
| }
| label_3:
0x00099f38 ldrb r1, [r3] | r1 = *(r3);
0x00099f3c mov r2, r3 | r2 = r3;
0x00099f40 cmp r1, 0 |
0x00099f44 add r3, r3, 1 | r3++;
| if (r1 == 0) {
0x00099f48 beq 0x9a3e0 | goto label_28;
| }
0x00099f4c ldr r0, [pc, 0x4a0] | r0 = *(0x9a3f0);
0x00099f50 str r3, [sp, 0x14] | var_14h = r3;
0x00099f54 str r2, [sp, 0x10] | var_10h = r2;
0x00099f58 bl 0x1517c | strchr (r0, r1);
0x00099f5c ldr r2, [sp, 0x10] | r2 = var_10h;
0x00099f60 ldr r3, [sp, 0x14] | r3 = var_14h;
0x00099f64 cmp r0, 0 |
| if (r0 != 0) {
0x00099f68 bne 0x9a010 | goto label_29;
| }
| do {
0x00099f6c ldrb r3, [r2], 1 | r3 = *(r2);
| r2++;
0x00099f70 cmp r3, 0 |
0x00099f74 strb r3, [r8, 1]! | *((r8 += 1)) = r3;
0x00099f78 bne 0x99f6c |
| } while (r3 != 0);
| label_18:
0x00099f7c cmp sl, 1 |
| if (sl == 1) {
0x00099f80 bne 0x99f9c |
0x00099f84 ldr r3, [r5, 0x14] | r3 = *((r5 + 0x14));
0x00099f88 cmp r3, 0 |
| if (r3 == 0) {
0x00099f8c ldrbne r2, [r3] | r2 = *(r3);
| }
| if (r3 == 0) {
0x00099f90 strne r2, [sp, 4] | var_4h = r2;
| }
| if (r3 == 0) {
0x00099f94 movne r2, 0 | r2 = 0;
| }
| if (r3 != 0) {
0x00099f98 strbne r2, [r3] | *(r3) = r2;
| goto label_30;
| }
| }
| label_30:
0x00099f9c ldr r3, [r5, 4] | r3 = *((r5 + 4));
0x00099fa0 cmp r3, 0x20 |
| if (r3 == 0x20) {
0x00099fa4 beq 0x9a134 | goto label_31;
| }
| if (r3 > 0x20) {
0x00099fa8 bhi 0x9a05c | goto label_32;
| }
0x00099fac cmp r3, 4 |
| if (r3 == 4) {
0x00099fb0 beq 0x9a0b4 | goto label_33;
| }
| if (r3 > 4) {
0x00099fb4 bhi 0x9a024 | goto label_34;
| }
0x00099fb8 cmp r3, 1 |
| if (r3 == 1) {
0x00099fbc beq 0x9a09c | goto label_35;
| }
0x00099fc0 cmp r3, 2 |
| if (r3 == 2) {
0x00099fc4 beq 0x9a0ac | goto label_36;
| }
| do {
| label_4:
0x00099fc8 cmp sl, 1 |
| if (sl == 1) {
0x00099fcc bne 0x99fe0 |
0x00099fd0 ldr r3, [r5, 0x14] | r3 = *((r5 + 0x14));
0x00099fd4 cmp r3, 0 |
| if (r3 == 0) {
0x00099fd8 ldrne r2, [sp, 4] | r2 = var_4h;
| }
| if (r3 != 0) {
0x00099fdc strbne r2, [r3] | *(r3) = r2;
| goto label_37;
| }
| }
| label_37:
0x00099fe0 ldr r1, [r5, 8] | r1 = *((r5 + 8));
0x00099fe4 ldrd r2, r3, [r4, 0x30] | __asm ("ldrd r2, r3, [r4, 0x30]");
0x00099fe8 ldr r5, [r5] | r5 = *(r5);
0x00099fec adds r8, r2, r1 | r8 = r2 + r1;
0x00099ff0 adc sb, r3, r1, asr 31 | __asm ("adc sb, r3, r1, asr 31");
0x00099ff4 mov r2, r8 | r2 = r8;
0x00099ff8 mov r3, sb | r3 = sb;
0x00099ffc strd r2, r3, [r4, 0x30] | __asm ("strd r2, r3, [r4, 0x30]");
0x0009a000 add r6, r6, r1 | r6 += r1;
0x0009a004 b 0x99ed8 | goto label_1;
| label_27:
0x0009a008 mov r8, r3 | r8 = r3;
0x0009a00c b 0x99f28 | goto label_2;
| label_29:
0x0009a010 ldr r2, [r5, 0x14] | r2 = *((r5 + 0x14));
0x0009a014 cmp r2, 0 |
| if (r2 == 0) {
0x0009a018 subne r2, r2, 1 | r2--;
| }
| if (r2 == 0) {
0x0009a01c strne r2, [r5, 0x14] | *((r5 + 0x14)) = r2;
| }
0x0009a020 b 0x99f38 | goto label_3;
| label_34:
0x0009a024 cmp r3, 8 |
| if (r3 == 8) {
0x0009a028 beq 0x9a1cc | goto label_38;
| }
0x0009a02c cmp r3, 0x10 |
0x0009a030 bne 0x99fc8 |
| } while (r3 != 0x10);
0x0009a034 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x0009a038 cmp r2, 4 |
| if (r2 == 4) {
0x0009a03c beq 0x9a10c | goto label_39;
| }
0x0009a040 cmp r2, 8 |
| if (r2 != 8) {
0x0009a044 bne 0x99fc8 | goto label_4;
| }
0x0009a048 mov r1, r6 | r1 = r6;
0x0009a04c add r0, sp, 0x18 | r0 += s1;
0x0009a050 bl 0x14624 | memcpy (r0, r1, r2);
0x0009a054 ldrd r2, r3, [sp, 0x18] | __asm ("ldrd r2, r3, [s1]");
0x0009a058 b 0x9a128 | goto label_40;
| label_32:
0x0009a05c cmp r3, 0x100 |
| if (r3 == 0x100) {
0x0009a060 beq 0x9a17c | goto label_41;
| }
| if (r3 > 0x100) {
0x0009a064 bhi 0x9a080 | goto label_42;
| }
0x0009a068 cmp r3, 0x40 |
| if (r3 == 0x40) {
0x0009a06c beq 0x9a168 | goto label_43;
| }
0x0009a070 cmp r3, 0x80 |
| if (r3 != 0x80) {
0x0009a074 bne 0x99fc8 | goto label_4;
| }
0x0009a078 mov r1, r6 | r1 = r6;
0x0009a07c b 0x9a0a0 | goto label_5;
| label_42:
0x0009a080 cmp r3, 0x200 |
| if (r3 == 0x200) {
0x0009a084 beq 0x9a1d4 | goto label_44;
| }
0x0009a088 cmp r3, 0x400 |
| if (r3 != 0x400) {
0x0009a08c bne 0x99fc8 | goto label_4;
| }
0x0009a090 ldr r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0009a094 bl 0x1436c | printf (r0);
0x0009a098 b 0x99fc8 | goto label_4;
| label_35:
0x0009a09c ldr r1, [r4, 0x30] | r1 = *((r4 + 0x30));
| do {
| label_5:
0x0009a0a0 ldr r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0009a0a4 bl 0x1436c | printf (r0, r1);
0x0009a0a8 b 0x99fc8 | goto label_4;
| label_36:
0x0009a0ac ldr r1, [pc, 0x344] | r1 = " -0+#";
0x0009a0b0 b 0x9a0a0 |
| } while (1);
| label_33:
0x0009a0b4 ldrb r2, [r6] | r2 = *(r6);
0x0009a0b8 ldr r1, [pc, 0x33c] | r1 = *(0x9a3f8);
| do {
0x0009a0bc ldrb r3, [r1] | r3 = *(r1);
0x0009a0c0 cmp r3, r2 |
| if (r3 == r2) {
0x0009a0c4 bne 0x9a0dc |
0x0009a0c8 add r1, r1, 1 | r1++;
| label_6:
0x0009a0cc ldr r3, [r5, 0xc] | r3 = *((r5 + 0xc));
0x0009a0d0 mov r2, 0x73 | r2 = 0x73;
0x0009a0d4 strb r2, [r3] | *(r3) = r2;
0x0009a0d8 b 0x9a0a0 | goto label_5;
| }
0x0009a0dc ldrb r3, [r1, 4]! | r3 = *((r1 += 4));
0x0009a0e0 cmp r3, 0 |
0x0009a0e4 bne 0x9a0bc |
| } while (r3 != 0);
0x0009a0e8 sub r3, r2, 0x20 | r3 = r2 - 0x20;
0x0009a0ec cmp r3, 0x5e |
| if (r3 > 0x5e) {
0x0009a0f0 ldrls r3, [r5, 0xc] | r3 = *((r5 + 0xc));
| }
| if (r3 < 0x5e) {
0x0009a0f4 bls 0x9a1c4 | goto label_45;
| }
0x0009a0f8 ldr r1, [pc, 0x300] | r1 = *(0x9a3fc);
0x0009a0fc add r0, sp, 0x18 | r0 += s1;
0x0009a100 bl 0x14f48 | sprintf (r0, r1, r2)
0x0009a104 add r1, sp, 0x18 | r1 += s1;
0x0009a108 b 0x9a0cc | goto label_6;
| label_39:
0x0009a10c mov r1, r6 | r1 = r6;
0x0009a110 add r0, sp, 0x18 | r0 += s1;
0x0009a114 bl 0x14624 | memcpy (r0, r1, r2);
0x0009a118 ldr r0, [sp, 0x18] | r0 = s1;
0x0009a11c bl 0xa6a9c | r0 = fcn_000a6a9c (r0);
0x0009a120 mov r2, r0 | r2 = r0;
0x0009a124 mov r3, r1 | r3 = r1;
| label_40:
0x0009a128 ldr r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0009a12c bl 0x1436c | printf (r0, r1, r2, r3);
0x0009a130 b 0x99fc8 | goto label_4;
| label_31:
0x0009a134 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x0009a138 cmp r2, 2 |
| if (r2 == 2) {
0x0009a13c beq 0x9a154 | goto label_46;
| }
| label_7:
0x0009a140 cmp r2, 4 |
| if (r2 == 4) {
0x0009a144 beq 0x9a1f4 | goto label_47;
| }
0x0009a148 cmp r2, 1 |
| if (r2 != 1) {
0x0009a14c bne 0x99fc8 | goto label_4;
| }
0x0009a150 b 0x9a1cc | goto label_38;
| label_46:
0x0009a154 mov r1, r6 | r1 = r6;
0x0009a158 add r0, sp, 0x18 | r0 += s1;
0x0009a15c bl 0x14624 | memcpy (r0, r1, r2);
0x0009a160 ldrsh r1, [sp, 0x18] | r1 = s1;
0x0009a164 b 0x9a0a0 | goto label_5;
| label_43:
0x0009a168 ldrb r1, [r6] | r1 = *(r6);
0x0009a16c sub r3, r1, 0x20 | r3 = r1 - 0x20;
0x0009a170 cmp r3, 0x5f |
| if (r3 < 0x5f) {
0x0009a174 movhs r1, 0x2e | r1 = 0x2e;
| }
0x0009a178 b 0x9a0a0 | goto label_5;
| label_41:
0x0009a17c ldrb r2, [r6] | r2 = *(r6);
0x0009a180 ldr r3, [r5, 0xc] | r3 = *((r5 + 0xc));
0x0009a184 cmp r2, 0x1f |
| if (r2 <= 0x1f) {
0x0009a188 bhi 0x9a1a4 |
0x0009a18c mov r2, 0x73 | r2 = 0x73;
0x0009a190 strb r2, [r3] | *(r3) = r2;
0x0009a194 ldr r3, [pc, 0x268] | r3 = "%03o";
0x0009a198 ldrb r1, [r6] | r1 = *(r6);
0x0009a19c add r1, r3, r1, lsl 2 | r1 = r3 + (r1 << 2);
0x0009a1a0 b 0x9a0a0 | goto label_5;
| }
0x0009a1a4 cmp r2, 0x7f |
| if (r2 != 0x7f) {
0x0009a1a8 moveq r2, 0x73 | r2 = 0x73;
| }
| if (r2 != 0x7f) {
0x0009a1ac strbeq r2, [r3] | *(r3) = r2;
| }
| if (r2 == 0x7f) {
0x0009a1b0 ldreq r1, [pc, 0x250] | r1 = *((pc + 0x250));
| goto label_48;
| }
| if (r2 == 0x7f) {
| label_48:
0x0009a1b4 beq 0x9a0a0 | goto label_5;
| }
0x0009a1b8 cmp r2, 0x7e |
| if (r2 <= 0x7e) {
0x0009a1bc movhi r2, 0x78 | r2 = 0x78;
| }
| if (r2 <= 0x7e) {
0x0009a1c0 bhi 0x9a1c8 |
| label_45:
0x0009a1c4 mov r2, 0x63 | r2 = 0x63;
| }
0x0009a1c8 strb r2, [r3] | *(r3) = r2;
| label_38:
0x0009a1cc ldrb r1, [r6] | r1 = *(r6);
0x0009a1d0 b 0x9a0a0 | goto label_5;
| label_44:
0x0009a1d4 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x0009a1d8 cmp r2, 2 |
| if (r2 != 2) {
0x0009a1dc bne 0x9a140 | goto label_7;
| }
0x0009a1e0 mov r1, r6 | r1 = r6;
0x0009a1e4 add r0, sp, 0x18 | r0 += s1;
0x0009a1e8 bl 0x14624 | memcpy (r0, r1, r2);
0x0009a1ec ldrh r1, [sp, 0x18] | r1 = s1;
0x0009a1f0 b 0x9a0a0 | goto label_5;
| label_47:
0x0009a1f4 mov r1, r6 | r1 = r6;
0x0009a1f8 add r0, sp, 0x18 | r0 += s1;
0x0009a1fc bl 0x14624 | memcpy (r0, r1, r2);
0x0009a200 ldr r1, [sp, 0x18] | r1 = s1;
0x0009a204 b 0x9a0a0 | goto label_5;
| label_20:
0x0009a208 ldr r2, [r4, 0x4c] | r2 = *((r4 + 0x4c));
0x0009a20c strd r2, r3, [r4, 0x48] | __asm ("strd r2, r3, [r4, 0x48]");
0x0009a210 ldrd r2, r3, [r4, 0x20] | __asm ("ldrd r2, r3, [r4, 0x20]");
0x0009a214 adds r0, r2, r5 | r0 = r2 + r5;
0x0009a218 adc r1, r3, r5, asr 31 | __asm ("adc r1, r3, r5, asr 31");
0x0009a21c strd r0, r1, [r4, 0x20] | __asm ("strd r0, r1, [r4, 0x20]");
0x0009a220 strd r0, r1, [r4, 0x30] | __asm ("strd r0, r1, [r4, 0x30]");
0x0009a224 b 0x99dd4 | goto label_8;
| label_21:
0x0009a228 ldr r3, [r4, 0x44] | r3 = *((r4 + 0x44));
0x0009a22c cmp r3, 0 |
| if (r3 == 0) {
0x0009a230 beq 0x9a244 | goto label_49;
| }
0x0009a234 mov r0, r4 | r0 = r4;
0x0009a238 bl 0x99a98 | r0 = fcn_00099a98 (r0);
0x0009a23c cmp r0, 0 |
| if (r0 == 0) {
0x0009a240 beq 0x99df8 | goto label_9;
| }
| label_49:
0x0009a244 ldr r2, [r4, 8] | r2 = *((r4 + 8));
0x0009a248 ldr r0, [r4, 0x48] | r0 = *((r4 + 0x48));
0x0009a24c cmn r2, 1 |
0x0009a250 add r0, r0, r6 | r0 += r6;
| if (r2 != 1) {
0x0009a254 moveq r2, r7 | r2 = r7;
| }
| if (r2 != 1) {
0x0009a258 beq 0x9a264 |
0x0009a25c cmp r2, r7 |
| if (r2 >= r7) {
0x0009a260 movge r2, r7 | r2 = r7;
| goto label_50;
| }
| }
| label_50:
0x0009a264 ldr r3, [sl] | r3 = *(sl);
0x0009a268 mov r1, 1 | r1 = 1;
0x0009a26c bl 0x14d08 | r0 = fread (r0, r1, r2, r3);
0x0009a270 cmp r0, 0 |
| if (r0 != 0) {
0x0009a274 bne 0x9a308 | goto label_51;
| }
0x0009a278 ldr r3, [sl] | r3 = *(sl);
0x0009a27c ldrh r3, [r3] | r3 = *(r3);
0x0009a280 tst r3, 8 |
| if ((r3 & 8) != 0) {
0x0009a284 beq 0x9a294 |
0x0009a288 ldr r3, [r4, 0x18] | r3 = *((r4 + 0x18));
0x0009a28c ldr r0, [r3, -4] | r0 = *((r3 - 4));
0x0009a290 bl 0x18018 | fcn_00018018 (r0);
| }
0x0009a294 mov r3, 1 | r3 = 1;
0x0009a298 str r3, [r4, 0x44] | *((r4 + 0x44)) = r3;
0x0009a29c b 0x99dec | goto label_10;
| label_22:
0x0009a2a0 mov r2, r7 | r2 = r7;
0x0009a2a4 mov r1, 0 | r1 = 0;
0x0009a2a8 add r0, r5, r6 | r0 = r5 + r6;
0x0009a2ac bl 0x14d98 | memset (r0, r1, r2);
0x0009a2b0 ldrd r2, r3, [r4, 0x30] | __asm ("ldrd r2, r3, [r4, 0x30]");
0x0009a2b4 ldr r7, [r4, 0x48] | r7 = *((r4 + 0x48));
0x0009a2b8 adds r0, r2, r6 | r0 = r2 + r6;
0x0009a2bc adc r1, r3, r6, asr 31 | __asm ("adc r1, r3, r6, asr 31");
0x0009a2c0 strd r0, r1, [r4, 0x28] | __asm ("strd r0, r1, [r4, 0x28]");
| label_15:
0x0009a2c4 cmp r7, 0 |
| if (r7 == 0) {
0x0009a2c8 beq 0x99e38 | goto label_11;
| }
0x0009a2cc ldrd r2, r3, [r4, 0x30] | __asm ("ldrd r2, r3, [r4, 0x30]");
0x0009a2d0 ldr fp, [r4, 0x10] | fp = *((r4 + 0x10));
0x0009a2d4 strd r2, r3, [sp, 8] | __asm ("strd r2, r3, [var_8h]");
| label_14:
0x0009a2d8 cmp fp, 0 |
| if (fp == 0) {
0x0009a2dc beq 0x99da0 | goto label_12;
| }
0x0009a2e0 ldr r3, [fp, 4] | r3 = *(arg_4h);
0x0009a2e4 mov r6, r7 | r6 = r7;
0x0009a2e8 str r3, [sp] | *(sp) = r3;
| label_26:
0x0009a2ec ldr r3, [sp] | r3 = *(sp);
0x0009a2f0 cmp r3, 0 |
| if (r3 != 0) {
0x0009a2f4 bne 0x99ea8 | goto label_13;
| }
| label_25:
0x0009a2f8 ldrd r2, r3, [sp, 8] | __asm ("ldrd r2, r3, [var_8h]");
0x0009a2fc ldr fp, [fp] | fp = *(fp);
0x0009a300 strd r2, r3, [r4, 0x30] | __asm ("strd r2, r3, [r4, 0x30]");
0x0009a304 b 0x9a2d8 | goto label_14;
| label_51:
0x0009a308 mov r3, 0 | r3 = 0;
0x0009a30c str r3, [r4, 0x44] | *((r4 + 0x44)) = r3;
0x0009a310 ldr r3, [r4, 8] | r3 = *((r4 + 8));
0x0009a314 cmn r3, 1 |
| if (r3 == 1) {
0x0009a318 subne r3, r3, r0 | r3 -= r0;
| }
| if (r3 == 1) {
0x0009a31c strne r3, [r4, 8] | *((r4 + 8)) = r3;
| }
0x0009a320 subs r7, r7, r0 | r7 -= r0;
| if (r7 == r7) {
0x0009a324 bne 0x9a3a0 |
0x0009a328 ldr r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x0009a32c ldr r7, [r4, 0x48] | r7 = *((r4 + 0x48));
0x0009a330 bics r2, r3, 2 | __asm ("bics r2, r3, 2");
| if (r7 != r7) {
0x0009a334 beq 0x9a358 |
0x0009a338 mov r2, r5 | r2 = r5;
0x0009a33c ldr r1, [r4, 0x4c] | r1 = *((r4 + 0x4c));
0x0009a340 mov r0, r7 | r0 = r7;
0x0009a344 str r3, [sp] | *(sp) = r3;
0x0009a348 bl 0x14c60 | memcmp (r0, r1, r2);
0x0009a34c ldr r3, [sp] | r3 = *(sp);
0x0009a350 subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 == r0) {
0x0009a354 beq 0x9a36c | goto label_52;
| }
| }
0x0009a358 sub r3, r3, 1 | r3--;
0x0009a35c cmp r3, 1 |
| if (r3 > 1) {
0x0009a360 movls r3, 3 | r3 = 3;
| }
| if (r3 > 1) {
0x0009a364 strls r3, [r4, 0xc] | *((r4 + 0xc)) = r3;
| }
0x0009a368 b 0x9a2c4 | goto label_15;
| label_52:
0x0009a36c cmp r3, 3 |
| if (r3 == 3) {
0x0009a370 bne 0x9a37c |
0x0009a374 mov r0, fp | r0 = fp;
0x0009a378 bl 0x14660 | puts (r0);
| }
0x0009a37c mov r3, 1 | r3 = 1;
0x0009a380 str r3, [r4, 0xc] | *((r4 + 0xc)) = r3;
0x0009a384 ldrd r2, r3, [r4, 0x20] | __asm ("ldrd r2, r3, [r4, 0x20]");
0x0009a388 mov r7, r5 | r7 = r5;
0x0009a38c adds r0, r2, r8 | r0 = r2 + r8;
0x0009a390 adc r1, r3, sb | __asm ("adc r1, r3, sb");
0x0009a394 strd r0, r1, [r4, 0x20] | __asm ("strd r0, r1, [r4, 0x20]");
0x0009a398 strd r0, r1, [r4, 0x30] | __asm ("strd r0, r1, [r4, 0x30]");
0x0009a39c b 0x99dec | goto label_10;
| }
0x0009a3a0 add r6, r6, r0 | r6 += r0;
0x0009a3a4 b 0x99dec | goto label_10;
| label_24:
0x0009a3a8 ldr r3, [r5, 4] | r3 = *((r5 + 4));
0x0009a3ac cmp r3, 1 |
| if (r3 == 1) {
0x0009a3b0 beq 0x9a3c4 | goto label_53;
| }
0x0009a3b4 cmp r3, 0x400 |
| if (r3 == 0x400) {
0x0009a3b8 beq 0x9a3d4 | goto label_54;
| }
| do {
| label_17:
0x0009a3bc ldr r5, [r5] | r5 = *(r5);
0x0009a3c0 b 0x99e64 | goto label_16;
| label_53:
0x0009a3c4 ldr r1, [r4, 0x28] | r1 = *((r4 + 0x28));
0x0009a3c8 ldr r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0009a3cc bl 0x1436c | printf (r0, r1);
0x0009a3d0 b 0x9a3bc |
| } while (1);
| label_54:
0x0009a3d4 ldr r0, [r5, 0x10] | r0 = *((r5 + 0x10));
0x0009a3d8 bl 0x1436c | printf (r0);
0x0009a3dc b 0x9a3bc | goto label_17;
| label_28:
0x0009a3e0 strb r1, [r8, 1] | *((r8 + 1)) = r1;
0x0009a3e4 b 0x99f7c | goto label_18;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0x9eb14 */
| #include <stdint.h>
|
; (fcn) fcn.0009eb14 () | void fcn_0009eb14 (int32_t arg_1h, int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_14h;
| r0 = arg1;
0x0009eb14 ldr r3, [pc, 0x3c4] | r3 = *(0x9eedc);
0x0009eb18 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0009eb1c ldr r4, [r3] | r4 = *(0x9eedc);
0x0009eb20 sub sp, sp, 0x14 |
0x0009eb24 ldr r3, [r4] |
0x0009eb28 ldr r3, [r3] | r3 = *(0x9eedc);
0x0009eb2c tst r3, 2 |
| if ((r3 & 2) == 0) {
0x0009eb30 beq 0x9eed8 | goto label_3;
| }
0x0009eb34 ldr r3, [r0] | r3 = *(r0);
0x0009eb38 mov r5, r0 | r5 = r0;
0x0009eb3c cmp r3, 0 |
| if (r3 == 0) {
0x0009eb40 beq 0x9ec68 | goto label_4;
| }
0x0009eb44 ldr r3, [r4, 0x38] | r3 = *((r4 + 0x38));
0x0009eb48 cmp r3, 0 |
| if (r3 == 0) {
0x0009eb4c beq 0x9eed8 | goto label_3;
| }
0x0009eb50 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x0009eb54 mov r5, 0 | r5 = 0;
0x0009eb58 str r3, [sp, 4] | var_4h = r3;
0x0009eb5c bl 0x9e54c | fcn_0009e54c ();
0x0009eb60 ldr r7, [r4, 0x38] | r7 = *((r4 + 0x38));
0x0009eb64 mov r6, r5 | r6 = r5;
| do {
0x0009eb68 cmp r7, r6 |
| if (r7 <= r6) {
0x0009eb6c bgt 0x9ebd4 |
0x0009eb70 add r3, r5, 2 | r3 = r5 + 2;
0x0009eb74 mov r1, r3 | r1 = r3;
0x0009eb78 ldr r0, [r4, 4] | r0 = *((r4 + 4));
0x0009eb7c str r3, [sp] | *(sp) = r3;
0x0009eb80 bl 0xa65d4 | r0 = fcn_000a65d4 (r0, r1);
0x0009eb84 cmp r0, 1 |
0x0009eb88 mov r8, r0 | r8 = r0;
| if (r0 > 1) {
0x0009eb8c movle r5, r7 | r5 = r7;
| }
| if (r0 > 1) {
0x0009eb90 movle r8, 1 | r8 = 1;
| }
| if (r0 > 1) {
0x0009eb94 ble 0x9ebb0 |
0x0009eb98 mov r1, r8 | r1 = r8;
0x0009eb9c mov r0, r7 | r0 = r7;
0x0009eba0 bl 0xa6778 | fcn_000a6778 (r0, r1);
0x0009eba4 cmp r1, 0 |
0x0009eba8 mov r5, r0 | r5 = r0;
| if (r1 != 0) {
0x0009ebac addne r5, r0, 1 | r5 = r0 + 1;
| goto label_5;
| }
| }
| label_5:
0x0009ebb0 lsl r3, r5, 2 | r3 = r5 << 2;
0x0009ebb4 mov r6, 0 | r6 = 0;
0x0009ebb8 str r3, [sp, 8] | var_8h = r3;
| label_0:
0x0009ebbc cmp r5, r6 |
| if (r5 <= r6) {
0x0009ebc0 ble 0x9ec48 | goto label_6;
| }
0x0009ebc4 lsl fp, r6, 2 |
0x0009ebc8 mov sl, r6 | sl = r6;
0x0009ebcc mov sb, 1 | sb = 1;
0x0009ebd0 b 0x9ec14 | goto label_7;
| }
0x0009ebd4 ldr r3, [r4, 0x34] | r3 = *((r4 + 0x34));
0x0009ebd8 ldr r0, [r3, r6, lsl 2] | offset_0 = r6 << 2;
| r0 = *((r3 + offset_0));
0x0009ebdc bl 0x1514c | strlen (r0);
0x0009ebe0 add r6, r6, 1 | r6++;
0x0009ebe4 cmp r5, r0 |
| if (r5 >= r0) {
0x0009ebe8 movlt r5, r0 | r5 = r0;
| }
0x0009ebec b 0x9eb68 |
| } while (1);
| do {
0x0009ebf0 str r1, [sp, 0xc] | var_ch = r1;
0x0009ebf4 bl 0x1514c | strlen (r0);
0x0009ebf8 ldr r2, [sp] | r2 = *(sp);
0x0009ebfc ldr r3, [pc, 0x2e0] | r3 = *(0x9eee0);
0x0009ec00 ldr r1, [sp, 0xc] | r1 = var_ch;
0x0009ec04 add sb, sb, 1 | sb++;
0x0009ec08 sub r2, r2, r0 | r2 -= r0;
0x0009ec0c ldr r0, [pc, 0x2d4] | r0 = *(0x9eee4);
0x0009ec10 bl 0x1436c | printf (r0, r1, r2, r3);
| label_7:
0x0009ec14 ldr r3, [r4, 0x34] | r3 = *((r4 + 0x34));
0x0009ec18 cmp sb, r8 |
0x0009ec1c ldr r1, [r3, fp] | r1 = *((r3 + fp));
0x0009ec20 mov r0, r1 | r0 = r1;
| if (sb == r8) {
0x0009ec24 beq 0x9ec3c | goto label_8;
| }
0x0009ec28 ldr r3, [sp, 8] | r3 = var_8h;
0x0009ec2c add sl, sl, r5 | sl += r5;
0x0009ec30 cmp r7, sl |
0x0009ec34 add fp, fp, r3 |
0x0009ec38 bgt 0x9ebf0 |
| } while (r7 > sl);
| label_8:
0x0009ec3c bl 0x14660 | puts (r0);
0x0009ec40 add r6, r6, 1 | r6++;
0x0009ec44 b 0x9ebbc | goto label_0;
| label_6:
0x0009ec48 ldr r1, [r4, 0x18] | r1 = *((r4 + 0x18));
0x0009ec4c ldr r3, [sp, 4] | r3 = var_4h;
0x0009ec50 mov r2, 1 | r2 = 1;
0x0009ec54 sub r1, r1, r3 | r1 -= r3;
0x0009ec58 mov r0, 0 | r0 = 0;
0x0009ec5c add sp, sp, 0x14 |
0x0009ec60 pop {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0009ec64 b 0x9e584 | void (*0x9e584)() ();
| label_4:
0x0009ec68 mov r3, 1 | r3 = 1;
0x0009ec6c str r3, [r0] | *(r0) = r3;
0x0009ec70 mov r0, 0x800 | r0 = 0x800;
0x0009ec74 bl 0x18968 | fcn_00018968 (r0);
0x0009ec78 ldr r2, [r4, 0x14] | r2 = *((r4 + 0x14));
0x0009ec7c ldr r1, [r4, 0x20] | r1 = *((r4 + 0x20));
0x0009ec80 add r2, r2, 1 | r2++;
0x0009ec84 mov r7, r0 | r7 = r0;
0x0009ec88 bl 0xa40f4 | fcn_000a40f4 (r0);
0x0009ec8c mov r0, r7 | r0 = r7;
0x0009ec90 bl 0x9d540 | r0 = fcn_0009d540 (r0);
0x0009ec94 mov r6, r0 | r6 = r0;
0x0009ec98 bl 0x9d4b0 | fcn_0009d4b0 ();
0x0009ec9c ldr r3, [r4, 0x34] | r3 = *((r4 + 0x34));
0x0009eca0 cmp r3, 0 |
| if (r3 == 0) {
0x0009eca4 bne 0x9ecb8 |
0x0009eca8 mov r1, r6 | r1 = r6;
0x0009ecac mov r0, r7 | r0 = r7;
0x0009ecb0 bl 0x9e7e0 | r0 = fcn_0009e7e0 (r0, r1);
0x0009ecb4 mov r8, r0 | r8 = r0;
| }
0x0009ecb8 mov r0, r7 | r0 = r7;
0x0009ecbc bl 0x1514c | strlen (r0);
0x0009ecc0 ldr sl, [pc, 0x224] | sl = " `\"#$%^&*()=+{}[]:;'|\\<>";
0x0009ecc4 add sb, r7, r0 | sb = r7 + r0;
0x0009ecc8 sub r6, sb, r8 | r6 = sb - r8;
| do {
0x0009eccc cmp r6, sb |
| if (r6 > sb) {
0x0009ecd0 blo 0x9ed64 |
0x0009ecd4 ldr r0, [r4, 0x34] | r0 = *((r4 + 0x34));
0x0009ecd8 ldr r1, [r4, 0x38] | r1 = *((r4 + 0x38));
0x0009ecdc cmp r0, 0 |
| if (r0 != 0) {
0x0009ece0 beq 0x9ed1c |
0x0009ece4 bl 0x98a10 | fcn_00098a10 ();
0x0009ece8 mov fp, 0 |
0x0009ecec mov r6, fp | r6 = fp;
| label_1:
0x0009ecf0 ldr r1, [r4, 0x38] | r1 = *((r4 + 0x38));
0x0009ecf4 ldr sb, [r4, 0x34] | sb = *((r4 + 0x34));
0x0009ecf8 sub r1, r1, 1 | r1--;
0x0009ecfc cmp r1, r6 |
0x0009ed00 lsl r0, r6, 2 | r0 = r6 << 2;
0x0009ed04 ldr sl, [sb, r6, lsl 2] | offset_1 = r6 << 2;
| sl = *((sb + offset_1));
0x0009ed08 lsl r2, fp, 2 | r2 = fp << 2;
0x0009ed0c add r3, fp, 1 | r3 += arg_1h;
| if (r1 > r6) {
0x0009ed10 bhi 0x9ed7c | goto label_9;
| }
0x0009ed14 str sl, [sb, r2] | *((sb + r2)) = sl;
0x0009ed18 str r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
| }
0x0009ed1c ldr r3, [r4, 0x38] | r3 = *((r4 + 0x38));
0x0009ed20 cmp r3, 1 |
| if (r3 == 1) {
0x0009ed24 beq 0x9ee98 | goto label_10;
| }
0x0009ed28 bl 0x9d8c4 | fcn_0009d8c4 ();
0x0009ed2c ldr r5, [r4, 0x34] | r5 = *((r4 + 0x34));
0x0009ed30 cmp r5, 0 |
| if (r5 == 0) {
0x0009ed34 beq 0x9ee80 | goto label_11;
| }
0x0009ed38 ldr r0, [r5] | r0 = *(r5);
0x0009ed3c bl 0x189d4 | r0 = fcn_000189d4 (r0);
0x0009ed40 mov r5, r0 | r5 = r0;
0x0009ed44 mov r3, r0 | r3 = r0;
| label_2:
0x0009ed48 ldrb r1, [r3] | r1 = *(r3);
0x0009ed4c cmp r1, 0 |
| if (r1 == 0) {
0x0009ed50 beq 0x9eddc | goto label_12;
| }
0x0009ed54 ldr ip, [r4, 0x38] | ip = *((r4 + 0x38));
0x0009ed58 mov r2, 1 | r2 = 1;
0x0009ed5c sub r0, r3, r5 | r0 = r3 - r5;
0x0009ed60 b 0x9edcc | goto label_13;
| }
0x0009ed64 ldrb r1, [r6], 1 | r1 = *(r6);
| r6++;
0x0009ed68 mov r0, sl | r0 = sl;
0x0009ed6c bl 0x1517c | r0 = strchr (r0, r1);
0x0009ed70 cmp r0, 0 |
| if (r0 == 0) {
0x0009ed74 addne r8, r8, 1 | r8++;
| }
0x0009ed78 b 0x9eccc |
| } while (1);
| label_9:
0x0009ed7c add r0, sb, r0 | r0 = sb + r0;
0x0009ed80 ldr r1, [r0, 4] | r1 = *((r0 + 4));
0x0009ed84 mov r0, sl | r0 = sl;
0x0009ed88 stm sp, {r2, r3} | *(sp) = r2;
| *((sp + 4)) = r3;
0x0009ed8c bl 0x14ed0 | strcmp (r0, r1);
0x0009ed90 ldm sp, {r2, r3} | r2 = *(sp);
| r3 = *((sp + 4));
0x0009ed94 add r6, r6, 1 | r6++;
0x0009ed98 cmp r0, 0 |
| if (r0 == 0) {
0x0009ed9c strne sl, [sb, r2] | *((sb + r2)) = sl;
| }
| if (r0 != 0) {
0x0009eda0 movne fp, r3 | goto label_14;
| }
| if (r0 != 0) {
| label_14:
0x0009eda4 bne 0x9ecf0 | goto label_1;
| }
0x0009eda8 mov r0, sl | r0 = sl;
0x0009edac bl 0x152a8 | free (r0);
0x0009edb0 b 0x9ecf0 | goto label_1;
| do {
0x0009edb4 ldr lr, [r4, 0x34] |
0x0009edb8 ldr lr, [lr, r2, lsl 2] |
0x0009edbc ldrb lr, [lr, r0] |
0x0009edc0 cmp lr, r1 |
| if (lr != r1) {
0x0009edc4 bne 0x9eddc | goto label_12;
| }
0x0009edc8 add r2, r2, 1 | r2++;
| label_13:
0x0009edcc cmp ip, r2 |
0x0009edd0 bhi 0x9edb4 |
| } while (ip > r2);
0x0009edd4 add r3, r3, 1 | r3++;
0x0009edd8 b 0x9ed48 | goto label_2;
| label_12:
0x0009eddc cmp r3, r5 |
| if (r3 == r5) {
0x0009ede0 beq 0x9ee80 | goto label_11;
| }
0x0009ede4 mov r2, 0 | r2 = 0;
0x0009ede8 strb r2, [r3] | *(r3) = r2;
0x0009edec mov r0, r5 | r0 = r5;
0x0009edf0 bl 0x9e774 | r0 = fcn_0009e774 (r0);
0x0009edf4 mov sb, r0 | sb = r0;
0x0009edf8 mov r0, r5 | r0 = r5;
0x0009edfc bl 0x152a8 | free (r0);
0x0009ee00 mov r0, sb | r0 = sb;
0x0009ee04 bl 0x1514c | strlen (r0);
0x0009ee08 mov r5, sb | r5 = sb;
0x0009ee0c mov r6, r0 | r6 = r0;
| do {
0x0009ee10 ldr r3, [r4, 0x18] | r3 = *((r4 + 0x18));
0x0009ee14 ldr r2, [r4, 0x1c] | r2 = *((r4 + 0x1c));
0x0009ee18 sub r3, r3, r8 | r3 -= r8;
0x0009ee1c add r3, r3, r6 | r3 += r6;
0x0009ee20 cmp r3, r2 |
| if (r3 < r2) {
0x0009ee24 bge 0x9ee80 |
0x0009ee28 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x0009ee2c ldr r1, [r4, 0x20] | r1 = *((r4 + 0x20));
0x0009ee30 mov r0, r7 | r0 = r7;
0x0009ee34 add r1, r1, r3 | r1 += r3;
0x0009ee38 bl 0x142f4 | strcpy (r0, r1);
0x0009ee3c ldr ip, [r4, 0x20] | ip = *((r4 + 0x20));
0x0009ee40 ldr r0, [r4, 0x14] | r0 = *((r4 + 0x14));
0x0009ee44 add r2, r5, r8 | r2 = r5 + r8;
0x0009ee48 mov r3, r7 | r3 = r7;
0x0009ee4c ldr r1, [pc, 0x9c] | r1 = " `\"#$%^&*()=+{}[]:;'|\\<>";
0x0009ee50 add r0, ip, r0 | r0 = ip + r0;
0x0009ee54 bl 0x14f48 | sprintf (r0, " `\"#$%^&*()=+{}[]:;'|\\<>", r2)
0x0009ee58 ldr r0, [r4, 0x20] | r0 = *((r4 + 0x20));
0x0009ee5c bl 0x1514c | strlen (r0);
0x0009ee60 ldr r3, [r4, 0x14] | r3 = *((r4 + 0x14));
0x0009ee64 mov r2, 0 | r2 = 0;
0x0009ee68 sub r8, r3, r8 | r8 = r3 - r8;
0x0009ee6c add r6, r8, r6 | r6 = r8 + r6;
0x0009ee70 str r0, [r4, 0x18] | *((r4 + 0x18)) = r0;
0x0009ee74 sub r1, r0, r6 | r1 = r0 - r6;
0x0009ee78 ldr r0, [r4, 0xc] | r0 = *((r4 + 0xc));
0x0009ee7c bl 0x9e584 | fcn_0009e584 (r0, r1);
| }
| label_11:
0x0009ee80 mov r0, r5 | r0 = r5;
0x0009ee84 bl 0x152a8 | free (r0);
0x0009ee88 mov r0, r7 | r0 = r7;
0x0009ee8c add sp, sp, 0x14 |
0x0009ee90 pop {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0009ee94 b 0x152a8 | void (*0x152a8)() ();
| label_10:
0x0009ee98 ldr r3, [r4, 0x34] | r3 = *((r4 + 0x34));
0x0009ee9c mov sb, 0 | sb = 0;
0x0009eea0 ldr r0, [r3] | r0 = *(r3);
0x0009eea4 str sb, [r5] | *(r5) = sb;
0x0009eea8 bl 0x9e774 | r0 = fcn_0009e774 (r0);
0x0009eeac mov r5, r0 | r5 = r0;
0x0009eeb0 bl 0x1514c | r0 = strlen (r0);
0x0009eeb4 add r3, r5, r0 | r3 = r5 + r0;
0x0009eeb8 ldrb r3, [r3, -1] | r3 = *((r3 - 1));
0x0009eebc mov r6, r0 | r6 = r0;
0x0009eec0 cmp r3, 0x2f |
| if (r3 == 0x2f) {
0x0009eec4 movne r3, 0x20 | r3 = 0x20;
| }
| if (r3 == 0x2f) {
0x0009eec8 addne r6, r0, 1 | r6 = r0 + 1;
| }
| if (r3 == 0x2f) {
0x0009eecc strbne r3, [r5, r0] | *((r5 + r0)) = r3;
| }
| if (r3 == 0x2f) {
0x0009eed0 strbne sb, [r5, r6] | *((r5 + r6)) = sb;
| }
0x0009eed4 b 0x9ee10 |
| } while (1);
| label_3:
0x0009eed8 add sp, sp, 0x14 |
0x0009eedc pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0xa0278 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.000a0278 () | void fcn_000a0278 (int32_t arg_1a0h, int32_t arg1, int32_t arg2) {
| int32_t fildes;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_8h_2;
| char * fd;
| int32_t var_28h;
| int32_t var_38h;
| void * s;
| int32_t var_a8h;
| int32_t var_a8h_2;
| int32_t var_c4h;
| int32_t var_c8h;
| int32_t var_17ch;
| r0 = arg1;
| r1 = arg2;
0x000a0278 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000a027c sub sp, sp, 0x17c |
0x000a0280 strd r2, r3, [sp, 8] | __asm ("strd r2, r3, [var_8h]");
0x000a0284 ldr r3, [sp, 0x1a0] | r3 = *(arg_1a0h);
0x000a0288 mov sl, r0 | sl = r0;
0x000a028c tst r3, 1 |
| if ((r3 & 1) == 0) {
0x000a0290 movne r7, 0 | r7 = 0;
| }
| if ((r3 & 1) != 0) {
0x000a0294 moveq r7, 2 | r7 = 2;
| }
0x000a0298 str r1, [sp, 4] | var_4h = r1;
| do {
0x000a029c mov r1, r7 | r1 = r7;
0x000a02a0 ldr r0, [sp, 4] | r0 = var_4h;
0x000a02a4 bl 0x14df8 | r0 = open64 ();
0x000a02a8 subs r3, r0, 0 | r3 = r0 - 0;
0x000a02ac str r3, [sp] | *(sp) = r3;
| if (r3 >= r0) {
0x000a02b0 bge 0xa02e0 | goto label_6;
| }
0x000a02b4 cmp r7, 0 |
| if (r7 == 0) {
0x000a02b8 bne 0xa02d8 |
0x000a02bc ldr r3, [pc, 0x238] |
0x000a02c0 ldr r3, [r3] | r3 = *(0xa04f8);
0x000a02c4 ldr r4, [r3] | r4 = *(0xa04f8);
0x000a02c8 rsb r4, r4, 0 | r4 -= ;
| label_0:
0x000a02cc mov r0, r4 | r0 = r4;
0x000a02d0 add sp, sp, 0x17c |
0x000a02d4 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x000a02d8 mov r7, 0 | r7 = 0;
0x000a02dc b 0xa029c |
| } while (1);
| label_6:
0x000a02e0 ldr r6, [sl] | r6 = *(sl);
0x000a02e4 mvn r5, 0 | r5 = ~0;
0x000a02e8 cmp r6, 0 |
| if (r6 != 0) {
0x000a02ec addeq r6, sp, 0x10 | r6 += fd;
| }
0x000a02f0 mov r4, r5 | r4 = r5;
0x000a02f4 mov r8, 0 | r8 = 0;
| label_4:
0x000a02f8 ldr r3, [pc, 0x200] | r3 = *(0xa04fc);
0x000a02fc cmp r8, r3 |
| if (r8 <= r3) {
0x000a0300 movgt r3, 0 | r3 = 0;
| }
| if (r8 > r3) {
0x000a0304 movle r3, 1 | r3 = 1;
| }
0x000a0308 cmp r5, 0 |
| if (r5 != 0) {
0x000a030c moveq r3, 0 | r3 = 0;
| }
0x000a0310 cmp r3, 0 |
| if (r3 != 0) {
0x000a0314 bne 0xa0348 | goto label_7;
| }
| label_1:
0x000a0318 ldr r0, [sp] | r0 = *(sp);
0x000a031c bl 0x15260 | close (r0);
0x000a0320 cmp r5, 0 |
| if (r5 != 0) {
0x000a0324 movne r4, r5 | r4 = r5;
| goto label_8;
| }
| if (r5 != 0) {
| label_8:
0x000a0328 bne 0xa02cc | goto label_0;
| }
0x000a032c ldr r3, [sl] | r3 = *(sl);
0x000a0330 cmp r3, 0 |
| if (r3 != 0) {
0x000a0334 bne 0xa02cc | goto label_0;
| }
0x000a0338 add r0, sp, 0x10 | r0 += fd;
0x000a033c bl 0x189d4 | fcn_000189d4 (r0);
0x000a0340 str r0, [sl] | *(sl) = r0;
0x000a0344 b 0xa02cc | goto label_0;
| label_7:
0x000a0348 add fp, sp, 0x10 |
0x000a034c mov r2, r8 | r2 = r8;
0x000a0350 ldr r1, [pc, 0x1ac] | r1 = *(0xa0500);
0x000a0354 mov r0, fp | r0 = fp;
0x000a0358 bl 0x14f48 | sprintf (r0, r1, r2)
0x000a035c ldr r3, [pc, 0x198] | r3 = *(0xa04f8);
0x000a0360 add r1, sp, 0x28 | r1 += var_28h;
0x000a0364 ldr sb, [r3] | sb = *(0xa04f8);
0x000a0368 mov r3, 0 | r3 = 0;
0x000a036c str r3, [sb] | *(sb) = r3;
0x000a0370 mov r0, r6 | r0 = r6;
0x000a0374 bl 0x14420 | r0 = stat64 ();
0x000a0378 cmp r0, 0 |
| if (r0 != 0) {
0x000a037c bne 0xa0470 | goto label_9;
| }
0x000a0380 ldr r3, [sp, 0x38] | r3 = var_38h;
0x000a0384 and r3, r3, 0xf000 | r3 &= 0xf000;
0x000a0388 cmp r3, 0x6000 |
0x000a038c bne 0xa0470 |
| while (r0 == 0) {
0x000a0390 mov r1, r7 | r1 = r7;
0x000a0394 mov r0, r6 | r0 = r6;
0x000a0398 bl 0x14df8 | open64 ();
0x000a039c subs r4, r0, 0 | r4 -= fd;
| if (r4 < fd) {
0x000a03a0 blt 0xa04b0 | goto label_10;
| }
| label_2:
0x000a03a4 add r2, sp, 0x90 | r2 += s;
0x000a03a8 ldr r1, [pc, 0x158] | r1 = "/dev/loop%u";
0x000a03ac mov r0, r4 | r0 = r4;
0x000a03b0 bl 0x14330 | ioctl (r0, "/dev/loop%u");
0x000a03b4 subs r5, r0, 0 | r5 -= fd;
| if (r5 == fd) {
0x000a03b8 beq 0xa04f4 | goto label_11;
| }
0x000a03bc ldr r3, [sb] | r3 = *(sb);
0x000a03c0 cmp r3, 6 |
| if (r3 != 6) {
0x000a03c4 bne 0xa04f4 | goto label_11;
| }
0x000a03c8 mov r1, 0x4c00 | r1 = 0x4c00;
0x000a03cc ldr r2, [sp] | r2 = *(sp);
0x000a03d0 mov r0, r4 | r0 = r4;
0x000a03d4 bl 0x14330 | ioctl (r0, r1);
0x000a03d8 subs r1, r0, 0 | r1 -= fd;
| if (r1 == fd) {
0x000a03dc bne 0xa0464 |
0x000a03e0 mov r2, 0xe8 | r2 = 0xe8;
0x000a03e4 add r0, sp, 0x90 | r0 += s;
0x000a03e8 bl 0x14d98 | memset (r0, r1, r2);
0x000a03ec mov r2, 0x40 | r2 = 0x40;
0x000a03f0 ldr r1, [sp, 4] | r1 = var_4h;
0x000a03f4 add r0, sp, 0xc8 | r0 += var_c8h;
0x000a03f8 bl 0xa40f4 | fcn_000a40f4 (r0);
0x000a03fc ldrd r2, r3, [sp, 8] | __asm ("ldrd r2, r3, [var_8h]");
0x000a0400 ldr r1, [pc, 0x104] | r1 = *(0xa0508);
0x000a0404 strd r2, r3, [sp, 0xa8] | __asm ("strd r2, r3, [var_a8h]");
0x000a0408 ldr r3, [sp, 0x1a0] | r3 = *(arg_1a0h);
0x000a040c add r2, sp, 0x90 | r2 += s;
0x000a0410 bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x000a0414 mov r0, r4 | r0 = r4;
0x000a0418 str r3, [sp, 0xc4] | var_c4h = r3;
0x000a041c bl 0x14330 | ioctl (r0, r1);
0x000a0420 subs r5, r0, 0 | r5 -= fd;
| if (r5 == fd) {
0x000a0424 beq 0xa04e0 | goto label_12;
| }
0x000a0428 ldr r3, [sp, 0xc4] | r3 = var_c4h;
0x000a042c tst r3, 4 |
| if ((r3 & 4) != 0) {
0x000a0430 beq 0xa0454 |
0x000a0434 sub r3, r3, 4 | r3 -= 4;
0x000a0438 add r2, sp, 0x90 | r2 += s;
0x000a043c ldr r1, [pc, 0xc8] | r1 = *(0xa0508);
0x000a0440 mov r0, r4 | r0 = r4;
0x000a0444 str r3, [sp, 0xc4] | var_c4h = r3;
0x000a0448 bl 0x14330 | ioctl (r0, r1);
0x000a044c subs r5, r0, 0 | r5 -= fd;
| if (r5 == fd) {
0x000a0450 beq 0xa04e0 | goto label_12;
| }
| }
0x000a0454 mov r2, 0 | r2 = 0;
0x000a0458 ldr r1, [pc, 0xb0] | r1 = *(0xa050c);
0x000a045c mov r0, r4 | r0 = r4;
0x000a0460 bl 0x14330 | ioctl (r0, r1);
| }
| label_5:
0x000a0464 mov r0, r4 | r0 = r4;
0x000a0468 bl 0x15260 | close (r0);
0x000a046c b 0xa04e0 | goto label_12;
| label_9:
0x000a0470 ldr r3, [sb] | r3 = *(sb);
0x000a0474 cmp r3, 2 |
0x000a0478 cmpeq r6, fp | __asm ("cmpeq r6, fp");
| if (r3 != 2) {
0x000a047c bne 0xa04a8 | goto label_3;
| }
0x000a0480 mov r1, r8 | r1 = r8;
0x000a0484 mov r0, 7 | r0 = 7;
0x000a0488 bl 0xa06e4 | r0 = fcn_000a06e4 ();
0x000a048c mov r2, r0 | r2 = r0;
0x000a0490 mov r3, r1 | r3 = r1;
0x000a0494 mov r0, fp | r0 = fp;
0x000a0498 ldr r1, [pc, 0x74] | r1 = *(0xa0510);
0x000a049c bl 0x1448c | r0 = mknod ();
0x000a04a0 cmp r0, 0 |
0x000a04a4 beq 0xa0390 |
| }
| label_3:
0x000a04a8 mvn r5, 0 | r5 = ~0;
0x000a04ac b 0xa0318 | goto label_1;
| label_10:
0x000a04b0 ldr r3, [sb] | r3 = *(sb);
0x000a04b4 cmp r3, 0x1e |
| if (r3 != 0x1e) {
0x000a04b8 bne 0xa04d4 | goto label_13;
| }
0x000a04bc mov r1, 0 | r1 = 0;
0x000a04c0 mov r0, r6 | r0 = r6;
0x000a04c4 bl 0x14df8 | open64 ();
0x000a04c8 mov r7, 0 | r7 = 0;
0x000a04cc subs r4, r0, 0 | r4 -= fd;
| if (r4 >= fd) {
0x000a04d0 bge 0xa03a4 | goto label_2;
| }
| label_13:
0x000a04d4 ldr r3, [sb] | r3 = *(sb);
0x000a04d8 cmp r3, 6 |
| if (r3 == 6) {
0x000a04dc beq 0xa04a8 | goto label_3;
| }
| label_12:
0x000a04e0 ldr r3, [sl] | r3 = *(sl);
0x000a04e4 cmp r3, 0 |
| if (r3 != 0) {
0x000a04e8 bne 0xa0318 | goto label_1;
| }
0x000a04ec add r8, r8, 1 | r8++;
0x000a04f0 b 0xa02f8 | goto label_4;
| label_11:
0x000a04f4 mvn r5, 0 | r5 = ~0;
0x000a04f8 b 0xa0464 | goto label_5;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0xa1774 */
| #include <stdint.h>
|
; (fcn) fcn.000a1774 () | void fcn_000a1774 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_2ch;
| int32_t var_30h;
| int32_t var_34h;
| int32_t var_38h;
| char * s;
| int32_t var_1h;
| char * var_70h;
| int32_t var_1h_2;
| char * var_0h_2;
| int32_t var_88h;
| int32_t var_8ch;
| int32_t var_470h;
| int32_t var_4h_2;
| r0 = arg1;
| r1 = arg2;
0x000a1774 push {r4, r5, r6, r7, r8, sb, lr} |
0x000a1778 subs r4, r0, 0 | r4 = r0 - 0;
0x000a177c sub sp, sp, 0x470 |
0x000a1780 sub sp, sp, 4 |
0x000a1784 mov r5, r1 | r5 = r1;
| if (r4 != r0) {
0x000a1788 bne 0xa17c8 | goto label_2;
| }
0x000a178c bl 0x1457c | r0 = getpagesize ();
0x000a1790 mov r6, r0 | r6 = r0;
0x000a1794 mov r0, 0x58 | r0 = 0x58;
0x000a1798 bl 0x189b8 | r0 = fcn_000189b8 (r0);
0x000a179c mov r4, r0 | r4 = r0;
0x000a17a0 ldr r0, [pc, 0x2b8] | r0 = *(0xa1a5c);
0x000a17a4 bl 0x18f64 | fcn_00018f64 (r0);
0x000a17a8 str r0, [r4] | *(r4) = r0;
| do {
0x000a17ac lsrs r6, r6, 1 | r6 >>= 1;
0x000a17b0 ldrb r3, [r4, 4] | r3 = *((r4 + 4));
| if (r6 == r6) {
0x000a17b4 addne r3, r3, 1 | r3++;
| }
| if (r6 == r6) {
0x000a17b8 strbne r3, [r4, 4] | *((r4 + 4)) = r3;
| }
0x000a17bc bne 0xa17ac |
| } while (r6 != r6);
0x000a17c0 sub r3, r3, 0xa | r3 -= 0xa;
0x000a17c4 strb r3, [r4, 5] | *((r4 + 5)) = r3;
| label_2:
0x000a17c8 ldr r8, [pc, 0x294] | r8 = *(0xa1a60);
0x000a17cc ldr sb, [pc, 0x294] | sb = *(0x000a1a68);
0x000a17d0 and r8, r8, r5 | r8 &= r5;
| do {
| label_1:
0x000a17d4 ldr r0, [r4] | r0 = *(r4);
0x000a17d8 bl 0x14c48 | r0 = readdir64 ();
0x000a17dc subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 == r0) {
0x000a17e0 bne 0xa1800 |
0x000a17e4 mov r0, r4 | r0 = r4;
0x000a17e8 bl 0xa1748 | fcn_000a1748 (r0);
0x000a17ec mov r4, r6 | r4 = r6;
| label_0:
0x000a17f0 mov r0, r4 | r0 = r4;
0x000a17f4 add sp, sp, 0x470 |
0x000a17f8 add sp, sp, 4 |
0x000a17fc pop {r4, r5, r6, r7, r8, sb, pc} |
| }
0x000a1800 mov r1, 0 | r1 = 0;
0x000a1804 add r0, r6, 0x13 | r0 = r6 + 0x13;
0x000a1808 mov r2, 0xa | r2 = 0xa;
0x000a180c bl 0x1a0ec | fcn_0001a0ec (r0, r1);
0x000a1810 ldr r3, [sb] | r3 = *(sb);
0x000a1814 ldr r1, [r3] | r1 = *(r3);
0x000a1818 cmp r1, 0 |
0x000a181c mov r6, r0 | r6 = r0;
0x000a1820 bne 0xa17d4 |
| } while (r1 != 0);
0x000a1824 mov r2, 0x48 | r2 = 0x48;
0x000a1828 add r0, r4, 0x10 | r0 = r4 + 0x10;
0x000a182c bl 0x14d98 | memset (r0, r1, r2);
0x000a1830 bics r3, r5, 1 | __asm ("bics r3, r5, 1");
0x000a1834 str r6, [r4, 0x24] | *((r4 + 0x24)) = r6;
| if (r1 == 0) {
0x000a1838 beq 0xa17f0 | goto label_0;
| }
0x000a183c mov r2, r6 | r2 = r6;
0x000a1840 ldr r1, [pc, 0x224] | r1 = *(0xa1a68);
0x000a1844 add r0, sp, 0x3c | r0 += s;
0x000a1848 bl 0x14f48 | sprintf (r0, r1, r2)
0x000a184c add r3, sp, 0x3c | r3 += s;
0x000a1850 tst r5, 0x10 |
0x000a1854 add r6, r3, r0 | r6 = r3 + r0;
| if ((r5 & 0x10) == 0) {
0x000a1858 beq 0xa1880 | goto label_3;
| }
0x000a185c add r1, sp, 0x70 | r1 += var_70h;
0x000a1860 mov r0, r3 | r0 = r3;
0x000a1864 bl 0x14420 | r0 = stat64 ();
0x000a1868 cmp r0, 0 |
| if (r0 != 0) {
0x000a186c bne 0xa17d4 | goto label_1;
| }
0x000a1870 ldr r3, [sp, 0x88] | r3 = var_88h;
0x000a1874 str r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
0x000a1878 ldr r3, [sp, 0x8c] | r3 = var_8ch;
0x000a187c str r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
| label_3:
0x000a1880 cmp r8, 0 |
| if (r8 == 0) {
0x000a1884 beq 0xa19cc | goto label_4;
| }
0x000a1888 ldr r1, [pc, 0x1e0] | r1 = *(0xa1a6c);
0x000a188c mov r0, r6 | r0 = r6;
0x000a1890 bl 0x142f4 | strcpy (r0, r1);
0x000a1894 add r1, sp, 0x70 | r1 += var_70h;
0x000a1898 add r0, sp, 0x3c | r0 += s;
0x000a189c bl 0xa1690 | r0 = fcn_000a1690 (r0);
0x000a18a0 cmp r0, 0 |
| if (r0 < 0) {
0x000a18a4 blt 0xa17d4 | goto label_1;
| }
0x000a18a8 mov r1, 0x29 | r1 = 0x29;
0x000a18ac add r0, sp, 0x70 | r0 += var_70h;
0x000a18b0 bl 0x1496c | strrchr (r0, r1);
0x000a18b4 mov r3, 0 | r3 = 0;
0x000a18b8 mov r1, 0x28 | r1 = 0x28;
0x000a18bc mov r7, r0 | r7 = r0;
0x000a18c0 strb r3, [r7], 2 | *(r7) = r3;
| r7 += 2;
0x000a18c4 add r0, sp, 0x70 | r0 += var_70h;
0x000a18c8 bl 0x1517c | strchr (r0, r1);
0x000a18cc mov r2, 0x10 | r2 = 0x10;
0x000a18d0 add r1, r0, 1 | r1 += var_1h_2;
0x000a18d4 add r0, r4, 0x48 | r0 = r4 + 0x48;
0x000a18d8 bl 0xa40f4 | fcn_000a40f4 (r0);
0x000a18dc add r3, sp, 0x38 | r3 += var_38h;
0x000a18e0 str r3, [sp, 0x20] | var_20h = r3;
0x000a18e4 add r3, sp, 0x34 | r3 += var_34h;
0x000a18e8 str r3, [sp, 0x1c] | var_1ch = r3;
0x000a18ec add r3, r4, 0x20 | r3 = r4 + 0x20;
0x000a18f0 str r3, [sp, 0x18] | var_18h = r3;
0x000a18f4 add r2, sp, 0x2c | r2 += var_2ch;
0x000a18f8 add r3, sp, 0x30 | r3 += var_30h;
0x000a18fc str r2, [sp, 0x14] | var_14h = r2;
0x000a1900 str r3, [sp, 8] | var_8h = r3;
0x000a1904 add r2, r4, 0x18 | r2 = r4 + 0x18;
0x000a1908 add r3, r4, 0x30 | r3 = r4 + 0x30;
0x000a190c str r2, [sp, 0x10] | var_10h = r2;
0x000a1910 str r3, [sp, 4] | var_4h = r3;
0x000a1914 add r2, r4, 0x1c | r2 = r4 + 0x1c;
0x000a1918 add r3, r4, 0x2c | r3 = r4 + 0x2c;
0x000a191c str r2, [sp, 0xc] | var_ch = r2;
0x000a1920 str r3, [sp] | *(sp) = r3;
0x000a1924 add r2, r4, 0x44 | r2 = r4 + 0x44;
0x000a1928 add r3, r4, 0x28 | r3 = r4 + 0x28;
0x000a192c ldr r1, [pc, 0x140] | r1 = *(0xa1a70);
0x000a1930 mov r0, r7 | r0 = r7;
0x000a1934 bl 0x14c9c | r0 = sscanf (r0, r1, r2);
0x000a1938 cmp r0, 0xa |
| if (r0 <= 0xa) {
0x000a193c ble 0xa17d4 | goto label_1;
| }
0x000a1940 ldrb r2, [r4, 5] | r2 = *((r4 + 5));
0x000a1944 ldr r3, [sp, 0x38] | r3 = var_38h;
0x000a1948 ldr r1, [sp, 0x34] | r1 = var_34h;
0x000a194c lsl r3, r3, r2 | r3 <<= r2;
0x000a1950 ldr r2, [sp, 0x30] | r2 = var_30h;
0x000a1954 str r3, [r4, 0x14] | *((r4 + 0x14)) = r3;
0x000a1958 ldr r3, [pc, 0x118] | r3 = "%c %u %u %u %d %*s %*s %*s %*s %*s %*s %lu %lu %*s %*s %*s %ld %*s %*s %lu %lu %lu ";
0x000a195c lsr r1, r1, 0xa | r1 >>= 0xa;
0x000a1960 and r3, r3, r2, asr 8 | r3 &= (r2 >> 8);
0x000a1964 str r3, [r4, 0x3c] | *((r4 + 0x3c)) = r3;
0x000a1968 ldr r3, [pc, 0x10c] | r3 = *(0xa1a78);
0x000a196c cmp r1, 0 |
0x000a1970 and r3, r3, r2, asr 12 | r3 &= (r2 >> 12);
0x000a1974 and r2, r2, 0xff | r2 &= 0xff;
0x000a1978 orr r3, r3, r2 | r3 |= r2;
0x000a197c str r3, [r4, 0x40] | *((r4 + 0x40)) = r3;
0x000a1980 mov r3, 0x20 | r3 = 0x20;
0x000a1984 str r1, [r4, 0x10] | *((r4 + 0x10)) = r1;
0x000a1988 strb r3, [r4, 0x45] | *((r4 + 0x45)) = r3;
0x000a198c strb r3, [r4, 0x46] | *((r4 + 0x46)) = r3;
| if (r1 == 0) {
0x000a1990 bne 0xa19ac |
0x000a1994 ldrb r3, [r4, 0x44] | r3 = *((r4 + 0x44));
0x000a1998 cmp r3, 0x5a |
| if (r3 == 0x5a) {
0x000a199c movne r3, 0x57 | r3 = 0x57;
| }
| if (r3 == 0x5a) {
0x000a19a0 strbne r3, [r4, 0x45] | *((r4 + 0x45)) = r3;
| }
| if (r3 == 0x5a) {
0x000a19a4 movne r3, 2 | r3 = 2;
| }
| if (r3 != 0x5a) {
0x000a19a8 bne 0xa19b0 | goto label_5;
| }
| }
0x000a19ac mov r3, 1 | r3 = 1;
| label_5:
0x000a19b0 ldr r2, [sp, 0x2c] | r2 = var_2ch;
0x000a19b4 cmp r2, 0 |
| if (r2 != 0) {
0x000a19b8 beq 0xa19cc |
0x000a19bc add r3, r4, r3 | r3 = r4 + r3;
| if (r2 >= 0) {
0x000a19c0 movlt r2, 0x3c | r2 = 0x3c;
| }
| if (r2 < 0) {
0x000a19c4 movge r2, 0x4e | r2 = 0x4e;
| }
0x000a19c8 strb r2, [r3, 0x44] | *((r3 + 0x44)) = r2;
| }
| label_4:
0x000a19cc tst r5, 0x100 |
| if ((r5 & 0x100) != 0) {
0x000a19d0 beq 0xa19f4 |
0x000a19d4 ldr r1, [pc, 0xa4] | r1 = *(0xa1a7c);
0x000a19d8 mov r0, r6 | r0 = r6;
0x000a19dc bl 0x142f4 | strcpy (r0, r1);
0x000a19e0 ldr r0, [r4, 0xc] | r0 = *((r4 + 0xc));
0x000a19e4 bl 0x152a8 | free (r0);
0x000a19e8 add r0, sp, 0x3c | r0 += s;
0x000a19ec bl 0x19208 | fcn_00019208 (r0);
0x000a19f0 str r0, [r4, 0xc] | *((r4 + 0xc)) = r0;
| }
0x000a19f4 ldr r3, [pc, 0x88] | r3 = "exe";
0x000a19f8 tst r5, r3 |
| if ((r5 & r3) == 0) {
0x000a19fc beq 0xa17f0 | goto label_0;
| }
0x000a1a00 ldr r0, [r4, 8] | r0 = *((r4 + 8));
0x000a1a04 bl 0x152a8 | free (r0);
0x000a1a08 mov r3, 0 | r3 = 0;
0x000a1a0c str r3, [r4, 8] | *((r4 + 8)) = r3;
0x000a1a10 ldr r1, [pc, 0x70] | r1 = "_lib_ld_uClibc.so.0";
0x000a1a14 mov r0, r6 | r0 = r6;
0x000a1a18 bl 0x142f4 | strcpy (r0, "_lib_ld_uClibc.so.0");
0x000a1a1c add r1, sp, 0x70 | r1 += var_70h;
0x000a1a20 add r0, sp, 0x3c | r0 += s;
0x000a1a24 bl 0xa1690 | fcn_000a1690 (r0);
0x000a1a28 subs r1, r0, 0 | r1 -= s;
| if (r1 <= s) {
0x000a1a2c ble 0xa17f0 | goto label_0;
| }
0x000a1a30 ands r5, r5, 0x10000 | r5 &= 0x10000;
| if (r5 == r5) {
0x000a1a34 beq 0xa1a50 | goto label_6;
| }
0x000a1a38 strh r1, [r4, 6] | *((r4 + 6)) = r1;
0x000a1a3c add r0, sp, 0x70 | r0 += var_70h;
0x000a1a40 add r1, r1, 1 | r1 += var_1h;
0x000a1a44 bl 0x18a48 | fcn_00018a48 (r0, r1);
| do {
0x000a1a48 str r0, [r4, 8] | *((r4 + 8)) = r0;
0x000a1a4c b 0xa17f0 | goto label_0;
| label_6:
0x000a1a50 strh r5, [r4, 6] | *((r4 + 6)) = r5;
0x000a1a54 add r0, sp, 0x70 | r0 += var_70h;
0x000a1a58 bl 0x189d4 | fcn_000189d4 (r0);
0x000a1a5c b 0xa1a48 |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0xa1a8c */
| #include <stdint.h>
|
; (fcn) fcn.000a1a8c () | void fcn_000a1a8c (int32_t arg1, int32_t arg2) {
| char * s;
| int32_t var_20h;
| r0 = arg1;
| r1 = arg2;
0x000a1a8c push {r4, r5, r6, r7, r8, lr} |
0x000a1a90 sub sp, sp, 0x20 |
0x000a1a94 mov r4, r0 | r4 = r0;
0x000a1a98 mov r6, r1 | r6 = r1;
0x000a1a9c mov r0, sp | r0 = sp;
0x000a1aa0 ldr r1, [pc, 0x12c] | r1 = *(0xa1bd0);
0x000a1aa4 mov r7, r3 | r7 = r3;
0x000a1aa8 bl 0x14f48 | sprintf (r0, r1, r2)
0x000a1aac sub r2, r6, 1 | r2 = r6 - 1;
0x000a1ab0 mov r1, r4 | r1 = r4;
0x000a1ab4 mov r0, sp | r0 = sp;
0x000a1ab8 bl 0x19740 | fcn_00019740 (r0);
0x000a1abc subs r5, r0, 0 | r5 -= s;
| if (r5 <= s) {
0x000a1ac0 ble 0xa1bb4 | goto label_1;
| }
0x000a1ac4 mov r3, 0 | r3 = 0;
0x000a1ac8 strb r3, [r4, r5] | *((r4 + r5)) = r3;
| do {
0x000a1acc subs r5, r5, 1 | r5--;
| if (r5 <= r5) {
0x000a1ad0 blo 0xa1ae0 | goto label_2;
| }
0x000a1ad4 ldrb r3, [r4, r5] | r3 = *((r4 + r5));
0x000a1ad8 cmp r3, 0 |
0x000a1adc beq 0xa1acc |
| } while (r3 == 0);
| label_2:
0x000a1ae0 mov r1, 0x20 | r1 = 0x20;
0x000a1ae4 mov r0, r4 | r0 = r4;
0x000a1ae8 bl 0x151e8 | strchrnul ();
0x000a1aec mov r3, 0 | r3 = 0;
0x000a1af0 add r5, r5, 1 | r5 += s;
0x000a1af4 add r5, r4, r5 | r5 = r4 + r5;
0x000a1af8 strb r3, [r0] | *(r0) = r3;
0x000a1afc mov r0, r4 | r0 = r4;
0x000a1b00 bl 0x17e94 | fcn_00017e94 (r0);
0x000a1b04 mov r3, 0x20 | r3 = 0x20;
0x000a1b08 mov r8, r0 | r8 = r0;
| do {
0x000a1b0c cmp r5, r4 |
| if (r5 == r4) {
0x000a1b10 bne 0xa1ba4 |
0x000a1b14 ldrb r3, [r8] | r3 = *(r8);
0x000a1b18 cmp r3, 0x2d |
| if (r3 != 0x2d) {
0x000a1b1c addeq r8, r8, 1 | r8++;
| }
0x000a1b20 cmp r7, 0 |
| if (r7 != 0) {
0x000a1b24 beq 0xa1b9c |
0x000a1b28 mov r0, r7 | r0 = r7;
0x000a1b2c bl 0x1514c | strlen (r0);
0x000a1b30 mov r1, r7 | r1 = r7;
0x000a1b34 mov r2, r0 | r2 = r0;
0x000a1b38 mov r5, r0 | r5 = r0;
0x000a1b3c mov r0, r8 | r0 = r8;
0x000a1b40 bl 0x14b94 | r0 = strncmp (r0, r1, r2);
0x000a1b44 cmp r0, 0 |
| if (r0 == 0) {
0x000a1b48 beq 0xa1b9c | goto label_0;
| }
0x000a1b4c add r5, r5, 3 | r5 += 3;
0x000a1b50 cmp r6, r5 |
| if (r6 > r5) {
0x000a1b54 ble 0xa1b68 |
0x000a1b58 sub r2, r6, r5 | r2 = r6 - r5;
0x000a1b5c mov r1, r4 | r1 = r4;
0x000a1b60 add r0, r4, r5 | r0 = r4 + r5;
0x000a1b64 bl 0x1442c | memmove (r0, r1, r2);
| }
0x000a1b68 mov r3, r7 | r3 = r7;
0x000a1b6c ldr r2, [pc, 0x64] | r2 = "/proc/%u/cmdline";
0x000a1b70 mov r1, r6 | r1 = r6;
0x000a1b74 mov r0, r4 | r0 = r4;
0x000a1b78 bl 0x14450 | snprintf (r0, r1, "/proc/%u/cmdline", r3);
0x000a1b7c cmp r6, r5 |
| if (r6 <= r5) {
0x000a1b80 ble 0xa1b9c | goto label_0;
| }
0x000a1b84 add r5, r4, r5 | r5 = r4 + r5;
0x000a1b88 mov r3, 0x20 | r3 = 0x20;
0x000a1b8c strb r3, [r5, -1] | *((r5 - 1)) = r3;
0x000a1b90 add r4, r4, r6 | r4 += r6;
0x000a1b94 mov r3, 0 | r3 = 0;
0x000a1b98 strb r3, [r4, -1] | *((r4 - 1)) = r3;
| }
| label_0:
0x000a1b9c add sp, sp, 0x20 |
0x000a1ba0 pop {r4, r5, r6, r7, r8, pc} |
| }
0x000a1ba4 ldrb r2, [r5, -1]! | r2 = *((r5 -= 1));
0x000a1ba8 cmp r2, 0x1f |
| if (r2 > 0x1f) {
0x000a1bac strbls r3, [r5] | *(r5) = r3;
| }
0x000a1bb0 b 0xa1b0c |
| } while (1);
| label_1:
0x000a1bb4 cmp r7, 0 |
0x000a1bb8 ldr r3, [pc, 0x1c] | r3 = "__s";
0x000a1bbc ldr r2, [pc, 0x1c] | r2 = *(0xa1bdc);
| if (r7 == 0) {
0x000a1bc0 movne r3, r7 | r3 = r7;
| }
0x000a1bc4 mov r1, r6 | r1 = r6;
0x000a1bc8 mov r0, r4 | r0 = r4;
0x000a1bcc bl 0x14450 | snprintf (r0, r1, r2, r3);
0x000a1bd0 b 0xa1b9c | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0xa2294 */
| #include <stdint.h>
|
; (fcn) fcn.000a2294 () | void fcn_000a2294 (int32_t arg1, char * s) {
| int32_t var_4h;
| void * ptr;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int8_t var_220h_2;
| int32_t var_20h;
| int8_t var_220h_4;
| int8_t var_220h_5;
| int8_t var_220h;
| int32_t var_3eh;
| int8_t var_220h_3;
| int32_t var_5fh;
| void * s2;
| int32_t var_a0h;
| void * var_170h;
| int32_t var_0h;
| int32_t var_240h;
| int32_t var_244h;
| int32_t var_0h_3;
| int32_t var_0h_4;
| int32_t var_0h_2;
| r0 = arg1;
| r1 = s;
0x000a2294 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000a2298 mov r4, r0 | r4 = r0;
0x000a229c sub sp, sp, 0x244 |
0x000a22a0 mov r0, r1 | r0 = r1;
0x000a22a4 mov r8, r1 | r8 = r1;
0x000a22a8 bl 0x1514c | strlen (r0);
0x000a22ac ldrb r2, [r8, 1] | r2 = *((r8 + 1));
0x000a22b0 add r7, r8, 3 | r7 = r8 + 3;
0x000a22b4 cmp r2, 0x36 |
| if (r2 != 0x36) {
0x000a22b8 moveq r6, 0x40 | r6 = 0x40;
| }
| if (r2 == 0x36) {
0x000a22bc movne r6, 0x20 | r6 = 0x20;
| }
0x000a22c0 add fp, sp, 0x20 |
| if (r2 != 0x36) {
0x000a22c4 addeq r3, r0, 0x58 | r3 = r0 + 0x58;
| }
| if (r2 == 0x36) {
0x000a22c8 addne r3, r0, 0x2d | r3 = r0 + 0x2d;
| }
0x000a22cc mov r0, r3 | r0 = r3;
0x000a22d0 bl 0x189b8 | fcn_000189b8 (r0);
0x000a22d4 ldrb r2, [r8, 1] | r2 = *((r8 + 1));
0x000a22d8 mov r3, 0x24 | r3 = 0x24;
0x000a22dc ldr r1, [pc, 0x49c] | r1 = *(0xa277c);
0x000a22e0 strb r2, [r0, 1] | *((r0 + 1)) = r2;
0x000a22e4 str r0, [sp, 0x14] | var_14h = r0;
0x000a22e8 strb r3, [r0] | *(r0) = r3;
0x000a22ec strb r3, [r0, 2] | *((r0 + 2)) = r3;
0x000a22f0 add r5, r0, 3 | r5 = r0 + 3;
0x000a22f4 mov r2, 7 | r2 = 7;
0x000a22f8 mov r0, r7 | r0 = r7;
0x000a22fc bl 0x14b94 | r0 = strncmp (r0, r1, r2);
0x000a2300 cmp r0, 0 |
| if (r0 != 0) {
0x000a2304 bne 0xa2654 | goto label_7;
| }
0x000a2308 mov r2, 0xa | r2 = 0xa;
0x000a230c add r0, r8, r2 | r0 = r8 + r2;
0x000a2310 mov r1, fp | r1 = fp;
0x000a2314 bl 0x1a0ec | fcn_0001a0ec (r0, r1);
0x000a2318 ldr r3, [sp, 0x20] | r3 = var_20h;
0x000a231c ldrb r2, [r3] | r2 = *(r3);
0x000a2320 cmp r2, 0x24 |
| if (r2 != 0x24) {
0x000a2324 bne 0xa2654 | goto label_7;
| }
0x000a2328 add r7, r3, 1 | r7 = r3 + 1;
0x000a232c ldr r3, [pc, 0x450] | r3 = "rounds=%u$";
0x000a2330 ldr r1, [pc, 0x448] | r1 = *(0xa277c);
0x000a2334 cmp r0, r3 |
| if (r0 >= r3) {
0x000a2338 movlo r3, r0 | r3 = r0;
| }
0x000a233c cmp r3, 0x3e8 |
| if (r3 >= 0x3e8) {
0x000a2340 movlo r3, 0x3e8 | r3 = 0x3e8;
| }
0x000a2344 mov r0, r5 | r0 = r5;
0x000a2348 mov r2, r3 | r2 = r3;
0x000a234c str r3, [sp, 4] | var_4h = r3;
0x000a2350 bl 0x14f48 | r0 = sprintf (r0, r1, r2)
0x000a2354 add r5, r5, r0 | r5 += r0;
| label_0:
0x000a2358 mov r1, 0x24 | r1 = 0x24;
0x000a235c mov r0, r7 | r0 = r7;
0x000a2360 bl 0x151e8 | r0 = strchrnul ();
0x000a2364 sub r0, r0, r7 | r0 -= r7;
0x000a2368 cmp r0, 0x10 |
| if (r0 >= 0x10) {
0x000a236c movlo r8, r0 | r8 = r0;
| }
| if (r0 < 0x10) {
0x000a2370 movhs r8, 0x10 | r8 = 0x10;
| }
0x000a2374 mov r1, r8 | r1 = r8;
0x000a2378 mov r0, r7 | r0 = r7;
0x000a237c bl 0x189f8 | fcn_000189f8 (r0, r1);
0x000a2380 add r7, sp, 0xa0 | r7 += var_a0h;
0x000a2384 mov r1, r0 | r1 = r0;
0x000a2388 str r0, [sp, 8] | ptr = r0;
0x000a238c mov r0, r5 | r0 = r5;
0x000a2390 bl 0x142f4 | strcpy (r0, r1);
0x000a2394 add r3, r5, r8 | r3 = r5 + r8;
0x000a2398 add r3, r3, 1 | r3++;
0x000a239c str r3, [sp, 0x18] | var_18h = r3;
0x000a23a0 mov r3, 0x24 | r3 = 0x24;
0x000a23a4 strb r3, [r5, r8] | *((r5 + r8)) = r3;
0x000a23a8 mov r0, r4 | r0 = r4;
0x000a23ac bl 0x1514c | strlen (r0);
0x000a23b0 ldr r5, [pc, 0x3d0] | r5 = *(0xa2784);
0x000a23b4 mov sl, r0 | sl = r0;
0x000a23b8 mov r0, r4 | r0 = r4;
0x000a23bc bl 0x189d4 | fcn_000189d4 (r0);
0x000a23c0 ldr r2, [pc, 0x3c4] | r2 = *(0xa2788);
0x000a23c4 ldr r3, [pc, 0x3c4] | r3 = *(0xa278c);
0x000a23c8 cmp r6, 0x20 |
| if (r6 == 0x20) {
0x000a23cc movne r3, r2 | r3 = r2;
| }
0x000a23d0 str r3, [sp, 0x10] | var_10h = r3;
0x000a23d4 ldr r3, [pc, 0x3b8] | r3 = *(0xa2790);
0x000a23d8 ldr r2, [pc, 0x3b8] | r2 = *(0xa2794);
| if (r6 != 0x20) {
0x000a23dc moveq r5, r3 | r5 = r3;
| }
0x000a23e0 ldr r3, [pc, 0x3b4] | r3 = *(0xa2798);
| if (r6 == 0x20) {
0x000a23e4 movne r3, r2 | r3 = r2;
| }
0x000a23e8 str r3, [sp, 0xc] | var_ch = r3;
0x000a23ec mov sb, r0 | sb = r0;
0x000a23f0 mov r0, r7 | r0 = r7;
0x000a23f4 blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r2, r3);
0x000a23f8 mov r2, sl | r2 = sl;
0x000a23fc mov r1, sb | r1 = sb;
0x000a2400 mov r0, r7 | r0 = r7;
0x000a2404 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2408 mov r2, r8 | r2 = r8;
0x000a240c ldr r1, [sp, 8] | r1 = ptr;
0x000a2410 mov r0, r7 | r0 = r7;
0x000a2414 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2418 ldr r3, [sp, 0xc] | r3 = var_ch;
0x000a241c add r0, sp, 0x170 | r0 += var_170h;
0x000a2420 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
0x000a2424 mov r2, sl | r2 = sl;
0x000a2428 mov r1, sb | r1 = sb;
0x000a242c add r0, sp, 0x170 | r0 += var_170h;
0x000a2430 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2434 mov r2, r8 | r2 = r8;
0x000a2438 ldr r1, [sp, 8] | r1 = ptr;
0x000a243c add r0, sp, 0x170 | r0 += var_170h;
0x000a2440 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2444 mov r2, sl | r2 = sl;
0x000a2448 mov r1, sb | r1 = sb;
0x000a244c add r0, sp, 0x170 | r0 += var_170h;
0x000a2450 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2454 ldr r3, [sp, 0x10] | r3 = var_10h;
0x000a2458 mov r1, fp | r1 = fp;
0x000a245c add r0, sp, 0x170 | r0 += var_170h;
0x000a2460 blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000a2464 mov r3, sl | r3 = sl;
| label_1:
0x000a2468 cmp r6, r3 |
| if (r6 <= r3) {
0x000a246c blo 0xa2660 | goto label_8;
| }
0x000a2470 mov r2, r3 | r2 = r3;
0x000a2474 mov r1, fp | r1 = fp;
0x000a2478 mov r0, r7 | r0 = r7;
0x000a247c blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2480 mov r4, sl | r4 = sl;
| label_2:
0x000a2484 cmp r4, 0 |
| if (r4 != 0) {
0x000a2488 bne 0xa2680 | goto label_9;
| }
0x000a248c add r1, sp, 0x20 | r1 += var_20h;
0x000a2490 mov r0, r7 | r0 = r7;
0x000a2494 ldr r3, [sp, 0x10] | r3 = var_10h;
0x000a2498 blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000a249c add r7, sp, 0x170 | r7 += var_170h;
0x000a24a0 mov r0, r7 | r0 = r7;
0x000a24a4 ldr r3, [sp, 0xc] | r3 = var_ch;
0x000a24a8 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
0x000a24ac mov fp, r4 |
| label_3:
0x000a24b0 cmp fp, sl |
| if (fp != sl) {
0x000a24b4 bne 0xa26a4 | goto label_10;
| }
0x000a24b8 add r3, sp, 0x60 | r3 += s2;
0x000a24bc mov r1, r3 | r1 = r3;
0x000a24c0 str r3, [sp, 0x1c] | var_1ch = r3;
0x000a24c4 mov r0, r7 | r0 = r7;
0x000a24c8 ldr r3, [sp, 0x10] | r3 = var_10h;
0x000a24cc blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000a24d0 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x000a24d4 mov r0, sb | r0 = sb;
0x000a24d8 mov sl, fp | sl = fp;
0x000a24dc mov r7, r3 | r7 = r3;
| label_4:
0x000a24e0 cmp r6, sl |
| if (r6 < sl) {
0x000a24e4 bls 0xa26bc | goto label_11;
| }
0x000a24e8 mov r2, sl | r2 = sl;
0x000a24ec mov r1, r7 | r1 = r7;
0x000a24f0 add r7, sp, 0x170 | r7 += var_170h;
0x000a24f4 bl 0x14624 | memcpy (r0, r1, r2);
0x000a24f8 mov r0, r7 | r0 = r7;
0x000a24fc ldr r3, [sp, 0xc] | r3 = var_ch;
0x000a2500 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
0x000a2504 mov sl, 0 | sl = 0;
| label_5:
0x000a2508 ldrb r3, [sp, 0x20] | r3 = var_20h;
0x000a250c add r3, r3, 0x10 | r3 += 0x10;
0x000a2510 cmp r3, sl |
| if (r3 > sl) {
0x000a2514 bhi 0xa26d4 | goto label_12;
| }
0x000a2518 add r1, sp, 0x60 | r1 += s2;
0x000a251c mov r0, r7 | r0 = r7;
0x000a2520 ldr r3, [sp, 0x10] | r3 = var_10h;
0x000a2524 blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000a2528 mov r2, r8 | r2 = r8;
0x000a252c add r1, sp, 0x60 | r1 += s2;
0x000a2530 ldr r0, [sp, 8] | r0 = ptr;
0x000a2534 bl 0x14624 | memcpy (r0, r1, r2);
0x000a2538 mov r7, 0 | r7 = 0;
| do {
0x000a253c ldr r3, [sp, 0xc] | r3 = var_ch;
0x000a2540 add r0, sp, 0xa0 | r0 += var_a0h;
0x000a2544 blx r3 | uint32_t (*r3)(uint32_t, uint32_t) (r0, r3);
0x000a2548 ands sl, r7, 1 | sl = r7 & 1;
| if (sl == r7) {
0x000a254c movne r1, sb | r1 = sb;
| }
| if (sl != r7) {
0x000a2550 addeq r1, sp, 0x20 | r1 += var_20h;
| }
| if (sl == r7) {
0x000a2554 movne r2, fp | r2 = fp;
| }
| if (sl != r7) {
0x000a2558 moveq r2, r6 | r2 = r6;
| }
0x000a255c add r0, sp, 0xa0 | r0 += var_a0h;
0x000a2560 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a2564 mov r1, 3 | r1 = 3;
0x000a2568 mov r0, r7 | r0 = r7;
0x000a256c bl 0xa667c | fcn_000a667c (r0, r1);
0x000a2570 cmp r1, 0 |
| if (r1 != 0) {
0x000a2574 beq 0xa2588 |
0x000a2578 mov r2, r8 | r2 = r8;
0x000a257c ldr r1, [sp, 8] | r1 = ptr;
0x000a2580 add r0, sp, 0xa0 | r0 += var_a0h;
0x000a2584 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
| }
0x000a2588 mov r1, 7 | r1 = 7;
0x000a258c mov r0, r7 | r0 = r7;
0x000a2590 bl 0xa667c | fcn_000a667c (r0, r1);
0x000a2594 cmp r1, 0 |
| if (r1 != 0) {
0x000a2598 beq 0xa25ac |
0x000a259c mov r2, fp | r2 = fp;
0x000a25a0 mov r1, sb | r1 = sb;
0x000a25a4 add r0, sp, 0xa0 | r0 += var_a0h;
0x000a25a8 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
| }
0x000a25ac cmp sl, 0 |
| if (sl == 0) {
0x000a25b0 addne r1, sp, 0x20 | r1 += var_20h;
| }
| if (sl != 0) {
0x000a25b4 moveq r1, sb | r1 = sb;
| }
| if (sl == 0) {
0x000a25b8 movne r2, r6 | r2 = r6;
| }
| if (sl != 0) {
0x000a25bc moveq r2, fp | r2 = fp;
| }
0x000a25c0 add r0, sp, 0xa0 | r0 += var_a0h;
0x000a25c4 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a25c8 ldr r3, [sp, 0x10] | r3 = var_10h;
0x000a25cc add r1, sp, 0x20 | r1 += var_20h;
0x000a25d0 add r0, sp, 0xa0 | r0 += var_a0h;
0x000a25d4 blx r3 | uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r1, r3);
0x000a25d8 ldr r3, [sp, 4] | r3 = var_4h;
0x000a25dc add r7, r7, 1 | r7++;
0x000a25e0 cmp r3, r7 |
0x000a25e4 bhi 0xa253c |
| } while (r3 > r7);
0x000a25e8 cmp r6, 0x20 |
| if (r6 != 0x20) {
0x000a25ec bne 0xa2714 | goto label_13;
| }
| do {
0x000a25f0 add r2, r4, 0xa | r2 = r4 + 0xa;
0x000a25f4 cmp r2, 0x1d |
0x000a25f8 add r5, r4, 0x14 | r5 = r4 + 0x14;
| if (r2 <= 0x1d) {
0x000a25fc subhi r2, r4, 0x14 | r2 = r4 - 0x14;
| }
0x000a2600 add r3, sp, 0x240 | r3 += var_240h;
0x000a2604 cmp r5, 0x1d |
0x000a2608 add r2, r3, r2 | r2 = r3 + r2;
| if (r5 <= 0x1d) {
0x000a260c subhi r5, r4, 0xa | r5 = r4 - 0xa;
| }
0x000a2610 add r4, r3, r4 | r4 = r3 + r4;
0x000a2614 ldrb r3, [r2, -0x220] | r3 = var_220h_4;
0x000a2618 ldrb r1, [r4, -0x220] | r1 = var_220h_2;
0x000a261c add r2, sp, 0x240 | r2 += var_240h;
0x000a2620 add r2, r2, r5 | r2 += r5;
0x000a2624 lsl r3, r3, 8 | r3 <<= 8;
0x000a2628 orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x000a262c ldrb r1, [r2, -0x220] | r1 = var_220h_5;
0x000a2630 ldr r0, [sp, 0x18] | r0 = var_18h;
0x000a2634 mov r2, 4 | r2 = 4;
0x000a2638 orr r1, r3, r1 | r1 = r3 | r1;
0x000a263c bl 0xa1f8c | fcn_000a1f8c (r0, r1);
0x000a2640 cmp r5, 0x1d |
0x000a2644 str r0, [sp, 0x18] | var_18h = r0;
| if (r5 == 0x1d) {
0x000a2648 beq 0xa26ec | goto label_14;
| }
0x000a264c add r4, r5, 1 | r4 = r5 + 1;
0x000a2650 b 0xa25f0 |
| } while (1);
| label_7:
0x000a2654 ldr r3, [pc, 0x144] | r3 = *(0xa279c);
0x000a2658 str r3, [sp, 4] | var_4h = r3;
0x000a265c b 0xa2358 | goto label_0;
| label_8:
0x000a2660 mov r2, r6 | r2 = r6;
0x000a2664 mov r1, fp | r1 = fp;
0x000a2668 mov r0, r7 | r0 = r7;
0x000a266c str r3, [sp, 0x1c] | var_1ch = r3;
0x000a2670 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t, uint32_t) (r0, r1, r2, r3);
0x000a2674 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x000a2678 sub r3, r3, r6 | r3 -= r6;
0x000a267c b 0xa2468 | goto label_1;
| label_9:
0x000a2680 tst r4, 1 |
| if ((r4 & 1) == 0) {
0x000a2684 movne r2, r6 | r2 = r6;
| }
| if ((r4 & 1) == 0) {
0x000a2688 movne r1, fp | r1 = fp;
| }
| if ((r4 & 1) != 0) {
0x000a268c moveq r2, sl | r2 = sl;
| }
| if ((r4 & 1) != 0) {
0x000a2690 moveq r1, sb | r1 = sb;
| }
0x000a2694 mov r0, r7 | r0 = r7;
0x000a2698 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a269c lsr r4, r4, 1 | r4 >>= 1;
0x000a26a0 b 0xa2484 | goto label_2;
| label_10:
0x000a26a4 mov r2, sl | r2 = sl;
0x000a26a8 mov r1, sb | r1 = sb;
0x000a26ac mov r0, r7 | r0 = r7;
0x000a26b0 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a26b4 add fp, fp, 1 |
0x000a26b8 b 0xa24b0 | goto label_3;
| label_11:
0x000a26bc mov r2, r6 | r2 = r6;
0x000a26c0 mov r1, r7 | r1 = r7;
0x000a26c4 bl 0x14624 | memcpy (r0, r1, r2);
0x000a26c8 sub sl, sl, r6 | sl -= r6;
0x000a26cc add r0, r0, r6 | r0 += r6;
0x000a26d0 b 0xa24e0 | goto label_4;
| label_12:
0x000a26d4 mov r2, r8 | r2 = r8;
0x000a26d8 ldr r1, [sp, 8] | r1 = ptr;
0x000a26dc mov r0, r7 | r0 = r7;
0x000a26e0 blx r5 | uint32_t (*r5)(uint32_t, uint32_t, uint32_t) (r0, r1, r2);
0x000a26e4 add sl, sl, 1 | sl++;
0x000a26e8 b 0xa2508 | goto label_5;
| label_14:
0x000a26ec ldrh r1, [sp, 0x3e] | r1 = var_3eh;
0x000a26f0 mov r2, 3 | r2 = 3;
| label_6:
0x000a26f4 bl 0xa1f8c | fcn_000a1f8c (r0, r1);
0x000a26f8 mov r0, sb | r0 = sb;
0x000a26fc bl 0x152a8 | free (r0);
0x000a2700 ldr r0, [sp, 8] | r0 = ptr;
0x000a2704 bl 0x152a8 | free (r0);
0x000a2708 ldr r0, [sp, 0x14] | r0 = var_14h;
0x000a270c add sp, sp, 0x244 |
0x000a2710 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| do {
| label_13:
0x000a2714 add r5, r4, 0x15 | r5 = r4 + 0x15;
0x000a2718 add r2, r4, 0x2a | r2 = r4 + 0x2a;
0x000a271c cmp r5, 0x3e |
| if (r5 <= 0x3e) {
0x000a2720 subhi r5, r4, 0x2a | r5 = r4 - 0x2a;
| }
0x000a2724 add r3, sp, 0x240 | r3 += var_240h;
0x000a2728 cmp r2, 0x3e |
| if (r2 <= 0x3e) {
0x000a272c subhi r2, r4, 0x15 | r2 = r4 - 0x15;
| }
0x000a2730 add r4, r3, r4 | r4 = r3 + r4;
0x000a2734 add r3, r3, r5 | r3 += r5;
0x000a2738 ldrb r3, [r3, -0x220] | r3 = var_220h;
0x000a273c ldrb r1, [r4, -0x220] | r1 = var_220h_2;
0x000a2740 lsl r3, r3, 8 | r3 <<= 8;
0x000a2744 orr r3, r3, r1, lsl 16 | r3 |= (r1 << 16);
0x000a2748 add r1, sp, 0x240 | r1 += var_240h;
0x000a274c add r2, r1, r2 | r2 = r1 + r2;
0x000a2750 ldrb r1, [r2, -0x220] | r1 = var_220h_3;
0x000a2754 ldr r0, [sp, 0x18] | r0 = var_18h;
0x000a2758 mov r2, 4 | r2 = 4;
0x000a275c orr r1, r3, r1 | r1 = r3 | r1;
0x000a2760 bl 0xa1f8c | fcn_000a1f8c (r0, r1);
0x000a2764 cmp r5, 0x14 |
0x000a2768 str r0, [sp, 0x18] | var_18h = r0;
| if (r5 == 0x14) {
0x000a276c addne r4, r5, 1 | r4 = r5 + 1;
| }
0x000a2770 bne 0xa2714 |
| } while (r5 != 0x14);
0x000a2774 mov r2, 2 | r2 = 2;
0x000a2778 ldrb r1, [sp, 0x5f] | r1 = var_5fh;
0x000a277c b 0xa26f4 | goto label_6;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/bin/busybox @ 0xa4850 */
| #include <stdint.h>
|
; (fcn) fcn.000a4850 () | void fcn_000a4850 (int32_t arg1, int32_t arg2) {
| char * s;
| char * s2;
| int32_t var_b7h;
| int32_t var_b8h;
| r0 = arg1;
| r1 = arg2;
0x000a4850 push {r4, r5, r6, r7, r8, lr} |
0x000a4854 ldr r8, [pc, 0x88] | r8 = *(0xa48e0);
0x000a4858 sub sp, sp, 0xb8 |
0x000a485c mov r7, r0 | r7 = r0;
0x000a4860 mov r5, r1 | r5 = r1;
0x000a4864 mov r4, 0 | r4 = 0;
| do {
0x000a4868 mov r3, r4 | r3 = r4;
0x000a486c mov r2, r7 | r2 = r7;
0x000a4870 mov r1, r8 | r1 = r8;
0x000a4874 mov r0, sp | r0 = sp;
0x000a4878 bl 0x14f48 | sprintf (r0, r1, r2)
0x000a487c mov r2, 0x80 | r2 = 0x80;
0x000a4880 add r1, sp, 0x38 | r1 += s2;
0x000a4884 mov r0, sp | r0 = sp;
0x000a4888 bl 0x19740 | r0 = fcn_00019740 (r0);
0x000a488c cmp r0, 0 |
| if (r0 > 0) {
0x000a4890 bgt 0xa48ac | goto label_1;
| }
| label_0:
0x000a4894 add r4, r4, 1 | r4++;
0x000a4898 cmp r4, 0x80 |
0x000a489c bne 0xa4868 |
| } while (r4 != 0x80);
0x000a48a0 mov r1, r5 | r1 = r5;
0x000a48a4 ldr r0, [pc, 0x3c] | r0 = "_sys_class_ubi_ubi_u__u_name";
0x000a48a8 bl 0x18254 | fcn_00018254 ();
| label_1:
0x000a48ac mov r6, 0 | r6 = 0;
0x000a48b0 mov r1, 0xa | r1 = 0xa;
0x000a48b4 add r0, sp, 0x38 | r0 += s2;
0x000a48b8 strb r6, [sp, 0xb7] | var_b7h = r6;
0x000a48bc bl 0x151e8 | strchrnul ();
0x000a48c0 add r1, sp, 0x38 | r1 += s2;
0x000a48c4 strb r6, [r0] | *(r0) = r6;
0x000a48c8 mov r0, r5 | r0 = r5;
0x000a48cc bl 0x14ed0 | r0 = strcmp (r0, r1);
0x000a48d0 cmp r0, r6 |
| if (r0 != r6) {
0x000a48d4 bne 0xa4894 | goto label_0;
| }
0x000a48d8 mov r0, r4 | r0 = r4;
0x000a48dc add sp, sp, 0xb8 |
0x000a48e0 pop {r4, r5, r6, r7, r8, pc} |
| }
[*] Function sprintf used 51 times busybox