int FUN_00407f84(undefined4 *param_1,int param_2)
{
undefined1 uVar1;
int iVar2;
int iVar3;
int iVar4;
int *__s;
undefined4 *puVar5;
undefined4 uVar6;
char *pcVar7;
undefined4 uVar8;
int iVar9;
int *piVar10;
int iVar11;
int local_50;
int local_4c;
undefined4 *local_48;
undefined4 *local_44;
undefined4 *local_40;
undefined4 *local_3c;
undefined4 *local_38;
undefined4 *local_34;
undefined4 *local_30;
iVar2 = sobj_new();
iVar3 = sobj_new();
iVar9 = 0;
if (iVar2 != 0) {
local_34 = param_1 + 6;
local_38 = param_1 + 8;
local_3c = param_1 + 10;
local_40 = param_1 + 0xc;
local_44 = param_1 + 0xe;
local_48 = param_1 + 0x10;
local_30 = param_1 + 4;
do {
iVar9 = 0;
iVar11 = iVar3;
if (iVar3 == 0) break;
sobj_free(iVar2);
FUN_00407458(param_1[1],iVar2,&local_50);
if (local_50 == 0) {
iVar9 = sobj_empty(iVar2,0x420000);
if (iVar9 == 0) {
if ((local_50 != 0) ||
((((((iVar4 = sobj_strcmp(iVar2,&DAT_0042335c), iVar9 = iVar2, iVar4 != 0 &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226a0), iVar4 != 0)) &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226a4), iVar4 != 0)) &&
((iVar4 = sobj_strcmp(iVar2,&DAT_004226a8), iVar4 != 0 &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226ac), iVar4 != 0)))) &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226b0), iVar4 != 0)) &&
(((iVar4 = sobj_strcmp(iVar2,&DAT_004226b4), iVar4 != 0 &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226b8), iVar4 != 0)) &&
((iVar4 = sobj_strcmp(iVar2,&DAT_004226bc), iVar4 != 0 &&
((iVar4 = sobj_strcmp(iVar2,&DAT_004226c0), iVar4 != 0 &&
(iVar4 = sobj_strcmp(iVar2,&DAT_004226c4), iVar4 != 0)))))))))) goto LAB_0040822c;
goto LAB_00408b38;
}
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
client_printf(*param_1,"unable to read token !");
uVar6 = *param_1;
pcVar7 = "SYNTAX ERROR";
LAB_004082dc:
client_printf(uVar6,"\n!! %s <<<<<<<<<<<<<<<<<<<<<<<<<\n",pcVar7);
LAB_00408b90:
iVar9 = 0;
break;
}
LAB_0040822c:
sobj_free(iVar3);
FUN_00407458(param_1[1],iVar3,&local_4c);
__s = (int *)malloc(0x20);
if (__s == (int *)0x0) {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","INTERNAL ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","INTERNAL ERROR",param_1[2]);
client_printf(*param_1,"memory allocation failed !");
uVar6 = *param_1;
pcVar7 = "INTERNAL ERROR";
goto LAB_004082dc;
}
memset(__s,0,0x20);
if (local_50 == 0) {
iVar9 = sobj_get_char(iVar2,0);
if (iVar9 == 0x24) {
sobj_remove_char(iVar2,0);
iVar9 = sobj_empty(iVar2);
if (iVar9 != 0) {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
uVar6 = *param_1;
pcVar7 = "no variable name available !";
goto LAB_00408810;
}
__s[2] = 1;
iVar9 = sobj_strcmp(iVar2,"_GLOBALS");
puVar5 = local_34;
if (((((iVar9 != 0) &&
(iVar9 = sobj_strcmp(iVar2,"_SERVER"), puVar5 = local_38, iVar9 != 0)) &&
(iVar9 = sobj_strcmp(iVar2,&DAT_004226fc), puVar5 = local_3c, iVar9 != 0)) &&
((iVar9 = sobj_strcmp(iVar2,"_POST"), puVar5 = local_40, iVar9 != 0 &&
(iVar9 = sobj_strcmp(iVar2,&DAT_0042270c), puVar5 = local_44, iVar9 != 0)))) &&
((iVar9 = sobj_strcmp(iVar2,"_FILES"), puVar5 = local_48, iVar9 != 0 &&
(iVar9 = sobj_strcmp(iVar2,"_FILETYPES"), puVar5 = param_1 + 0x12, iVar9 != 0)))) {
puVar5 = (undefined4 *)0x0;
LAB_00408608:
iVar9 = sobj_strdup(iVar2);
__s[3] = iVar9;
__s[4] = (int)puVar5;
goto LAB_004087b4;
}
if (puVar5 == (undefined4 *)0x0) goto LAB_00408608;
iVar9 = sobj_strcmp(iVar3,&DAT_00422728);
if (iVar9 == 0) {
sobj_free(iVar2);
sobj_free(iVar3);
FUN_00407458(param_1[1],iVar2,&local_50);
FUN_00407458(param_1[1],iVar3,&local_4c);
iVar9 = sobj_strcmp(iVar3,"]");
if (iVar9 == 0) {
sobj_free(iVar3);
FUN_00407458(param_1[1],iVar3,&local_4c);
goto LAB_00408608;
}
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
uVar6 = *param_1;
pcVar7 = "expecting \']\'";
}
else {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
uVar6 = *param_1;
pcVar7 = "expecting \'[\'";
}
goto LAB_00408810;
}
iVar9 = sobj_strcmp(iVar3,&DAT_0042274c);
if (iVar9 != 0) {
__s[2] = 0;
goto LAB_004087a4;
}
__s[2] = 2;
iVar9 = sobj_strdup(iVar2);
piVar10 = __s + 5;
__s[3] = iVar9;
__s[6] = (int)piVar10;
__s[5] = (int)piVar10;
iVar9 = FUN_00407c68(iVar9);
if (iVar9 == 0) {
pcVar7 = (char *)__s[3];
puVar5 = (undefined4 *)param_1[4];
while( true ) {
if (puVar5 == local_30) {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","INTERNAL ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","INTERNAL ERROR",param_1[2]);
uVar8 = *param_1;
uVar6 = sobj_get_string(iVar2);
client_printf(uVar8,"unknow function - [%s]",uVar6);
uVar6 = *param_1;
pcVar7 = "INTERNAL ERROR";
goto LAB_00408af4;
}
iVar9 = strcmp(pcVar7,(char *)puVar5[2]);
if (iVar9 == 0) break;
puVar5 = (undefined4 *)*puVar5;
}
__s[4] = 0;
}
else {
__s[4] = *(int *)(iVar9 + 8);
}
iVar9 = FUN_00408ba4(param_1,piVar10);
if (-1 < iVar9) {
sobj_free(iVar3);
FUN_00407458(param_1[1],iVar3,&local_4c);
goto LAB_004087b4;
}
LAB_00408b88:
FUN_00407e78(__s);
goto LAB_00408b90;
}
__s[2] = 0;
LAB_004087a4:
iVar9 = sobj_strdup(iVar2);
__s[3] = iVar9;
LAB_004087b4:
if (local_4c != 0) {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
uVar6 = *param_1;
pcVar7 = "should not see quotation mark here !";
LAB_00408810:
client_printf(uVar6,pcVar7);
uVar6 = *param_1;
pcVar7 = "SYNTAX ERROR";
LAB_00408af4:
client_printf(uVar6,"\n!! %s <<<<<<<<<<<<<<<<<<<<<<<<<\n",pcVar7);
goto LAB_00408b88;
}
iVar9 = sobj_strcmp(iVar3,".");
uVar1 = 0x2e;
if (iVar9 == 0) {
LAB_004088f4:
*(undefined1 *)(__s + 7) = uVar1;
iVar9 = 0;
}
else {
iVar9 = sobj_strcmp(iVar3,&DAT_00422768);
uVar1 = 0x2b;
if (iVar9 == 0) goto LAB_004088f4;
iVar9 = sobj_strcmp(iVar3,"-");
uVar1 = 0x2d;
if (iVar9 == 0) goto LAB_004088f4;
iVar9 = sobj_strcmp(iVar3,&DAT_0042276c);
uVar1 = 0x2a;
if (iVar9 == 0) goto LAB_004088f4;
iVar9 = sobj_strcmp(iVar3,&DAT_00422580);
uVar1 = 0x2f;
if (iVar9 == 0) goto LAB_004088f4;
iVar9 = sobj_strcmp(iVar3,&DAT_00422770);
uVar1 = 0x25;
if (iVar9 == 0) goto LAB_004088f4;
iVar9 = sobj_strcmp(iVar3,&DAT_0042335c);
if (((((iVar9 != 0) && (iVar9 = sobj_strcmp(iVar3,&DAT_004226a0), iVar9 != 0)) &&
((iVar9 = sobj_strcmp(iVar3,&DAT_004226a4), iVar9 != 0 &&
(((iVar9 = sobj_strcmp(iVar3,&DAT_004226a8), iVar9 != 0 &&
(iVar9 = sobj_strcmp(iVar3,&DAT_004226ac), iVar9 != 0)) &&
(iVar9 = sobj_strcmp(iVar3,&DAT_004226b0), iVar9 != 0)))))) &&
((iVar9 = sobj_strcmp(iVar3,&DAT_004226b4), iVar9 != 0 &&
(iVar9 = sobj_strcmp(iVar3,&DAT_004226b8), iVar9 != 0)))) &&
((iVar9 = sobj_strcmp(iVar3,&DAT_004226bc), iVar9 != 0 &&
((iVar9 = sobj_strcmp(iVar3,&DAT_004226c0), iVar9 != 0 &&
(iVar9 = sobj_strcmp(iVar3,&DAT_004226c4), iVar9 != 0)))))) {
client_printf(*param_1,"\n!! %s >>>>>>>>>>>>>>>>>>>>>>>>>\n","SYNTAX ERROR");
client_printf(*param_1,"!! %s: File:[%s]\n","SYNTAX ERROR",param_1[2]);
uVar8 = *param_1;
uVar6 = sobj_get_string(iVar2);
client_printf(uVar8,"unknown token - [%s]",uVar6);
uVar6 = *param_1;
pcVar7 = "SYNTAX ERROR";
goto LAB_00408af4;
}
*(undefined1 *)(__s + 7) = 0;
iVar11 = 0;
iVar9 = iVar3;
}
puVar5 = *(undefined4 **)(param_2 + 4);
*__s = param_2;
*(int **)(param_2 + 4) = __s;
*puVar5 = __s;
__s[1] = (int)puVar5;
iVar3 = iVar11;
} while (iVar9 == 0);
sobj_del(iVar2);
iVar3 = iVar11;
}
LAB_00408b38:
if (iVar3 != 0) {
sobj_del(iVar3);
}
return iVar9;
}