
int SHA_Final(SHA_State *s,uchar *output)

{
  int iVar1;
  SHA_State *s_00;
  uchar *puVar2;
  uchar *output_00;
  uint32 uVar3;
  int iVar4;
  uint uVar5;
  undefined *puVar6;
  uchar c [64];
  
  puVar6 = PTR___stack_chk_guard_00112630;
  iVar4 = s->blkused;
  iVar1 = *(int *)PTR___stack_chk_guard_00112630;
  if (iVar4 < 0x38) {
    iVar4 = 0x38 - iVar4;
  }
  else {
    iVar4 = 0x78 - iVar4;
  }
  uVar5 = s->lenlo;
  uVar3 = s->lenhi;
  (*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40);
  c[0] = 0x80;
  SHA_Bytes(s,c,iVar4);
  c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d;
  c._4_4_ = uVar5 << 3;
  SHA_Bytes(s,c,8);
  puVar2 = output;
  do {
    output_00 = puVar2 + 4;
    s_00 = (SHA_State *)(s->h + 1);
    *puVar2 = *(uchar *)s->h;
    puVar2[1] = (uchar)*(undefined2 *)s->h;
    puVar2[2] = (uchar)(s->h[0] >> 8);
    puVar2[3] = (uchar)s->h[0];
    s = s_00;
    puVar2 = output_00;
  } while (output_00 != output + 0x14);
  if (iVar1 == *(int *)puVar6) {
    return *(int *)puVar6;
  }
  puVar6 = PTR___stack_chk_fail_001122c8;
  (*(code *)PTR___stack_chk_fail_001122c8)();
  SHA_Final(s_00,output_00);
  (**(code **)(puVar6 + 0x8a73c))(s_00,0x60);
                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */
                    /* WARNING: Treating indirect jump as call */
  iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00);
  return iVar1;
}



int SHA_Final(uchar *md,SHA_CTX *c)

{
  uchar *md_00;
  SHA_CTX *pSVar1;
  SHA_CTX *c_00;
  int iVar2;
  int iVar3;
  uint uVar4;
  undefined *puVar5;
  uint local_6c;
  int local_68;
  int local_2c;
  
  puVar5 = PTR___stack_chk_guard_00112630;
  iVar3 = *(int *)(md + 0x54);
  local_2c = *(int *)PTR___stack_chk_guard_00112630;
  if (iVar3 < 0x38) {
    iVar3 = 0x38 - iVar3;
  }
  else {
    iVar3 = 0x78 - iVar3;
  }
  uVar4 = *(uint *)(md + 0x5c);
  iVar2 = *(int *)(md + 0x58);
  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);
  local_6c = CONCAT13(0x80,local_6c._1_3_);
  SHA_Bytes(md,&local_6c,iVar3);
  local_6c = iVar2 << 3 | uVar4 >> 0x1d;
  local_68 = uVar4 << 3;
  SHA_Bytes(md,&local_6c,8);
  pSVar1 = c;
  do {
    c_00 = (SHA_CTX *)&pSVar1->h1;
    md_00 = md + 4;
    *(uchar *)&pSVar1->h0 = *md;
    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;
    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);
    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;
    md = md_00;
    pSVar1 = c_00;
  } while (c_00 != (SHA_CTX *)&c->Nl);
  if (local_2c == *(int *)puVar5) {
    return *(int *)puVar5;
  }
  puVar5 = PTR___stack_chk_fail_001122c8;
  (*(code *)PTR___stack_chk_fail_001122c8)();
  SHA_Final(md_00,c_00);
  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);
                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */
                    /* WARNING: Treating indirect jump as call */
  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);
  return iVar3;
}


lui gp,0x9
addiu gp,gp,0x27b4
addu gp,gp,t9
addiu sp,sp,-0x88
sw s7,0x80(sp)
sw s4,0x74(sp)
lw s7,-0x6c80(gp)
lw s4,0x54(a0)
sw gp,0x10(sp)
sw s1,0x68(sp)
or s1,a0,zero
sw s0,0x64(sp)
slti v0,s4,0x38
sw ra,0x84(sp)
or s0,a1,zero
sw s6,0x7c(sp)
sw s5,0x78(sp)
sw s3,0x70(sp)
sw s2,0x6c(sp)
lw v1,0x0(s7)
sw v1,0x5c(sp)
bne v0,zero,0x00086c48
_li v0,0x38
li v0,0x78
subu s4,v0,s4
lw s5,0x5c(s1)
addiu s2,sp,0x1c
lw s3,0x58(s1)
li a3,0x40
lw t9,-0x70d8(gp)
or a1,zero,zero
srl v0,s5,0x1d
lw s6,-0x78f0(gp)
sll s3,s3,0x3
or a2,s4,zero
or a0,s2,zero
jalr t9
_or s3,s3,v0
li v0,-0x80
or a2,s4,zero
or a1,s2,zero
sb v0,0x1c(sp)
or a0,s1,zero
or t9,s6,zero
bal 0x00086650
_sll s5,s5,0x3
li a2,0x8
sw s3,0x1c(sp)
or a1,s2,zero
sw s5,0x20(sp)
or t9,s6,zero
bal 0x00086650
_or a0,s1,zero
addiu v1,s0,0x14
lw gp,0x10(sp)
or a1,s0,zero
or a0,s1,zero
lbu v0,0x0(a0)
addiu a1,a1,0x4
addiu a0,a0,0x4
sb v0,-0x4(a1)
lhu v0,-0x4(a0)
sb v0,-0x3(a1)
lw v0,-0x4(a0)
srl v0,v0,0x8
sb v0,-0x2(a1)
lw v0,-0x4(a0)
bne a1,v1,0x00086be0
_sb v0,-0x1(a1)
lw v1,0x5c(sp)
lw v0,0x0(s7)
bne v1,v0,0x00086c50
_lw ra,0x84(sp)
lw s7,0x80(sp)
lw s6,0x7c(sp)
lw s5,0x78(sp)
lw s4,0x74(sp)
lw s3,0x70(sp)
lw s2,0x6c(sp)
lw s1,0x68(sp)
lw s0,0x64(sp)
jr ra
_addiu sp,sp,0x88
b 0x00086b60
_subu s4,v0,s4
lw t9,-0x6fe8(gp)
jalr t9
_nop
lui gp,0x9
addiu gp,gp,0x2654
addu gp,gp,t9
addiu sp,sp,-0x20
lw t9,-0x78e4(gp)
sw ra,0x1c(sp)
sw s0,0x18(sp)
sw gp,0x10(sp)
bal 0x00086afc
_or s0,a0,zero
li a1,0x60
lw gp,0x10(sp)
lw t9,-0x7f18(gp)
jalr t9
_or a0,s0,zero
or a0,s0,zero
lw gp,0x10(sp)
lw ra,0x1c(sp)
lw s0,0x18(sp)
lw t9,-0x7fc0(gp)
jr t9
_addiu sp,sp,0x20
(translation_unit "int SHA_Final(uchar *md,SHA_CTX *c)\n\n{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}\n\n" (function_definition "int SHA_Final(uchar *md,SHA_CTX *c)\n\n{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" primitive_type (function_declarator "SHA_Final(uchar *md,SHA_CTX *c)" identifier (parameter_list "(uchar *md,SHA_CTX *c)" ( (parameter_declaration "uchar *md" type_identifier (pointer_declarator "*md" * identifier)) , (parameter_declaration "SHA_CTX *c" type_identifier (pointer_declarator "*c" * identifier)) ))) (compound_statement "{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" { (declaration "uchar *md_00;" type_identifier (pointer_declarator "*md_00" * identifier) ;) (declaration "SHA_CTX *pSVar1;" type_identifier (pointer_declarator "*pSVar1" * identifier) ;) (declaration "SHA_CTX *c_00;" type_identifier (pointer_declarator "*c_00" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "undefined *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "uint local_6c;" type_identifier identifier ;) (declaration "int local_68;" primitive_type identifier ;) (declaration "int local_2c;" primitive_type identifier ;) (expression_statement "puVar5 = PTR___stack_chk_guard_00112630;" (assignment_expression "puVar5 = PTR___stack_chk_guard_00112630" identifier = identifier) ;) (expression_statement "iVar3 = *(int *)(md + 0x54);" (assignment_expression "iVar3 = *(int *)(md + 0x54)" identifier = (pointer_expression "*(int *)(md + 0x54)" * (cast_expression "(int *)(md + 0x54)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x54)" ( (binary_expression "md + 0x54" identifier + number_literal) ))))) ;) (expression_statement "local_2c = *(int *)PTR___stack_chk_guard_00112630;" (assignment_expression "local_2c = *(int *)PTR___stack_chk_guard_00112630" identifier = (pointer_expression "*(int *)PTR___stack_chk_guard_00112630" * (cast_expression "(int *)PTR___stack_chk_guard_00112630" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }" if (parenthesized_expression "(iVar3 < 0x38)" ( (binary_expression "iVar3 < 0x38" identifier < number_literal) )) (compound_statement "{\n    iVar3 = 0x38 - iVar3;\n  }" { (expression_statement "iVar3 = 0x38 - iVar3;" (assignment_expression "iVar3 = 0x38 - iVar3" identifier = (binary_expression "0x38 - iVar3" number_literal - identifier)) ;) }) (else_clause "else {\n    iVar3 = 0x78 - iVar3;\n  }" else (compound_statement "{\n    iVar3 = 0x78 - iVar3;\n  }" { (expression_statement "iVar3 = 0x78 - iVar3;" (assignment_expression "iVar3 = 0x78 - iVar3" identifier = (binary_expression "0x78 - iVar3" number_literal - identifier)) ;) }))) (expression_statement "uVar4 = *(uint *)(md + 0x5c);" (assignment_expression "uVar4 = *(uint *)(md + 0x5c)" identifier = (pointer_expression "*(uint *)(md + 0x5c)" * (cast_expression "(uint *)(md + 0x5c)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x5c)" ( (binary_expression "md + 0x5c" identifier + number_literal) ))))) ;) (expression_statement "iVar2 = *(int *)(md + 0x58);" (assignment_expression "iVar2 = *(int *)(md + 0x58)" identifier = (pointer_expression "*(int *)(md + 0x58)" * (cast_expression "(int *)(md + 0x58)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x58)" ( (binary_expression "md + 0x58" identifier + number_literal) ))))) ;) (expression_statement "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);" (call_expression "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40)" (parenthesized_expression "(*(code *)PTR___memset_chk_001121d8)" ( (pointer_expression "*(code *)PTR___memset_chk_001121d8" * (cast_expression "(code *)PTR___memset_chk_001121d8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(&local_6c,0,iVar3,0x40)" ( (pointer_expression "&local_6c" & identifier) , number_literal , identifier , number_literal ))) ;) (expression_statement "local_6c = CONCAT13(0x80,local_6c._1_3_);" (assignment_expression "local_6c = CONCAT13(0x80,local_6c._1_3_)" identifier = (call_expression "CONCAT13(0x80,local_6c._1_3_)" identifier (argument_list "(0x80,local_6c._1_3_)" ( number_literal , (field_expression "local_6c._1_3_" identifier . field_identifier) )))) ;) (expression_statement "SHA_Bytes(md,&local_6c,iVar3);" (call_expression "SHA_Bytes(md,&local_6c,iVar3)" identifier (argument_list "(md,&local_6c,iVar3)" ( identifier , (pointer_expression "&local_6c" & identifier) , identifier ))) ;) (expression_statement "local_6c = iVar2 << 3 | uVar4 >> 0x1d;" (assignment_expression "local_6c = iVar2 << 3 | uVar4 >> 0x1d" identifier = (binary_expression "iVar2 << 3 | uVar4 >> 0x1d" (binary_expression "iVar2 << 3" identifier << number_literal) | (binary_expression "uVar4 >> 0x1d" identifier >> number_literal))) ;) (expression_statement "local_68 = uVar4 << 3;" (assignment_expression "local_68 = uVar4 << 3" identifier = (binary_expression "uVar4 << 3" identifier << number_literal)) ;) (expression_statement "SHA_Bytes(md,&local_6c,8);" (call_expression "SHA_Bytes(md,&local_6c,8)" identifier (argument_list "(md,&local_6c,8)" ( identifier , (pointer_expression "&local_6c" & identifier) , number_literal ))) ;) (expression_statement "pSVar1 = c;" (assignment_expression "pSVar1 = c" identifier = identifier) ;) (do_statement "do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);" do (compound_statement "{\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  }" { (expression_statement "c_00 = (SHA_CTX *)&pSVar1->h1;" (assignment_expression "c_00 = (SHA_CTX *)&pSVar1->h1" identifier = (cast_expression "(SHA_CTX *)&pSVar1->h1" ( (type_descriptor "SHA_CTX *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&pSVar1->h1" & (field_expression "pSVar1->h1" identifier -> field_identifier)))) ;) (expression_statement "md_00 = md + 4;" (assignment_expression "md_00 = md + 4" identifier = (binary_expression "md + 4" identifier + number_literal)) ;) (expression_statement "*(uchar *)&pSVar1->h0 = *md;" (assignment_expression "*(uchar *)&pSVar1->h0 = *md" (pointer_expression "*(uchar *)&pSVar1->h0" * (cast_expression "(uchar *)&pSVar1->h0" ( (type_descriptor "uchar *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier)))) = (pointer_expression "*md" * identifier)) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 1)" * (cast_expression "(char *)((int)&pSVar1->h0 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 1)" ( (binary_expression "(int)&pSVar1->h0 + 1" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)*(undefined2 *)md" ( (type_descriptor "char" primitive_type) ) (pointer_expression "*(undefined2 *)md" * (cast_expression "(undefined2 *)md" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)))) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);" (assignment_expression "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8)" (pointer_expression "*(char *)((int)&pSVar1->h0 + 2)" * (cast_expression "(char *)((int)&pSVar1->h0 + 2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 2)" ( (binary_expression "(int)&pSVar1->h0 + 2" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)((uint)*(undefined4 *)md >> 8)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "((uint)*(undefined4 *)md >> 8)" ( (binary_expression "(uint)*(undefined4 *)md >> 8" (binary_expression "(uint)*(undefined4 *)md" (parenthesized_expression "(uint)" ( identifier )) * (cast_expression "(undefined4 *)md" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) >> number_literal) )))) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 3)" * (cast_expression "(char *)((int)&pSVar1->h0 + 3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 3)" ( (binary_expression "(int)&pSVar1->h0 + 3" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)*(undefined4 *)md" ( (type_descriptor "char" primitive_type) ) (pointer_expression "*(undefined4 *)md" * (cast_expression "(undefined4 *)md" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)))) ;) (expression_statement "md = md_00;" (assignment_expression "md = md_00" identifier = identifier) ;) (expression_statement "pSVar1 = c_00;" (assignment_expression "pSVar1 = c_00" identifier = identifier) ;) }) while (parenthesized_expression "(c_00 != (SHA_CTX *)&c->Nl)" ( (binary_expression "c_00 != (SHA_CTX *)&c->Nl" identifier != (cast_expression "(SHA_CTX *)&c->Nl" ( (type_descriptor "SHA_CTX *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&c->Nl" & (field_expression "c->Nl" identifier -> field_identifier)))) )) ;) (if_statement "if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }" if (parenthesized_expression "(local_2c == *(int *)puVar5)" ( (binary_expression "local_2c == *(int *)puVar5" identifier == (pointer_expression "*(int *)puVar5" * (cast_expression "(int *)puVar5" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) )) (compound_statement "{\n    return *(int *)puVar5;\n  }" { (return_statement "return *(int *)puVar5;" return (pointer_expression "*(int *)puVar5" * (cast_expression "(int *)puVar5" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) })) (expression_statement "puVar5 = PTR___stack_chk_fail_001122c8;" (assignment_expression "puVar5 = PTR___stack_chk_fail_001122c8" identifier = identifier) ;) (expression_statement "(*(code *)PTR___stack_chk_fail_001122c8)();" (call_expression "(*(code *)PTR___stack_chk_fail_001122c8)()" (parenthesized_expression "(*(code *)PTR___stack_chk_fail_001122c8)" ( (pointer_expression "*(code *)PTR___stack_chk_fail_001122c8" * (cast_expression "(code *)PTR___stack_chk_fail_001122c8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "SHA_Final(md_00,c_00);" (call_expression "SHA_Final(md_00,c_00)" identifier (argument_list "(md_00,c_00)" ( identifier , identifier ))) ;) (expression_statement "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60);" (call_expression "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a73c))" ( (pointer_expression "**(code **)(puVar5 + 0x8a73c)" * (pointer_expression "*(code **)(puVar5 + 0x8a73c)" * (cast_expression "(code **)(puVar5 + 0x8a73c)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar5 + 0x8a73c)" ( (binary_expression "puVar5 + 0x8a73c" identifier + number_literal) ))))) )) (argument_list "(md_00,0x60)" ( identifier , number_literal ))) ;) comment comment (expression_statement "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);" (assignment_expression "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00)" identifier = (call_expression "(**(code **)(puVar5 + 0x8a694))(md_00)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a694))" ( (pointer_expression "**(code **)(puVar5 + 0x8a694)" * (pointer_expression "*(code **)(puVar5 + 0x8a694)" * (cast_expression "(code **)(puVar5 + 0x8a694)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar5 + 0x8a694)" ( (binary_expression "puVar5 + 0x8a694" identifier + number_literal) ))))) )) (argument_list "(md_00)" ( identifier )))) ;) (return_statement "return iVar3;" return identifier ;) })))
(translation_unit "int SHA_Final(SHA_State *s,uchar *output)\n\n{\n  int iVar1;\n  SHA_State *s_00;\n  uchar *puVar2;\n  uchar *output_00;\n  uint32 uVar3;\n  int iVar4;\n  uint uVar5;\n  undefined *puVar6;\n  uchar c [64];\n  \n  puVar6 = PTR___stack_chk_guard_00112630;\n  iVar4 = s->blkused;\n  iVar1 = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar4 < 0x38) {\n    iVar4 = 0x38 - iVar4;\n  }\n  else {\n    iVar4 = 0x78 - iVar4;\n  }\n  uVar5 = s->lenlo;\n  uVar3 = s->lenhi;\n  (*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40);\n  c[0] = 0x80;\n  SHA_Bytes(s,c,iVar4);\n  c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d;\n  c._4_4_ = uVar5 << 3;\n  SHA_Bytes(s,c,8);\n  puVar2 = output;\n  do {\n    output_00 = puVar2 + 4;\n    s_00 = (SHA_State *)(s->h + 1);\n    *puVar2 = *(uchar *)s->h;\n    puVar2[1] = (uchar)*(undefined2 *)s->h;\n    puVar2[2] = (uchar)(s->h[0] >> 8);\n    puVar2[3] = (uchar)s->h[0];\n    s = s_00;\n    puVar2 = output_00;\n  } while (output_00 != output + 0x14);\n  if (iVar1 == *(int *)puVar6) {\n    return *(int *)puVar6;\n  }\n  puVar6 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(s_00,output_00);\n  (**(code **)(puVar6 + 0x8a73c))(s_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00);\n  return iVar1;\n}\n\n" (function_definition "int SHA_Final(SHA_State *s,uchar *output)\n\n{\n  int iVar1;\n  SHA_State *s_00;\n  uchar *puVar2;\n  uchar *output_00;\n  uint32 uVar3;\n  int iVar4;\n  uint uVar5;\n  undefined *puVar6;\n  uchar c [64];\n  \n  puVar6 = PTR___stack_chk_guard_00112630;\n  iVar4 = s->blkused;\n  iVar1 = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar4 < 0x38) {\n    iVar4 = 0x38 - iVar4;\n  }\n  else {\n    iVar4 = 0x78 - iVar4;\n  }\n  uVar5 = s->lenlo;\n  uVar3 = s->lenhi;\n  (*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40);\n  c[0] = 0x80;\n  SHA_Bytes(s,c,iVar4);\n  c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d;\n  c._4_4_ = uVar5 << 3;\n  SHA_Bytes(s,c,8);\n  puVar2 = output;\n  do {\n    output_00 = puVar2 + 4;\n    s_00 = (SHA_State *)(s->h + 1);\n    *puVar2 = *(uchar *)s->h;\n    puVar2[1] = (uchar)*(undefined2 *)s->h;\n    puVar2[2] = (uchar)(s->h[0] >> 8);\n    puVar2[3] = (uchar)s->h[0];\n    s = s_00;\n    puVar2 = output_00;\n  } while (output_00 != output + 0x14);\n  if (iVar1 == *(int *)puVar6) {\n    return *(int *)puVar6;\n  }\n  puVar6 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(s_00,output_00);\n  (**(code **)(puVar6 + 0x8a73c))(s_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00);\n  return iVar1;\n}" primitive_type (function_declarator "SHA_Final(SHA_State *s,uchar *output)" identifier (parameter_list "(SHA_State *s,uchar *output)" ( (parameter_declaration "SHA_State *s" type_identifier (pointer_declarator "*s" * identifier)) , (parameter_declaration "uchar *output" type_identifier (pointer_declarator "*output" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  SHA_State *s_00;\n  uchar *puVar2;\n  uchar *output_00;\n  uint32 uVar3;\n  int iVar4;\n  uint uVar5;\n  undefined *puVar6;\n  uchar c [64];\n  \n  puVar6 = PTR___stack_chk_guard_00112630;\n  iVar4 = s->blkused;\n  iVar1 = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar4 < 0x38) {\n    iVar4 = 0x38 - iVar4;\n  }\n  else {\n    iVar4 = 0x78 - iVar4;\n  }\n  uVar5 = s->lenlo;\n  uVar3 = s->lenhi;\n  (*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40);\n  c[0] = 0x80;\n  SHA_Bytes(s,c,iVar4);\n  c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d;\n  c._4_4_ = uVar5 << 3;\n  SHA_Bytes(s,c,8);\n  puVar2 = output;\n  do {\n    output_00 = puVar2 + 4;\n    s_00 = (SHA_State *)(s->h + 1);\n    *puVar2 = *(uchar *)s->h;\n    puVar2[1] = (uchar)*(undefined2 *)s->h;\n    puVar2[2] = (uchar)(s->h[0] >> 8);\n    puVar2[3] = (uchar)s->h[0];\n    s = s_00;\n    puVar2 = output_00;\n  } while (output_00 != output + 0x14);\n  if (iVar1 == *(int *)puVar6) {\n    return *(int *)puVar6;\n  }\n  puVar6 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(s_00,output_00);\n  (**(code **)(puVar6 + 0x8a73c))(s_00,0x60);\n                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */\n                    /* WARNING: Treating indirect jump as call */\n  iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00);\n  return iVar1;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "SHA_State *s_00;" type_identifier (pointer_declarator "*s_00" * identifier) ;) (declaration "uchar *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "uchar *output_00;" type_identifier (pointer_declarator "*output_00" * identifier) ;) (declaration "uint32 uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "undefined *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "uchar c [64];" type_identifier (array_declarator "c [64]" identifier [ number_literal ]) ;) (expression_statement "puVar6 = PTR___stack_chk_guard_00112630;" (assignment_expression "puVar6 = PTR___stack_chk_guard_00112630" identifier = identifier) ;) (expression_statement "iVar4 = s->blkused;" (assignment_expression "iVar4 = s->blkused" identifier = (field_expression "s->blkused" identifier -> field_identifier)) ;) (expression_statement "iVar1 = *(int *)PTR___stack_chk_guard_00112630;" (assignment_expression "iVar1 = *(int *)PTR___stack_chk_guard_00112630" identifier = (pointer_expression "*(int *)PTR___stack_chk_guard_00112630" * (cast_expression "(int *)PTR___stack_chk_guard_00112630" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar4 < 0x38) {\n    iVar4 = 0x38 - iVar4;\n  }\n  else {\n    iVar4 = 0x78 - iVar4;\n  }" if (parenthesized_expression "(iVar4 < 0x38)" ( (binary_expression "iVar4 < 0x38" identifier < number_literal) )) (compound_statement "{\n    iVar4 = 0x38 - iVar4;\n  }" { (expression_statement "iVar4 = 0x38 - iVar4;" (assignment_expression "iVar4 = 0x38 - iVar4" identifier = (binary_expression "0x38 - iVar4" number_literal - identifier)) ;) }) (else_clause "else {\n    iVar4 = 0x78 - iVar4;\n  }" else (compound_statement "{\n    iVar4 = 0x78 - iVar4;\n  }" { (expression_statement "iVar4 = 0x78 - iVar4;" (assignment_expression "iVar4 = 0x78 - iVar4" identifier = (binary_expression "0x78 - iVar4" number_literal - identifier)) ;) }))) (expression_statement "uVar5 = s->lenlo;" (assignment_expression "uVar5 = s->lenlo" identifier = (field_expression "s->lenlo" identifier -> field_identifier)) ;) (expression_statement "uVar3 = s->lenhi;" (assignment_expression "uVar3 = s->lenhi" identifier = (field_expression "s->lenhi" identifier -> field_identifier)) ;) (expression_statement "(*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40);" (call_expression "(*(code *)PTR___memset_chk_001121d8)(c,0,iVar4,0x40)" (parenthesized_expression "(*(code *)PTR___memset_chk_001121d8)" ( (pointer_expression "*(code *)PTR___memset_chk_001121d8" * (cast_expression "(code *)PTR___memset_chk_001121d8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(c,0,iVar4,0x40)" ( identifier , number_literal , identifier , number_literal ))) ;) (expression_statement "c[0] = 0x80;" (assignment_expression "c[0] = 0x80" (subscript_expression "c[0]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "SHA_Bytes(s,c,iVar4);" (call_expression "SHA_Bytes(s,c,iVar4)" identifier (argument_list "(s,c,iVar4)" ( identifier , identifier , identifier ))) ;) (expression_statement "c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d;" (assignment_expression "c._0_4_ = uVar3 << 3 | uVar5 >> 0x1d" (field_expression "c._0_4_" identifier . field_identifier) = (binary_expression "uVar3 << 3 | uVar5 >> 0x1d" (binary_expression "uVar3 << 3" identifier << number_literal) | (binary_expression "uVar5 >> 0x1d" identifier >> number_literal))) ;) (expression_statement "c._4_4_ = uVar5 << 3;" (assignment_expression "c._4_4_ = uVar5 << 3" (field_expression "c._4_4_" identifier . field_identifier) = (binary_expression "uVar5 << 3" identifier << number_literal)) ;) (expression_statement "SHA_Bytes(s,c,8);" (call_expression "SHA_Bytes(s,c,8)" identifier (argument_list "(s,c,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "puVar2 = output;" (assignment_expression "puVar2 = output" identifier = identifier) ;) (do_statement "do {\n    output_00 = puVar2 + 4;\n    s_00 = (SHA_State *)(s->h + 1);\n    *puVar2 = *(uchar *)s->h;\n    puVar2[1] = (uchar)*(undefined2 *)s->h;\n    puVar2[2] = (uchar)(s->h[0] >> 8);\n    puVar2[3] = (uchar)s->h[0];\n    s = s_00;\n    puVar2 = output_00;\n  } while (output_00 != output + 0x14);" do (compound_statement "{\n    output_00 = puVar2 + 4;\n    s_00 = (SHA_State *)(s->h + 1);\n    *puVar2 = *(uchar *)s->h;\n    puVar2[1] = (uchar)*(undefined2 *)s->h;\n    puVar2[2] = (uchar)(s->h[0] >> 8);\n    puVar2[3] = (uchar)s->h[0];\n    s = s_00;\n    puVar2 = output_00;\n  }" { (expression_statement "output_00 = puVar2 + 4;" (assignment_expression "output_00 = puVar2 + 4" identifier = (binary_expression "puVar2 + 4" identifier + number_literal)) ;) (expression_statement "s_00 = (SHA_State *)(s->h + 1);" (assignment_expression "s_00 = (SHA_State *)(s->h + 1)" identifier = (cast_expression "(SHA_State *)(s->h + 1)" ( (type_descriptor "SHA_State *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(s->h + 1)" ( (binary_expression "s->h + 1" (field_expression "s->h" identifier -> field_identifier) + number_literal) )))) ;) (expression_statement "*puVar2 = *(uchar *)s->h;" (assignment_expression "*puVar2 = *(uchar *)s->h" (pointer_expression "*puVar2" * identifier) = (pointer_expression "*(uchar *)s->h" * (cast_expression "(uchar *)s->h" ( (type_descriptor "uchar *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "s->h" identifier -> field_identifier)))) ;) (expression_statement "puVar2[1] = (uchar)*(undefined2 *)s->h;" (assignment_expression "puVar2[1] = (uchar)*(undefined2 *)s->h" (subscript_expression "puVar2[1]" identifier [ number_literal ]) = (binary_expression "(uchar)*(undefined2 *)s->h" (parenthesized_expression "(uchar)" ( identifier )) * (cast_expression "(undefined2 *)s->h" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "s->h" identifier -> field_identifier)))) ;) (expression_statement "puVar2[2] = (uchar)(s->h[0] >> 8);" (assignment_expression "puVar2[2] = (uchar)(s->h[0] >> 8)" (subscript_expression "puVar2[2]" identifier [ number_literal ]) = (call_expression "(uchar)(s->h[0] >> 8)" (parenthesized_expression "(uchar)" ( identifier )) (argument_list "(s->h[0] >> 8)" ( (binary_expression "s->h[0] >> 8" (subscript_expression "s->h[0]" (field_expression "s->h" identifier -> field_identifier) [ number_literal ]) >> number_literal) )))) ;) (expression_statement "puVar2[3] = (uchar)s->h[0];" (assignment_expression "puVar2[3] = (uchar)s->h[0]" (subscript_expression "puVar2[3]" identifier [ number_literal ]) = (cast_expression "(uchar)s->h[0]" ( (type_descriptor "uchar" type_identifier) ) (subscript_expression "s->h[0]" (field_expression "s->h" identifier -> field_identifier) [ number_literal ]))) ;) (expression_statement "s = s_00;" (assignment_expression "s = s_00" identifier = identifier) ;) (expression_statement "puVar2 = output_00;" (assignment_expression "puVar2 = output_00" identifier = identifier) ;) }) while (parenthesized_expression "(output_00 != output + 0x14)" ( (binary_expression "output_00 != output + 0x14" identifier != (binary_expression "output + 0x14" identifier + number_literal)) )) ;) (if_statement "if (iVar1 == *(int *)puVar6) {\n    return *(int *)puVar6;\n  }" if (parenthesized_expression "(iVar1 == *(int *)puVar6)" ( (binary_expression "iVar1 == *(int *)puVar6" identifier == (pointer_expression "*(int *)puVar6" * (cast_expression "(int *)puVar6" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) )) (compound_statement "{\n    return *(int *)puVar6;\n  }" { (return_statement "return *(int *)puVar6;" return (pointer_expression "*(int *)puVar6" * (cast_expression "(int *)puVar6" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) })) (expression_statement "puVar6 = PTR___stack_chk_fail_001122c8;" (assignment_expression "puVar6 = PTR___stack_chk_fail_001122c8" identifier = identifier) ;) (expression_statement "(*(code *)PTR___stack_chk_fail_001122c8)();" (call_expression "(*(code *)PTR___stack_chk_fail_001122c8)()" (parenthesized_expression "(*(code *)PTR___stack_chk_fail_001122c8)" ( (pointer_expression "*(code *)PTR___stack_chk_fail_001122c8" * (cast_expression "(code *)PTR___stack_chk_fail_001122c8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "SHA_Final(s_00,output_00);" (call_expression "SHA_Final(s_00,output_00)" identifier (argument_list "(s_00,output_00)" ( identifier , identifier ))) ;) (expression_statement "(**(code **)(puVar6 + 0x8a73c))(s_00,0x60);" (call_expression "(**(code **)(puVar6 + 0x8a73c))(s_00,0x60)" (parenthesized_expression "(**(code **)(puVar6 + 0x8a73c))" ( (pointer_expression "**(code **)(puVar6 + 0x8a73c)" * (pointer_expression "*(code **)(puVar6 + 0x8a73c)" * (cast_expression "(code **)(puVar6 + 0x8a73c)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar6 + 0x8a73c)" ( (binary_expression "puVar6 + 0x8a73c" identifier + number_literal) ))))) )) (argument_list "(s_00,0x60)" ( identifier , number_literal ))) ;) comment comment (expression_statement "iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00);" (assignment_expression "iVar1 = (**(code **)(puVar6 + 0x8a694))(s_00)" identifier = (call_expression "(**(code **)(puVar6 + 0x8a694))(s_00)" (parenthesized_expression "(**(code **)(puVar6 + 0x8a694))" ( (pointer_expression "**(code **)(puVar6 + 0x8a694)" * (pointer_expression "*(code **)(puVar6 + 0x8a694)" * (cast_expression "(code **)(puVar6 + 0x8a694)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar6 + 0x8a694)" ( (binary_expression "puVar6 + 0x8a694" identifier + number_literal) ))))) )) (argument_list "(s_00)" ( identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })))
(translation_unit "int SHA_Final(uchar *md,SHA_CTX *c)\n\n{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    \n                    \n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}\n\n" (function_definition "int SHA_Final(uchar *md,SHA_CTX *c)\n\n{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    \n                    \n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" primitive_type (function_declarator "SHA_Final(uchar *md,SHA_CTX *c)" identifier (parameter_list "(uchar *md,SHA_CTX *c)" ( (parameter_declaration "uchar *md" type_identifier (pointer_declarator "*md" * identifier)) , (parameter_declaration "SHA_CTX *c" type_identifier (pointer_declarator "*c" * identifier)) ))) (compound_statement "{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    \n                    \n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" { (declaration "uchar *md_00;" type_identifier (pointer_declarator "*md_00" * identifier) ;) (declaration "SHA_CTX *pSVar1;" type_identifier (pointer_declarator "*pSVar1" * identifier) ;) (declaration "SHA_CTX *c_00;" type_identifier (pointer_declarator "*c_00" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "undefined *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "uint local_6c;" type_identifier identifier ;) (declaration "int local_68;" primitive_type identifier ;) (declaration "int local_2c;" primitive_type identifier ;) (expression_statement "puVar5 = PTR___stack_chk_guard_00112630;" (assignment_expression "puVar5 = PTR___stack_chk_guard_00112630" identifier = identifier) ;) (expression_statement "iVar3 = *(int *)(md + 0x54);" (assignment_expression "iVar3 = *(int *)(md + 0x54)" identifier = (pointer_expression "*(int *)(md + 0x54)" * (cast_expression "(int *)(md + 0x54)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x54)" ( (binary_expression "md + 0x54" identifier + number_literal) ))))) ;) (expression_statement "local_2c = *(int *)PTR___stack_chk_guard_00112630;" (assignment_expression "local_2c = *(int *)PTR___stack_chk_guard_00112630" identifier = (pointer_expression "*(int *)PTR___stack_chk_guard_00112630" * (cast_expression "(int *)PTR___stack_chk_guard_00112630" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }" if (parenthesized_expression "(iVar3 < 0x38)" ( (binary_expression "iVar3 < 0x38" identifier < number_literal) )) (compound_statement "{\n    iVar3 = 0x38 - iVar3;\n  }" { (expression_statement "iVar3 = 0x38 - iVar3;" (assignment_expression "iVar3 = 0x38 - iVar3" identifier = (binary_expression "0x38 - iVar3" number_literal - identifier)) ;) }) (else_clause "else {\n    iVar3 = 0x78 - iVar3;\n  }" else (compound_statement "{\n    iVar3 = 0x78 - iVar3;\n  }" { (expression_statement "iVar3 = 0x78 - iVar3;" (assignment_expression "iVar3 = 0x78 - iVar3" identifier = (binary_expression "0x78 - iVar3" number_literal - identifier)) ;) }))) (expression_statement "uVar4 = *(uint *)(md + 0x5c);" (assignment_expression "uVar4 = *(uint *)(md + 0x5c)" identifier = (pointer_expression "*(uint *)(md + 0x5c)" * (cast_expression "(uint *)(md + 0x5c)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x5c)" ( (binary_expression "md + 0x5c" identifier + number_literal) ))))) ;) (expression_statement "iVar2 = *(int *)(md + 0x58);" (assignment_expression "iVar2 = *(int *)(md + 0x58)" identifier = (pointer_expression "*(int *)(md + 0x58)" * (cast_expression "(int *)(md + 0x58)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(md + 0x58)" ( (binary_expression "md + 0x58" identifier + number_literal) ))))) ;) (expression_statement "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);" (call_expression "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40)" (parenthesized_expression "(*(code *)PTR___memset_chk_001121d8)" ( (pointer_expression "*(code *)PTR___memset_chk_001121d8" * (cast_expression "(code *)PTR___memset_chk_001121d8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(&local_6c,0,iVar3,0x40)" ( (pointer_expression "&local_6c" & identifier) , number_literal , identifier , number_literal ))) ;) (expression_statement "local_6c = CONCAT13(0x80,local_6c._1_3_);" (assignment_expression "local_6c = CONCAT13(0x80,local_6c._1_3_)" identifier = (call_expression "CONCAT13(0x80,local_6c._1_3_)" identifier (argument_list "(0x80,local_6c._1_3_)" ( number_literal , (field_expression "local_6c._1_3_" identifier . field_identifier) )))) ;) (expression_statement "SHA_Bytes(md,&local_6c,iVar3);" (call_expression "SHA_Bytes(md,&local_6c,iVar3)" identifier (argument_list "(md,&local_6c,iVar3)" ( identifier , (pointer_expression "&local_6c" & identifier) , identifier ))) ;) (expression_statement "local_6c = iVar2 << 3 | uVar4 >> 0x1d;" (assignment_expression "local_6c = iVar2 << 3 | uVar4 >> 0x1d" identifier = (binary_expression "iVar2 << 3 | uVar4 >> 0x1d" (binary_expression "iVar2 << 3" identifier << number_literal) | (binary_expression "uVar4 >> 0x1d" identifier >> number_literal))) ;) (expression_statement "local_68 = uVar4 << 3;" (assignment_expression "local_68 = uVar4 << 3" identifier = (binary_expression "uVar4 << 3" identifier << number_literal)) ;) (expression_statement "SHA_Bytes(md,&local_6c,8);" (call_expression "SHA_Bytes(md,&local_6c,8)" identifier (argument_list "(md,&local_6c,8)" ( identifier , (pointer_expression "&local_6c" & identifier) , number_literal ))) ;) (expression_statement "pSVar1 = c;" (assignment_expression "pSVar1 = c" identifier = identifier) ;) (do_statement "do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);" do (compound_statement "{\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  }" { (expression_statement "c_00 = (SHA_CTX *)&pSVar1->h1;" (assignment_expression "c_00 = (SHA_CTX *)&pSVar1->h1" identifier = (cast_expression "(SHA_CTX *)&pSVar1->h1" ( (type_descriptor "SHA_CTX *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&pSVar1->h1" & (field_expression "pSVar1->h1" identifier -> field_identifier)))) ;) (expression_statement "md_00 = md + 4;" (assignment_expression "md_00 = md + 4" identifier = (binary_expression "md + 4" identifier + number_literal)) ;) (expression_statement "*(uchar *)&pSVar1->h0 = *md;" (assignment_expression "*(uchar *)&pSVar1->h0 = *md" (pointer_expression "*(uchar *)&pSVar1->h0" * (cast_expression "(uchar *)&pSVar1->h0" ( (type_descriptor "uchar *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier)))) = (pointer_expression "*md" * identifier)) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 1)" * (cast_expression "(char *)((int)&pSVar1->h0 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 1)" ( (binary_expression "(int)&pSVar1->h0 + 1" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)*(undefined2 *)md" ( (type_descriptor "char" primitive_type) ) (pointer_expression "*(undefined2 *)md" * (cast_expression "(undefined2 *)md" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)))) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);" (assignment_expression "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8)" (pointer_expression "*(char *)((int)&pSVar1->h0 + 2)" * (cast_expression "(char *)((int)&pSVar1->h0 + 2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 2)" ( (binary_expression "(int)&pSVar1->h0 + 2" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)((uint)*(undefined4 *)md >> 8)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "((uint)*(undefined4 *)md >> 8)" ( (binary_expression "(uint)*(undefined4 *)md >> 8" (binary_expression "(uint)*(undefined4 *)md" (parenthesized_expression "(uint)" ( identifier )) * (cast_expression "(undefined4 *)md" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) >> number_literal) )))) ;) (expression_statement "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 3)" * (cast_expression "(char *)((int)&pSVar1->h0 + 3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)&pSVar1->h0 + 3)" ( (binary_expression "(int)&pSVar1->h0 + 3" (cast_expression "(int)&pSVar1->h0" ( (type_descriptor "int" primitive_type) ) (pointer_expression "&pSVar1->h0" & (field_expression "pSVar1->h0" identifier -> field_identifier))) + number_literal) )))) = (cast_expression "(char)*(undefined4 *)md" ( (type_descriptor "char" primitive_type) ) (pointer_expression "*(undefined4 *)md" * (cast_expression "(undefined4 *)md" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)))) ;) (expression_statement "md = md_00;" (assignment_expression "md = md_00" identifier = identifier) ;) (expression_statement "pSVar1 = c_00;" (assignment_expression "pSVar1 = c_00" identifier = identifier) ;) }) while (parenthesized_expression "(c_00 != (SHA_CTX *)&c->Nl)" ( (binary_expression "c_00 != (SHA_CTX *)&c->Nl" identifier != (cast_expression "(SHA_CTX *)&c->Nl" ( (type_descriptor "SHA_CTX *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&c->Nl" & (field_expression "c->Nl" identifier -> field_identifier)))) )) ;) (if_statement "if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }" if (parenthesized_expression "(local_2c == *(int *)puVar5)" ( (binary_expression "local_2c == *(int *)puVar5" identifier == (pointer_expression "*(int *)puVar5" * (cast_expression "(int *)puVar5" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) )) (compound_statement "{\n    return *(int *)puVar5;\n  }" { (return_statement "return *(int *)puVar5;" return (pointer_expression "*(int *)puVar5" * (cast_expression "(int *)puVar5" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) })) (expression_statement "puVar5 = PTR___stack_chk_fail_001122c8;" (assignment_expression "puVar5 = PTR___stack_chk_fail_001122c8" identifier = identifier) ;) (expression_statement "(*(code *)PTR___stack_chk_fail_001122c8)();" (call_expression "(*(code *)PTR___stack_chk_fail_001122c8)()" (parenthesized_expression "(*(code *)PTR___stack_chk_fail_001122c8)" ( (pointer_expression "*(code *)PTR___stack_chk_fail_001122c8" * (cast_expression "(code *)PTR___stack_chk_fail_001122c8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "SHA_Final(md_00,c_00);" (call_expression "SHA_Final(md_00,c_00)" identifier (argument_list "(md_00,c_00)" ( identifier , identifier ))) ;) (expression_statement "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60);" (call_expression "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a73c))" ( (pointer_expression "**(code **)(puVar5 + 0x8a73c)" * (pointer_expression "*(code **)(puVar5 + 0x8a73c)" * (cast_expression "(code **)(puVar5 + 0x8a73c)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar5 + 0x8a73c)" ( (binary_expression "puVar5 + 0x8a73c" identifier + number_literal) ))))) )) (argument_list "(md_00,0x60)" ( identifier , number_literal ))) ;) (expression_statement "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);" (assignment_expression "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00)" identifier = (call_expression "(**(code **)(puVar5 + 0x8a694))(md_00)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a694))" ( (pointer_expression "**(code **)(puVar5 + 0x8a694)" * (pointer_expression "*(code **)(puVar5 + 0x8a694)" * (cast_expression "(code **)(puVar5 + 0x8a694)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar5 + 0x8a694)" ( (binary_expression "puVar5 + 0x8a694" identifier + number_literal) ))))) )) (argument_list "(md_00)" ( identifier )))) ;) (return_statement "return iVar3;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression LIT - IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression LIT - IDENT)) ;) }))) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression & IDENT) , LIT , IDENT , LIT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (field_expression IDENT . field_identifier) )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (binary_expression IDENT << LIT) | (binary_expression IDENT >> LIT))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT << LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , LIT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression & (field_expression IDENT -> field_identifier)))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression & (field_expression IDENT -> field_identifier)))) = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression & (field_expression IDENT -> field_identifier))) + LIT) )))) = (cast_expression ( (type_descriptor TYPE) ) (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression & (field_expression IDENT -> field_identifier))) + LIT) )))) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression (binary_expression (parenthesized_expression ( IDENT )) * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) >> LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression & (field_expression IDENT -> field_identifier))) + LIT) )))) = (cast_expression ( (type_descriptor TYPE) ) (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression & (field_expression IDENT -> field_identifier)))) )) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT))) )) (compound_statement { (return_statement return (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (argument_list ( IDENT , LIT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (argument_list ( IDENT )))) ;) (return_statement return IDENT ;) })))
(function_definition "int SHA_Final(uchar *md,SHA_CTX *c)\n\n{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    \n                    \n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" (primitive_type "int") (function_declarator "SHA_Final(uchar *md,SHA_CTX *c)" (identifier "SHA_Final") (parameter_list "(uchar *md,SHA_CTX *c)" (( "(") (parameter_declaration "uchar *md" (type_identifier "uchar") (pointer_declarator "*md" (* "*") (identifier "md"))) (, ",") (parameter_declaration "SHA_CTX *c" (type_identifier "SHA_CTX") (pointer_declarator "*c" (* "*") (identifier "c"))) () ")"))) (compound_statement "{\n  uchar *md_00;\n  SHA_CTX *pSVar1;\n  SHA_CTX *c_00;\n  int iVar2;\n  int iVar3;\n  uint uVar4;\n  undefined *puVar5;\n  uint local_6c;\n  int local_68;\n  int local_2c;\n  \n  puVar5 = PTR___stack_chk_guard_00112630;\n  iVar3 = *(int *)(md + 0x54);\n  local_2c = *(int *)PTR___stack_chk_guard_00112630;\n  if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }\n  uVar4 = *(uint *)(md + 0x5c);\n  iVar2 = *(int *)(md + 0x58);\n  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);\n  local_6c = CONCAT13(0x80,local_6c._1_3_);\n  SHA_Bytes(md,&local_6c,iVar3);\n  local_6c = iVar2 << 3 | uVar4 >> 0x1d;\n  local_68 = uVar4 << 3;\n  SHA_Bytes(md,&local_6c,8);\n  pSVar1 = c;\n  do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);\n  if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }\n  puVar5 = PTR___stack_chk_fail_001122c8;\n  (*(code *)PTR___stack_chk_fail_001122c8)();\n  SHA_Final(md_00,c_00);\n  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);\n                    \n                    \n  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);\n  return iVar3;\n}" ({ "{") (declaration "uchar *md_00;" (type_identifier "uchar") (pointer_declarator "*md_00" (* "*") (identifier "md_00")) (; ";")) (declaration "SHA_CTX *pSVar1;" (type_identifier "SHA_CTX") (pointer_declarator "*pSVar1" (* "*") (identifier "pSVar1")) (; ";")) (declaration "SHA_CTX *c_00;" (type_identifier "SHA_CTX") (pointer_declarator "*c_00" (* "*") (identifier "c_00")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "uint uVar4;" (type_identifier "uint") (identifier "uVar4") (; ";")) (declaration "undefined *puVar5;" (type_identifier "undefined") (pointer_declarator "*puVar5" (* "*") (identifier "puVar5")) (; ";")) (declaration "uint local_6c;" (type_identifier "uint") (identifier "local_6c") (; ";")) (declaration "int local_68;" (primitive_type "int") (identifier "local_68") (; ";")) (declaration "int local_2c;" (primitive_type "int") (identifier "local_2c") (; ";")) (expression_statement "puVar5 = PTR___stack_chk_guard_00112630;" (assignment_expression "puVar5 = PTR___stack_chk_guard_00112630" (identifier "puVar5") (= "=") (identifier "PTR___stack_chk_guard_00112630")) (; ";")) (expression_statement "iVar3 = *(int *)(md + 0x54);" (assignment_expression "iVar3 = *(int *)(md + 0x54)" (identifier "iVar3") (= "=") (pointer_expression "*(int *)(md + 0x54)" (* "*") (cast_expression "(int *)(md + 0x54)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(md + 0x54)" (( "(") (binary_expression "md + 0x54" (identifier "md") (+ "+") (number_literal "0x54")) () ")"))))) (; ";")) (expression_statement "local_2c = *(int *)PTR___stack_chk_guard_00112630;" (assignment_expression "local_2c = *(int *)PTR___stack_chk_guard_00112630" (identifier "local_2c") (= "=") (pointer_expression "*(int *)PTR___stack_chk_guard_00112630" (* "*") (cast_expression "(int *)PTR___stack_chk_guard_00112630" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___stack_chk_guard_00112630")))) (; ";")) (if_statement "if (iVar3 < 0x38) {\n    iVar3 = 0x38 - iVar3;\n  }\n  else {\n    iVar3 = 0x78 - iVar3;\n  }" (if "if") (parenthesized_expression "(iVar3 < 0x38)" (( "(") (binary_expression "iVar3 < 0x38" (identifier "iVar3") (< "<") (number_literal "0x38")) () ")")) (compound_statement "{\n    iVar3 = 0x38 - iVar3;\n  }" ({ "{") (expression_statement "iVar3 = 0x38 - iVar3;" (assignment_expression "iVar3 = 0x38 - iVar3" (identifier "iVar3") (= "=") (binary_expression "0x38 - iVar3" (number_literal "0x38") (- "-") (identifier "iVar3"))) (; ";")) (} "}")) (else_clause "else {\n    iVar3 = 0x78 - iVar3;\n  }" (else "else") (compound_statement "{\n    iVar3 = 0x78 - iVar3;\n  }" ({ "{") (expression_statement "iVar3 = 0x78 - iVar3;" (assignment_expression "iVar3 = 0x78 - iVar3" (identifier "iVar3") (= "=") (binary_expression "0x78 - iVar3" (number_literal "0x78") (- "-") (identifier "iVar3"))) (; ";")) (} "}")))) (expression_statement "uVar4 = *(uint *)(md + 0x5c);" (assignment_expression "uVar4 = *(uint *)(md + 0x5c)" (identifier "uVar4") (= "=") (pointer_expression "*(uint *)(md + 0x5c)" (* "*") (cast_expression "(uint *)(md + 0x5c)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(md + 0x5c)" (( "(") (binary_expression "md + 0x5c" (identifier "md") (+ "+") (number_literal "0x5c")) () ")"))))) (; ";")) (expression_statement "iVar2 = *(int *)(md + 0x58);" (assignment_expression "iVar2 = *(int *)(md + 0x58)" (identifier "iVar2") (= "=") (pointer_expression "*(int *)(md + 0x58)" (* "*") (cast_expression "(int *)(md + 0x58)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(md + 0x58)" (( "(") (binary_expression "md + 0x58" (identifier "md") (+ "+") (number_literal "0x58")) () ")"))))) (; ";")) (expression_statement "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);" (call_expression "(*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40)" (parenthesized_expression "(*(code *)PTR___memset_chk_001121d8)" (( "(") (pointer_expression "*(code *)PTR___memset_chk_001121d8" (* "*") (cast_expression "(code *)PTR___memset_chk_001121d8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___memset_chk_001121d8"))) () ")")) (argument_list "(&local_6c,0,iVar3,0x40)" (( "(") (pointer_expression "&local_6c" (& "&") (identifier "local_6c")) (, ",") (number_literal "0") (, ",") (identifier "iVar3") (, ",") (number_literal "0x40") () ")"))) (; ";")) (expression_statement "local_6c = CONCAT13(0x80,local_6c._1_3_);" (assignment_expression "local_6c = CONCAT13(0x80,local_6c._1_3_)" (identifier "local_6c") (= "=") (call_expression "CONCAT13(0x80,local_6c._1_3_)" (identifier "CONCAT13") (argument_list "(0x80,local_6c._1_3_)" (( "(") (number_literal "0x80") (, ",") (field_expression "local_6c._1_3_" (identifier "local_6c") (. ".") (field_identifier "_1_3_")) () ")")))) (; ";")) (expression_statement "SHA_Bytes(md,&local_6c,iVar3);" (call_expression "SHA_Bytes(md,&local_6c,iVar3)" (identifier "SHA_Bytes") (argument_list "(md,&local_6c,iVar3)" (( "(") (identifier "md") (, ",") (pointer_expression "&local_6c" (& "&") (identifier "local_6c")) (, ",") (identifier "iVar3") () ")"))) (; ";")) (expression_statement "local_6c = iVar2 << 3 | uVar4 >> 0x1d;" (assignment_expression "local_6c = iVar2 << 3 | uVar4 >> 0x1d" (identifier "local_6c") (= "=") (binary_expression "iVar2 << 3 | uVar4 >> 0x1d" (binary_expression "iVar2 << 3" (identifier "iVar2") (<< "<<") (number_literal "3")) (| "|") (binary_expression "uVar4 >> 0x1d" (identifier "uVar4") (>> ">>") (number_literal "0x1d")))) (; ";")) (expression_statement "local_68 = uVar4 << 3;" (assignment_expression "local_68 = uVar4 << 3" (identifier "local_68") (= "=") (binary_expression "uVar4 << 3" (identifier "uVar4") (<< "<<") (number_literal "3"))) (; ";")) (expression_statement "SHA_Bytes(md,&local_6c,8);" (call_expression "SHA_Bytes(md,&local_6c,8)" (identifier "SHA_Bytes") (argument_list "(md,&local_6c,8)" (( "(") (identifier "md") (, ",") (pointer_expression "&local_6c" (& "&") (identifier "local_6c")) (, ",") (number_literal "8") () ")"))) (; ";")) (expression_statement "pSVar1 = c;" (assignment_expression "pSVar1 = c" (identifier "pSVar1") (= "=") (identifier "c")) (; ";")) (do_statement "do {\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  } while (c_00 != (SHA_CTX *)&c->Nl);" (do "do") (compound_statement "{\n    c_00 = (SHA_CTX *)&pSVar1->h1;\n    md_00 = md + 4;\n    *(uchar *)&pSVar1->h0 = *md;\n    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;\n    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);\n    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;\n    md = md_00;\n    pSVar1 = c_00;\n  }" ({ "{") (expression_statement "c_00 = (SHA_CTX *)&pSVar1->h1;" (assignment_expression "c_00 = (SHA_CTX *)&pSVar1->h1" (identifier "c_00") (= "=") (cast_expression "(SHA_CTX *)&pSVar1->h1" (( "(") (type_descriptor "SHA_CTX *" (type_identifier "SHA_CTX") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "&pSVar1->h1" (& "&") (field_expression "pSVar1->h1" (identifier "pSVar1") (-> "->") (field_identifier "h1"))))) (; ";")) (expression_statement "md_00 = md + 4;" (assignment_expression "md_00 = md + 4" (identifier "md_00") (= "=") (binary_expression "md + 4" (identifier "md") (+ "+") (number_literal "4"))) (; ";")) (expression_statement "*(uchar *)&pSVar1->h0 = *md;" (assignment_expression "*(uchar *)&pSVar1->h0 = *md" (pointer_expression "*(uchar *)&pSVar1->h0" (* "*") (cast_expression "(uchar *)&pSVar1->h0" (( "(") (type_descriptor "uchar *" (type_identifier "uchar") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "&pSVar1->h0" (& "&") (field_expression "pSVar1->h0" (identifier "pSVar1") (-> "->") (field_identifier "h0"))))) (= "=") (pointer_expression "*md" (* "*") (identifier "md"))) (; ";")) (expression_statement "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 1)" (* "*") (cast_expression "(char *)((int)&pSVar1->h0 + 1)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)&pSVar1->h0 + 1)" (( "(") (binary_expression "(int)&pSVar1->h0 + 1" (cast_expression "(int)&pSVar1->h0" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "&pSVar1->h0" (& "&") (field_expression "pSVar1->h0" (identifier "pSVar1") (-> "->") (field_identifier "h0")))) (+ "+") (number_literal "1")) () ")")))) (= "=") (cast_expression "(char)*(undefined2 *)md" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (pointer_expression "*(undefined2 *)md" (* "*") (cast_expression "(undefined2 *)md" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "md"))))) (; ";")) (expression_statement "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);" (assignment_expression "*(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8)" (pointer_expression "*(char *)((int)&pSVar1->h0 + 2)" (* "*") (cast_expression "(char *)((int)&pSVar1->h0 + 2)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)&pSVar1->h0 + 2)" (( "(") (binary_expression "(int)&pSVar1->h0 + 2" (cast_expression "(int)&pSVar1->h0" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "&pSVar1->h0" (& "&") (field_expression "pSVar1->h0" (identifier "pSVar1") (-> "->") (field_identifier "h0")))) (+ "+") (number_literal "2")) () ")")))) (= "=") (cast_expression "(char)((uint)*(undefined4 *)md >> 8)" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (parenthesized_expression "((uint)*(undefined4 *)md >> 8)" (( "(") (binary_expression "(uint)*(undefined4 *)md >> 8" (binary_expression "(uint)*(undefined4 *)md" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (* "*") (cast_expression "(undefined4 *)md" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "md"))) (>> ">>") (number_literal "8")) () ")")))) (; ";")) (expression_statement "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;" (assignment_expression "*(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md" (pointer_expression "*(char *)((int)&pSVar1->h0 + 3)" (* "*") (cast_expression "(char *)((int)&pSVar1->h0 + 3)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)&pSVar1->h0 + 3)" (( "(") (binary_expression "(int)&pSVar1->h0 + 3" (cast_expression "(int)&pSVar1->h0" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "&pSVar1->h0" (& "&") (field_expression "pSVar1->h0" (identifier "pSVar1") (-> "->") (field_identifier "h0")))) (+ "+") (number_literal "3")) () ")")))) (= "=") (cast_expression "(char)*(undefined4 *)md" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (pointer_expression "*(undefined4 *)md" (* "*") (cast_expression "(undefined4 *)md" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "md"))))) (; ";")) (expression_statement "md = md_00;" (assignment_expression "md = md_00" (identifier "md") (= "=") (identifier "md_00")) (; ";")) (expression_statement "pSVar1 = c_00;" (assignment_expression "pSVar1 = c_00" (identifier "pSVar1") (= "=") (identifier "c_00")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(c_00 != (SHA_CTX *)&c->Nl)" (( "(") (binary_expression "c_00 != (SHA_CTX *)&c->Nl" (identifier "c_00") (!= "!=") (cast_expression "(SHA_CTX *)&c->Nl" (( "(") (type_descriptor "SHA_CTX *" (type_identifier "SHA_CTX") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "&c->Nl" (& "&") (field_expression "c->Nl" (identifier "c") (-> "->") (field_identifier "Nl"))))) () ")")) (; ";")) (if_statement "if (local_2c == *(int *)puVar5) {\n    return *(int *)puVar5;\n  }" (if "if") (parenthesized_expression "(local_2c == *(int *)puVar5)" (( "(") (binary_expression "local_2c == *(int *)puVar5" (identifier "local_2c") (== "==") (pointer_expression "*(int *)puVar5" (* "*") (cast_expression "(int *)puVar5" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar5")))) () ")")) (compound_statement "{\n    return *(int *)puVar5;\n  }" ({ "{") (return_statement "return *(int *)puVar5;" (return "return") (pointer_expression "*(int *)puVar5" (* "*") (cast_expression "(int *)puVar5" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar5"))) (; ";")) (} "}"))) (expression_statement "puVar5 = PTR___stack_chk_fail_001122c8;" (assignment_expression "puVar5 = PTR___stack_chk_fail_001122c8" (identifier "puVar5") (= "=") (identifier "PTR___stack_chk_fail_001122c8")) (; ";")) (expression_statement "(*(code *)PTR___stack_chk_fail_001122c8)();" (call_expression "(*(code *)PTR___stack_chk_fail_001122c8)()" (parenthesized_expression "(*(code *)PTR___stack_chk_fail_001122c8)" (( "(") (pointer_expression "*(code *)PTR___stack_chk_fail_001122c8" (* "*") (cast_expression "(code *)PTR___stack_chk_fail_001122c8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___stack_chk_fail_001122c8"))) () ")")) (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "SHA_Final(md_00,c_00);" (call_expression "SHA_Final(md_00,c_00)" (identifier "SHA_Final") (argument_list "(md_00,c_00)" (( "(") (identifier "md_00") (, ",") (identifier "c_00") () ")"))) (; ";")) (expression_statement "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60);" (call_expression "(**(code **)(puVar5 + 0x8a73c))(md_00,0x60)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a73c))" (( "(") (pointer_expression "**(code **)(puVar5 + 0x8a73c)" (* "*") (pointer_expression "*(code **)(puVar5 + 0x8a73c)" (* "*") (cast_expression "(code **)(puVar5 + 0x8a73c)" (( "(") (type_descriptor "code **" (type_identifier "code") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(puVar5 + 0x8a73c)" (( "(") (binary_expression "puVar5 + 0x8a73c" (identifier "puVar5") (+ "+") (number_literal "0x8a73c")) () ")"))))) () ")")) (argument_list "(md_00,0x60)" (( "(") (identifier "md_00") (, ",") (number_literal "0x60") () ")"))) (; ";")) (expression_statement "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);" (assignment_expression "iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00)" (identifier "iVar3") (= "=") (call_expression "(**(code **)(puVar5 + 0x8a694))(md_00)" (parenthesized_expression "(**(code **)(puVar5 + 0x8a694))" (( "(") (pointer_expression "**(code **)(puVar5 + 0x8a694)" (* "*") (pointer_expression "*(code **)(puVar5 + 0x8a694)" (* "*") (cast_expression "(code **)(puVar5 + 0x8a694)" (( "(") (type_descriptor "code **" (type_identifier "code") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(puVar5 + 0x8a694)" (( "(") (binary_expression "puVar5 + 0x8a694" (identifier "puVar5") (+ "+") (number_literal "0x8a694")) () ")"))))) () ")")) (argument_list "(md_00)" (( "(") (identifier "md_00") () ")")))) (; ";")) (return_statement "return iVar3;" (return "return") (identifier "iVar3") (; ";")) (} "}")))

int function_1(type_1 *s,type_2 *var_7)

{
  int var_8;
  type_1 *s_00;
  type_2 *var_5;
  type_2 *var_6;
  type_3 var_3;
  int var_1;
  type_4 var_4;
  type_5 *var_9;
  type_2 c [64];
  
  var_9 = PTR___stack_chk_guard_00112630;
  var_1 = s->blkused;
  var_8 = *(int *)PTR___stack_chk_guard_00112630;
  if (var_1 < 0x38) {
    var_1 = 0x38 - var_1;
  }
  else {
    var_1 = 0x78 - var_1;
  }
  var_4 = s->lenlo;
  var_3 = s->lenhi;
  (*(type_6 *)PTR___memset_chk_001121d8)(c,0,var_1,0x40);
  c[0] = 0x80;
  var_2(s,c,var_1);
  c._0_4_ = var_3 << 3 | var_4 >> 0x1d;
  c._4_4_ = var_4 << 3;
  var_2(s,c,8);
  var_5 = var_7;
  do {
    var_6 = var_5 + 4;
    s_00 = (type_1 *)(s->h + 1);
    *var_5 = *(type_2 *)s->h;
    var_5[1] = (type_2)*(type_7 *)s->h;
    var_5[2] = (type_2)(s->h[0] >> 8);
    var_5[3] = (type_2)s->h[0];
    s = s_00;
    var_5 = var_6;
  } while (var_6 != var_7 + 0x14);
  if (var_8 == *(int *)var_9) {
    return *(int *)var_9;
  }
  var_9 = PTR___stack_chk_fail_001122c8;
  (*(type_6 *)PTR___stack_chk_fail_001122c8)();
  function_1(s_00,var_6);
  (**(type_6 **)(var_9 + 0x8a73c))(s_00,0x60);
                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */
                    /* WARNING: Treating indirect jump as call */
  var_8 = (**(type_6 **)(var_9 + 0x8a694))(s_00);
  return var_8;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (number_literal) right: (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (number_literal) right: (identifier))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (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 (pointer_expression argument: (identifier)) (number_literal) (identifier) (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (number_literal) (field_expression argument: (identifier) field: (field_identifier)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (do_statement body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier))))) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier)))) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier)))) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (binary_expression left: (parenthesized_expression (identifier)) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier))) right: (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier)))) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (field_expression argument: (identifier) field: (field_identifier))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier))))) consequence: (compound_statement (return_statement (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (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 (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) arguments: (argument_list (identifier) (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) arguments: (argument_list (identifier))))) (return_statement (identifier)))))

int MASKED(uchar *md,SHA_CTX *c)

{
  uchar *md_00;
  SHA_CTX *pSVar1;
  SHA_CTX *c_00;
  int iVar2;
  int iVar3;
  uint uVar4;
  undefined *puVar5;
  uint local_6c;
  int local_68;
  int local_2c;
  
  puVar5 = PTR___stack_chk_guard_00112630;
  iVar3 = *(int *)(md + 0x54);
  local_2c = *(int *)PTR___stack_chk_guard_00112630;
  if (iVar3 < 0x38) {
    iVar3 = 0x38 - iVar3;
  }
  else {
    iVar3 = 0x78 - iVar3;
  }
  uVar4 = *(uint *)(md + 0x5c);
  iVar2 = *(int *)(md + 0x58);
  (*(code *)PTR___memset_chk_001121d8)(&local_6c,0,iVar3,0x40);
  local_6c = CONCAT13(0x80,local_6c._1_3_);
  SHA_Bytes(md,&local_6c,iVar3);
  local_6c = iVar2 << 3 | uVar4 >> 0x1d;
  local_68 = uVar4 << 3;
  SHA_Bytes(md,&local_6c,8);
  pSVar1 = c;
  do {
    c_00 = (SHA_CTX *)&pSVar1->h1;
    md_00 = md + 4;
    *(uchar *)&pSVar1->h0 = *md;
    *(char *)((int)&pSVar1->h0 + 1) = (char)*(undefined2 *)md;
    *(char *)((int)&pSVar1->h0 + 2) = (char)((uint)*(undefined4 *)md >> 8);
    *(char *)((int)&pSVar1->h0 + 3) = (char)*(undefined4 *)md;
    md = md_00;
    pSVar1 = c_00;
  } while (c_00 != (SHA_CTX *)&c->Nl);
  if (local_2c == *(int *)puVar5) {
    return *(int *)puVar5;
  }
  puVar5 = PTR___stack_chk_fail_001122c8;
  (*(code *)PTR___stack_chk_fail_001122c8)();
  MASKED(md_00,c_00);
  (**(code **)(puVar5 + 0x8a73c))(md_00,0x60);
                    /* WARNING: Could not recover jumptable at 0x00086cac. Too many branches */
                    /* WARNING: Treating indirect jump as call */
  iVar3 = (**(code **)(puVar5 + 0x8a694))(md_00);
  return iVar3;
}

