
Bignum_conflict bignum_random_in_range(Bignum_conflict lower,Bignum_conflict upper)

{
  undefined *puVar1;
  undefined *puVar2;
  undefined1 *puVar3;
  int iVar4;
  Bignum_conflict a;
  uint uVar5;
  int iVar6;
  uint uVar7;
  int iVar8;
  undefined1 *puVar9;
  undefined1 *puVar10;
  
  puVar1 = PTR_bignum_from_bytes_000b2874;
  uVar5 = *upper * 0x20;
  uVar7 = uVar5 - 1;
  if ((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])) {
    do {
      uVar5 = uVar7;
      uVar7 = uVar5 - 1;
      if (uVar7 == 0xffffffff) break;
    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);
  }
  uVar7 = uVar5;
  if ((int)uVar5 < 0) {
    uVar7 = uVar5 + 7;
  }
  uVar5 = uVar5 & 0x80000007;
  iVar8 = (int)uVar7 >> 3;
  if ((int)uVar5 < 0) {
    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;
  }
  if (uVar5 != 0) {
    iVar8 = iVar8 + 1;
  }
  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1);
  puVar2 = PTR_freebn_000b29b0;
  iVar6 = iVar8;
  if (iVar8 < 0) {
    iVar6 = 0;
  }
  while( true ) {
    puVar9 = puVar3;
    if (0 < iVar8) {
      do {
        puVar10 = puVar9 + 1;
        iVar4 = random_byte();
        *puVar9 = (char)iVar4;
        puVar9 = puVar10;
      } while (puVar3 + iVar8 != puVar10);
    }
    if (uVar5 != 0) {
      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];
    }
    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);
    iVar4 = bignum_cmp(a,lower);
    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;
    if (a != (Bignum_conflict)0x0) {
      (*(code *)puVar2)(a);
    }
  }
  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar8);
  (*(code *)PTR_safefree_000b23d0)(puVar3);
  return a;
}



int bignum_random_in_range(undefined4 param_1,int *param_2)

{
  undefined *puVar1;
  undefined *puVar2;
  undefined1 *puVar3;
  undefined1 uVar6;
  int iVar4;
  int iVar5;
  uint uVar7;
  int iVar8;
  uint uVar9;
  int iVar10;
  undefined1 *puVar11;
  undefined1 *puVar12;
  
  puVar1 = PTR_bignum_from_bytes_000b2874;
  uVar7 = *param_2 * 0x20;
  uVar9 = uVar7 - 1;
  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {
    do {
      uVar7 = uVar9;
      uVar9 = uVar7 - 1;
      if (uVar9 == 0xffffffff) break;
    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);
  }
  uVar9 = uVar7;
  if ((int)uVar7 < 0) {
    uVar9 = uVar7 + 7;
  }
  uVar7 = uVar7 & 0x80000007;
  iVar10 = (int)uVar9 >> 3;
  if ((int)uVar7 < 0) {
    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;
  }
  if (uVar7 != 0) {
    iVar10 = iVar10 + 1;
  }
  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);
  puVar2 = PTR_freebn_000b29b0;
  iVar8 = iVar10;
  if (iVar10 < 0) {
    iVar8 = 0;
  }
  while( true ) {
    puVar11 = puVar3;
    if (0 < iVar10) {
      do {
        puVar12 = puVar11 + 1;
        uVar6 = random_byte();
        *puVar11 = uVar6;
        puVar11 = puVar12;
      } while (puVar3 + iVar10 != puVar12);
    }
    if (uVar7 != 0) {
      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];
    }
    iVar4 = (*(code *)puVar1)(puVar3,iVar10);
    iVar5 = bignum_cmp(iVar4,param_1);
    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;
    if (iVar4 != 0) {
      (*(code *)puVar2)(iVar4);
    }
  }
  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);
  (*(code *)PTR_safefree_000b23d0)(puVar3);
  return iVar4;
}


lui gp,0x6
addiu gp,gp,0x1f9c
addu gp,gp,t9
lw v1,0x0(a1)
addiu sp,sp,-0x50
sll v1,v1,0x5
sw s1,0x2c(sp)
sw gp,0x10(sp)
addiu s1,v1,-0x1
sw s8,0x48(sp)
sw s6,0x40(sp)
or s8,a0,zero
sw ra,0x4c(sp)
or s6,a1,zero
sw s7,0x44(sp)
sw s5,0x3c(sp)
sw s4,0x38(sp)
sw s3,0x34(sp)
sw s2,0x30(sp)
bltz s1,0x000585fc
_sw s0,0x28(sp)
sra v0,s1,0x5
addiu v0,v0,0x1
sll v0,v0,0x2
addu v0,a1,v0
lw v0,0x0(v0)
bgez v0,0x0005846c
_li a0,-0x1
b 0x00058478
_or s1,v1,zero
addiu v0,v0,0x1
sll v0,v0,0x2
addu v0,s6,v0
lw v0,0x0(v0)
srlv v0,v0,v1
bne v0,zero,0x00058478
_nop
or s1,v1,zero
addiu v1,s1,-0x1
bne v1,a0,0x0005844c
_sra v0,v1,0x5
bgez s1,0x00058484
_or s2,s1,zero
addiu s2,s1,0x7
lui v0,0x8000
addiu v0,v0,0x7
and s1,s1,v0
bgez s1,0x000584a8
_sra s2,s2,0x3
addiu s1,s1,-0x1
li v0,-0x8
or s1,s1,v0
addiu s1,s1,0x1
beq s1,zero,0x000584b4
_lw v0,-0x7afc(gp)
addiu s2,s2,0x1
li a1,0x1
lw t9,-0x7f68(gp)
or a0,s2,zero
lw s4,-0x78d4(gp)
jalr t9
_sw v0,0x1c(sp)
slti v1,s2,0x0
or a0,s2,zero
lw gp,0x10(sp)
movn a0,zero,v1
or s3,v0,zero
li v0,0xff
addu s0,s3,s2
lw a1,-0x79c0(gp)
or v1,a0,zero
li a0,0x8
addiu v1,v1,-0x1
sw a1,0x20(sp)
subu a0,a0,s1
addu s5,s3,v1
srav v0,v0,a0
seb v0,v0
sw v0,0x24(sp)
blez s2,0x00058534
_nop
or s7,s3,zero
lw t9,-0x7a9c(gp)
bal 0x0006fc40
_addiu s7,s7,0x1
lw gp,0x10(sp)
bne s0,s7,0x0005851c
_sb v0,-0x1(s7)
beq s1,zero,0x00058550
_lw t9,0x1c(sp)
lbu v0,0x0(s5)
lw v1,0x24(sp)
and v0,v1,v0
sb v0,0x0(s5)
lw t9,0x1c(sp)
or a1,s2,zero
jalr t9
_or a0,s3,zero
or a1,s8,zero
or a0,v0,zero
or t9,s4,zero
bal 0x00058268
_or s7,v0,zero
bltz v0,0x00058590
_lw gp,0x10(sp)
or a1,s6,zero
or t9,s4,zero
bal 0x00058268
_or a0,s7,zero
blez v0,0x000585a8
_lw gp,0x10(sp)
beq s7,zero,0x00058510
_lw t9,0x20(sp)
jalr t9
_or a0,s7,zero
b 0x00058510
_lw gp,0x10(sp)
lw t9,-0x7f10(gp)
or a1,s2,zero
jalr t9
_or a0,s3,zero
lw gp,0x10(sp)
lw t9,-0x7fa0(gp)
jalr t9
_or a0,s3,zero
or v0,s7,zero
lw ra,0x4c(sp)
lw s8,0x48(sp)
lw s7,0x44(sp)
lw s6,0x40(sp)
lw s5,0x3c(sp)
lw s4,0x38(sp)
lw s3,0x34(sp)
lw s2,0x30(sp)
lw s1,0x2c(sp)
lw s0,0x28(sp)
jr ra
_addiu sp,sp,0x50
b 0x00058478
_or s1,v1,zero
(translation_unit "int bignum_random_in_range(undefined4 param_1,int *param_2)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}\n\n" (function_definition "int bignum_random_in_range(undefined4 param_1,int *param_2)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" primitive_type (function_declarator "bignum_random_in_range(undefined4 param_1,int *param_2)" identifier (parameter_list "(undefined4 param_1,int *param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "undefined *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined1 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined1 uVar6;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "uint uVar7;" type_identifier identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "uint uVar9;" type_identifier identifier ;) (declaration "int iVar10;" primitive_type identifier ;) (declaration "undefined1 *puVar11;" type_identifier (pointer_declarator "*puVar11" * identifier) ;) (declaration "undefined1 *puVar12;" type_identifier (pointer_declarator "*puVar12" * identifier) ;) (expression_statement "puVar1 = PTR_bignum_from_bytes_000b2874;" (assignment_expression "puVar1 = PTR_bignum_from_bytes_000b2874" identifier = identifier) ;) (expression_statement "uVar7 = *param_2 * 0x20;" (assignment_expression "uVar7 = *param_2 * 0x20" identifier = (binary_expression "*param_2 * 0x20" (pointer_expression "*param_2" * identifier) * number_literal)) ;) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" identifier = (binary_expression "uVar7 - 1" identifier - number_literal)) ;) (if_statement "if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" if (parenthesized_expression "((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1]))" ( (binary_expression "(-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])" (parenthesized_expression "(-1 < (int)uVar9)" ( (binary_expression "-1 < (int)uVar9" number_literal < (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier)) )) && (parenthesized_expression "(-1 < param_2[((int)uVar9 >> 5) + 1])" ( (binary_expression "-1 < param_2[((int)uVar9 >> 5) + 1]" number_literal < (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" identifier [ (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" ( (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ])) ))) )) (compound_statement "{\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" { (do_statement "do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);" do (compound_statement "{\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    }" { (expression_statement "uVar7 = uVar9;" (assignment_expression "uVar7 = uVar9" identifier = identifier) ;) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" identifier = (binary_expression "uVar7 - 1" identifier - number_literal)) ;) (if_statement "if (uVar9 == 0xffffffff) break;" if (parenthesized_expression "(uVar9 == 0xffffffff)" ( (binary_expression "uVar9 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0)" ( (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0" (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f)" (cast_expression "(uint)param_2[((int)uVar9 >> 5) + 1]" ( (type_descriptor "uint" type_identifier) ) (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" identifier [ (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" ( (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ])) >> (parenthesized_expression "(uVar9 & 0x1f)" ( (binary_expression "uVar9 & 0x1f" identifier & number_literal) ))) == number_literal) )) ;) })) (expression_statement "uVar9 = uVar7;" (assignment_expression "uVar9 = uVar7" identifier = identifier) ;) (if_statement "if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }" if (parenthesized_expression "((int)uVar7 < 0)" ( (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar9 = uVar7 + 7;\n  }" { (expression_statement "uVar9 = uVar7 + 7;" (assignment_expression "uVar9 = uVar7 + 7" identifier = (binary_expression "uVar7 + 7" identifier + number_literal)) ;) })) (expression_statement "uVar7 = uVar7 & 0x80000007;" (assignment_expression "uVar7 = uVar7 & 0x80000007" identifier = (binary_expression "uVar7 & 0x80000007" identifier & number_literal)) ;) (expression_statement "iVar10 = (int)uVar9 >> 3;" (assignment_expression "iVar10 = (int)uVar9 >> 3" identifier = (binary_expression "(int)uVar9 >> 3" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal)) ;) (if_statement "if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" if (parenthesized_expression "((int)uVar7 < 0)" ( (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" { (expression_statement "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;" (assignment_expression "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1" identifier = (binary_expression "(uVar7 - 1 | 0xfffffff8) + 1" (parenthesized_expression "(uVar7 - 1 | 0xfffffff8)" ( (binary_expression "uVar7 - 1 | 0xfffffff8" (binary_expression "uVar7 - 1" identifier - number_literal) | number_literal) )) + number_literal)) ;) })) (if_statement "if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }" if (parenthesized_expression "(uVar7 != 0)" ( (binary_expression "uVar7 != 0" identifier != number_literal) )) (compound_statement "{\n    iVar10 = iVar10 + 1;\n  }" { (expression_statement "iVar10 = iVar10 + 1;" (assignment_expression "iVar10 = iVar10 + 1" identifier = (binary_expression "iVar10 + 1" identifier + number_literal)) ;) })) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" identifier = (cast_expression "(undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" (parenthesized_expression "(*(code *)PTR_safemalloc_000b2408)" ( (pointer_expression "*(code *)PTR_safemalloc_000b2408" * (cast_expression "(code *)PTR_safemalloc_000b2408" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar10,1)" ( identifier , number_literal ))))) ;) (expression_statement "puVar2 = PTR_freebn_000b29b0;" (assignment_expression "puVar2 = PTR_freebn_000b29b0" identifier = identifier) ;) (expression_statement "iVar8 = iVar10;" (assignment_expression "iVar8 = iVar10" identifier = identifier) ;) (if_statement "if (iVar10 < 0) {\n    iVar8 = 0;\n  }" if (parenthesized_expression "(iVar10 < 0)" ( (binary_expression "iVar10 < 0" identifier < number_literal) )) (compound_statement "{\n    iVar8 = 0;\n  }" { (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" identifier = number_literal) ;) })) (while_statement "while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" { (expression_statement "puVar11 = puVar3;" (assignment_expression "puVar11 = puVar3" identifier = identifier) ;) (if_statement "if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" if (parenthesized_expression "(0 < iVar10)" ( (binary_expression "0 < iVar10" number_literal < identifier) )) (compound_statement "{\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" { (do_statement "do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);" do (compound_statement "{\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      }" { (expression_statement "puVar12 = puVar11 + 1;" (assignment_expression "puVar12 = puVar11 + 1" identifier = (binary_expression "puVar11 + 1" identifier + number_literal)) ;) (expression_statement "uVar6 = random_byte();" (assignment_expression "uVar6 = random_byte()" identifier = (call_expression "random_byte()" identifier (argument_list "()" ( )))) ;) (expression_statement "*puVar11 = uVar6;" (assignment_expression "*puVar11 = uVar6" (pointer_expression "*puVar11" * identifier) = identifier) ;) (expression_statement "puVar11 = puVar12;" (assignment_expression "puVar11 = puVar12" identifier = identifier) ;) }) while (parenthesized_expression "(puVar3 + iVar10 != puVar12)" ( (binary_expression "puVar3 + iVar10 != puVar12" (binary_expression "puVar3 + iVar10" identifier + identifier) != identifier) )) ;) })) (if_statement "if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" if (parenthesized_expression "(uVar7 != 0)" ( (binary_expression "uVar7 != 0" identifier != number_literal) )) (compound_statement "{\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" { (expression_statement "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];" (assignment_expression "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (subscript_expression "puVar3[iVar8 + -1]" identifier [ (binary_expression "iVar8 + -1" identifier + number_literal) ]) = (binary_expression "(byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (call_expression "(byte)(0xff >> (8 - uVar7 & 0x1f))" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(0xff >> (8 - uVar7 & 0x1f))" ( (binary_expression "0xff >> (8 - uVar7 & 0x1f)" number_literal >> (parenthesized_expression "(8 - uVar7 & 0x1f)" ( (binary_expression "8 - uVar7 & 0x1f" (binary_expression "8 - uVar7" number_literal - identifier) & number_literal) ))) ))) & (subscript_expression "puVar3[iVar8 + -1]" identifier [ (binary_expression "iVar8 + -1" identifier + number_literal) ]))) ;) })) (expression_statement "iVar4 = (*(code *)puVar1)(puVar3,iVar10);" (assignment_expression "iVar4 = (*(code *)puVar1)(puVar3,iVar10)" identifier = (call_expression "(*(code *)puVar1)(puVar3,iVar10)" (parenthesized_expression "(*(code *)puVar1)" ( (pointer_expression "*(code *)puVar1" * (cast_expression "(code *)puVar1" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3,iVar10)" ( identifier , identifier )))) ;) (expression_statement "iVar5 = bignum_cmp(iVar4,param_1);" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_1)" identifier = (call_expression "bignum_cmp(iVar4,param_1)" identifier (argument_list "(iVar4,param_1)" ( identifier , identifier )))) ;) (if_statement "if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;" if (parenthesized_expression "((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1))" ( (binary_expression "(-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" (parenthesized_expression "(-1 < iVar5)" ( (binary_expression "-1 < iVar5" number_literal < identifier) )) && (parenthesized_expression "(iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" ( (comma_expression "iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_2)" identifier = (call_expression "bignum_cmp(iVar4,param_2)" identifier (argument_list "(iVar4,param_2)" ( identifier , identifier )))) , (binary_expression "iVar5 < 1" identifier < number_literal)) ))) )) (break_statement "break;" break ;)) (if_statement "if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n      (*(code *)puVar2)(iVar4);\n    }" { (expression_statement "(*(code *)puVar2)(iVar4);" (call_expression "(*(code *)puVar2)(iVar4)" (parenthesized_expression "(*(code *)puVar2)" ( (pointer_expression "*(code *)puVar2" * (cast_expression "(code *)puVar2" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar4)" ( identifier ))) ;) })) })) (expression_statement "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);" (call_expression "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10)" (parenthesized_expression "(*(code *)PTR_smemclr_000b2460)" ( (pointer_expression "*(code *)PTR_smemclr_000b2460" * (cast_expression "(code *)PTR_smemclr_000b2460" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3,iVar10)" ( identifier , identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000b23d0)(puVar3);" (call_expression "(*(code *)PTR_safefree_000b23d0)(puVar3)" (parenthesized_expression "(*(code *)PTR_safefree_000b23d0)" ( (pointer_expression "*(code *)PTR_safefree_000b23d0" * (cast_expression "(code *)PTR_safefree_000b23d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3)" ( identifier ))) ;) (return_statement "return iVar4;" return identifier ;) })))
(translation_unit "Bignum_conflict bignum_random_in_range(Bignum_conflict lower,Bignum_conflict upper)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  int iVar4;\n  Bignum_conflict a;\n  uint uVar5;\n  int iVar6;\n  uint uVar7;\n  int iVar8;\n  undefined1 *puVar9;\n  undefined1 *puVar10;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar5 = *upper * 0x20;\n  uVar7 = uVar5 - 1;\n  if ((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])) {\n    do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);\n  }\n  uVar7 = uVar5;\n  if ((int)uVar5 < 0) {\n    uVar7 = uVar5 + 7;\n  }\n  uVar5 = uVar5 & 0x80000007;\n  iVar8 = (int)uVar7 >> 3;\n  if ((int)uVar5 < 0) {\n    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar5 != 0) {\n    iVar8 = iVar8 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar6 = iVar8;\n  if (iVar8 < 0) {\n    iVar6 = 0;\n  }\n  while( true ) {\n    puVar9 = puVar3;\n    if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }\n    if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }\n    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);\n    iVar4 = bignum_cmp(a,lower);\n    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;\n    if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar8);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return a;\n}\n\n" (function_definition "Bignum_conflict bignum_random_in_range(Bignum_conflict lower,Bignum_conflict upper)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  int iVar4;\n  Bignum_conflict a;\n  uint uVar5;\n  int iVar6;\n  uint uVar7;\n  int iVar8;\n  undefined1 *puVar9;\n  undefined1 *puVar10;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar5 = *upper * 0x20;\n  uVar7 = uVar5 - 1;\n  if ((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])) {\n    do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);\n  }\n  uVar7 = uVar5;\n  if ((int)uVar5 < 0) {\n    uVar7 = uVar5 + 7;\n  }\n  uVar5 = uVar5 & 0x80000007;\n  iVar8 = (int)uVar7 >> 3;\n  if ((int)uVar5 < 0) {\n    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar5 != 0) {\n    iVar8 = iVar8 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar6 = iVar8;\n  if (iVar8 < 0) {\n    iVar6 = 0;\n  }\n  while( true ) {\n    puVar9 = puVar3;\n    if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }\n    if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }\n    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);\n    iVar4 = bignum_cmp(a,lower);\n    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;\n    if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar8);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return a;\n}" type_identifier (function_declarator "bignum_random_in_range(Bignum_conflict lower,Bignum_conflict upper)" identifier (parameter_list "(Bignum_conflict lower,Bignum_conflict upper)" ( (parameter_declaration "Bignum_conflict lower" type_identifier identifier) , (parameter_declaration "Bignum_conflict upper" type_identifier identifier) ))) (compound_statement "{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  int iVar4;\n  Bignum_conflict a;\n  uint uVar5;\n  int iVar6;\n  uint uVar7;\n  int iVar8;\n  undefined1 *puVar9;\n  undefined1 *puVar10;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar5 = *upper * 0x20;\n  uVar7 = uVar5 - 1;\n  if ((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])) {\n    do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);\n  }\n  uVar7 = uVar5;\n  if ((int)uVar5 < 0) {\n    uVar7 = uVar5 + 7;\n  }\n  uVar5 = uVar5 & 0x80000007;\n  iVar8 = (int)uVar7 >> 3;\n  if ((int)uVar5 < 0) {\n    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar5 != 0) {\n    iVar8 = iVar8 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar6 = iVar8;\n  if (iVar8 < 0) {\n    iVar6 = 0;\n  }\n  while( true ) {\n    puVar9 = puVar3;\n    if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }\n    if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }\n    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);\n    iVar4 = bignum_cmp(a,lower);\n    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;\n    if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar8);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return a;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "undefined *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined1 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "Bignum_conflict a;" type_identifier identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "uint uVar7;" type_identifier identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "undefined1 *puVar9;" type_identifier (pointer_declarator "*puVar9" * identifier) ;) (declaration "undefined1 *puVar10;" type_identifier (pointer_declarator "*puVar10" * identifier) ;) (expression_statement "puVar1 = PTR_bignum_from_bytes_000b2874;" (assignment_expression "puVar1 = PTR_bignum_from_bytes_000b2874" identifier = identifier) ;) (expression_statement "uVar5 = *upper * 0x20;" (assignment_expression "uVar5 = *upper * 0x20" identifier = (binary_expression "*upper * 0x20" (pointer_expression "*upper" * identifier) * number_literal)) ;) (expression_statement "uVar7 = uVar5 - 1;" (assignment_expression "uVar7 = uVar5 - 1" identifier = (binary_expression "uVar5 - 1" identifier - number_literal)) ;) (if_statement "if ((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])) {\n    do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);\n  }" if (parenthesized_expression "((-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1]))" ( (binary_expression "(-1 < (int)uVar7) && (-1 < (int)upper[((int)uVar7 >> 5) + 1])" (parenthesized_expression "(-1 < (int)uVar7)" ( (binary_expression "-1 < (int)uVar7" number_literal < (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier)) )) && (parenthesized_expression "(-1 < (int)upper[((int)uVar7 >> 5) + 1])" ( (binary_expression "-1 < (int)upper[((int)uVar7 >> 5) + 1]" number_literal < (cast_expression "(int)upper[((int)uVar7 >> 5) + 1]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "upper[((int)uVar7 >> 5) + 1]" identifier [ (binary_expression "((int)uVar7 >> 5) + 1" (parenthesized_expression "((int)uVar7 >> 5)" ( (binary_expression "(int)uVar7 >> 5" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ]))) ))) )) (compound_statement "{\n    do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);\n  }" { (do_statement "do {\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    } while (upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0);" do (compound_statement "{\n      uVar5 = uVar7;\n      uVar7 = uVar5 - 1;\n      if (uVar7 == 0xffffffff) break;\n    }" { (expression_statement "uVar5 = uVar7;" (assignment_expression "uVar5 = uVar7" identifier = identifier) ;) (expression_statement "uVar7 = uVar5 - 1;" (assignment_expression "uVar7 = uVar5 - 1" identifier = (binary_expression "uVar5 - 1" identifier - number_literal)) ;) (if_statement "if (uVar7 == 0xffffffff) break;" if (parenthesized_expression "(uVar7 == 0xffffffff)" ( (binary_expression "uVar7 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "(upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0)" ( (binary_expression "upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f) == 0" (binary_expression "upper[((int)uVar7 >> 5) + 1] >> (uVar7 & 0x1f)" (subscript_expression "upper[((int)uVar7 >> 5) + 1]" identifier [ (binary_expression "((int)uVar7 >> 5) + 1" (parenthesized_expression "((int)uVar7 >> 5)" ( (binary_expression "(int)uVar7 >> 5" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ]) >> (parenthesized_expression "(uVar7 & 0x1f)" ( (binary_expression "uVar7 & 0x1f" identifier & number_literal) ))) == number_literal) )) ;) })) (expression_statement "uVar7 = uVar5;" (assignment_expression "uVar7 = uVar5" identifier = identifier) ;) (if_statement "if ((int)uVar5 < 0) {\n    uVar7 = uVar5 + 7;\n  }" if (parenthesized_expression "((int)uVar5 < 0)" ( (binary_expression "(int)uVar5 < 0" (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar7 = uVar5 + 7;\n  }" { (expression_statement "uVar7 = uVar5 + 7;" (assignment_expression "uVar7 = uVar5 + 7" identifier = (binary_expression "uVar5 + 7" identifier + number_literal)) ;) })) (expression_statement "uVar5 = uVar5 & 0x80000007;" (assignment_expression "uVar5 = uVar5 & 0x80000007" identifier = (binary_expression "uVar5 & 0x80000007" identifier & number_literal)) ;) (expression_statement "iVar8 = (int)uVar7 >> 3;" (assignment_expression "iVar8 = (int)uVar7 >> 3" identifier = (binary_expression "(int)uVar7 >> 3" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal)) ;) (if_statement "if ((int)uVar5 < 0) {\n    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;\n  }" if (parenthesized_expression "((int)uVar5 < 0)" ( (binary_expression "(int)uVar5 < 0" (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;\n  }" { (expression_statement "uVar5 = (uVar5 - 1 | 0xfffffff8) + 1;" (assignment_expression "uVar5 = (uVar5 - 1 | 0xfffffff8) + 1" identifier = (binary_expression "(uVar5 - 1 | 0xfffffff8) + 1" (parenthesized_expression "(uVar5 - 1 | 0xfffffff8)" ( (binary_expression "uVar5 - 1 | 0xfffffff8" (binary_expression "uVar5 - 1" identifier - number_literal) | number_literal) )) + number_literal)) ;) })) (if_statement "if (uVar5 != 0) {\n    iVar8 = iVar8 + 1;\n  }" if (parenthesized_expression "(uVar5 != 0)" ( (binary_expression "uVar5 != 0" identifier != number_literal) )) (compound_statement "{\n    iVar8 = iVar8 + 1;\n  }" { (expression_statement "iVar8 = iVar8 + 1;" (assignment_expression "iVar8 = iVar8 + 1" identifier = (binary_expression "iVar8 + 1" identifier + number_literal)) ;) })) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1)" identifier = (cast_expression "(undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar8,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_safemalloc_000b2408)(iVar8,1)" (parenthesized_expression "(*(code *)PTR_safemalloc_000b2408)" ( (pointer_expression "*(code *)PTR_safemalloc_000b2408" * (cast_expression "(code *)PTR_safemalloc_000b2408" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar8,1)" ( identifier , number_literal ))))) ;) (expression_statement "puVar2 = PTR_freebn_000b29b0;" (assignment_expression "puVar2 = PTR_freebn_000b29b0" identifier = identifier) ;) (expression_statement "iVar6 = iVar8;" (assignment_expression "iVar6 = iVar8" identifier = identifier) ;) (if_statement "if (iVar8 < 0) {\n    iVar6 = 0;\n  }" if (parenthesized_expression "(iVar8 < 0)" ( (binary_expression "iVar8 < 0" identifier < number_literal) )) (compound_statement "{\n    iVar6 = 0;\n  }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) })) (while_statement "while( true ) {\n    puVar9 = puVar3;\n    if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }\n    if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }\n    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);\n    iVar4 = bignum_cmp(a,lower);\n    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;\n    if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    puVar9 = puVar3;\n    if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }\n    if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }\n    a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);\n    iVar4 = bignum_cmp(a,lower);\n    if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;\n    if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }\n  }" { (expression_statement "puVar9 = puVar3;" (assignment_expression "puVar9 = puVar3" identifier = identifier) ;) (if_statement "if (0 < iVar8) {\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }" if (parenthesized_expression "(0 < iVar8)" ( (binary_expression "0 < iVar8" number_literal < identifier) )) (compound_statement "{\n      do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);\n    }" { (do_statement "do {\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      } while (puVar3 + iVar8 != puVar10);" do (compound_statement "{\n        puVar10 = puVar9 + 1;\n        iVar4 = random_byte();\n        *puVar9 = (char)iVar4;\n        puVar9 = puVar10;\n      }" { (expression_statement "puVar10 = puVar9 + 1;" (assignment_expression "puVar10 = puVar9 + 1" identifier = (binary_expression "puVar9 + 1" identifier + number_literal)) ;) (expression_statement "iVar4 = random_byte();" (assignment_expression "iVar4 = random_byte()" identifier = (call_expression "random_byte()" identifier (argument_list "()" ( )))) ;) (expression_statement "*puVar9 = (char)iVar4;" (assignment_expression "*puVar9 = (char)iVar4" (pointer_expression "*puVar9" * identifier) = (cast_expression "(char)iVar4" ( (type_descriptor "char" primitive_type) ) identifier)) ;) (expression_statement "puVar9 = puVar10;" (assignment_expression "puVar9 = puVar10" identifier = identifier) ;) }) while (parenthesized_expression "(puVar3 + iVar8 != puVar10)" ( (binary_expression "puVar3 + iVar8 != puVar10" (binary_expression "puVar3 + iVar8" identifier + identifier) != identifier) )) ;) })) (if_statement "if (uVar5 != 0) {\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }" if (parenthesized_expression "(uVar5 != 0)" ( (binary_expression "uVar5 != 0" identifier != number_literal) )) (compound_statement "{\n      puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];\n    }" { (expression_statement "puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1];" (assignment_expression "puVar3[iVar6 + -1] = (byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1]" (subscript_expression "puVar3[iVar6 + -1]" identifier [ (binary_expression "iVar6 + -1" identifier + number_literal) ]) = (binary_expression "(byte)(0xff >> (8 - uVar5 & 0x1f)) & puVar3[iVar6 + -1]" (call_expression "(byte)(0xff >> (8 - uVar5 & 0x1f))" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(0xff >> (8 - uVar5 & 0x1f))" ( (binary_expression "0xff >> (8 - uVar5 & 0x1f)" number_literal >> (parenthesized_expression "(8 - uVar5 & 0x1f)" ( (binary_expression "8 - uVar5 & 0x1f" (binary_expression "8 - uVar5" number_literal - identifier) & number_literal) ))) ))) & (subscript_expression "puVar3[iVar6 + -1]" identifier [ (binary_expression "iVar6 + -1" identifier + number_literal) ]))) ;) })) (expression_statement "a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8);" (assignment_expression "a = (Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8)" identifier = (call_expression "(Bignum_conflict)(*(code *)puVar1)(puVar3,iVar8)" (call_expression "(Bignum_conflict)(*(code *)puVar1)" (parenthesized_expression "(Bignum_conflict)" ( identifier )) (argument_list "(*(code *)puVar1)" ( (pointer_expression "*(code *)puVar1" * (cast_expression "(code *)puVar1" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ))) (argument_list "(puVar3,iVar8)" ( identifier , identifier )))) ;) (expression_statement "iVar4 = bignum_cmp(a,lower);" (assignment_expression "iVar4 = bignum_cmp(a,lower)" identifier = (call_expression "bignum_cmp(a,lower)" identifier (argument_list "(a,lower)" ( identifier , identifier )))) ;) (if_statement "if ((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)) break;" if (parenthesized_expression "((-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1))" ( (binary_expression "(-1 < iVar4) && (iVar4 = bignum_cmp(a,upper), iVar4 < 1)" (parenthesized_expression "(-1 < iVar4)" ( (binary_expression "-1 < iVar4" number_literal < identifier) )) && (parenthesized_expression "(iVar4 = bignum_cmp(a,upper), iVar4 < 1)" ( (comma_expression "iVar4 = bignum_cmp(a,upper), iVar4 < 1" (assignment_expression "iVar4 = bignum_cmp(a,upper)" identifier = (call_expression "bignum_cmp(a,upper)" identifier (argument_list "(a,upper)" ( identifier , identifier )))) , (binary_expression "iVar4 < 1" identifier < number_literal)) ))) )) (break_statement "break;" break ;)) (if_statement "if (a != (Bignum_conflict)0x0) {\n      (*(code *)puVar2)(a);\n    }" if (parenthesized_expression "(a != (Bignum_conflict)0x0)" ( (binary_expression "a != (Bignum_conflict)0x0" identifier != (cast_expression "(Bignum_conflict)0x0" ( (type_descriptor "Bignum_conflict" type_identifier) ) number_literal)) )) (compound_statement "{\n      (*(code *)puVar2)(a);\n    }" { (expression_statement "(*(code *)puVar2)(a);" (call_expression "(*(code *)puVar2)(a)" (parenthesized_expression "(*(code *)puVar2)" ( (pointer_expression "*(code *)puVar2" * (cast_expression "(code *)puVar2" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(a)" ( identifier ))) ;) })) })) (expression_statement "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar8);" (call_expression "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar8)" (parenthesized_expression "(*(code *)PTR_smemclr_000b2460)" ( (pointer_expression "*(code *)PTR_smemclr_000b2460" * (cast_expression "(code *)PTR_smemclr_000b2460" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3,iVar8)" ( identifier , identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000b23d0)(puVar3);" (call_expression "(*(code *)PTR_safefree_000b23d0)(puVar3)" (parenthesized_expression "(*(code *)PTR_safefree_000b23d0)" ( (pointer_expression "*(code *)PTR_safefree_000b23d0" * (cast_expression "(code *)PTR_safefree_000b23d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3)" ( identifier ))) ;) (return_statement "return a;" return identifier ;) })))
(translation_unit "int bignum_random_in_range(undefined4 param_1,int *param_2)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}\n\n" (function_definition "int bignum_random_in_range(undefined4 param_1,int *param_2)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" primitive_type (function_declarator "bignum_random_in_range(undefined4 param_1,int *param_2)" identifier (parameter_list "(undefined4 param_1,int *param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "undefined *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined1 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined1 uVar6;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "uint uVar7;" type_identifier identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "uint uVar9;" type_identifier identifier ;) (declaration "int iVar10;" primitive_type identifier ;) (declaration "undefined1 *puVar11;" type_identifier (pointer_declarator "*puVar11" * identifier) ;) (declaration "undefined1 *puVar12;" type_identifier (pointer_declarator "*puVar12" * identifier) ;) (expression_statement "puVar1 = PTR_bignum_from_bytes_000b2874;" (assignment_expression "puVar1 = PTR_bignum_from_bytes_000b2874" identifier = identifier) ;) (expression_statement "uVar7 = *param_2 * 0x20;" (assignment_expression "uVar7 = *param_2 * 0x20" identifier = (binary_expression "*param_2 * 0x20" (pointer_expression "*param_2" * identifier) * number_literal)) ;) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" identifier = (binary_expression "uVar7 - 1" identifier - number_literal)) ;) (if_statement "if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" if (parenthesized_expression "((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1]))" ( (binary_expression "(-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])" (parenthesized_expression "(-1 < (int)uVar9)" ( (binary_expression "-1 < (int)uVar9" number_literal < (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier)) )) && (parenthesized_expression "(-1 < param_2[((int)uVar9 >> 5) + 1])" ( (binary_expression "-1 < param_2[((int)uVar9 >> 5) + 1]" number_literal < (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" identifier [ (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" ( (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ])) ))) )) (compound_statement "{\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" { (do_statement "do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);" do (compound_statement "{\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    }" { (expression_statement "uVar7 = uVar9;" (assignment_expression "uVar7 = uVar9" identifier = identifier) ;) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" identifier = (binary_expression "uVar7 - 1" identifier - number_literal)) ;) (if_statement "if (uVar9 == 0xffffffff) break;" if (parenthesized_expression "(uVar9 == 0xffffffff)" ( (binary_expression "uVar9 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0)" ( (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0" (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f)" (cast_expression "(uint)param_2[((int)uVar9 >> 5) + 1]" ( (type_descriptor "uint" type_identifier) ) (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" identifier [ (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" ( (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) + number_literal) ])) >> (parenthesized_expression "(uVar9 & 0x1f)" ( (binary_expression "uVar9 & 0x1f" identifier & number_literal) ))) == number_literal) )) ;) })) (expression_statement "uVar9 = uVar7;" (assignment_expression "uVar9 = uVar7" identifier = identifier) ;) (if_statement "if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }" if (parenthesized_expression "((int)uVar7 < 0)" ( (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar9 = uVar7 + 7;\n  }" { (expression_statement "uVar9 = uVar7 + 7;" (assignment_expression "uVar9 = uVar7 + 7" identifier = (binary_expression "uVar7 + 7" identifier + number_literal)) ;) })) (expression_statement "uVar7 = uVar7 & 0x80000007;" (assignment_expression "uVar7 = uVar7 & 0x80000007" identifier = (binary_expression "uVar7 & 0x80000007" identifier & number_literal)) ;) (expression_statement "iVar10 = (int)uVar9 >> 3;" (assignment_expression "iVar10 = (int)uVar9 >> 3" identifier = (binary_expression "(int)uVar9 >> 3" (cast_expression "(int)uVar9" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal)) ;) (if_statement "if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" if (parenthesized_expression "((int)uVar7 < 0)" ( (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" { (expression_statement "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;" (assignment_expression "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1" identifier = (binary_expression "(uVar7 - 1 | 0xfffffff8) + 1" (parenthesized_expression "(uVar7 - 1 | 0xfffffff8)" ( (binary_expression "uVar7 - 1 | 0xfffffff8" (binary_expression "uVar7 - 1" identifier - number_literal) | number_literal) )) + number_literal)) ;) })) (if_statement "if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }" if (parenthesized_expression "(uVar7 != 0)" ( (binary_expression "uVar7 != 0" identifier != number_literal) )) (compound_statement "{\n    iVar10 = iVar10 + 1;\n  }" { (expression_statement "iVar10 = iVar10 + 1;" (assignment_expression "iVar10 = iVar10 + 1" identifier = (binary_expression "iVar10 + 1" identifier + number_literal)) ;) })) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" identifier = (cast_expression "(undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" (parenthesized_expression "(*(code *)PTR_safemalloc_000b2408)" ( (pointer_expression "*(code *)PTR_safemalloc_000b2408" * (cast_expression "(code *)PTR_safemalloc_000b2408" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar10,1)" ( identifier , number_literal ))))) ;) (expression_statement "puVar2 = PTR_freebn_000b29b0;" (assignment_expression "puVar2 = PTR_freebn_000b29b0" identifier = identifier) ;) (expression_statement "iVar8 = iVar10;" (assignment_expression "iVar8 = iVar10" identifier = identifier) ;) (if_statement "if (iVar10 < 0) {\n    iVar8 = 0;\n  }" if (parenthesized_expression "(iVar10 < 0)" ( (binary_expression "iVar10 < 0" identifier < number_literal) )) (compound_statement "{\n    iVar8 = 0;\n  }" { (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" identifier = number_literal) ;) })) (while_statement "while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" { (expression_statement "puVar11 = puVar3;" (assignment_expression "puVar11 = puVar3" identifier = identifier) ;) (if_statement "if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" if (parenthesized_expression "(0 < iVar10)" ( (binary_expression "0 < iVar10" number_literal < identifier) )) (compound_statement "{\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" { (do_statement "do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);" do (compound_statement "{\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      }" { (expression_statement "puVar12 = puVar11 + 1;" (assignment_expression "puVar12 = puVar11 + 1" identifier = (binary_expression "puVar11 + 1" identifier + number_literal)) ;) (expression_statement "uVar6 = random_byte();" (assignment_expression "uVar6 = random_byte()" identifier = (call_expression "random_byte()" identifier (argument_list "()" ( )))) ;) (expression_statement "*puVar11 = uVar6;" (assignment_expression "*puVar11 = uVar6" (pointer_expression "*puVar11" * identifier) = identifier) ;) (expression_statement "puVar11 = puVar12;" (assignment_expression "puVar11 = puVar12" identifier = identifier) ;) }) while (parenthesized_expression "(puVar3 + iVar10 != puVar12)" ( (binary_expression "puVar3 + iVar10 != puVar12" (binary_expression "puVar3 + iVar10" identifier + identifier) != identifier) )) ;) })) (if_statement "if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" if (parenthesized_expression "(uVar7 != 0)" ( (binary_expression "uVar7 != 0" identifier != number_literal) )) (compound_statement "{\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" { (expression_statement "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];" (assignment_expression "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (subscript_expression "puVar3[iVar8 + -1]" identifier [ (binary_expression "iVar8 + -1" identifier + number_literal) ]) = (binary_expression "(byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (call_expression "(byte)(0xff >> (8 - uVar7 & 0x1f))" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(0xff >> (8 - uVar7 & 0x1f))" ( (binary_expression "0xff >> (8 - uVar7 & 0x1f)" number_literal >> (parenthesized_expression "(8 - uVar7 & 0x1f)" ( (binary_expression "8 - uVar7 & 0x1f" (binary_expression "8 - uVar7" number_literal - identifier) & number_literal) ))) ))) & (subscript_expression "puVar3[iVar8 + -1]" identifier [ (binary_expression "iVar8 + -1" identifier + number_literal) ]))) ;) })) (expression_statement "iVar4 = (*(code *)puVar1)(puVar3,iVar10);" (assignment_expression "iVar4 = (*(code *)puVar1)(puVar3,iVar10)" identifier = (call_expression "(*(code *)puVar1)(puVar3,iVar10)" (parenthesized_expression "(*(code *)puVar1)" ( (pointer_expression "*(code *)puVar1" * (cast_expression "(code *)puVar1" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3,iVar10)" ( identifier , identifier )))) ;) (expression_statement "iVar5 = bignum_cmp(iVar4,param_1);" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_1)" identifier = (call_expression "bignum_cmp(iVar4,param_1)" identifier (argument_list "(iVar4,param_1)" ( identifier , identifier )))) ;) (if_statement "if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;" if (parenthesized_expression "((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1))" ( (binary_expression "(-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" (parenthesized_expression "(-1 < iVar5)" ( (binary_expression "-1 < iVar5" number_literal < identifier) )) && (parenthesized_expression "(iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" ( (comma_expression "iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_2)" identifier = (call_expression "bignum_cmp(iVar4,param_2)" identifier (argument_list "(iVar4,param_2)" ( identifier , identifier )))) , (binary_expression "iVar5 < 1" identifier < number_literal)) ))) )) (break_statement "break;" break ;)) (if_statement "if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n      (*(code *)puVar2)(iVar4);\n    }" { (expression_statement "(*(code *)puVar2)(iVar4);" (call_expression "(*(code *)puVar2)(iVar4)" (parenthesized_expression "(*(code *)puVar2)" ( (pointer_expression "*(code *)puVar2" * (cast_expression "(code *)puVar2" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar4)" ( identifier ))) ;) })) })) (expression_statement "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);" (call_expression "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10)" (parenthesized_expression "(*(code *)PTR_smemclr_000b2460)" ( (pointer_expression "*(code *)PTR_smemclr_000b2460" * (cast_expression "(code *)PTR_smemclr_000b2460" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3,iVar10)" ( identifier , identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000b23d0)(puVar3);" (call_expression "(*(code *)PTR_safefree_000b23d0)(puVar3)" (parenthesized_expression "(*(code *)PTR_safefree_000b23d0)" ( (pointer_expression "*(code *)PTR_safefree_000b23d0" * (cast_expression "(code *)PTR_safefree_000b23d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(puVar3)" ( identifier ))) ;) (return_statement "return iVar4;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE 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 IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * IDENT) * LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT - LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression LIT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) && (parenthesized_expression ( (binary_expression LIT < (subscript_expression IDENT [ (binary_expression (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT) )) + LIT) ])) ))) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT - LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) }) while (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ (binary_expression (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT) )) + LIT) ])) >> (parenthesized_expression ( (binary_expression IDENT & LIT) ))) == LIT) )) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT & LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (parenthesized_expression ( (binary_expression (binary_expression IDENT - LIT) | LIT) )) + LIT)) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , LIT ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) })) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression (binary_expression IDENT + IDENT) != IDENT) )) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ (binary_expression IDENT + LIT) ]) = (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression LIT >> (parenthesized_expression ( (binary_expression (binary_expression LIT - IDENT) & LIT) ))) ))) & (subscript_expression IDENT [ (binary_expression IDENT + LIT) ]))) ;) })) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression LIT < IDENT) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) , (binary_expression IDENT < LIT)) ))) )) (break_statement break ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) })) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (return_statement return IDENT ;) })))
(function_definition "int bignum_random_in_range(undefined4 param_1,int *param_2)\n\n{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" (primitive_type "int") (function_declarator "bignum_random_in_range(undefined4 param_1,int *param_2)" (identifier "bignum_random_in_range") (parameter_list "(undefined4 param_1,int *param_2)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")"))) (compound_statement "{\n  undefined *puVar1;\n  undefined *puVar2;\n  undefined1 *puVar3;\n  undefined1 uVar6;\n  int iVar4;\n  int iVar5;\n  uint uVar7;\n  int iVar8;\n  uint uVar9;\n  int iVar10;\n  undefined1 *puVar11;\n  undefined1 *puVar12;\n  \n  puVar1 = PTR_bignum_from_bytes_000b2874;\n  uVar7 = *param_2 * 0x20;\n  uVar9 = uVar7 - 1;\n  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }\n  uVar9 = uVar7;\n  if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }\n  uVar7 = uVar7 & 0x80000007;\n  iVar10 = (int)uVar9 >> 3;\n  if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }\n  if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }\n  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);\n  puVar2 = PTR_freebn_000b29b0;\n  iVar8 = iVar10;\n  if (iVar10 < 0) {\n    iVar8 = 0;\n  }\n  while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }\n  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);\n  (*(code *)PTR_safefree_000b23d0)(puVar3);\n  return iVar4;\n}" ({ "{") (declaration "undefined *puVar1;" (type_identifier "undefined") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "undefined *puVar2;" (type_identifier "undefined") (pointer_declarator "*puVar2" (* "*") (identifier "puVar2")) (; ";")) (declaration "undefined1 *puVar3;" (type_identifier "undefined1") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "undefined1 uVar6;" (type_identifier "undefined1") (identifier "uVar6") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "uint uVar7;" (type_identifier "uint") (identifier "uVar7") (; ";")) (declaration "int iVar8;" (primitive_type "int") (identifier "iVar8") (; ";")) (declaration "uint uVar9;" (type_identifier "uint") (identifier "uVar9") (; ";")) (declaration "int iVar10;" (primitive_type "int") (identifier "iVar10") (; ";")) (declaration "undefined1 *puVar11;" (type_identifier "undefined1") (pointer_declarator "*puVar11" (* "*") (identifier "puVar11")) (; ";")) (declaration "undefined1 *puVar12;" (type_identifier "undefined1") (pointer_declarator "*puVar12" (* "*") (identifier "puVar12")) (; ";")) (expression_statement "puVar1 = PTR_bignum_from_bytes_000b2874;" (assignment_expression "puVar1 = PTR_bignum_from_bytes_000b2874" (identifier "puVar1") (= "=") (identifier "PTR_bignum_from_bytes_000b2874")) (; ";")) (expression_statement "uVar7 = *param_2 * 0x20;" (assignment_expression "uVar7 = *param_2 * 0x20" (identifier "uVar7") (= "=") (binary_expression "*param_2 * 0x20" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (* "*") (number_literal "0x20"))) (; ";")) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" (identifier "uVar9") (= "=") (binary_expression "uVar7 - 1" (identifier "uVar7") (- "-") (number_literal "1"))) (; ";")) (if_statement "if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" (if "if") (parenthesized_expression "((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1]))" (( "(") (binary_expression "(-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])" (parenthesized_expression "(-1 < (int)uVar9)" (( "(") (binary_expression "-1 < (int)uVar9" (number_literal "-1") (< "<") (cast_expression "(int)uVar9" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar9"))) () ")")) (&& "&&") (parenthesized_expression "(-1 < param_2[((int)uVar9 >> 5) + 1])" (( "(") (binary_expression "-1 < param_2[((int)uVar9 >> 5) + 1]" (number_literal "-1") (< "<") (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" (identifier "param_2") ([ "[") (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" (( "(") (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar9")) (>> ">>") (number_literal "5")) () ")")) (+ "+") (number_literal "1")) (] "]"))) () ")"))) () ")")) (compound_statement "{\n    do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);\n  }" ({ "{") (do_statement "do {\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);" (do "do") (compound_statement "{\n      uVar7 = uVar9;\n      uVar9 = uVar7 - 1;\n      if (uVar9 == 0xffffffff) break;\n    }" ({ "{") (expression_statement "uVar7 = uVar9;" (assignment_expression "uVar7 = uVar9" (identifier "uVar7") (= "=") (identifier "uVar9")) (; ";")) (expression_statement "uVar9 = uVar7 - 1;" (assignment_expression "uVar9 = uVar7 - 1" (identifier "uVar9") (= "=") (binary_expression "uVar7 - 1" (identifier "uVar7") (- "-") (number_literal "1"))) (; ";")) (if_statement "if (uVar9 == 0xffffffff) break;" (if "if") (parenthesized_expression "(uVar9 == 0xffffffff)" (( "(") (binary_expression "uVar9 == 0xffffffff" (identifier "uVar9") (== "==") (number_literal "0xffffffff")) () ")")) (break_statement "break;" (break "break") (; ";"))) (} "}")) (while "while") (parenthesized_expression "((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0)" (( "(") (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0" (binary_expression "(uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f)" (cast_expression "(uint)param_2[((int)uVar9 >> 5) + 1]" (( "(") (type_descriptor "uint" (type_identifier "uint")) () ")") (subscript_expression "param_2[((int)uVar9 >> 5) + 1]" (identifier "param_2") ([ "[") (binary_expression "((int)uVar9 >> 5) + 1" (parenthesized_expression "((int)uVar9 >> 5)" (( "(") (binary_expression "(int)uVar9 >> 5" (cast_expression "(int)uVar9" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar9")) (>> ">>") (number_literal "5")) () ")")) (+ "+") (number_literal "1")) (] "]"))) (>> ">>") (parenthesized_expression "(uVar9 & 0x1f)" (( "(") (binary_expression "uVar9 & 0x1f" (identifier "uVar9") (& "&") (number_literal "0x1f")) () ")"))) (== "==") (number_literal "0")) () ")")) (; ";")) (} "}"))) (expression_statement "uVar9 = uVar7;" (assignment_expression "uVar9 = uVar7" (identifier "uVar9") (= "=") (identifier "uVar7")) (; ";")) (if_statement "if ((int)uVar7 < 0) {\n    uVar9 = uVar7 + 7;\n  }" (if "if") (parenthesized_expression "((int)uVar7 < 0)" (( "(") (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar7")) (< "<") (number_literal "0")) () ")")) (compound_statement "{\n    uVar9 = uVar7 + 7;\n  }" ({ "{") (expression_statement "uVar9 = uVar7 + 7;" (assignment_expression "uVar9 = uVar7 + 7" (identifier "uVar9") (= "=") (binary_expression "uVar7 + 7" (identifier "uVar7") (+ "+") (number_literal "7"))) (; ";")) (} "}"))) (expression_statement "uVar7 = uVar7 & 0x80000007;" (assignment_expression "uVar7 = uVar7 & 0x80000007" (identifier "uVar7") (= "=") (binary_expression "uVar7 & 0x80000007" (identifier "uVar7") (& "&") (number_literal "0x80000007"))) (; ";")) (expression_statement "iVar10 = (int)uVar9 >> 3;" (assignment_expression "iVar10 = (int)uVar9 >> 3" (identifier "iVar10") (= "=") (binary_expression "(int)uVar9 >> 3" (cast_expression "(int)uVar9" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar9")) (>> ">>") (number_literal "3"))) (; ";")) (if_statement "if ((int)uVar7 < 0) {\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" (if "if") (parenthesized_expression "((int)uVar7 < 0)" (( "(") (binary_expression "(int)uVar7 < 0" (cast_expression "(int)uVar7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar7")) (< "<") (number_literal "0")) () ")")) (compound_statement "{\n    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;\n  }" ({ "{") (expression_statement "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;" (assignment_expression "uVar7 = (uVar7 - 1 | 0xfffffff8) + 1" (identifier "uVar7") (= "=") (binary_expression "(uVar7 - 1 | 0xfffffff8) + 1" (parenthesized_expression "(uVar7 - 1 | 0xfffffff8)" (( "(") (binary_expression "uVar7 - 1 | 0xfffffff8" (binary_expression "uVar7 - 1" (identifier "uVar7") (- "-") (number_literal "1")) (| "|") (number_literal "0xfffffff8")) () ")")) (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (if_statement "if (uVar7 != 0) {\n    iVar10 = iVar10 + 1;\n  }" (if "if") (parenthesized_expression "(uVar7 != 0)" (( "(") (binary_expression "uVar7 != 0" (identifier "uVar7") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    iVar10 = iVar10 + 1;\n  }" ({ "{") (expression_statement "iVar10 = iVar10 + 1;" (assignment_expression "iVar10 = iVar10 + 1" (identifier "iVar10") (= "=") (binary_expression "iVar10 + 1" (identifier "iVar10") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" (identifier "puVar3") (= "=") (cast_expression "(undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "(*(code *)PTR_safemalloc_000b2408)(iVar10,1)" (parenthesized_expression "(*(code *)PTR_safemalloc_000b2408)" (( "(") (pointer_expression "*(code *)PTR_safemalloc_000b2408" (* "*") (cast_expression "(code *)PTR_safemalloc_000b2408" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safemalloc_000b2408"))) () ")")) (argument_list "(iVar10,1)" (( "(") (identifier "iVar10") (, ",") (number_literal "1") () ")"))))) (; ";")) (expression_statement "puVar2 = PTR_freebn_000b29b0;" (assignment_expression "puVar2 = PTR_freebn_000b29b0" (identifier "puVar2") (= "=") (identifier "PTR_freebn_000b29b0")) (; ";")) (expression_statement "iVar8 = iVar10;" (assignment_expression "iVar8 = iVar10" (identifier "iVar8") (= "=") (identifier "iVar10")) (; ";")) (if_statement "if (iVar10 < 0) {\n    iVar8 = 0;\n  }" (if "if") (parenthesized_expression "(iVar10 < 0)" (( "(") (binary_expression "iVar10 < 0" (identifier "iVar10") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n    iVar8 = 0;\n  }" ({ "{") (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" (identifier "iVar8") (= "=") (number_literal "0")) (; ";")) (} "}"))) (while_statement "while( true ) {\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n    puVar11 = puVar3;\n    if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }\n    if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }\n    iVar4 = (*(code *)puVar1)(puVar3,iVar10);\n    iVar5 = bignum_cmp(iVar4,param_1);\n    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;\n    if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }\n  }" ({ "{") (expression_statement "puVar11 = puVar3;" (assignment_expression "puVar11 = puVar3" (identifier "puVar11") (= "=") (identifier "puVar3")) (; ";")) (if_statement "if (0 < iVar10) {\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" (if "if") (parenthesized_expression "(0 < iVar10)" (( "(") (binary_expression "0 < iVar10" (number_literal "0") (< "<") (identifier "iVar10")) () ")")) (compound_statement "{\n      do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);\n    }" ({ "{") (do_statement "do {\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      } while (puVar3 + iVar10 != puVar12);" (do "do") (compound_statement "{\n        puVar12 = puVar11 + 1;\n        uVar6 = random_byte();\n        *puVar11 = uVar6;\n        puVar11 = puVar12;\n      }" ({ "{") (expression_statement "puVar12 = puVar11 + 1;" (assignment_expression "puVar12 = puVar11 + 1" (identifier "puVar12") (= "=") (binary_expression "puVar11 + 1" (identifier "puVar11") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar6 = random_byte();" (assignment_expression "uVar6 = random_byte()" (identifier "uVar6") (= "=") (call_expression "random_byte()" (identifier "random_byte") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "*puVar11 = uVar6;" (assignment_expression "*puVar11 = uVar6" (pointer_expression "*puVar11" (* "*") (identifier "puVar11")) (= "=") (identifier "uVar6")) (; ";")) (expression_statement "puVar11 = puVar12;" (assignment_expression "puVar11 = puVar12" (identifier "puVar11") (= "=") (identifier "puVar12")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(puVar3 + iVar10 != puVar12)" (( "(") (binary_expression "puVar3 + iVar10 != puVar12" (binary_expression "puVar3 + iVar10" (identifier "puVar3") (+ "+") (identifier "iVar10")) (!= "!=") (identifier "puVar12")) () ")")) (; ";")) (} "}"))) (if_statement "if (uVar7 != 0) {\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" (if "if") (parenthesized_expression "(uVar7 != 0)" (( "(") (binary_expression "uVar7 != 0" (identifier "uVar7") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];\n    }" ({ "{") (expression_statement "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];" (assignment_expression "puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (subscript_expression "puVar3[iVar8 + -1]" (identifier "puVar3") ([ "[") (binary_expression "iVar8 + -1" (identifier "iVar8") (+ "+") (number_literal "-1")) (] "]")) (= "=") (binary_expression "(byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1]" (call_expression "(byte)(0xff >> (8 - uVar7 & 0x1f))" (parenthesized_expression "(byte)" (( "(") (identifier "byte") () ")")) (argument_list "(0xff >> (8 - uVar7 & 0x1f))" (( "(") (binary_expression "0xff >> (8 - uVar7 & 0x1f)" (number_literal "0xff") (>> ">>") (parenthesized_expression "(8 - uVar7 & 0x1f)" (( "(") (binary_expression "8 - uVar7 & 0x1f" (binary_expression "8 - uVar7" (number_literal "8") (- "-") (identifier "uVar7")) (& "&") (number_literal "0x1f")) () ")"))) () ")"))) (& "&") (subscript_expression "puVar3[iVar8 + -1]" (identifier "puVar3") ([ "[") (binary_expression "iVar8 + -1" (identifier "iVar8") (+ "+") (number_literal "-1")) (] "]")))) (; ";")) (} "}"))) (expression_statement "iVar4 = (*(code *)puVar1)(puVar3,iVar10);" (assignment_expression "iVar4 = (*(code *)puVar1)(puVar3,iVar10)" (identifier "iVar4") (= "=") (call_expression "(*(code *)puVar1)(puVar3,iVar10)" (parenthesized_expression "(*(code *)puVar1)" (( "(") (pointer_expression "*(code *)puVar1" (* "*") (cast_expression "(code *)puVar1" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar1"))) () ")")) (argument_list "(puVar3,iVar10)" (( "(") (identifier "puVar3") (, ",") (identifier "iVar10") () ")")))) (; ";")) (expression_statement "iVar5 = bignum_cmp(iVar4,param_1);" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_1)" (identifier "iVar5") (= "=") (call_expression "bignum_cmp(iVar4,param_1)" (identifier "bignum_cmp") (argument_list "(iVar4,param_1)" (( "(") (identifier "iVar4") (, ",") (identifier "param_1") () ")")))) (; ";")) (if_statement "if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;" (if "if") (parenthesized_expression "((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1))" (( "(") (binary_expression "(-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" (parenthesized_expression "(-1 < iVar5)" (( "(") (binary_expression "-1 < iVar5" (number_literal "-1") (< "<") (identifier "iVar5")) () ")")) (&& "&&") (parenthesized_expression "(iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)" (( "(") (comma_expression "iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1" (assignment_expression "iVar5 = bignum_cmp(iVar4,param_2)" (identifier "iVar5") (= "=") (call_expression "bignum_cmp(iVar4,param_2)" (identifier "bignum_cmp") (argument_list "(iVar4,param_2)" (( "(") (identifier "iVar4") (, ",") (identifier "param_2") () ")")))) (, ",") (binary_expression "iVar5 < 1" (identifier "iVar5") (< "<") (number_literal "1"))) () ")"))) () ")")) (break_statement "break;" (break "break") (; ";"))) (if_statement "if (iVar4 != 0) {\n      (*(code *)puVar2)(iVar4);\n    }" (if "if") (parenthesized_expression "(iVar4 != 0)" (( "(") (binary_expression "iVar4 != 0" (identifier "iVar4") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      (*(code *)puVar2)(iVar4);\n    }" ({ "{") (expression_statement "(*(code *)puVar2)(iVar4);" (call_expression "(*(code *)puVar2)(iVar4)" (parenthesized_expression "(*(code *)puVar2)" (( "(") (pointer_expression "*(code *)puVar2" (* "*") (cast_expression "(code *)puVar2" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar2"))) () ")")) (argument_list "(iVar4)" (( "(") (identifier "iVar4") () ")"))) (; ";")) (} "}"))) (} "}"))) (expression_statement "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);" (call_expression "(*(code *)PTR_smemclr_000b2460)(puVar3,iVar10)" (parenthesized_expression "(*(code *)PTR_smemclr_000b2460)" (( "(") (pointer_expression "*(code *)PTR_smemclr_000b2460" (* "*") (cast_expression "(code *)PTR_smemclr_000b2460" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_smemclr_000b2460"))) () ")")) (argument_list "(puVar3,iVar10)" (( "(") (identifier "puVar3") (, ",") (identifier "iVar10") () ")"))) (; ";")) (expression_statement "(*(code *)PTR_safefree_000b23d0)(puVar3);" (call_expression "(*(code *)PTR_safefree_000b23d0)(puVar3)" (parenthesized_expression "(*(code *)PTR_safefree_000b23d0)" (( "(") (pointer_expression "*(code *)PTR_safefree_000b23d0" (* "*") (cast_expression "(code *)PTR_safefree_000b23d0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000b23d0"))) () ")")) (argument_list "(puVar3)" (( "(") (identifier "puVar3") () ")"))) (; ";")) (return_statement "return iVar4;" (return "return") (identifier "iVar4") (; ";")) (} "}")))

type_1 function_1(type_1 lower,type_1 upper)

{
  type_2 *puVar1;
  type_2 *puVar2;
  type_3 *var_6;
  int var_10;
  type_1 var_11;
  type_4 var_1;
  int var_8;
  type_4 var_2;
  int var_3;
  type_3 *var_4;
  type_3 *var_7;
  
  puVar1 = PTR_bignum_from_bytes_000b2874;
  var_1 = *upper * 0x20;
  var_2 = var_1 - 1;
  if ((-1 < (int)var_2) && (-1 < (int)upper[((int)var_2 >> 5) + 1])) {
    do {
      var_1 = var_2;
      var_2 = var_1 - 1;
      if (var_2 == 0xffffffff) break;
    } while (upper[((int)var_2 >> 5) + 1] >> (var_2 & 0x1f) == 0);
  }
  var_2 = var_1;
  if ((int)var_1 < 0) {
    var_2 = var_1 + 7;
  }
  var_1 = var_1 & 0x80000007;
  var_3 = (int)var_2 >> 3;
  if ((int)var_1 < 0) {
    var_1 = (var_1 - 1 | 0xfffffff8) + 1;
  }
  if (var_1 != 0) {
    var_3 = var_3 + 1;
  }
  var_6 = (type_3 *)(*(type_5 *)PTR_safemalloc_000b2408)(var_3,1);
  puVar2 = PTR_freebn_000b29b0;
  var_8 = var_3;
  if (var_3 < 0) {
    var_8 = 0;
  }
  while( true ) {
    var_4 = var_6;
    if (0 < var_3) {
      do {
        var_7 = var_4 + 1;
        var_10 = var_5();
        *var_4 = (char)var_10;
        var_4 = var_7;
      } while (var_6 + var_3 != var_7);
    }
    if (var_1 != 0) {
      var_6[var_8 + -1] = (byte)(0xff >> (8 - var_1 & 0x1f)) & var_6[var_8 + -1];
    }
    var_11 = (type_1)(*(type_5 *)puVar1)(var_6,var_3);
    var_10 = var_9(var_11,lower);
    if ((-1 < var_10) && (var_10 = var_9(var_11,upper), var_10 < 1)) break;
    if (var_11 != (type_1)0x0) {
      (*(type_5 *)puVar2)(var_11);
    }
  }
  (*(type_5 *)PTR_smemclr_000b2460)(var_6,var_3);
  (*(type_5 *)PTR_safefree_000b23d0)(var_6);
  return var_11;
}


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

int MASKED(undefined4 param_1,int *param_2)

{
  undefined *puVar1;
  undefined *puVar2;
  undefined1 *puVar3;
  undefined1 uVar6;
  int iVar4;
  int iVar5;
  uint uVar7;
  int iVar8;
  uint uVar9;
  int iVar10;
  undefined1 *puVar11;
  undefined1 *puVar12;
  
  puVar1 = PTR_bignum_from_bytes_000b2874;
  uVar7 = *param_2 * 0x20;
  uVar9 = uVar7 - 1;
  if ((-1 < (int)uVar9) && (-1 < param_2[((int)uVar9 >> 5) + 1])) {
    do {
      uVar7 = uVar9;
      uVar9 = uVar7 - 1;
      if (uVar9 == 0xffffffff) break;
    } while ((uint)param_2[((int)uVar9 >> 5) + 1] >> (uVar9 & 0x1f) == 0);
  }
  uVar9 = uVar7;
  if ((int)uVar7 < 0) {
    uVar9 = uVar7 + 7;
  }
  uVar7 = uVar7 & 0x80000007;
  iVar10 = (int)uVar9 >> 3;
  if ((int)uVar7 < 0) {
    uVar7 = (uVar7 - 1 | 0xfffffff8) + 1;
  }
  if (uVar7 != 0) {
    iVar10 = iVar10 + 1;
  }
  puVar3 = (undefined1 *)(*(code *)PTR_safemalloc_000b2408)(iVar10,1);
  puVar2 = PTR_freebn_000b29b0;
  iVar8 = iVar10;
  if (iVar10 < 0) {
    iVar8 = 0;
  }
  while( true ) {
    puVar11 = puVar3;
    if (0 < iVar10) {
      do {
        puVar12 = puVar11 + 1;
        uVar6 = random_byte();
        *puVar11 = uVar6;
        puVar11 = puVar12;
      } while (puVar3 + iVar10 != puVar12);
    }
    if (uVar7 != 0) {
      puVar3[iVar8 + -1] = (byte)(0xff >> (8 - uVar7 & 0x1f)) & puVar3[iVar8 + -1];
    }
    iVar4 = (*(code *)puVar1)(puVar3,iVar10);
    iVar5 = bignum_cmp(iVar4,param_1);
    if ((-1 < iVar5) && (iVar5 = bignum_cmp(iVar4,param_2), iVar5 < 1)) break;
    if (iVar4 != 0) {
      (*(code *)puVar2)(iVar4);
    }
  }
  (*(code *)PTR_smemclr_000b2460)(puVar3,iVar10);
  (*(code *)PTR_safefree_000b23d0)(puVar3);
  return iVar4;
}

