
/* WARNING: Unknown calling convention */

_Bool can_write_any_file(void)

{
  undefined *puVar1;
  int iVar2;
  
  puVar1 = PTR_DAT_00032108;
  if (PTR_DAT_00032108[0x2571] != '\0') {
    return (_Bool)PTR_DAT_00032108[0x2570];
  }
  iVar2 = (*(code *)PTR_geteuid_00032390)();
  puVar1[0x2571] = 1;
  PTR_DAT_00032108[0x2570] = iVar2 == 0;
  return iVar2 == 0;
}



undefined1 can_write_any_file(void)

{
  undefined *puVar1;
  int iVar2;
  
  puVar1 = PTR_DAT_00032108;
  if (PTR_DAT_00032108[0x2571] != '\0') {
    return PTR_DAT_00032108[0x2570];
  }
  iVar2 = (*(code *)PTR_geteuid_00032390)();
  puVar1[0x2571] = 1;
  PTR_DAT_00032108[0x2570] = iVar2 == 0;
  return iVar2 == 0;
}


lui gp,0x2
addiu gp,gp,0x22d0
addu gp,gp,t9
addiu sp,sp,-0x20
sw s0,0x18(sp)
lw s0,-0x7fd8(gp)
sw gp,0x10(sp)
sw ra,0x1c(sp)
lbu v0,0x2571(s0)
beq v0,zero,0x00017e50
_lw v0,-0x7fd8(gp)
lw ra,0x1c(sp)
lw s0,0x18(sp)
addiu sp,sp,0x20
jr ra
_lbu v0,0x2570(v0)
lw t9,-0x7d50(gp)
jalr t9
_nop
li v1,0x1
lw gp,0x10(sp)
sltiu v0,v0,0x1
lw ra,0x1c(sp)
sb v1,0x2571(s0)
lw s0,0x18(sp)
addiu sp,sp,0x20
lw v1,-0x7fd8(gp)
jr ra
_sb v0,0x2570(v1)
(translation_unit "undefined1 can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}\n\n" (function_definition "undefined1 can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" type_identifier (function_declarator "can_write_any_file(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (expression_statement "puVar1 = PTR_DAT_00032108;" (assignment_expression "puVar1 = PTR_DAT_00032108" identifier = identifier) ;) (if_statement "if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }" if (parenthesized_expression "(PTR_DAT_00032108[0x2571] != '\0')" ( (binary_expression "PTR_DAT_00032108[0x2571] != '\0'" (subscript_expression "PTR_DAT_00032108[0x2571]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    return PTR_DAT_00032108[0x2570];\n  }" { (return_statement "return PTR_DAT_00032108[0x2570];" return (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ]) ;) })) (expression_statement "iVar2 = (*(code *)PTR_geteuid_00032390)();" (assignment_expression "iVar2 = (*(code *)PTR_geteuid_00032390)()" identifier = (call_expression "(*(code *)PTR_geteuid_00032390)()" (parenthesized_expression "(*(code *)PTR_geteuid_00032390)" ( (pointer_expression "*(code *)PTR_geteuid_00032390" * (cast_expression "(code *)PTR_geteuid_00032390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "puVar1[0x2571] = 1;" (assignment_expression "puVar1[0x2571] = 1" (subscript_expression "puVar1[0x2571]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "PTR_DAT_00032108[0x2570] = iVar2 == 0;" (assignment_expression "PTR_DAT_00032108[0x2570] = iVar2 == 0" (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ]) = (binary_expression "iVar2 == 0" identifier == number_literal)) ;) (return_statement "return iVar2 == 0;" return (binary_expression "iVar2 == 0" identifier == number_literal) ;) })))
(translation_unit "/* WARNING: Unknown calling convention */\n\n_Bool can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return (_Bool)PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}\n\n" comment (function_definition "_Bool can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return (_Bool)PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" type_identifier (function_declarator "can_write_any_file(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return (_Bool)PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (expression_statement "puVar1 = PTR_DAT_00032108;" (assignment_expression "puVar1 = PTR_DAT_00032108" identifier = identifier) ;) (if_statement "if (PTR_DAT_00032108[0x2571] != '\0') {\n    return (_Bool)PTR_DAT_00032108[0x2570];\n  }" if (parenthesized_expression "(PTR_DAT_00032108[0x2571] != '\0')" ( (binary_expression "PTR_DAT_00032108[0x2571] != '\0'" (subscript_expression "PTR_DAT_00032108[0x2571]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    return (_Bool)PTR_DAT_00032108[0x2570];\n  }" { (return_statement "return (_Bool)PTR_DAT_00032108[0x2570];" return (cast_expression "(_Bool)PTR_DAT_00032108[0x2570]" ( (type_descriptor "_Bool" type_identifier) ) (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ])) ;) })) (expression_statement "iVar2 = (*(code *)PTR_geteuid_00032390)();" (assignment_expression "iVar2 = (*(code *)PTR_geteuid_00032390)()" identifier = (call_expression "(*(code *)PTR_geteuid_00032390)()" (parenthesized_expression "(*(code *)PTR_geteuid_00032390)" ( (pointer_expression "*(code *)PTR_geteuid_00032390" * (cast_expression "(code *)PTR_geteuid_00032390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "puVar1[0x2571] = 1;" (assignment_expression "puVar1[0x2571] = 1" (subscript_expression "puVar1[0x2571]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "PTR_DAT_00032108[0x2570] = iVar2 == 0;" (assignment_expression "PTR_DAT_00032108[0x2570] = iVar2 == 0" (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ]) = (binary_expression "iVar2 == 0" identifier == number_literal)) ;) (return_statement "return iVar2 == 0;" return (binary_expression "iVar2 == 0" identifier == number_literal) ;) })))
(translation_unit "undefined1 can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}\n\n" (function_definition "undefined1 can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" type_identifier (function_declarator "can_write_any_file(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (expression_statement "puVar1 = PTR_DAT_00032108;" (assignment_expression "puVar1 = PTR_DAT_00032108" identifier = identifier) ;) (if_statement "if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }" if (parenthesized_expression "(PTR_DAT_00032108[0x2571] != '\0')" ( (binary_expression "PTR_DAT_00032108[0x2571] != '\0'" (subscript_expression "PTR_DAT_00032108[0x2571]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    return PTR_DAT_00032108[0x2570];\n  }" { (return_statement "return PTR_DAT_00032108[0x2570];" return (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ]) ;) })) (expression_statement "iVar2 = (*(code *)PTR_geteuid_00032390)();" (assignment_expression "iVar2 = (*(code *)PTR_geteuid_00032390)()" identifier = (call_expression "(*(code *)PTR_geteuid_00032390)()" (parenthesized_expression "(*(code *)PTR_geteuid_00032390)" ( (pointer_expression "*(code *)PTR_geteuid_00032390" * (cast_expression "(code *)PTR_geteuid_00032390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "puVar1[0x2571] = 1;" (assignment_expression "puVar1[0x2571] = 1" (subscript_expression "puVar1[0x2571]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "PTR_DAT_00032108[0x2570] = iVar2 == 0;" (assignment_expression "PTR_DAT_00032108[0x2570] = iVar2 == 0" (subscript_expression "PTR_DAT_00032108[0x2570]" identifier [ number_literal ]) = (binary_expression "iVar2 == 0" identifier == number_literal)) ;) (return_statement "return iVar2 == 0;" return (binary_expression "iVar2 == 0" identifier == number_literal) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) != (char_literal ' escape_sequence ')) )) (compound_statement { (return_statement return (subscript_expression IDENT [ LIT ]) ;) })) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT == LIT)) ;) (return_statement return (binary_expression IDENT == LIT) ;) })))
(function_definition "undefined1 can_write_any_file(void)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" (type_identifier "undefined1") (function_declarator "can_write_any_file(void)" (identifier "can_write_any_file") (parameter_list "(void)" (( "(") (parameter_declaration "void" (primitive_type "void")) () ")"))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  \n  puVar1 = PTR_DAT_00032108;\n  if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }\n  iVar2 = (*(code *)PTR_geteuid_00032390)();\n  puVar1[0x2571] = 1;\n  PTR_DAT_00032108[0x2570] = iVar2 == 0;\n  return iVar2 == 0;\n}" ({ "{") (declaration "undefined *puVar1;" (type_identifier "undefined") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (expression_statement "puVar1 = PTR_DAT_00032108;" (assignment_expression "puVar1 = PTR_DAT_00032108" (identifier "puVar1") (= "=") (identifier "PTR_DAT_00032108")) (; ";")) (if_statement "if (PTR_DAT_00032108[0x2571] != '\0') {\n    return PTR_DAT_00032108[0x2570];\n  }" (if "if") (parenthesized_expression "(PTR_DAT_00032108[0x2571] != '\0')" (( "(") (binary_expression "PTR_DAT_00032108[0x2571] != '\0'" (subscript_expression "PTR_DAT_00032108[0x2571]" (identifier "PTR_DAT_00032108") ([ "[") (number_literal "0x2571") (] "]")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n    return PTR_DAT_00032108[0x2570];\n  }" ({ "{") (return_statement "return PTR_DAT_00032108[0x2570];" (return "return") (subscript_expression "PTR_DAT_00032108[0x2570]" (identifier "PTR_DAT_00032108") ([ "[") (number_literal "0x2570") (] "]")) (; ";")) (} "}"))) (expression_statement "iVar2 = (*(code *)PTR_geteuid_00032390)();" (assignment_expression "iVar2 = (*(code *)PTR_geteuid_00032390)()" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_geteuid_00032390)()" (parenthesized_expression "(*(code *)PTR_geteuid_00032390)" (( "(") (pointer_expression "*(code *)PTR_geteuid_00032390" (* "*") (cast_expression "(code *)PTR_geteuid_00032390" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_geteuid_00032390"))) () ")")) (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "puVar1[0x2571] = 1;" (assignment_expression "puVar1[0x2571] = 1" (subscript_expression "puVar1[0x2571]" (identifier "puVar1") ([ "[") (number_literal "0x2571") (] "]")) (= "=") (number_literal "1")) (; ";")) (expression_statement "PTR_DAT_00032108[0x2570] = iVar2 == 0;" (assignment_expression "PTR_DAT_00032108[0x2570] = iVar2 == 0" (subscript_expression "PTR_DAT_00032108[0x2570]" (identifier "PTR_DAT_00032108") ([ "[") (number_literal "0x2570") (] "]")) (= "=") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0"))) (; ";")) (return_statement "return iVar2 == 0;" (return "return") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) (; ";")) (} "}")))

/* WARNING: Unknown calling convention */

type_1 function_1(void)

{
  type_2 *puVar1;
  int var_1;
  
  puVar1 = PTR_DAT_00032108;
  if (PTR_DAT_00032108[0x2571] != '\0') {
    return (type_1)PTR_DAT_00032108[0x2570];
  }
  var_1 = (*(type_3 *)PTR_geteuid_00032390)();
  puVar1[0x2571] = 1;
  PTR_DAT_00032108[0x2570] = var_1 == 0;
  return var_1 == 0;
}


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

undefined1 MASKED(void)

{
  undefined *puVar1;
  int iVar2;
  
  puVar1 = PTR_DAT_00032108;
  if (PTR_DAT_00032108[0x2571] != '\0') {
    return PTR_DAT_00032108[0x2570];
  }
  iVar2 = (*(code *)PTR_geteuid_00032390)();
  puVar1[0x2571] = 1;
  PTR_DAT_00032108[0x2570] = iVar2 == 0;
  return iVar2 == 0;
}

