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

void manual_hostkey_handler(control *ctrl,void *dlg,void *data,int event)

{
  int *piVar1;
  int iVar2;
  char *pcVar3;
  char *pcVar4;
  int in_GS_OFFSET;
  char *key;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x22a79;
  piVar1 = *(int **)((int)ctrl + 0x14);
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  if (event == 0) {
    if ((control *)piVar1[2] == ctrl) {
      dlg_update_start(ctrl,dlg);
      dlg_listbox_clear(ctrl,dlg);
      pcVar3 = (char *)0x0;
      while( true ) {
        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);
        if (pcVar3 == (char *)0x0) break;
        dlg_listbox_add(ctrl,dlg,key);
        pcVar3 = key;
      }
      dlg_update_done(ctrl,dlg);
    }
  }
  else if (event == 1) {
    if ((control *)*piVar1 == ctrl) {
      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);
      if (*pcVar3 == '\0') {
        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");
        safefree(pcVar3);
      }
      else {
        iVar2 = validate_manual_hostkey(pcVar3);
        if (iVar2 == 0) {
          dlg_error_msg(dlg,"Host key is not in a valid format");
        }
        else {
          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);
          if (pcVar4 == (char *)0x0) {
            conf_set_str_str((Conf *)data,0xad,pcVar3,"");
          }
          else {
            dlg_error_msg(dlg,"Specified host key is already listed");
          }
        }
        safefree(pcVar3);
        dlg_refresh((control *)piVar1[2],dlg);
      }
    }
    else if ((control *)piVar1[1] == ctrl) {
      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);
      if (iVar2 < 0) {
        dlg_beep(dlg);
      }
      else {
        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);
        if (pcVar3 != (char *)0x0) {
          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);
          conf_del_str_str((Conf *)data,0xad,pcVar3);
        }
      }
      dlg_refresh((control *)piVar1[2],dlg);
    }
  }
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail_local();
}



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

void FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)

{
  int *piVar1;
  int iVar2;
  char *pcVar3;
  int in_GS_OFFSET;
  undefined4 uVar4;
  undefined4 local_24;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x22a79;
  piVar1 = *(int **)(param_1 + 0x14);
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  if (param_4 == 0) {
    if (piVar1[2] == param_1) {
      FUN_0005aa50(param_1,param_2);
      FUN_00059740(param_1,param_2);
      uVar4 = 0;
      while( true ) {
        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);
        if (iVar2 == 0) break;
        FUN_00059ab0(param_1,param_2,local_24);
        uVar4 = local_24;
      }
      FUN_0005aa60(param_1,param_2);
    }
  }
  else if (param_4 == 1) {
    if (*piVar1 == param_1) {
      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);
      if (*pcVar3 == '\0') {
        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");
        FUN_00031580(pcVar3);
      }
      else {
        iVar2 = FUN_000316c0(pcVar3);
        if (iVar2 == 0) {
          FUN_0005abf0(param_2,"Host key is not in a valid format");
        }
        else {
          iVar2 = FUN_00020370(param_3,0xad,pcVar3);
          if (iVar2 == 0) {
            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);
          }
          else {
            FUN_0005abf0(param_2,"Specified host key is already listed");
          }
        }
        FUN_00031580(pcVar3);
        FUN_0005ac90(piVar1[2],param_2);
      }
    }
    else if (piVar1[1] == param_1) {
      iVar2 = FUN_00059c00(piVar1[2],param_2);
      if (iVar2 < 0) {
        FUN_0005abc0(param_2);
      }
      else {
        iVar2 = FUN_00020600(param_3,0xad,iVar2);
        if (iVar2 != 0) {
          FUN_00059580(piVar1[3],param_2,iVar2);
          FUN_00020e30(param_3,0xad,iVar2);
        }
      }
      FUN_0005ac90(piVar1[2],param_2);
    }
  }
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_00077880();
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x0001b410
ADD EBX,0xa2d2b
SUB ESP,0x2c
MOV EAX,dword ptr [ESP + 0x48]
MOV ESI,dword ptr [ESP + 0x40]
MOV EDI,dword ptr [ESP + 0x44]
MOV dword ptr [ESP + 0xc],EAX
MOV EAX,dword ptr [ESP + 0x4c]
MOV EBP,dword ptr [ESI + 0x14]
MOV EDX,dword ptr GS:[0x14]
MOV dword ptr [ESP + 0x1c],EDX
XOR EDX,EDX
TEST EAX,EAX
JNZ 0x00022ad0
CMP dword ptr [EBP + 0x8],ESI
JZ 0x00022b50
MOV EAX,dword ptr [ESP + 0x1c]
XOR EAX,dword ptr GS:[0x14]
JNZ 0x00022c90
ADD ESP,0x2c
POP EBX
POP ESI
POP EDI
POP EBP
RET
CMP EAX,0x1
JNZ 0x00022ab3
CMP dword ptr [EBP],ESI
JZ 0x00022bb0
CMP dword ptr [EBP + 0x4],ESI
JNZ 0x00022ab3
SUB ESP,0x8
PUSH EDI
PUSH dword ptr [EBP + 0x8]
CALL 0x00059c00
ADD ESP,0x10
TEST EAX,EAX
JS 0x00022c30
SUB ESP,0x4
PUSH EAX
PUSH 0xad
PUSH dword ptr [ESP + 0x18]
CALL 0x00020600
ADD ESP,0x10
MOV ESI,EAX
TEST EAX,EAX
JZ 0x00022b37
SUB ESP,0x4
PUSH EAX
PUSH EDI
PUSH dword ptr [EBP + 0xc]
CALL 0x00059580
ADD ESP,0xc
PUSH ESI
PUSH 0xad
PUSH dword ptr [ESP + 0x18]
CALL 0x00020e30
ADD ESP,0x10
SUB ESP,0x8
PUSH EDI
PUSH dword ptr [EBP + 0x8]
CALL 0x0005ac90
ADD ESP,0x10
JMP 0x00022ab3
SUB ESP,0x8
PUSH EDI
PUSH ESI
CALL 0x0005aa50
POP ECX
POP EBP
PUSH EDI
PUSH ESI
CALL 0x00059740
LEA EBP,[ESP + 0x28]
PUSH EBP
PUSH 0x0
JMP 0x00022b83
SUB ESP,0x4
PUSH dword ptr [ESP + 0x1c]
PUSH EDI
PUSH ESI
CALL 0x00059ab0
PUSH EBP
PUSH dword ptr [ESP + 0x2c]
PUSH 0xad
PUSH dword ptr [ESP + 0x28]
CALL 0x00020510
ADD ESP,0x20
TEST EAX,EAX
JNZ 0x00022b70
SUB ESP,0x8
PUSH EDI
PUSH ESI
CALL 0x0005aa60
ADD ESP,0x10
JMP 0x00022ab3
SUB ESP,0x8
PUSH EDI
PUSH dword ptr [EBP + 0xc]
CALL 0x00059660
ADD ESP,0x10
CMP byte ptr [EAX],0x0
MOV ESI,EAX
JZ 0x00022c08
SUB ESP,0xc
PUSH EAX
CALL 0x000316c0
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x00022c41
SUB ESP,0x8
LEA EAX,[EBX + 0xfffc6438]
PUSH EAX
PUSH EDI
CALL 0x0005abf0
ADD ESP,0x10
SUB ESP,0xc
PUSH ESI
CALL 0x00031580
POP EAX
POP EDX
PUSH EDI
PUSH dword ptr [EBP + 0x8]
CALL 0x0005ac90
ADD ESP,0x10
JMP 0x00022ab3
SUB ESP,0x8
LEA EAX,[EBX + 0xfffc6408]
PUSH EAX
PUSH EDI
CALL 0x0005abf0
MOV dword ptr [ESP],ESI
CALL 0x00031580
ADD ESP,0x10
JMP 0x00022ab3
SUB ESP,0xc
PUSH EDI
CALL 0x0005abc0
ADD ESP,0x10
JMP 0x00022b37
SUB ESP,0x4
PUSH ESI
PUSH 0xad
PUSH dword ptr [ESP + 0x18]
CALL 0x00020370
ADD ESP,0x10
TEST EAX,EAX
JZ 0x00022c72
SUB ESP,0x8
LEA EAX,[EBX + 0xfffc645c]
PUSH EAX
PUSH EDI
CALL 0x0005abf0
ADD ESP,0x10
JMP 0x00022be9
LEA EAX,[EBX + 0xfffc7b97]
PUSH EAX
PUSH ESI
PUSH 0xad
PUSH dword ptr [ESP + 0x18]
CALL 0x00020d70
ADD ESP,0x10
JMP 0x00022be9
CALL 0x00077880
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00077880();\n}\n\n" comment (function_definition "void FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00077880();\n}" primitive_type (function_declarator "FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "int param_4" primitive_type identifier) ))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00077880();\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "undefined4 local_24;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x22a79;" (assignment_expression "uStack_14 = 0x22a79" identifier = number_literal) ;) (expression_statement "piVar1 = *(int **)(param_1 + 0x14);" (assignment_expression "piVar1 = *(int **)(param_1 + 0x14)" identifier = (pointer_expression "*(int **)(param_1 + 0x14)" * (cast_expression "(int **)(param_1 + 0x14)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (if_statement "if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" if (parenthesized_expression "(param_4 == 0)" ( (binary_expression "param_4 == 0" identifier == number_literal) )) (compound_statement "{\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }" { (if_statement "if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" if (parenthesized_expression "(piVar1[2] == param_1)" ( (binary_expression "piVar1[2] == param_1" (subscript_expression "piVar1[2]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" { (expression_statement "FUN_0005aa50(param_1,param_2);" (call_expression "FUN_0005aa50(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) (expression_statement "FUN_00059740(param_1,param_2);" (call_expression "FUN_00059740(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" { (expression_statement "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);" (assignment_expression "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24)" identifier = (call_expression "FUN_00020510(param_3,0xad,uVar4,&local_24)" identifier (argument_list "(param_3,0xad,uVar4,&local_24)" ( identifier , number_literal , identifier , (pointer_expression "&local_24" & identifier) )))) ;) (if_statement "if (iVar2 == 0) break;" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "FUN_00059ab0(param_1,param_2,local_24);" (call_expression "FUN_00059ab0(param_1,param_2,local_24)" identifier (argument_list "(param_1,param_2,local_24)" ( identifier , identifier , identifier ))) ;) (expression_statement "uVar4 = local_24;" (assignment_expression "uVar4 = local_24" identifier = identifier) ;) })) (expression_statement "FUN_0005aa60(param_1,param_2);" (call_expression "FUN_0005aa60(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) })) }) (else_clause "else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" else (if_statement "if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" { (if_statement "if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" if (parenthesized_expression "(*piVar1 == param_1)" ( (binary_expression "*piVar1 == param_1" (pointer_expression "*piVar1" * identifier) == identifier) )) (compound_statement "{\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }" { (expression_statement "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);" (assignment_expression "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2)" identifier = (cast_expression "(char *)FUN_00059660(piVar1[3],param_2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00059660(piVar1[3],param_2)" identifier (argument_list "(piVar1[3],param_2)" ( (subscript_expression "piVar1[3]" identifier [ number_literal ]) , identifier ))))) ;) (if_statement "if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" if (parenthesized_expression "(*pcVar3 == '\0')" ( (binary_expression "*pcVar3 == '\0'" (pointer_expression "*pcVar3" * identifier) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }" { (expression_statement "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");" (call_expression "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint")" identifier (argument_list "(param_2,"You need to specify a host key or fingerprint")" ( identifier , (string_literal ""You need to specify a host key or fingerprint"" " string_content ") ))) ;) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) }) (else_clause "else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" else (compound_statement "{\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" { (expression_statement "iVar2 = FUN_000316c0(pcVar3);" (assignment_expression "iVar2 = FUN_000316c0(pcVar3)" identifier = (call_expression "FUN_000316c0(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier )))) ;) (if_statement "if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }" { (expression_statement "FUN_0005abf0(param_2,"Host key is not in a valid format");" (call_expression "FUN_0005abf0(param_2,"Host key is not in a valid format")" identifier (argument_list "(param_2,"Host key is not in a valid format")" ( identifier , (string_literal ""Host key is not in a valid format"" " string_content ") ))) ;) }) (else_clause "else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" else (compound_statement "{\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" { (expression_statement "iVar2 = FUN_00020370(param_3,0xad,pcVar3);" (assignment_expression "iVar2 = FUN_00020370(param_3,0xad,pcVar3)" identifier = (call_expression "FUN_00020370(param_3,0xad,pcVar3)" identifier (argument_list "(param_3,0xad,pcVar3)" ( identifier , number_literal , identifier )))) ;) (if_statement "if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }" { (expression_statement "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);" (call_expression "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b)" identifier (argument_list "(param_3,0xad,pcVar3,&DAT_0008d33b)" ( identifier , number_literal , identifier , (pointer_expression "&DAT_0008d33b" & identifier) ))) ;) }) (else_clause "else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" else (compound_statement "{\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" { (expression_statement "FUN_0005abf0(param_2,"Specified host key is already listed");" (call_expression "FUN_0005abf0(param_2,"Specified host key is already listed")" identifier (argument_list "(param_2,"Specified host key is already listed")" ( identifier , (string_literal ""Specified host key is already listed"" " string_content ") ))) ;) }))) }))) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier ))) ;) }))) }) (else_clause "else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" else (if_statement "if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" if (parenthesized_expression "(piVar1[1] == param_1)" ( (binary_expression "piVar1[1] == param_1" (subscript_expression "piVar1[1]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" { (expression_statement "iVar2 = FUN_00059c00(piVar1[2],param_2);" (assignment_expression "iVar2 = FUN_00059c00(piVar1[2],param_2)" identifier = (call_expression "FUN_00059c00(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier )))) ;) (if_statement "if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        FUN_0005abc0(param_2);\n      }" { (expression_statement "FUN_0005abc0(param_2);" (call_expression "FUN_0005abc0(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;) }) (else_clause "else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" else (compound_statement "{\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" { (expression_statement "iVar2 = FUN_00020600(param_3,0xad,iVar2);" (assignment_expression "iVar2 = FUN_00020600(param_3,0xad,iVar2)" identifier = (call_expression "FUN_00020600(param_3,0xad,iVar2)" identifier (argument_list "(param_3,0xad,iVar2)" ( identifier , number_literal , identifier )))) ;) (if_statement "if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" { (expression_statement "FUN_00059580(piVar1[3],param_2,iVar2);" (call_expression "FUN_00059580(piVar1[3],param_2,iVar2)" identifier (argument_list "(piVar1[3],param_2,iVar2)" ( (subscript_expression "piVar1[3]" identifier [ number_literal ]) , identifier , identifier ))) ;) (expression_statement "FUN_00020e30(param_3,0xad,iVar2);" (call_expression "FUN_00020e30(param_3,0xad,iVar2)" identifier (argument_list "(param_3,0xad,iVar2)" ( identifier , number_literal , identifier ))) ;) })) }))) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier ))) ;) })))) })))) (if_statement "if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(local_20 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) comment (expression_statement "FUN_00077880();" (call_expression "FUN_00077880()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nvoid manual_hostkey_handler(control *ctrl,void *dlg,void *data,int event)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  int in_GS_OFFSET;\n  char *key;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)((int)ctrl + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (event == 0) {\n    if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }\n  }\n  else if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}\n\n" comment comment (function_definition "void manual_hostkey_handler(control *ctrl,void *dlg,void *data,int event)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  int in_GS_OFFSET;\n  char *key;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)((int)ctrl + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (event == 0) {\n    if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }\n  }\n  else if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" primitive_type (function_declarator "manual_hostkey_handler(control *ctrl,void *dlg,void *data,int event)" identifier (parameter_list "(control *ctrl,void *dlg,void *data,int event)" ( (parameter_declaration "control *ctrl" type_identifier (pointer_declarator "*ctrl" * identifier)) , (parameter_declaration "void *dlg" primitive_type (pointer_declarator "*dlg" * identifier)) , (parameter_declaration "void *data" primitive_type (pointer_declarator "*data" * identifier)) , (parameter_declaration "int event" primitive_type identifier) ))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  int in_GS_OFFSET;\n  char *key;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)((int)ctrl + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (event == 0) {\n    if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }\n  }\n  else if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "char *key;" primitive_type (pointer_declarator "*key" * identifier) ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x22a79;" (assignment_expression "uStack_14 = 0x22a79" identifier = number_literal) ;) (expression_statement "piVar1 = *(int **)((int)ctrl + 0x14);" (assignment_expression "piVar1 = *(int **)((int)ctrl + 0x14)" identifier = (pointer_expression "*(int **)((int)ctrl + 0x14)" * (cast_expression "(int **)((int)ctrl + 0x14)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "((int)ctrl + 0x14)" ( (binary_expression "(int)ctrl + 0x14" (cast_expression "(int)ctrl" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) ))))) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (if_statement "if (event == 0) {\n    if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }\n  }\n  else if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }" if (parenthesized_expression "(event == 0)" ( (binary_expression "event == 0" identifier == number_literal) )) (compound_statement "{\n    if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }\n  }" { (if_statement "if ((control *)piVar1[2] == ctrl) {\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }" if (parenthesized_expression "((control *)piVar1[2] == ctrl)" ( (binary_expression "(control *)piVar1[2] == ctrl" (cast_expression "(control *)piVar1[2]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[2]" identifier [ number_literal ])) == identifier) )) (compound_statement "{\n      dlg_update_start(ctrl,dlg);\n      dlg_listbox_clear(ctrl,dlg);\n      pcVar3 = (char *)0x0;\n      while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }\n      dlg_update_done(ctrl,dlg);\n    }" { (expression_statement "dlg_update_start(ctrl,dlg);" (call_expression "dlg_update_start(ctrl,dlg)" identifier (argument_list "(ctrl,dlg)" ( identifier , identifier ))) ;) (expression_statement "dlg_listbox_clear(ctrl,dlg);" (call_expression "dlg_listbox_clear(ctrl,dlg)" identifier (argument_list "(ctrl,dlg)" ( identifier , identifier ))) ;) (expression_statement "pcVar3 = (char *)0x0;" (assignment_expression "pcVar3 = (char *)0x0" identifier = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (while_statement "while( true ) {\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);\n        if (pcVar3 == (char *)0x0) break;\n        dlg_listbox_add(ctrl,dlg,key);\n        pcVar3 = key;\n      }" { (expression_statement "pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key);" (assignment_expression "pcVar3 = conf_get_str_strs((Conf *)data,0xad,pcVar3,&key)" identifier = (call_expression "conf_get_str_strs((Conf *)data,0xad,pcVar3,&key)" identifier (argument_list "((Conf *)data,0xad,pcVar3,&key)" ( (cast_expression "(Conf *)data" ( (type_descriptor "Conf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) , number_literal , identifier , (pointer_expression "&key" & identifier) )))) ;) (if_statement "if (pcVar3 == (char *)0x0) break;" if (parenthesized_expression "(pcVar3 == (char *)0x0)" ( (binary_expression "pcVar3 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (expression_statement "dlg_listbox_add(ctrl,dlg,key);" (call_expression "dlg_listbox_add(ctrl,dlg,key)" identifier (argument_list "(ctrl,dlg,key)" ( identifier , identifier , identifier ))) ;) (expression_statement "pcVar3 = key;" (assignment_expression "pcVar3 = key" identifier = identifier) ;) })) (expression_statement "dlg_update_done(ctrl,dlg);" (call_expression "dlg_update_done(ctrl,dlg)" identifier (argument_list "(ctrl,dlg)" ( identifier , identifier ))) ;) })) }) (else_clause "else if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }" else (if_statement "if (event == 1) {\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }" if (parenthesized_expression "(event == 1)" ( (binary_expression "event == 1" identifier == number_literal) )) (compound_statement "{\n    if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }\n  }" { (if_statement "if ((control *)*piVar1 == ctrl) {\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }\n    else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }" if (parenthesized_expression "((control *)*piVar1 == ctrl)" ( (binary_expression "(control *)*piVar1 == ctrl" (cast_expression "(control *)*piVar1" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar1" * identifier)) == identifier) )) (compound_statement "{\n      pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);\n      if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }\n    }" { (expression_statement "pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg);" (assignment_expression "pcVar3 = dlg_editbox_get((control *)piVar1[3],dlg)" identifier = (call_expression "dlg_editbox_get((control *)piVar1[3],dlg)" identifier (argument_list "((control *)piVar1[3],dlg)" ( (cast_expression "(control *)piVar1[3]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[3]" identifier [ number_literal ])) , identifier )))) ;) (if_statement "if (*pcVar3 == '\0') {\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }\n      else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }" if (parenthesized_expression "(*pcVar3 == '\0')" ( (binary_expression "*pcVar3 == '\0'" (pointer_expression "*pcVar3" * identifier) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n        dlg_error_msg(dlg,"You need to specify a host key or fingerprint");\n        safefree(pcVar3);\n      }" { (expression_statement "dlg_error_msg(dlg,"You need to specify a host key or fingerprint");" (call_expression "dlg_error_msg(dlg,"You need to specify a host key or fingerprint")" identifier (argument_list "(dlg,"You need to specify a host key or fingerprint")" ( identifier , (string_literal ""You need to specify a host key or fingerprint"" " string_content ") ))) ;) (expression_statement "safefree(pcVar3);" (call_expression "safefree(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) }) (else_clause "else {\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }" else (compound_statement "{\n        iVar2 = validate_manual_hostkey(pcVar3);\n        if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }\n        safefree(pcVar3);\n        dlg_refresh((control *)piVar1[2],dlg);\n      }" { (expression_statement "iVar2 = validate_manual_hostkey(pcVar3);" (assignment_expression "iVar2 = validate_manual_hostkey(pcVar3)" identifier = (call_expression "validate_manual_hostkey(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier )))) ;) (if_statement "if (iVar2 == 0) {\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }\n        else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n          dlg_error_msg(dlg,"Host key is not in a valid format");\n        }" { (expression_statement "dlg_error_msg(dlg,"Host key is not in a valid format");" (call_expression "dlg_error_msg(dlg,"Host key is not in a valid format")" identifier (argument_list "(dlg,"Host key is not in a valid format")" ( identifier , (string_literal ""Host key is not in a valid format"" " string_content ") ))) ;) }) (else_clause "else {\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }" else (compound_statement "{\n          pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);\n          if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }\n        }" { (expression_statement "pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3);" (assignment_expression "pcVar4 = conf_get_str_str_opt((Conf *)data,0xad,pcVar3)" identifier = (call_expression "conf_get_str_str_opt((Conf *)data,0xad,pcVar3)" identifier (argument_list "((Conf *)data,0xad,pcVar3)" ( (cast_expression "(Conf *)data" ( (type_descriptor "Conf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) , number_literal , identifier )))) ;) (if_statement "if (pcVar4 == (char *)0x0) {\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }\n          else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }" if (parenthesized_expression "(pcVar4 == (char *)0x0)" ( (binary_expression "pcVar4 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            conf_set_str_str((Conf *)data,0xad,pcVar3,"");\n          }" { (expression_statement "conf_set_str_str((Conf *)data,0xad,pcVar3,"");" (call_expression "conf_set_str_str((Conf *)data,0xad,pcVar3,"")" identifier (argument_list "((Conf *)data,0xad,pcVar3,"")" ( (cast_expression "(Conf *)data" ( (type_descriptor "Conf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) , number_literal , identifier , (string_literal """" " ") ))) ;) }) (else_clause "else {\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }" else (compound_statement "{\n            dlg_error_msg(dlg,"Specified host key is already listed");\n          }" { (expression_statement "dlg_error_msg(dlg,"Specified host key is already listed");" (call_expression "dlg_error_msg(dlg,"Specified host key is already listed")" identifier (argument_list "(dlg,"Specified host key is already listed")" ( identifier , (string_literal ""Specified host key is already listed"" " string_content ") ))) ;) }))) }))) (expression_statement "safefree(pcVar3);" (call_expression "safefree(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) (expression_statement "dlg_refresh((control *)piVar1[2],dlg);" (call_expression "dlg_refresh((control *)piVar1[2],dlg)" identifier (argument_list "((control *)piVar1[2],dlg)" ( (cast_expression "(control *)piVar1[2]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[2]" identifier [ number_literal ])) , identifier ))) ;) }))) }) (else_clause "else if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }" else (if_statement "if ((control *)piVar1[1] == ctrl) {\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }" if (parenthesized_expression "((control *)piVar1[1] == ctrl)" ( (binary_expression "(control *)piVar1[1] == ctrl" (cast_expression "(control *)piVar1[1]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[1]" identifier [ number_literal ])) == identifier) )) (compound_statement "{\n      iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);\n      if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }\n      dlg_refresh((control *)piVar1[2],dlg);\n    }" { (expression_statement "iVar2 = dlg_listbox_index((control *)piVar1[2],dlg);" (assignment_expression "iVar2 = dlg_listbox_index((control *)piVar1[2],dlg)" identifier = (call_expression "dlg_listbox_index((control *)piVar1[2],dlg)" identifier (argument_list "((control *)piVar1[2],dlg)" ( (cast_expression "(control *)piVar1[2]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[2]" identifier [ number_literal ])) , identifier )))) ;) (if_statement "if (iVar2 < 0) {\n        dlg_beep(dlg);\n      }\n      else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        dlg_beep(dlg);\n      }" { (expression_statement "dlg_beep(dlg);" (call_expression "dlg_beep(dlg)" identifier (argument_list "(dlg)" ( identifier ))) ;) }) (else_clause "else {\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }" else (compound_statement "{\n        pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);\n        if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }\n      }" { (expression_statement "pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2);" (assignment_expression "pcVar3 = conf_get_str_nthstrkey((Conf *)data,0xad,iVar2)" identifier = (call_expression "conf_get_str_nthstrkey((Conf *)data,0xad,iVar2)" identifier (argument_list "((Conf *)data,0xad,iVar2)" ( (cast_expression "(Conf *)data" ( (type_descriptor "Conf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) , number_literal , identifier )))) ;) (if_statement "if (pcVar3 != (char *)0x0) {\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }" if (parenthesized_expression "(pcVar3 != (char *)0x0)" ( (binary_expression "pcVar3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);\n          conf_del_str_str((Conf *)data,0xad,pcVar3);\n        }" { (expression_statement "dlg_editbox_set((control *)piVar1[3],dlg,pcVar3);" (call_expression "dlg_editbox_set((control *)piVar1[3],dlg,pcVar3)" identifier (argument_list "((control *)piVar1[3],dlg,pcVar3)" ( (cast_expression "(control *)piVar1[3]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[3]" identifier [ number_literal ])) , identifier , identifier ))) ;) (expression_statement "conf_del_str_str((Conf *)data,0xad,pcVar3);" (call_expression "conf_del_str_str((Conf *)data,0xad,pcVar3)" identifier (argument_list "((Conf *)data,0xad,pcVar3)" ( (cast_expression "(Conf *)data" ( (type_descriptor "Conf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) , number_literal , identifier ))) ;) })) }))) (expression_statement "dlg_refresh((control *)piVar1[2],dlg);" (call_expression "dlg_refresh((control *)piVar1[2],dlg)" identifier (argument_list "((control *)piVar1[2],dlg)" ( (cast_expression "(control *)piVar1[2]" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar1[2]" identifier [ number_literal ])) , identifier ))) ;) })))) })))) (if_statement "if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(local_20 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "void FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_00077880();\n}\n\n" (function_definition "void FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_00077880();\n}" primitive_type (function_declarator "FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "int param_4" primitive_type identifier) ))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_00077880();\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "undefined4 local_24;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x22a79;" (assignment_expression "uStack_14 = 0x22a79" identifier = number_literal) ;) (expression_statement "piVar1 = *(int **)(param_1 + 0x14);" (assignment_expression "piVar1 = *(int **)(param_1 + 0x14)" identifier = (pointer_expression "*(int **)(param_1 + 0x14)" * (cast_expression "(int **)(param_1 + 0x14)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (if_statement "if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" if (parenthesized_expression "(param_4 == 0)" ( (binary_expression "param_4 == 0" identifier == number_literal) )) (compound_statement "{\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }" { (if_statement "if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" if (parenthesized_expression "(piVar1[2] == param_1)" ( (binary_expression "piVar1[2] == param_1" (subscript_expression "piVar1[2]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" { (expression_statement "FUN_0005aa50(param_1,param_2);" (call_expression "FUN_0005aa50(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) (expression_statement "FUN_00059740(param_1,param_2);" (call_expression "FUN_00059740(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" { (expression_statement "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);" (assignment_expression "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24)" identifier = (call_expression "FUN_00020510(param_3,0xad,uVar4,&local_24)" identifier (argument_list "(param_3,0xad,uVar4,&local_24)" ( identifier , number_literal , identifier , (pointer_expression "&local_24" & identifier) )))) ;) (if_statement "if (iVar2 == 0) break;" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "FUN_00059ab0(param_1,param_2,local_24);" (call_expression "FUN_00059ab0(param_1,param_2,local_24)" identifier (argument_list "(param_1,param_2,local_24)" ( identifier , identifier , identifier ))) ;) (expression_statement "uVar4 = local_24;" (assignment_expression "uVar4 = local_24" identifier = identifier) ;) })) (expression_statement "FUN_0005aa60(param_1,param_2);" (call_expression "FUN_0005aa60(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier ))) ;) })) }) (else_clause "else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" else (if_statement "if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" { (if_statement "if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" if (parenthesized_expression "(*piVar1 == param_1)" ( (binary_expression "*piVar1 == param_1" (pointer_expression "*piVar1" * identifier) == identifier) )) (compound_statement "{\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }" { (expression_statement "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);" (assignment_expression "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2)" identifier = (cast_expression "(char *)FUN_00059660(piVar1[3],param_2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00059660(piVar1[3],param_2)" identifier (argument_list "(piVar1[3],param_2)" ( (subscript_expression "piVar1[3]" identifier [ number_literal ]) , identifier ))))) ;) (if_statement "if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" if (parenthesized_expression "(*pcVar3 == '\0')" ( (binary_expression "*pcVar3 == '\0'" (pointer_expression "*pcVar3" * identifier) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }" { (expression_statement "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");" (call_expression "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint")" identifier (argument_list "(param_2,"You need to specify a host key or fingerprint")" ( identifier , (string_literal ""You need to specify a host key or fingerprint"" " string_content ") ))) ;) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) }) (else_clause "else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" else (compound_statement "{\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" { (expression_statement "iVar2 = FUN_000316c0(pcVar3);" (assignment_expression "iVar2 = FUN_000316c0(pcVar3)" identifier = (call_expression "FUN_000316c0(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier )))) ;) (if_statement "if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }" { (expression_statement "FUN_0005abf0(param_2,"Host key is not in a valid format");" (call_expression "FUN_0005abf0(param_2,"Host key is not in a valid format")" identifier (argument_list "(param_2,"Host key is not in a valid format")" ( identifier , (string_literal ""Host key is not in a valid format"" " string_content ") ))) ;) }) (else_clause "else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" else (compound_statement "{\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" { (expression_statement "iVar2 = FUN_00020370(param_3,0xad,pcVar3);" (assignment_expression "iVar2 = FUN_00020370(param_3,0xad,pcVar3)" identifier = (call_expression "FUN_00020370(param_3,0xad,pcVar3)" identifier (argument_list "(param_3,0xad,pcVar3)" ( identifier , number_literal , identifier )))) ;) (if_statement "if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }" { (expression_statement "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);" (call_expression "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b)" identifier (argument_list "(param_3,0xad,pcVar3,&DAT_0008d33b)" ( identifier , number_literal , identifier , (pointer_expression "&DAT_0008d33b" & identifier) ))) ;) }) (else_clause "else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" else (compound_statement "{\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" { (expression_statement "FUN_0005abf0(param_2,"Specified host key is already listed");" (call_expression "FUN_0005abf0(param_2,"Specified host key is already listed")" identifier (argument_list "(param_2,"Specified host key is already listed")" ( identifier , (string_literal ""Specified host key is already listed"" " string_content ") ))) ;) }))) }))) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier ))) ;) }))) }) (else_clause "else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" else (if_statement "if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" if (parenthesized_expression "(piVar1[1] == param_1)" ( (binary_expression "piVar1[1] == param_1" (subscript_expression "piVar1[1]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" { (expression_statement "iVar2 = FUN_00059c00(piVar1[2],param_2);" (assignment_expression "iVar2 = FUN_00059c00(piVar1[2],param_2)" identifier = (call_expression "FUN_00059c00(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier )))) ;) (if_statement "if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        FUN_0005abc0(param_2);\n      }" { (expression_statement "FUN_0005abc0(param_2);" (call_expression "FUN_0005abc0(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;) }) (else_clause "else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" else (compound_statement "{\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" { (expression_statement "iVar2 = FUN_00020600(param_3,0xad,iVar2);" (assignment_expression "iVar2 = FUN_00020600(param_3,0xad,iVar2)" identifier = (call_expression "FUN_00020600(param_3,0xad,iVar2)" identifier (argument_list "(param_3,0xad,iVar2)" ( identifier , number_literal , identifier )))) ;) (if_statement "if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" { (expression_statement "FUN_00059580(piVar1[3],param_2,iVar2);" (call_expression "FUN_00059580(piVar1[3],param_2,iVar2)" identifier (argument_list "(piVar1[3],param_2,iVar2)" ( (subscript_expression "piVar1[3]" identifier [ number_literal ]) , identifier , identifier ))) ;) (expression_statement "FUN_00020e30(param_3,0xad,iVar2);" (call_expression "FUN_00020e30(param_3,0xad,iVar2)" identifier (argument_list "(param_3,0xad,iVar2)" ( identifier , number_literal , identifier ))) ;) })) }))) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" identifier (argument_list "(piVar1[2],param_2)" ( (subscript_expression "piVar1[2]" identifier [ number_literal ]) , identifier ))) ;) })))) })))) (if_statement "if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(local_20 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "FUN_00077880();" (call_expression "FUN_00077880()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT , IDENT , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) })) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , IDENT ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT , IDENT , (pointer_expression & IDENT) ))) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") ))) ;) }))) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , IDENT ))) ;) }))) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT , IDENT ))) ;) })) }))) (expression_statement (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , IDENT ))) ;) })))) })))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (return_statement return ;) })) (expression_statement (call_expression IDENT (argument_list ( ))) ;) })))
(function_definition "void FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)\n\n{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_00077880();\n}" (primitive_type "void") (function_declarator "FUN_00022a70(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" (identifier "FUN_00022a70") (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,int param_4)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) (, ",") (parameter_declaration "int param_4" (primitive_type "int") (identifier "param_4")) () ")"))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  char *pcVar3;\n  int in_GS_OFFSET;\n  undefined4 uVar4;\n  undefined4 local_24;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x22a79;\n  piVar1 = *(int **)(param_1 + 0x14);\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_00077880();\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "char *pcVar3;" (primitive_type "char") (pointer_declarator "*pcVar3" (* "*") (identifier "pcVar3")) (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "undefined4 uVar4;" (type_identifier "undefined4") (identifier "uVar4") (; ";")) (declaration "undefined4 local_24;" (type_identifier "undefined4") (identifier "local_24") (; ";")) (declaration "int local_20;" (primitive_type "int") (identifier "local_20") (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x22a79;" (assignment_expression "uStack_14 = 0x22a79" (identifier "uStack_14") (= "=") (number_literal "0x22a79")) (; ";")) (expression_statement "piVar1 = *(int **)(param_1 + 0x14);" (assignment_expression "piVar1 = *(int **)(param_1 + 0x14)" (identifier "piVar1") (= "=") (pointer_expression "*(int **)(param_1 + 0x14)" (* "*") (cast_expression "(int **)(param_1 + 0x14)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (= "=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (if_statement "if (param_4 == 0) {\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }\n  else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" (if "if") (parenthesized_expression "(param_4 == 0)" (( "(") (binary_expression "param_4 == 0" (identifier "param_4") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }\n  }" ({ "{") (if_statement "if (piVar1[2] == param_1) {\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" (if "if") (parenthesized_expression "(piVar1[2] == param_1)" (( "(") (binary_expression "piVar1[2] == param_1" (subscript_expression "piVar1[2]" (identifier "piVar1") ([ "[") (number_literal "2") (] "]")) (== "==") (identifier "param_1")) () ")")) (compound_statement "{\n      FUN_0005aa50(param_1,param_2);\n      FUN_00059740(param_1,param_2);\n      uVar4 = 0;\n      while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }\n      FUN_0005aa60(param_1,param_2);\n    }" ({ "{") (expression_statement "FUN_0005aa50(param_1,param_2);" (call_expression "FUN_0005aa50(param_1,param_2)" (identifier "FUN_0005aa50") (argument_list "(param_1,param_2)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") () ")"))) (; ";")) (expression_statement "FUN_00059740(param_1,param_2);" (call_expression "FUN_00059740(param_1,param_2)" (identifier "FUN_00059740") (argument_list "(param_1,param_2)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") () ")"))) (; ";")) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" (identifier "uVar4") (= "=") (number_literal "0")) (; ";")) (while_statement "while( true ) {\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);\n        if (iVar2 == 0) break;\n        FUN_00059ab0(param_1,param_2,local_24);\n        uVar4 = local_24;\n      }" ({ "{") (expression_statement "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);" (assignment_expression "iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24)" (identifier "iVar2") (= "=") (call_expression "FUN_00020510(param_3,0xad,uVar4,&local_24)" (identifier "FUN_00020510") (argument_list "(param_3,0xad,uVar4,&local_24)" (( "(") (identifier "param_3") (, ",") (number_literal "0xad") (, ",") (identifier "uVar4") (, ",") (pointer_expression "&local_24" (& "&") (identifier "local_24")) () ")")))) (; ";")) (if_statement "if (iVar2 == 0) break;" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "FUN_00059ab0(param_1,param_2,local_24);" (call_expression "FUN_00059ab0(param_1,param_2,local_24)" (identifier "FUN_00059ab0") (argument_list "(param_1,param_2,local_24)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (identifier "local_24") () ")"))) (; ";")) (expression_statement "uVar4 = local_24;" (assignment_expression "uVar4 = local_24" (identifier "uVar4") (= "=") (identifier "local_24")) (; ";")) (} "}"))) (expression_statement "FUN_0005aa60(param_1,param_2);" (call_expression "FUN_0005aa60(param_1,param_2)" (identifier "FUN_0005aa60") (argument_list "(param_1,param_2)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") () ")"))) (; ";")) (} "}"))) (} "}")) (else_clause "else if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" (else "else") (if_statement "if (param_4 == 1) {\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" (if "if") (parenthesized_expression "(param_4 == 1)" (( "(") (binary_expression "param_4 == 1" (identifier "param_4") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n    if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }\n  }" ({ "{") (if_statement "if (*piVar1 == param_1) {\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }\n    else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" (if "if") (parenthesized_expression "(*piVar1 == param_1)" (( "(") (binary_expression "*piVar1 == param_1" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (== "==") (identifier "param_1")) () ")")) (compound_statement "{\n      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);\n      if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }\n    }" ({ "{") (expression_statement "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);" (assignment_expression "pcVar3 = (char *)FUN_00059660(piVar1[3],param_2)" (identifier "pcVar3") (= "=") (cast_expression "(char *)FUN_00059660(piVar1[3],param_2)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_00059660(piVar1[3],param_2)" (identifier "FUN_00059660") (argument_list "(piVar1[3],param_2)" (( "(") (subscript_expression "piVar1[3]" (identifier "piVar1") ([ "[") (number_literal "3") (] "]")) (, ",") (identifier "param_2") () ")"))))) (; ";")) (if_statement "if (*pcVar3 == '\0') {\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }\n      else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" (if "if") (parenthesized_expression "(*pcVar3 == '\0')" (( "(") (binary_expression "*pcVar3 == '\0'" (pointer_expression "*pcVar3" (* "*") (identifier "pcVar3")) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");\n        FUN_00031580(pcVar3);\n      }" ({ "{") (expression_statement "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");" (call_expression "FUN_0005abf0(param_2,"You need to specify a host key or fingerprint")" (identifier "FUN_0005abf0") (argument_list "(param_2,"You need to specify a host key or fingerprint")" (( "(") (identifier "param_2") (, ",") (string_literal ""You need to specify a host key or fingerprint"" (" """) (string_content "You need to specify a host key or fingerprint") (" """)) () ")"))) (; ";")) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" (identifier "FUN_00031580") (argument_list "(pcVar3)" (( "(") (identifier "pcVar3") () ")"))) (; ";")) (} "}")) (else_clause "else {\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" (else "else") (compound_statement "{\n        iVar2 = FUN_000316c0(pcVar3);\n        if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }\n        FUN_00031580(pcVar3);\n        FUN_0005ac90(piVar1[2],param_2);\n      }" ({ "{") (expression_statement "iVar2 = FUN_000316c0(pcVar3);" (assignment_expression "iVar2 = FUN_000316c0(pcVar3)" (identifier "iVar2") (= "=") (call_expression "FUN_000316c0(pcVar3)" (identifier "FUN_000316c0") (argument_list "(pcVar3)" (( "(") (identifier "pcVar3") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }\n        else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          FUN_0005abf0(param_2,"Host key is not in a valid format");\n        }" ({ "{") (expression_statement "FUN_0005abf0(param_2,"Host key is not in a valid format");" (call_expression "FUN_0005abf0(param_2,"Host key is not in a valid format")" (identifier "FUN_0005abf0") (argument_list "(param_2,"Host key is not in a valid format")" (( "(") (identifier "param_2") (, ",") (string_literal ""Host key is not in a valid format"" (" """) (string_content "Host key is not in a valid format") (" """)) () ")"))) (; ";")) (} "}")) (else_clause "else {\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" (else "else") (compound_statement "{\n          iVar2 = FUN_00020370(param_3,0xad,pcVar3);\n          if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }\n        }" ({ "{") (expression_statement "iVar2 = FUN_00020370(param_3,0xad,pcVar3);" (assignment_expression "iVar2 = FUN_00020370(param_3,0xad,pcVar3)" (identifier "iVar2") (= "=") (call_expression "FUN_00020370(param_3,0xad,pcVar3)" (identifier "FUN_00020370") (argument_list "(param_3,0xad,pcVar3)" (( "(") (identifier "param_3") (, ",") (number_literal "0xad") (, ",") (identifier "pcVar3") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }\n          else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);\n          }" ({ "{") (expression_statement "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);" (call_expression "FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b)" (identifier "FUN_00020d70") (argument_list "(param_3,0xad,pcVar3,&DAT_0008d33b)" (( "(") (identifier "param_3") (, ",") (number_literal "0xad") (, ",") (identifier "pcVar3") (, ",") (pointer_expression "&DAT_0008d33b" (& "&") (identifier "DAT_0008d33b")) () ")"))) (; ";")) (} "}")) (else_clause "else {\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" (else "else") (compound_statement "{\n            FUN_0005abf0(param_2,"Specified host key is already listed");\n          }" ({ "{") (expression_statement "FUN_0005abf0(param_2,"Specified host key is already listed");" (call_expression "FUN_0005abf0(param_2,"Specified host key is already listed")" (identifier "FUN_0005abf0") (argument_list "(param_2,"Specified host key is already listed")" (( "(") (identifier "param_2") (, ",") (string_literal ""Specified host key is already listed"" (" """) (string_content "Specified host key is already listed") (" """)) () ")"))) (; ";")) (} "}")))) (} "}")))) (expression_statement "FUN_00031580(pcVar3);" (call_expression "FUN_00031580(pcVar3)" (identifier "FUN_00031580") (argument_list "(pcVar3)" (( "(") (identifier "pcVar3") () ")"))) (; ";")) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" (identifier "FUN_0005ac90") (argument_list "(piVar1[2],param_2)" (( "(") (subscript_expression "piVar1[2]" (identifier "piVar1") ([ "[") (number_literal "2") (] "]")) (, ",") (identifier "param_2") () ")"))) (; ";")) (} "}")))) (} "}")) (else_clause "else if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" (else "else") (if_statement "if (piVar1[1] == param_1) {\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" (if "if") (parenthesized_expression "(piVar1[1] == param_1)" (( "(") (binary_expression "piVar1[1] == param_1" (subscript_expression "piVar1[1]" (identifier "piVar1") ([ "[") (number_literal "1") (] "]")) (== "==") (identifier "param_1")) () ")")) (compound_statement "{\n      iVar2 = FUN_00059c00(piVar1[2],param_2);\n      if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }\n      FUN_0005ac90(piVar1[2],param_2);\n    }" ({ "{") (expression_statement "iVar2 = FUN_00059c00(piVar1[2],param_2);" (assignment_expression "iVar2 = FUN_00059c00(piVar1[2],param_2)" (identifier "iVar2") (= "=") (call_expression "FUN_00059c00(piVar1[2],param_2)" (identifier "FUN_00059c00") (argument_list "(piVar1[2],param_2)" (( "(") (subscript_expression "piVar1[2]" (identifier "piVar1") ([ "[") (number_literal "2") (] "]")) (, ",") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (iVar2 < 0) {\n        FUN_0005abc0(param_2);\n      }\n      else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" (if "if") (parenthesized_expression "(iVar2 < 0)" (( "(") (binary_expression "iVar2 < 0" (identifier "iVar2") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n        FUN_0005abc0(param_2);\n      }" ({ "{") (expression_statement "FUN_0005abc0(param_2);" (call_expression "FUN_0005abc0(param_2)" (identifier "FUN_0005abc0") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")"))) (; ";")) (} "}")) (else_clause "else {\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" (else "else") (compound_statement "{\n        iVar2 = FUN_00020600(param_3,0xad,iVar2);\n        if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }\n      }" ({ "{") (expression_statement "iVar2 = FUN_00020600(param_3,0xad,iVar2);" (assignment_expression "iVar2 = FUN_00020600(param_3,0xad,iVar2)" (identifier "iVar2") (= "=") (call_expression "FUN_00020600(param_3,0xad,iVar2)" (identifier "FUN_00020600") (argument_list "(param_3,0xad,iVar2)" (( "(") (identifier "param_3") (, ",") (number_literal "0xad") (, ",") (identifier "iVar2") () ")")))) (; ";")) (if_statement "if (iVar2 != 0) {\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" (if "if") (parenthesized_expression "(iVar2 != 0)" (( "(") (binary_expression "iVar2 != 0" (identifier "iVar2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n          FUN_00059580(piVar1[3],param_2,iVar2);\n          FUN_00020e30(param_3,0xad,iVar2);\n        }" ({ "{") (expression_statement "FUN_00059580(piVar1[3],param_2,iVar2);" (call_expression "FUN_00059580(piVar1[3],param_2,iVar2)" (identifier "FUN_00059580") (argument_list "(piVar1[3],param_2,iVar2)" (( "(") (subscript_expression "piVar1[3]" (identifier "piVar1") ([ "[") (number_literal "3") (] "]")) (, ",") (identifier "param_2") (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "FUN_00020e30(param_3,0xad,iVar2);" (call_expression "FUN_00020e30(param_3,0xad,iVar2)" (identifier "FUN_00020e30") (argument_list "(param_3,0xad,iVar2)" (( "(") (identifier "param_3") (, ",") (number_literal "0xad") (, ",") (identifier "iVar2") () ")"))) (; ";")) (} "}"))) (} "}")))) (expression_statement "FUN_0005ac90(piVar1[2],param_2);" (call_expression "FUN_0005ac90(piVar1[2],param_2)" (identifier "FUN_0005ac90") (argument_list "(piVar1[2],param_2)" (( "(") (subscript_expression "piVar1[2]" (identifier "piVar1") ([ "[") (number_literal "2") (] "]")) (, ",") (identifier "param_2") () ")"))) (; ";")) (} "}"))))) (} "}"))))) (if_statement "if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" (if "if") (parenthesized_expression "(local_20 == *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "local_20 == *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (== "==") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n    return;\n  }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "FUN_00077880();" (call_expression "FUN_00077880()" (identifier "FUN_00077880") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))

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

void function_1(type_1 *var_3,void *dlg,void *data,int var_2)

{
  int *piVar1;
  int var_14;
  char *var_7;
  char *var_16;
  int var_1;
  char *key;
  int var_24;
  type_2 uStack_14;
  
  uStack_14 = 0x22a79;
  piVar1 = *(int **)((int)var_3 + 0x14);
  var_24 = *(int *)(var_1 + 0x14);
  if (var_2 == 0) {
    if ((type_1 *)piVar1[2] == var_3) {
      var_4(var_3,dlg);
      var_5(var_3,dlg);
      var_7 = (char *)0x0;
      while( true ) {
        var_7 = var_6((type_3 *)data,0xad,var_7,&key);
        if (var_7 == (char *)0x0) break;
        var_8(var_3,dlg,key);
        var_7 = key;
      }
      var_9(var_3,dlg);
    }
  }
  else if (var_2 == 1) {
    if ((type_1 *)*piVar1 == var_3) {
      var_7 = var_10((type_1 *)piVar1[3],dlg);
      if (*var_7 == '\0') {
        var_11(dlg,"You need to specify a host key or fingerprint");
        var_12(var_7);
      }
      else {
        var_14 = var_13(var_7);
        if (var_14 == 0) {
          var_11(dlg,"Host key is not in a valid format");
        }
        else {
          var_16 = var_15((type_3 *)data,0xad,var_7);
          if (var_16 == (char *)0x0) {
            var_17((type_3 *)data,0xad,var_7,"");
          }
          else {
            var_11(dlg,"Specified host key is already listed");
          }
        }
        var_12(var_7);
        var_18((type_1 *)piVar1[2],dlg);
      }
    }
    else if ((type_1 *)piVar1[1] == var_3) {
      var_14 = var_19((type_1 *)piVar1[2],dlg);
      if (var_14 < 0) {
        var_20(dlg);
      }
      else {
        var_7 = var_21((type_3 *)data,0xad,var_14);
        if (var_7 != (char *)0x0) {
          var_22((type_1 *)piVar1[3],dlg,var_7);
          var_23((type_3 *)data,0xad,var_7);
        }
      }
      var_18((type_1 *)piVar1[2],dlg);
    }
  }
  if (var_24 == *(int *)(var_1 + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  var_25();
}


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

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

void MASKED(int param_1,undefined4 param_2,undefined4 param_3,int param_4)

{
  int *piVar1;
  int iVar2;
  char *pcVar3;
  int in_GS_OFFSET;
  undefined4 uVar4;
  undefined4 local_24;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x22a79;
  piVar1 = *(int **)(param_1 + 0x14);
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  if (param_4 == 0) {
    if (piVar1[2] == param_1) {
      FUN_0005aa50(param_1,param_2);
      FUN_00059740(param_1,param_2);
      uVar4 = 0;
      while( true ) {
        iVar2 = FUN_00020510(param_3,0xad,uVar4,&local_24);
        if (iVar2 == 0) break;
        FUN_00059ab0(param_1,param_2,local_24);
        uVar4 = local_24;
      }
      FUN_0005aa60(param_1,param_2);
    }
  }
  else if (param_4 == 1) {
    if (*piVar1 == param_1) {
      pcVar3 = (char *)FUN_00059660(piVar1[3],param_2);
      if (*pcVar3 == '\0') {
        FUN_0005abf0(param_2,"You need to specify a host key or fingerprint");
        FUN_00031580(pcVar3);
      }
      else {
        iVar2 = FUN_000316c0(pcVar3);
        if (iVar2 == 0) {
          FUN_0005abf0(param_2,"Host key is not in a valid format");
        }
        else {
          iVar2 = FUN_00020370(param_3,0xad,pcVar3);
          if (iVar2 == 0) {
            FUN_00020d70(param_3,0xad,pcVar3,&DAT_0008d33b);
          }
          else {
            FUN_0005abf0(param_2,"Specified host key is already listed");
          }
        }
        FUN_00031580(pcVar3);
        FUN_0005ac90(piVar1[2],param_2);
      }
    }
    else if (piVar1[1] == param_1) {
      iVar2 = FUN_00059c00(piVar1[2],param_2);
      if (iVar2 < 0) {
        FUN_0005abc0(param_2);
      }
      else {
        iVar2 = FUN_00020600(param_3,0xad,iVar2);
        if (iVar2 != 0) {
          FUN_00059580(piVar1[3],param_2,iVar2);
          FUN_00020e30(param_3,0xad,iVar2);
        }
      }
      FUN_0005ac90(piVar1[2],param_2);
    }
  }
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_00077880();
}

