
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

int __regparm3 unescape(char **in,char **out,char *seq,char value)

{
  size_t __n;
  int iVar1;
  
  __n = strlen(seq);
  iVar1 = strncmp(*in,seq,__n);
  if (iVar1 == 0) {
    **out = value;
    *in = *in + __n;
    *out = *out + 1;
    return 1;
  }
  return 0;
}



/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

undefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)

{
  size_t __n;
  int iVar1;
  
  __n = strlen(param_3);
  iVar1 = strncmp((char *)*param_1,param_3,__n);
  if (iVar1 == 0) {
    *(undefined1 *)*param_2 = param_4;
    *param_1 = *param_1 + __n;
    *param_2 = *param_2 + 1;
    return 1;
  }
  return 0;
}


PUSH EBP
MOV EBP,EDX
PUSH EDI
MOV EDI,ECX
PUSH ESI
MOV ESI,EAX
PUSH EBX
CALL 0x00035840
ADD EBX,0x1aac41
SUB ESP,0x28
MOV EAX,dword ptr [ESP + 0x3c]
MOV dword ptr [ESP + 0x14],EAX
PUSH ECX
CALL 0x000295f0
ADD ESP,0xc
PUSH EAX
MOV dword ptr [ESP + 0x14],EAX
PUSH EDI
PUSH dword ptr [ESI]
CALL 0x00029990
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x001e4410
MOV EAX,dword ptr [EBP]
MOVZX EDX,byte ptr [ESP + 0x8]
MOV ECX,dword ptr [ESP + 0xc]
MOV byte ptr [EAX],DL
MOV EAX,0x1
ADD dword ptr [ESI],ECX
ADD dword ptr [EBP],0x1
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
ADD ESP,0x1c
XOR EAX,EAX
POP EBX
POP ESI
POP EDI
POP EBP
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}\n\n" comment (function_definition "undefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)" identifier (parameter_list "(int *param_1,int *param_2,char *param_3,undefined1 param_4)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "undefined1 param_4" type_identifier identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (expression_statement "__n = strlen(param_3);" (assignment_expression "__n = strlen(param_3)" identifier = (call_expression "strlen(param_3)" identifier (argument_list "(param_3)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp((char *)*param_1,param_3,__n);" (assignment_expression "iVar1 = strncmp((char *)*param_1,param_3,__n)" identifier = (call_expression "strncmp((char *)*param_1,param_3,__n)" identifier (argument_list "((char *)*param_1,param_3,__n)" ( (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)) , identifier , identifier )))) ;) (if_statement "if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" { (expression_statement "*(undefined1 *)*param_2 = param_4;" (assignment_expression "*(undefined1 *)*param_2 = param_4" (pointer_expression "*(undefined1 *)*param_2" * (cast_expression "(undefined1 *)*param_2" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) = identifier) ;) (expression_statement "*param_1 = *param_1 + __n;" (assignment_expression "*param_1 = *param_1 + __n" (pointer_expression "*param_1" * identifier) = (binary_expression "*param_1 + __n" (pointer_expression "*param_1" * identifier) + identifier)) ;) (expression_statement "*param_2 = *param_2 + 1;" (assignment_expression "*param_2 = *param_2 + 1" (pointer_expression "*param_2" * identifier) = (binary_expression "*param_2 + 1" (pointer_expression "*param_2" * identifier) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint __regparm3 unescape(char **in,char **out,char *seq,char value)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(seq);\n  iVar1 = strncmp(*in,seq,__n);\n  if (iVar1 == 0) {\n    **out = value;\n    *in = *in + __n;\n    *out = *out + 1;\n    return 1;\n  }\n  return 0;\n}\n\n" comment (function_definition "int __regparm3 unescape(char **in,char **out,char *seq,char value)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(seq);\n  iVar1 = strncmp(*in,seq,__n);\n  if (iVar1 == 0) {\n    **out = value;\n    *in = *in + __n;\n    *out = *out + 1;\n    return 1;\n  }\n  return 0;\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "unescape(char **in,char **out,char *seq,char value)" identifier (parameter_list "(char **in,char **out,char *seq,char value)" ( (parameter_declaration "char **in" primitive_type (pointer_declarator "**in" * (pointer_declarator "*in" * identifier))) , (parameter_declaration "char **out" primitive_type (pointer_declarator "**out" * (pointer_declarator "*out" * identifier))) , (parameter_declaration "char *seq" primitive_type (pointer_declarator "*seq" * identifier)) , (parameter_declaration "char value" primitive_type identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(seq);\n  iVar1 = strncmp(*in,seq,__n);\n  if (iVar1 == 0) {\n    **out = value;\n    *in = *in + __n;\n    *out = *out + 1;\n    return 1;\n  }\n  return 0;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (expression_statement "__n = strlen(seq);" (assignment_expression "__n = strlen(seq)" identifier = (call_expression "strlen(seq)" identifier (argument_list "(seq)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp(*in,seq,__n);" (assignment_expression "iVar1 = strncmp(*in,seq,__n)" identifier = (call_expression "strncmp(*in,seq,__n)" identifier (argument_list "(*in,seq,__n)" ( (pointer_expression "*in" * identifier) , identifier , identifier )))) ;) (if_statement "if (iVar1 == 0) {\n    **out = value;\n    *in = *in + __n;\n    *out = *out + 1;\n    return 1;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    **out = value;\n    *in = *in + __n;\n    *out = *out + 1;\n    return 1;\n  }" { (expression_statement "**out = value;" (assignment_expression "**out = value" (pointer_expression "**out" * (pointer_expression "*out" * identifier)) = identifier) ;) (expression_statement "*in = *in + __n;" (assignment_expression "*in = *in + __n" (pointer_expression "*in" * identifier) = (binary_expression "*in + __n" (pointer_expression "*in" * identifier) + identifier)) ;) (expression_statement "*out = *out + 1;" (assignment_expression "*out = *out + 1" (pointer_expression "*out" * identifier) = (binary_expression "*out + 1" (pointer_expression "*out" * identifier) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "undefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)" identifier (parameter_list "(int *param_1,int *param_2,char *param_3,undefined1 param_4)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "undefined1 param_4" type_identifier identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (expression_statement "__n = strlen(param_3);" (assignment_expression "__n = strlen(param_3)" identifier = (call_expression "strlen(param_3)" identifier (argument_list "(param_3)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp((char *)*param_1,param_3,__n);" (assignment_expression "iVar1 = strncmp((char *)*param_1,param_3,__n)" identifier = (call_expression "strncmp((char *)*param_1,param_3,__n)" identifier (argument_list "((char *)*param_1,param_3,__n)" ( (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)) , identifier , identifier )))) ;) (if_statement "if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" { (expression_statement "*(undefined1 *)*param_2 = param_4;" (assignment_expression "*(undefined1 *)*param_2 = param_4" (pointer_expression "*(undefined1 *)*param_2" * (cast_expression "(undefined1 *)*param_2" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) = identifier) ;) (expression_statement "*param_1 = *param_1 + __n;" (assignment_expression "*param_1 = *param_1 + __n" (pointer_expression "*param_1" * identifier) = (binary_expression "*param_1 + __n" (pointer_expression "*param_1" * identifier) + identifier)) ;) (expression_statement "*param_2 = *param_2 + 1;" (assignment_expression "*param_2 = *param_2 + 1" (pointer_expression "*param_2" * identifier) = (binary_expression "*param_2 + 1" (pointer_expression "*param_2" * identifier) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)) , IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (pointer_expression * IDENT) + IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (pointer_expression * IDENT) + LIT)) ;) (return_statement return LIT ;) })) (return_statement return LIT ;) })))
(function_definition "undefined4 __regparm3 FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)\n\n{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" (type_identifier "undefined4") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_001e43b0(int *param_1,int *param_2,char *param_3,undefined1 param_4)" (identifier "FUN_001e43b0") (parameter_list "(int *param_1,int *param_2,char *param_3,undefined1 param_4)" (( "(") (parameter_declaration "int *param_1" (primitive_type "int") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "char *param_3" (primitive_type "char") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) (, ",") (parameter_declaration "undefined1 param_4" (type_identifier "undefined1") (identifier "param_4")) () ")"))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  \n  __n = strlen(param_3);\n  iVar1 = strncmp((char *)*param_1,param_3,__n);\n  if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }\n  return 0;\n}" ({ "{") (declaration "size_t __n;" (primitive_type "size_t") (identifier "__n") (; ";")) (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (expression_statement "__n = strlen(param_3);" (assignment_expression "__n = strlen(param_3)" (identifier "__n") (= "=") (call_expression "strlen(param_3)" (identifier "strlen") (argument_list "(param_3)" (( "(") (identifier "param_3") () ")")))) (; ";")) (expression_statement "iVar1 = strncmp((char *)*param_1,param_3,__n);" (assignment_expression "iVar1 = strncmp((char *)*param_1,param_3,__n)" (identifier "iVar1") (= "=") (call_expression "strncmp((char *)*param_1,param_3,__n)" (identifier "strncmp") (argument_list "((char *)*param_1,param_3,__n)" (( "(") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (, ",") (identifier "param_3") (, ",") (identifier "__n") () ")")))) (; ";")) (if_statement "if (iVar1 == 0) {\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" (if "if") (parenthesized_expression "(iVar1 == 0)" (( "(") (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    *(undefined1 *)*param_2 = param_4;\n    *param_1 = *param_1 + __n;\n    *param_2 = *param_2 + 1;\n    return 1;\n  }" ({ "{") (expression_statement "*(undefined1 *)*param_2 = param_4;" (assignment_expression "*(undefined1 *)*param_2 = param_4" (pointer_expression "*(undefined1 *)*param_2" (* "*") (cast_expression "(undefined1 *)*param_2" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_2" (* "*") (identifier "param_2")))) (= "=") (identifier "param_4")) (; ";")) (expression_statement "*param_1 = *param_1 + __n;" (assignment_expression "*param_1 = *param_1 + __n" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (binary_expression "*param_1 + __n" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (+ "+") (identifier "__n"))) (; ";")) (expression_statement "*param_2 = *param_2 + 1;" (assignment_expression "*param_2 = *param_2 + 1" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (binary_expression "*param_2 + 1" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (+ "+") (number_literal "1"))) (; ";")) (return_statement "return 1;" (return "return") (number_literal "1") (; ";")) (} "}"))) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

int __regparm3 function_1(char **in,char **out,char *seq,char value)

{
  size_t var_4;
  int var_3;
  
  var_4 = var_1(seq);
  var_3 = var_2(*in,seq,var_4);
  if (var_3 == 0) {
    **out = value;
    *in = *in + var_4;
    *out = *out + 1;
    return 1;
  }
  return 0;
}


(translation_unit (function_definition type: (type_identifier) (ERROR (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))) (identifier) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier)))) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))) (return_statement (number_literal)))) (return_statement (number_literal)))))

/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

undefined4 __regparm3 MASKED(int *param_1,int *param_2,char *param_3,undefined1 param_4)

{
  size_t __n;
  int iVar1;
  
  __n = strlen(param_3);
  iVar1 = strncmp((char *)*param_1,param_3,__n);
  if (iVar1 == 0) {
    *(undefined1 *)*param_2 = param_4;
    *param_1 = *param_1 + __n;
    *param_2 = *param_2 + 1;
    return 1;
  }
  return 0;
}

