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

agent_pending_query *
agent_query(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,
           void *callback_ctx)

{
  int iVar1;
  char *__s;
  size_t sVar2;
  int iVar3;
  int iVar4;
  ssize_t sVar5;
  agent_pending_query *conn;
  agent_pending_query *paVar6;
  int in_GS_OFFSET;
  sockaddr_un addr;
  
  iVar1 = *(int *)(in_GS_OFFSET + 0x14);
  __s = getenv("SSH_AUTH_SOCK");
  if ((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)) {
    iVar3 = socket(1,1,0);
    if (iVar3 < 0) {
      perror("socket(PF_UNIX)");
                    /* WARNING: Subroutine does not return */
      exit(1);
    }
    cloexec(iVar3);
    addr.sun_family = 1;
    __strcpy_chk(addr.sun_path,__s,0x6c);
    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);
    if (-1 < iVar4) {
      iVar4 = 0;
      if (0 < inlen) {
        do {
          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);
          if (sVar5 < 1) goto LAB_0007b872;
          iVar4 = iVar4 + sVar5;
        } while (iVar4 < inlen);
      }
      conn = (agent_pending_query *)safemalloc(1,0x1c);
      conn->fd = iVar3;
      conn->retbuf = conn->sizebuf;
      conn->retsize = 4;
      conn->retlen = 0;
      conn->callback = callback;
      conn->callback_ctx = callback_ctx;
      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {
        no_nonblock(iVar3);
        do {
          iVar3 = agent_try_read(conn);
        } while (iVar3 == 0);
        *out = conn->retbuf;
        *outlen = conn->retlen;
        paVar6 = (agent_pending_query *)0x0;
        safefree(conn);
      }
      else {
        if (agent_pending_queries == (tree234 *)0x0) {
          agent_pending_queries = newtree234(agent_conncmp);
        }
        add234(agent_pending_queries,conn);
        uxsel_set(iVar3,1,agent_select_result);
        paVar6 = conn;
      }
      goto LAB_0007b894;
    }
LAB_0007b872:
    close(iVar3);
  }
  paVar6 = (agent_pending_query *)0x0;
  *out = (void *)0x0;
  *outlen = 0;
LAB_0007b894:
  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    __stack_chk_fail_local();
  }
  return paVar6;
}



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

int * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)

{
  char *__s;
  size_t sVar1;
  int iVar2;
  int iVar3;
  ssize_t sVar4;
  int *piVar5;
  int *piVar6;
  int in_GS_OFFSET;
  sockaddr local_8e [6];
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x7b769;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  __s = getenv("SSH_AUTH_SOCK");
  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {
    iVar2 = socket(1,1,0);
    if (iVar2 < 0) {
      perror("socket(PF_UNIX)");
                    /* WARNING: Subroutine does not return */
      exit(1);
    }
    FUN_0007d310(iVar2);
    local_8e[0].sa_family = 1;
    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);
    iVar3 = connect(iVar2,local_8e,0x6e);
    if (-1 < iVar3) {
      iVar3 = 0;
      if (0 < param_2) {
        do {
          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);
          if (sVar4 < 1) goto LAB_0007b872;
          iVar3 = iVar3 + sVar4;
        } while (iVar3 < param_2);
      }
      piVar5 = (int *)FUN_0001fe90(1,0x1c);
      *piVar5 = iVar2;
      piVar5[1] = (int)(piVar5 + 2);
      piVar5[3] = 4;
      piVar5[4] = 0;
      piVar5[5] = param_5;
      piVar5[6] = param_6;
      if (param_5 == 0) {
        FUN_0007d4d0(iVar2);
        do {
          iVar2 = FUN_0007b510();
        } while (iVar2 == 0);
        *param_3 = piVar5[1];
        *param_4 = piVar5[4];
        piVar6 = (int *)0x0;
        FUN_00020030(piVar5);
      }
      else {
        if (DAT_000c79dc == 0) {
          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);
        }
        FUN_0007af60(DAT_000c79dc,piVar5);
        FUN_00083290(iVar2,1,FUN_0007b620);
        piVar6 = piVar5;
      }
      goto LAB_0007b894;
    }
LAB_0007b872:
    close(iVar2);
  }
  piVar6 = (int *)0x0;
  *param_3 = 0;
  *param_4 = 0;
LAB_0007b894:
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_00089270();
  }
  return piVar6;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00015ff0
ADD EBX,0x4b607
SUB ESP,0xb8
MOV EAX,dword ptr [ESP + 0xcc]
MOV ESI,dword ptr [ESP + 0xd0]
MOV dword ptr [ESP + 0x18],EAX
MOV EAX,dword ptr [ESP + 0xd4]
MOV dword ptr [ESP + 0x1c],EAX
MOV EAX,dword ptr [ESP + 0xd8]
MOV dword ptr [ESP + 0x20],EAX
MOV EAX,dword ptr [ESP + 0xdc]
MOV dword ptr [ESP + 0x24],EAX
MOV EAX,dword ptr [ESP + 0xe0]
MOV dword ptr [ESP + 0x28],EAX
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0xa8],EAX
XOR EAX,EAX
LEA EAX,[EBX + 0xfffd169c]
PUSH EAX
CALL 0x00014340
ADD ESP,0x10
TEST EAX,EAX
JZ 0x0007b87e
SUB ESP,0xc
MOV EBP,EAX
PUSH EAX
CALL 0x00014440
ADD ESP,0x10
CMP EAX,0x6b
JA 0x0007b87e
SUB ESP,0x4
PUSH 0x0
PUSH 0x1
PUSH 0x1
CALL 0x00014710
ADD ESP,0x10
MOV EDI,EAX
TEST EAX,EAX
JS 0x0007b97d
SUB ESP,0xc
PUSH EAX
CALL 0x0007d310
MOV EAX,0x1
MOV word ptr [ESP + 0x3e],AX
ADD ESP,0xc
PUSH 0x6c
PUSH EBP
LEA EAX,[ESP + 0x3c]
LEA EBP,[ESP + 0x3a]
PUSH EAX
CALL 0x000145f0
ADD ESP,0xc
PUSH 0x6e
PUSH EBP
PUSH EDI
CALL 0x000147f0
ADD ESP,0x10
TEST EAX,EAX
JS 0x0007b872
XOR EBP,EBP
TEST ESI,ESI
JG 0x0007b856
JMP 0x0007b8b8
ADD EBP,EAX
CMP ESI,EBP
JLE 0x0007b8b8
MOV EAX,ESI
SUB ESP,0x4
SUB EAX,EBP
PUSH EAX
MOV EAX,dword ptr [ESP + 0x14]
ADD EAX,EBP
PUSH EAX
PUSH EDI
CALL 0x00014460
ADD ESP,0x10
TEST EAX,EAX
JG 0x0007b850
SUB ESP,0xc
PUSH EDI
CALL 0x00014810
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x10]
XOR ESI,ESI
MOV dword ptr [EAX],0x0
MOV EAX,dword ptr [ESP + 0x14]
MOV dword ptr [EAX],0x0
MOV EDX,dword ptr [ESP + 0x9c]
XOR EDX,dword ptr GS:[0x14]
MOV EAX,ESI
JNZ 0x0007b978
ADD ESP,0xac
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0x8
PUSH 0x1c
PUSH 0x1
CALL 0x0001fe90
MOV ECX,dword ptr [ESP + 0x2c]
MOV dword ptr [EAX],EDI
MOV ESI,EAX
LEA EAX,[EAX + 0x8]
MOV dword ptr [ESI + 0x4],EAX
MOV EAX,dword ptr [ESP + 0x28]
ADD ESP,0x10
MOV dword ptr [ESI + 0xc],0x4
MOV dword ptr [ESI + 0x10],0x0
MOV dword ptr [ESI + 0x14],EAX
MOV dword ptr [ESI + 0x18],ECX
TEST EAX,EAX
JZ 0x0007b939
MOV EAX,dword ptr [EBX + 0xc6c]
TEST EAX,EAX
JZ 0x0007b91f
SUB ESP,0x8
PUSH ESI
PUSH EAX
CALL 0x0007af60
ADD ESP,0xc
LEA EAX,[EBX + 0xfffb48b0]
PUSH EAX
PUSH 0x1
PUSH EDI
CALL 0x00083290
ADD ESP,0x10
JMP 0x0007b894
SUB ESP,0xc
LEA EAX,[EBX + 0xfffb4760]
PUSH EAX
CALL 0x00077680
ADD ESP,0x10
MOV dword ptr [EBX + 0xc6c],EAX
JMP 0x0007b8fb
SUB ESP,0xc
PUSH EDI
CALL 0x0007d4d0
ADD ESP,0x10
LEA ESI,[ESI]
MOV EAX,ESI
CALL 0x0007b510
TEST EAX,EAX
JZ 0x0007b948
MOV EAX,dword ptr [ESI + 0x4]
MOV ECX,dword ptr [ESP + 0x10]
SUB ESP,0xc
MOV dword ptr [ECX],EAX
MOV ECX,dword ptr [ESP + 0x20]
MOV EAX,dword ptr [ESI + 0x10]
MOV dword ptr [ECX],EAX
PUSH ESI
XOR ESI,ESI
CALL 0x00020030
ADD ESP,0x10
JMP 0x0007b894
CALL 0x00089270
SUB ESP,0xc
LEA EAX,[EBX + 0xfffd16aa]
PUSH EAX
CALL 0x000142a0
MOV dword ptr [ESP],0x1
CALL 0x000143a0
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\n  }\n  return piVar6;\n}\n\n" comment (function_definition "int * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\n  }\n  return piVar6;\n}" primitive_type (pointer_declarator "* FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" * (function_declarator "FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" identifier (parameter_list "(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "int *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "int param_5" primitive_type identifier) , (parameter_declaration "int param_6" primitive_type identifier) )))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\n  }\n  return piVar6;\n}" { (declaration "char *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "ssize_t sVar4;" primitive_type identifier ;) (declaration "int *piVar5;" primitive_type (pointer_declarator "*piVar5" * identifier) ;) (declaration "int *piVar6;" primitive_type (pointer_declarator "*piVar6" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sockaddr local_8e [6];" type_identifier (array_declarator "local_8e [6]" identifier [ number_literal ]) ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x7b769;" (assignment_expression "uStack_14 = 0x7b769" 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) ))))) ;) (expression_statement "__s = getenv("SSH_AUTH_SOCK");" (assignment_expression "__s = getenv("SSH_AUTH_SOCK")" identifier = (call_expression "getenv("SSH_AUTH_SOCK")" identifier (argument_list "("SSH_AUTH_SOCK")" ( (string_literal ""SSH_AUTH_SOCK"" " string_content ") )))) ;) (if_statement "if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" if (parenthesized_expression "((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c))" ( (binary_expression "(__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)" (parenthesized_expression "(__s != (char *)0x0)" ( (binary_expression "__s != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(sVar1 = strlen(__s), sVar1 < 0x6c)" ( (comma_expression "sVar1 = strlen(__s), sVar1 < 0x6c" (assignment_expression "sVar1 = strlen(__s)" identifier = (call_expression "strlen(__s)" identifier (argument_list "(__s)" ( identifier )))) , (binary_expression "sVar1 < 0x6c" identifier < number_literal)) ))) )) (compound_statement "{\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" { (expression_statement "iVar2 = socket(1,1,0);" (assignment_expression "iVar2 = socket(1,1,0)" identifier = (call_expression "socket(1,1,0)" identifier (argument_list "(1,1,0)" ( number_literal , number_literal , number_literal )))) ;) (if_statement "if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }" { (expression_statement "perror("socket(PF_UNIX)");" (call_expression "perror("socket(PF_UNIX)")" identifier (argument_list "("socket(PF_UNIX)")" ( (string_literal ""socket(PF_UNIX)"" " string_content ") ))) ;) comment (expression_statement "exit(1);" (call_expression "exit(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })) (expression_statement "FUN_0007d310(iVar2);" (call_expression "FUN_0007d310(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "local_8e[0].sa_family = 1;" (assignment_expression "local_8e[0].sa_family = 1" (field_expression "local_8e[0].sa_family" (subscript_expression "local_8e[0]" identifier [ number_literal ]) . field_identifier) = number_literal) ;) (expression_statement "__strcpy_chk(local_8e[0].sa_data,__s,0x6c);" (call_expression "__strcpy_chk(local_8e[0].sa_data,__s,0x6c)" identifier (argument_list "(local_8e[0].sa_data,__s,0x6c)" ( (field_expression "local_8e[0].sa_data" (subscript_expression "local_8e[0]" identifier [ number_literal ]) . field_identifier) , identifier , number_literal ))) ;) (expression_statement "iVar3 = connect(iVar2,local_8e,0x6e);" (assignment_expression "iVar3 = connect(iVar2,local_8e,0x6e)" identifier = (call_expression "connect(iVar2,local_8e,0x6e)" identifier (argument_list "(iVar2,local_8e,0x6e)" ( identifier , identifier , number_literal )))) ;) (if_statement "if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" if (parenthesized_expression "(-1 < iVar3)" ( (binary_expression "-1 < iVar3" number_literal < identifier) )) (compound_statement "{\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (if_statement "if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" if (parenthesized_expression "(0 < param_2)" ( (binary_expression "0 < param_2" number_literal < identifier) )) (compound_statement "{\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" { (do_statement "do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);" do (compound_statement "{\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        }" { (expression_statement "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);" (assignment_expression "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" identifier = (call_expression "write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" identifier (argument_list "(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" ( identifier , (cast_expression "(void *)(param_1 + iVar3)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + iVar3)" ( (binary_expression "param_1 + iVar3" identifier + identifier) ))) , (binary_expression "param_2 - iVar3" identifier - identifier) )))) ;) (if_statement "if (sVar4 < 1) goto LAB_0007b872;" if (parenthesized_expression "(sVar4 < 1)" ( (binary_expression "sVar4 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0007b872;" goto statement_identifier ;)) (expression_statement "iVar3 = iVar3 + sVar4;" (assignment_expression "iVar3 = iVar3 + sVar4" identifier = (binary_expression "iVar3 + sVar4" identifier + identifier)) ;) }) while (parenthesized_expression "(iVar3 < param_2)" ( (binary_expression "iVar3 < param_2" identifier < identifier) )) ;) })) (expression_statement "piVar5 = (int *)FUN_0001fe90(1,0x1c);" (assignment_expression "piVar5 = (int *)FUN_0001fe90(1,0x1c)" identifier = (cast_expression "(int *)FUN_0001fe90(1,0x1c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001fe90(1,0x1c)" identifier (argument_list "(1,0x1c)" ( number_literal , number_literal ))))) ;) (expression_statement "*piVar5 = iVar2;" (assignment_expression "*piVar5 = iVar2" (pointer_expression "*piVar5" * identifier) = identifier) ;) (expression_statement "piVar5[1] = (int)(piVar5 + 2);" (assignment_expression "piVar5[1] = (int)(piVar5 + 2)" (subscript_expression "piVar5[1]" identifier [ number_literal ]) = (cast_expression "(int)(piVar5 + 2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(piVar5 + 2)" ( (binary_expression "piVar5 + 2" identifier + number_literal) )))) ;) (expression_statement "piVar5[3] = 4;" (assignment_expression "piVar5[3] = 4" (subscript_expression "piVar5[3]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "piVar5[4] = 0;" (assignment_expression "piVar5[4] = 0" (subscript_expression "piVar5[4]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "piVar5[5] = param_5;" (assignment_expression "piVar5[5] = param_5" (subscript_expression "piVar5[5]" identifier [ number_literal ]) = identifier) ;) (expression_statement "piVar5[6] = param_6;" (assignment_expression "piVar5[6] = param_6" (subscript_expression "piVar5[6]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" if (parenthesized_expression "(param_5 == 0)" ( (binary_expression "param_5 == 0" identifier == number_literal) )) (compound_statement "{\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }" { (expression_statement "FUN_0007d4d0(iVar2);" (call_expression "FUN_0007d4d0(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;) (do_statement "do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);" do (compound_statement "{\n          iVar2 = FUN_0007b510();\n        }" { (expression_statement "iVar2 = FUN_0007b510();" (assignment_expression "iVar2 = FUN_0007b510()" identifier = (call_expression "FUN_0007b510()" identifier (argument_list "()" ( )))) ;) }) while (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) ;) (expression_statement "*param_3 = piVar5[1];" (assignment_expression "*param_3 = piVar5[1]" (pointer_expression "*param_3" * identifier) = (subscript_expression "piVar5[1]" identifier [ number_literal ])) ;) (expression_statement "*param_4 = piVar5[4];" (assignment_expression "*param_4 = piVar5[4]" (pointer_expression "*param_4" * identifier) = (subscript_expression "piVar5[4]" identifier [ number_literal ])) ;) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" identifier = (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "FUN_00020030(piVar5);" (call_expression "FUN_00020030(piVar5)" identifier (argument_list "(piVar5)" ( identifier ))) ;) }) (else_clause "else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" else (compound_statement "{\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" { (if_statement "if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" if (parenthesized_expression "(DAT_000c79dc == 0)" ( (binary_expression "DAT_000c79dc == 0" identifier == number_literal) )) (compound_statement "{\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" { (expression_statement "DAT_000c79dc = FUN_00077680(FUN_0007b4d0);" (assignment_expression "DAT_000c79dc = FUN_00077680(FUN_0007b4d0)" identifier = (call_expression "FUN_00077680(FUN_0007b4d0)" identifier (argument_list "(FUN_0007b4d0)" ( identifier )))) ;) })) (expression_statement "FUN_0007af60(DAT_000c79dc,piVar5);" (call_expression "FUN_0007af60(DAT_000c79dc,piVar5)" identifier (argument_list "(DAT_000c79dc,piVar5)" ( identifier , identifier ))) ;) (expression_statement "FUN_00083290(iVar2,1,FUN_0007b620);" (call_expression "FUN_00083290(iVar2,1,FUN_0007b620)" identifier (argument_list "(iVar2,1,FUN_0007b620)" ( identifier , number_literal , identifier ))) ;) (expression_statement "piVar6 = piVar5;" (assignment_expression "piVar6 = piVar5" identifier = identifier) ;) }))) (goto_statement "goto LAB_0007b894;" goto statement_identifier ;) })) (labeled_statement "LAB_0007b872:\n    close(iVar2);" statement_identifier : (expression_statement "close(iVar2);" (call_expression "close(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;)) })) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" identifier = (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" * identifier) = number_literal) ;) (expression_statement "*param_4 = 0;" (assignment_expression "*param_4 = 0" (pointer_expression "*param_4" * identifier) = number_literal) ;) (labeled_statement "LAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\n  }" statement_identifier : (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\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                    /* WARNING: Subroutine does not return */\n    FUN_00089270();\n  }" { comment (expression_statement "FUN_00089270();" (call_expression "FUN_00089270()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return piVar6;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nagent_pending_query *\nagent_query(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,\n           void *callback_ctx)\n\n{\n  int iVar1;\n  char *__s;\n  size_t sVar2;\n  int iVar3;\n  int iVar4;\n  ssize_t sVar5;\n  agent_pending_query *conn;\n  agent_pending_query *paVar6;\n  int in_GS_OFFSET;\n  sockaddr_un addr;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)) {\n    iVar3 = socket(1,1,0);\n    if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    cloexec(iVar3);\n    addr.sun_family = 1;\n    __strcpy_chk(addr.sun_path,__s,0x6c);\n    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);\n    if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar3);\n  }\n  paVar6 = (agent_pending_query *)0x0;\n  *out = (void *)0x0;\n  *outlen = 0;\nLAB_0007b894:\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return paVar6;\n}\n\n" comment comment (function_definition "agent_pending_query *\nagent_query(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,\n           void *callback_ctx)\n\n{\n  int iVar1;\n  char *__s;\n  size_t sVar2;\n  int iVar3;\n  int iVar4;\n  ssize_t sVar5;\n  agent_pending_query *conn;\n  agent_pending_query *paVar6;\n  int in_GS_OFFSET;\n  sockaddr_un addr;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)) {\n    iVar3 = socket(1,1,0);\n    if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    cloexec(iVar3);\n    addr.sun_family = 1;\n    __strcpy_chk(addr.sun_path,__s,0x6c);\n    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);\n    if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar3);\n  }\n  paVar6 = (agent_pending_query *)0x0;\n  *out = (void *)0x0;\n  *outlen = 0;\nLAB_0007b894:\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return paVar6;\n}" type_identifier (pointer_declarator "*\nagent_query(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,\n           void *callback_ctx)" * (function_declarator "agent_query(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,\n           void *callback_ctx)" identifier (parameter_list "(void *in,int inlen,void **out,int *outlen,_func_void_void_ptr_void_ptr_int *callback,\n           void *callback_ctx)" ( (parameter_declaration "void *in" primitive_type (pointer_declarator "*in" * identifier)) , (parameter_declaration "int inlen" primitive_type identifier) , (parameter_declaration "void **out" primitive_type (pointer_declarator "**out" * (pointer_declarator "*out" * identifier))) , (parameter_declaration "int *outlen" primitive_type (pointer_declarator "*outlen" * identifier)) , (parameter_declaration "_func_void_void_ptr_void_ptr_int *callback" type_identifier (pointer_declarator "*callback" * identifier)) , (parameter_declaration "void *callback_ctx" primitive_type (pointer_declarator "*callback_ctx" * identifier)) )))) (compound_statement "{\n  int iVar1;\n  char *__s;\n  size_t sVar2;\n  int iVar3;\n  int iVar4;\n  ssize_t sVar5;\n  agent_pending_query *conn;\n  agent_pending_query *paVar6;\n  int in_GS_OFFSET;\n  sockaddr_un addr;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)) {\n    iVar3 = socket(1,1,0);\n    if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    cloexec(iVar3);\n    addr.sun_family = 1;\n    __strcpy_chk(addr.sun_path,__s,0x6c);\n    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);\n    if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar3);\n  }\n  paVar6 = (agent_pending_query *)0x0;\n  *out = (void *)0x0;\n  *outlen = 0;\nLAB_0007b894:\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return paVar6;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "char *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "size_t sVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "ssize_t sVar5;" primitive_type identifier ;) (declaration "agent_pending_query *conn;" type_identifier (pointer_declarator "*conn" * identifier) ;) (declaration "agent_pending_query *paVar6;" type_identifier (pointer_declarator "*paVar6" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sockaddr_un addr;" type_identifier identifier ;) (expression_statement "iVar1 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar1 = *(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) ))))) ;) (expression_statement "__s = getenv("SSH_AUTH_SOCK");" (assignment_expression "__s = getenv("SSH_AUTH_SOCK")" identifier = (call_expression "getenv("SSH_AUTH_SOCK")" identifier (argument_list "("SSH_AUTH_SOCK")" ( (string_literal ""SSH_AUTH_SOCK"" " string_content ") )))) ;) (if_statement "if ((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)) {\n    iVar3 = socket(1,1,0);\n    if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    cloexec(iVar3);\n    addr.sun_family = 1;\n    __strcpy_chk(addr.sun_path,__s,0x6c);\n    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);\n    if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar3);\n  }" if (parenthesized_expression "((__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c))" ( (binary_expression "(__s != (char *)0x0) && (sVar2 = strlen(__s), sVar2 < 0x6c)" (parenthesized_expression "(__s != (char *)0x0)" ( (binary_expression "__s != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(sVar2 = strlen(__s), sVar2 < 0x6c)" ( (comma_expression "sVar2 = strlen(__s), sVar2 < 0x6c" (assignment_expression "sVar2 = strlen(__s)" identifier = (call_expression "strlen(__s)" identifier (argument_list "(__s)" ( identifier )))) , (binary_expression "sVar2 < 0x6c" identifier < number_literal)) ))) )) (compound_statement "{\n    iVar3 = socket(1,1,0);\n    if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }\n    cloexec(iVar3);\n    addr.sun_family = 1;\n    __strcpy_chk(addr.sun_path,__s,0x6c);\n    iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);\n    if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar3);\n  }" { (expression_statement "iVar3 = socket(1,1,0);" (assignment_expression "iVar3 = socket(1,1,0)" identifier = (call_expression "socket(1,1,0)" identifier (argument_list "(1,1,0)" ( number_literal , number_literal , number_literal )))) ;) (if_statement "if (iVar3 < 0) {\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }" if (parenthesized_expression "(iVar3 < 0)" ( (binary_expression "iVar3 < 0" identifier < number_literal) )) (compound_statement "{\n      perror("socket(PF_UNIX)");\n                    /* WARNING: Subroutine does not return */\n      exit(1);\n    }" { (expression_statement "perror("socket(PF_UNIX)");" (call_expression "perror("socket(PF_UNIX)")" identifier (argument_list "("socket(PF_UNIX)")" ( (string_literal ""socket(PF_UNIX)"" " string_content ") ))) ;) comment (expression_statement "exit(1);" (call_expression "exit(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })) (expression_statement "cloexec(iVar3);" (call_expression "cloexec(iVar3)" identifier (argument_list "(iVar3)" ( identifier ))) ;) (expression_statement "addr.sun_family = 1;" (assignment_expression "addr.sun_family = 1" (field_expression "addr.sun_family" identifier . field_identifier) = number_literal) ;) (expression_statement "__strcpy_chk(addr.sun_path,__s,0x6c);" (call_expression "__strcpy_chk(addr.sun_path,__s,0x6c)" identifier (argument_list "(addr.sun_path,__s,0x6c)" ( (field_expression "addr.sun_path" identifier . field_identifier) , identifier , number_literal ))) ;) (expression_statement "iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e);" (assignment_expression "iVar4 = connect(iVar3,(sockaddr *)&addr,0x6e)" identifier = (call_expression "connect(iVar3,(sockaddr *)&addr,0x6e)" identifier (argument_list "(iVar3,(sockaddr *)&addr,0x6e)" ( identifier , (cast_expression "(sockaddr *)&addr" ( (type_descriptor "sockaddr *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&addr" & identifier)) , number_literal )))) ;) (if_statement "if (-1 < iVar4) {\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }" if (parenthesized_expression "(-1 < iVar4)" ( (binary_expression "-1 < iVar4" number_literal < identifier) )) (compound_statement "{\n      iVar4 = 0;\n      if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }\n      conn = (agent_pending_query *)safemalloc(1,0x1c);\n      conn->fd = iVar3;\n      conn->retbuf = conn->sizebuf;\n      conn->retsize = 4;\n      conn->retlen = 0;\n      conn->callback = callback;\n      conn->callback_ctx = callback_ctx;\n      if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }\n      goto LAB_0007b894;\n    }" { (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (if_statement "if (0 < inlen) {\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }" if (parenthesized_expression "(0 < inlen)" ( (binary_expression "0 < inlen" number_literal < identifier) )) (compound_statement "{\n        do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);\n      }" { (do_statement "do {\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        } while (iVar4 < inlen);" do (compound_statement "{\n          sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);\n          if (sVar5 < 1) goto LAB_0007b872;\n          iVar4 = iVar4 + sVar5;\n        }" { (expression_statement "sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4);" (assignment_expression "sVar5 = write(iVar3,(void *)((int)in + iVar4),inlen - iVar4)" identifier = (call_expression "write(iVar3,(void *)((int)in + iVar4),inlen - iVar4)" identifier (argument_list "(iVar3,(void *)((int)in + iVar4),inlen - iVar4)" ( identifier , (cast_expression "(void *)((int)in + iVar4)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)in + iVar4)" ( (binary_expression "(int)in + iVar4" (cast_expression "(int)in" ( (type_descriptor "int" primitive_type) ) identifier) + identifier) ))) , (binary_expression "inlen - iVar4" identifier - identifier) )))) ;) (if_statement "if (sVar5 < 1) goto LAB_0007b872;" if (parenthesized_expression "(sVar5 < 1)" ( (binary_expression "sVar5 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0007b872;" goto statement_identifier ;)) (expression_statement "iVar4 = iVar4 + sVar5;" (assignment_expression "iVar4 = iVar4 + sVar5" identifier = (binary_expression "iVar4 + sVar5" identifier + identifier)) ;) }) while (parenthesized_expression "(iVar4 < inlen)" ( (binary_expression "iVar4 < inlen" identifier < identifier) )) ;) })) (expression_statement "conn = (agent_pending_query *)safemalloc(1,0x1c);" (assignment_expression "conn = (agent_pending_query *)safemalloc(1,0x1c)" identifier = (cast_expression "(agent_pending_query *)safemalloc(1,0x1c)" ( (type_descriptor "agent_pending_query *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "safemalloc(1,0x1c)" identifier (argument_list "(1,0x1c)" ( number_literal , number_literal ))))) ;) (expression_statement "conn->fd = iVar3;" (assignment_expression "conn->fd = iVar3" (field_expression "conn->fd" identifier -> field_identifier) = identifier) ;) (expression_statement "conn->retbuf = conn->sizebuf;" (assignment_expression "conn->retbuf = conn->sizebuf" (field_expression "conn->retbuf" identifier -> field_identifier) = (field_expression "conn->sizebuf" identifier -> field_identifier)) ;) (expression_statement "conn->retsize = 4;" (assignment_expression "conn->retsize = 4" (field_expression "conn->retsize" identifier -> field_identifier) = number_literal) ;) (expression_statement "conn->retlen = 0;" (assignment_expression "conn->retlen = 0" (field_expression "conn->retlen" identifier -> field_identifier) = number_literal) ;) (expression_statement "conn->callback = callback;" (assignment_expression "conn->callback = callback" (field_expression "conn->callback" identifier -> field_identifier) = identifier) ;) (expression_statement "conn->callback_ctx = callback_ctx;" (assignment_expression "conn->callback_ctx = callback_ctx" (field_expression "conn->callback_ctx" identifier -> field_identifier) = identifier) ;) (if_statement "if (callback == (_func_void_void_ptr_void_ptr_int *)0x0) {\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }\n      else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }" if (parenthesized_expression "(callback == (_func_void_void_ptr_void_ptr_int *)0x0)" ( (binary_expression "callback == (_func_void_void_ptr_void_ptr_int *)0x0" identifier == (cast_expression "(_func_void_void_ptr_void_ptr_int *)0x0" ( (type_descriptor "_func_void_void_ptr_void_ptr_int *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        no_nonblock(iVar3);\n        do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);\n        *out = conn->retbuf;\n        *outlen = conn->retlen;\n        paVar6 = (agent_pending_query *)0x0;\n        safefree(conn);\n      }" { (expression_statement "no_nonblock(iVar3);" (call_expression "no_nonblock(iVar3)" identifier (argument_list "(iVar3)" ( identifier ))) ;) (do_statement "do {\n          iVar3 = agent_try_read(conn);\n        } while (iVar3 == 0);" do (compound_statement "{\n          iVar3 = agent_try_read(conn);\n        }" { (expression_statement "iVar3 = agent_try_read(conn);" (assignment_expression "iVar3 = agent_try_read(conn)" identifier = (call_expression "agent_try_read(conn)" identifier (argument_list "(conn)" ( identifier )))) ;) }) while (parenthesized_expression "(iVar3 == 0)" ( (binary_expression "iVar3 == 0" identifier == number_literal) )) ;) (expression_statement "*out = conn->retbuf;" (assignment_expression "*out = conn->retbuf" (pointer_expression "*out" * identifier) = (field_expression "conn->retbuf" identifier -> field_identifier)) ;) (expression_statement "*outlen = conn->retlen;" (assignment_expression "*outlen = conn->retlen" (pointer_expression "*outlen" * identifier) = (field_expression "conn->retlen" identifier -> field_identifier)) ;) (expression_statement "paVar6 = (agent_pending_query *)0x0;" (assignment_expression "paVar6 = (agent_pending_query *)0x0" identifier = (cast_expression "(agent_pending_query *)0x0" ( (type_descriptor "agent_pending_query *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "safefree(conn);" (call_expression "safefree(conn)" identifier (argument_list "(conn)" ( identifier ))) ;) }) (else_clause "else {\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }" else (compound_statement "{\n        if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }\n        add234(agent_pending_queries,conn);\n        uxsel_set(iVar3,1,agent_select_result);\n        paVar6 = conn;\n      }" { (if_statement "if (agent_pending_queries == (tree234 *)0x0) {\n          agent_pending_queries = newtree234(agent_conncmp);\n        }" if (parenthesized_expression "(agent_pending_queries == (tree234 *)0x0)" ( (binary_expression "agent_pending_queries == (tree234 *)0x0" identifier == (cast_expression "(tree234 *)0x0" ( (type_descriptor "tree234 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          agent_pending_queries = newtree234(agent_conncmp);\n        }" { (expression_statement "agent_pending_queries = newtree234(agent_conncmp);" (assignment_expression "agent_pending_queries = newtree234(agent_conncmp)" identifier = (call_expression "newtree234(agent_conncmp)" identifier (argument_list "(agent_conncmp)" ( identifier )))) ;) })) (expression_statement "add234(agent_pending_queries,conn);" (call_expression "add234(agent_pending_queries,conn)" identifier (argument_list "(agent_pending_queries,conn)" ( identifier , identifier ))) ;) (expression_statement "uxsel_set(iVar3,1,agent_select_result);" (call_expression "uxsel_set(iVar3,1,agent_select_result)" identifier (argument_list "(iVar3,1,agent_select_result)" ( identifier , number_literal , identifier ))) ;) (expression_statement "paVar6 = conn;" (assignment_expression "paVar6 = conn" identifier = identifier) ;) }))) (goto_statement "goto LAB_0007b894;" goto statement_identifier ;) })) (labeled_statement "LAB_0007b872:\n    close(iVar3);" statement_identifier : (expression_statement "close(iVar3);" (call_expression "close(iVar3)" identifier (argument_list "(iVar3)" ( identifier ))) ;)) })) (expression_statement "paVar6 = (agent_pending_query *)0x0;" (assignment_expression "paVar6 = (agent_pending_query *)0x0" identifier = (cast_expression "(agent_pending_query *)0x0" ( (type_descriptor "agent_pending_query *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "*out = (void *)0x0;" (assignment_expression "*out = (void *)0x0" (pointer_expression "*out" * identifier) = (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "*outlen = 0;" (assignment_expression "*outlen = 0" (pointer_expression "*outlen" * identifier) = number_literal) ;) (labeled_statement "LAB_0007b894:\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" statement_identifier : (if_statement "if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" if (parenthesized_expression "(iVar1 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar1 != *(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                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" { comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return paVar6;" return identifier ;) })))
(translation_unit "int * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }\n  return piVar6;\n}\n\n" (function_definition "int * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }\n  return piVar6;\n}" primitive_type (pointer_declarator "* FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" * (function_declarator "FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" identifier (parameter_list "(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "int *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "int param_5" primitive_type identifier) , (parameter_declaration "int param_6" primitive_type identifier) )))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }\n  return piVar6;\n}" { (declaration "char *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "ssize_t sVar4;" primitive_type identifier ;) (declaration "int *piVar5;" primitive_type (pointer_declarator "*piVar5" * identifier) ;) (declaration "int *piVar6;" primitive_type (pointer_declarator "*piVar6" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sockaddr local_8e [6];" type_identifier (array_declarator "local_8e [6]" identifier [ number_literal ]) ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x7b769;" (assignment_expression "uStack_14 = 0x7b769" 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) ))))) ;) (expression_statement "__s = getenv("SSH_AUTH_SOCK");" (assignment_expression "__s = getenv("SSH_AUTH_SOCK")" identifier = (call_expression "getenv("SSH_AUTH_SOCK")" identifier (argument_list "("SSH_AUTH_SOCK")" ( (string_literal ""SSH_AUTH_SOCK"" " string_content ") )))) ;) (if_statement "if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" if (parenthesized_expression "((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c))" ( (binary_expression "(__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)" (parenthesized_expression "(__s != (char *)0x0)" ( (binary_expression "__s != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(sVar1 = strlen(__s), sVar1 < 0x6c)" ( (comma_expression "sVar1 = strlen(__s), sVar1 < 0x6c" (assignment_expression "sVar1 = strlen(__s)" identifier = (call_expression "strlen(__s)" identifier (argument_list "(__s)" ( identifier )))) , (binary_expression "sVar1 < 0x6c" identifier < number_literal)) ))) )) (compound_statement "{\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" { (expression_statement "iVar2 = socket(1,1,0);" (assignment_expression "iVar2 = socket(1,1,0)" identifier = (call_expression "socket(1,1,0)" identifier (argument_list "(1,1,0)" ( number_literal , number_literal , number_literal )))) ;) (if_statement "if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }" { (expression_statement "perror("socket(PF_UNIX)");" (call_expression "perror("socket(PF_UNIX)")" identifier (argument_list "("socket(PF_UNIX)")" ( (string_literal ""socket(PF_UNIX)"" " string_content ") ))) ;) (expression_statement "exit(1);" (call_expression "exit(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })) (expression_statement "FUN_0007d310(iVar2);" (call_expression "FUN_0007d310(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "local_8e[0].sa_family = 1;" (assignment_expression "local_8e[0].sa_family = 1" (field_expression "local_8e[0].sa_family" (subscript_expression "local_8e[0]" identifier [ number_literal ]) . field_identifier) = number_literal) ;) (expression_statement "__strcpy_chk(local_8e[0].sa_data,__s,0x6c);" (call_expression "__strcpy_chk(local_8e[0].sa_data,__s,0x6c)" identifier (argument_list "(local_8e[0].sa_data,__s,0x6c)" ( (field_expression "local_8e[0].sa_data" (subscript_expression "local_8e[0]" identifier [ number_literal ]) . field_identifier) , identifier , number_literal ))) ;) (expression_statement "iVar3 = connect(iVar2,local_8e,0x6e);" (assignment_expression "iVar3 = connect(iVar2,local_8e,0x6e)" identifier = (call_expression "connect(iVar2,local_8e,0x6e)" identifier (argument_list "(iVar2,local_8e,0x6e)" ( identifier , identifier , number_literal )))) ;) (if_statement "if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" if (parenthesized_expression "(-1 < iVar3)" ( (binary_expression "-1 < iVar3" number_literal < identifier) )) (compound_statement "{\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (if_statement "if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" if (parenthesized_expression "(0 < param_2)" ( (binary_expression "0 < param_2" number_literal < identifier) )) (compound_statement "{\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" { (do_statement "do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);" do (compound_statement "{\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        }" { (expression_statement "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);" (assignment_expression "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" identifier = (call_expression "write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" identifier (argument_list "(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" ( identifier , (cast_expression "(void *)(param_1 + iVar3)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + iVar3)" ( (binary_expression "param_1 + iVar3" identifier + identifier) ))) , (binary_expression "param_2 - iVar3" identifier - identifier) )))) ;) (if_statement "if (sVar4 < 1) goto LAB_0007b872;" if (parenthesized_expression "(sVar4 < 1)" ( (binary_expression "sVar4 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0007b872;" goto statement_identifier ;)) (expression_statement "iVar3 = iVar3 + sVar4;" (assignment_expression "iVar3 = iVar3 + sVar4" identifier = (binary_expression "iVar3 + sVar4" identifier + identifier)) ;) }) while (parenthesized_expression "(iVar3 < param_2)" ( (binary_expression "iVar3 < param_2" identifier < identifier) )) ;) })) (expression_statement "piVar5 = (int *)FUN_0001fe90(1,0x1c);" (assignment_expression "piVar5 = (int *)FUN_0001fe90(1,0x1c)" identifier = (cast_expression "(int *)FUN_0001fe90(1,0x1c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001fe90(1,0x1c)" identifier (argument_list "(1,0x1c)" ( number_literal , number_literal ))))) ;) (expression_statement "*piVar5 = iVar2;" (assignment_expression "*piVar5 = iVar2" (pointer_expression "*piVar5" * identifier) = identifier) ;) (expression_statement "piVar5[1] = (int)(piVar5 + 2);" (assignment_expression "piVar5[1] = (int)(piVar5 + 2)" (subscript_expression "piVar5[1]" identifier [ number_literal ]) = (cast_expression "(int)(piVar5 + 2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(piVar5 + 2)" ( (binary_expression "piVar5 + 2" identifier + number_literal) )))) ;) (expression_statement "piVar5[3] = 4;" (assignment_expression "piVar5[3] = 4" (subscript_expression "piVar5[3]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "piVar5[4] = 0;" (assignment_expression "piVar5[4] = 0" (subscript_expression "piVar5[4]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "piVar5[5] = param_5;" (assignment_expression "piVar5[5] = param_5" (subscript_expression "piVar5[5]" identifier [ number_literal ]) = identifier) ;) (expression_statement "piVar5[6] = param_6;" (assignment_expression "piVar5[6] = param_6" (subscript_expression "piVar5[6]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" if (parenthesized_expression "(param_5 == 0)" ( (binary_expression "param_5 == 0" identifier == number_literal) )) (compound_statement "{\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }" { (expression_statement "FUN_0007d4d0(iVar2);" (call_expression "FUN_0007d4d0(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;) (do_statement "do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);" do (compound_statement "{\n          iVar2 = FUN_0007b510();\n        }" { (expression_statement "iVar2 = FUN_0007b510();" (assignment_expression "iVar2 = FUN_0007b510()" identifier = (call_expression "FUN_0007b510()" identifier (argument_list "()" ( )))) ;) }) while (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) ;) (expression_statement "*param_3 = piVar5[1];" (assignment_expression "*param_3 = piVar5[1]" (pointer_expression "*param_3" * identifier) = (subscript_expression "piVar5[1]" identifier [ number_literal ])) ;) (expression_statement "*param_4 = piVar5[4];" (assignment_expression "*param_4 = piVar5[4]" (pointer_expression "*param_4" * identifier) = (subscript_expression "piVar5[4]" identifier [ number_literal ])) ;) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" identifier = (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "FUN_00020030(piVar5);" (call_expression "FUN_00020030(piVar5)" identifier (argument_list "(piVar5)" ( identifier ))) ;) }) (else_clause "else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" else (compound_statement "{\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" { (if_statement "if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" if (parenthesized_expression "(DAT_000c79dc == 0)" ( (binary_expression "DAT_000c79dc == 0" identifier == number_literal) )) (compound_statement "{\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" { (expression_statement "DAT_000c79dc = FUN_00077680(FUN_0007b4d0);" (assignment_expression "DAT_000c79dc = FUN_00077680(FUN_0007b4d0)" identifier = (call_expression "FUN_00077680(FUN_0007b4d0)" identifier (argument_list "(FUN_0007b4d0)" ( identifier )))) ;) })) (expression_statement "FUN_0007af60(DAT_000c79dc,piVar5);" (call_expression "FUN_0007af60(DAT_000c79dc,piVar5)" identifier (argument_list "(DAT_000c79dc,piVar5)" ( identifier , identifier ))) ;) (expression_statement "FUN_00083290(iVar2,1,FUN_0007b620);" (call_expression "FUN_00083290(iVar2,1,FUN_0007b620)" identifier (argument_list "(iVar2,1,FUN_0007b620)" ( identifier , number_literal , identifier ))) ;) (expression_statement "piVar6 = piVar5;" (assignment_expression "piVar6 = piVar5" identifier = identifier) ;) }))) (goto_statement "goto LAB_0007b894;" goto statement_identifier ;) })) (labeled_statement "LAB_0007b872:\n    close(iVar2);" statement_identifier : (expression_statement "close(iVar2);" (call_expression "close(iVar2)" identifier (argument_list "(iVar2)" ( identifier ))) ;)) })) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" identifier = (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" * identifier) = number_literal) ;) (expression_statement "*param_4 = 0;" (assignment_expression "*param_4 = 0" (pointer_expression "*param_4" * identifier) = number_literal) ;) (labeled_statement "LAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }" statement_identifier : (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\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                    \n    FUN_00089270();\n  }" { (expression_statement "FUN_00089270();" (call_expression "FUN_00089270()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return piVar6;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) )))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (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 *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (string_literal " string_content ") )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) , (binary_expression IDENT < LIT)) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , LIT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (string_literal " string_content ") ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT ))) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) , IDENT , LIT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) ))) , (binary_expression IDENT - IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT , LIT ))))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) }) while (parenthesized_expression ( (binary_expression IDENT == LIT) )) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }))) (goto_statement goto statement_identifier ;) })) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;)) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (labeled_statement statement_identifier : (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 { (expression_statement (call_expression IDENT (argument_list ( ))) ;) }))) (return_statement return IDENT ;) })))
(function_definition "int * FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }\n  return piVar6;\n}" (primitive_type "int") (pointer_declarator "* FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" (* "*") (function_declarator "FUN_0007b760(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" (identifier "FUN_0007b760") (parameter_list "(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) (, ",") (parameter_declaration "int *param_3" (primitive_type "int") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) (, ",") (parameter_declaration "int *param_4" (primitive_type "int") (pointer_declarator "*param_4" (* "*") (identifier "param_4"))) (, ",") (parameter_declaration "int param_5" (primitive_type "int") (identifier "param_5")) (, ",") (parameter_declaration "int param_6" (primitive_type "int") (identifier "param_6")) () ")")))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int iVar3;\n  ssize_t sVar4;\n  int *piVar5;\n  int *piVar6;\n  int in_GS_OFFSET;\n  sockaddr local_8e [6];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x7b769;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  __s = getenv("SSH_AUTH_SOCK");\n  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }\n  piVar6 = (int *)0x0;\n  *param_3 = 0;\n  *param_4 = 0;\nLAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }\n  return piVar6;\n}" ({ "{") (declaration "char *__s;" (primitive_type "char") (pointer_declarator "*__s" (* "*") (identifier "__s")) (; ";")) (declaration "size_t sVar1;" (primitive_type "size_t") (identifier "sVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "ssize_t sVar4;" (primitive_type "ssize_t") (identifier "sVar4") (; ";")) (declaration "int *piVar5;" (primitive_type "int") (pointer_declarator "*piVar5" (* "*") (identifier "piVar5")) (; ";")) (declaration "int *piVar6;" (primitive_type "int") (pointer_declarator "*piVar6" (* "*") (identifier "piVar6")) (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "sockaddr local_8e [6];" (type_identifier "sockaddr") (array_declarator "local_8e [6]" (identifier "local_8e") ([ "[") (number_literal "6") (] "]")) (; ";")) (declaration "int local_20;" (primitive_type "int") (identifier "local_20") (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x7b769;" (assignment_expression "uStack_14 = 0x7b769" (identifier "uStack_14") (= "=") (number_literal "0x7b769")) (; ";")) (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")) () ")"))))) (; ";")) (expression_statement "__s = getenv("SSH_AUTH_SOCK");" (assignment_expression "__s = getenv("SSH_AUTH_SOCK")" (identifier "__s") (= "=") (call_expression "getenv("SSH_AUTH_SOCK")" (identifier "getenv") (argument_list "("SSH_AUTH_SOCK")" (( "(") (string_literal ""SSH_AUTH_SOCK"" (" """) (string_content "SSH_AUTH_SOCK") (" """)) () ")")))) (; ";")) (if_statement "if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" (if "if") (parenthesized_expression "((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c))" (( "(") (binary_expression "(__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)" (parenthesized_expression "(__s != (char *)0x0)" (( "(") (binary_expression "__s != (char *)0x0" (identifier "__s") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(sVar1 = strlen(__s), sVar1 < 0x6c)" (( "(") (comma_expression "sVar1 = strlen(__s), sVar1 < 0x6c" (assignment_expression "sVar1 = strlen(__s)" (identifier "sVar1") (= "=") (call_expression "strlen(__s)" (identifier "strlen") (argument_list "(__s)" (( "(") (identifier "__s") () ")")))) (, ",") (binary_expression "sVar1 < 0x6c" (identifier "sVar1") (< "<") (number_literal "0x6c"))) () ")"))) () ")")) (compound_statement "{\n    iVar2 = socket(1,1,0);\n    if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }\n    FUN_0007d310(iVar2);\n    local_8e[0].sa_family = 1;\n    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);\n    iVar3 = connect(iVar2,local_8e,0x6e);\n    if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }\nLAB_0007b872:\n    close(iVar2);\n  }" ({ "{") (expression_statement "iVar2 = socket(1,1,0);" (assignment_expression "iVar2 = socket(1,1,0)" (identifier "iVar2") (= "=") (call_expression "socket(1,1,0)" (identifier "socket") (argument_list "(1,1,0)" (( "(") (number_literal "1") (, ",") (number_literal "1") (, ",") (number_literal "0") () ")")))) (; ";")) (if_statement "if (iVar2 < 0) {\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }" (if "if") (parenthesized_expression "(iVar2 < 0)" (( "(") (binary_expression "iVar2 < 0" (identifier "iVar2") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n      perror("socket(PF_UNIX)");\n                    \n      exit(1);\n    }" ({ "{") (expression_statement "perror("socket(PF_UNIX)");" (call_expression "perror("socket(PF_UNIX)")" (identifier "perror") (argument_list "("socket(PF_UNIX)")" (( "(") (string_literal ""socket(PF_UNIX)"" (" """) (string_content "socket(PF_UNIX)") (" """)) () ")"))) (; ";")) (expression_statement "exit(1);" (call_expression "exit(1)" (identifier "exit") (argument_list "(1)" (( "(") (number_literal "1") () ")"))) (; ";")) (} "}"))) (expression_statement "FUN_0007d310(iVar2);" (call_expression "FUN_0007d310(iVar2)" (identifier "FUN_0007d310") (argument_list "(iVar2)" (( "(") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "local_8e[0].sa_family = 1;" (assignment_expression "local_8e[0].sa_family = 1" (field_expression "local_8e[0].sa_family" (subscript_expression "local_8e[0]" (identifier "local_8e") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "sa_family")) (= "=") (number_literal "1")) (; ";")) (expression_statement "__strcpy_chk(local_8e[0].sa_data,__s,0x6c);" (call_expression "__strcpy_chk(local_8e[0].sa_data,__s,0x6c)" (identifier "__strcpy_chk") (argument_list "(local_8e[0].sa_data,__s,0x6c)" (( "(") (field_expression "local_8e[0].sa_data" (subscript_expression "local_8e[0]" (identifier "local_8e") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "sa_data")) (, ",") (identifier "__s") (, ",") (number_literal "0x6c") () ")"))) (; ";")) (expression_statement "iVar3 = connect(iVar2,local_8e,0x6e);" (assignment_expression "iVar3 = connect(iVar2,local_8e,0x6e)" (identifier "iVar3") (= "=") (call_expression "connect(iVar2,local_8e,0x6e)" (identifier "connect") (argument_list "(iVar2,local_8e,0x6e)" (( "(") (identifier "iVar2") (, ",") (identifier "local_8e") (, ",") (number_literal "0x6e") () ")")))) (; ";")) (if_statement "if (-1 < iVar3) {\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" (if "if") (parenthesized_expression "(-1 < iVar3)" (( "(") (binary_expression "-1 < iVar3" (number_literal "-1") (< "<") (identifier "iVar3")) () ")")) (compound_statement "{\n      iVar3 = 0;\n      if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }\n      piVar5 = (int *)FUN_0001fe90(1,0x1c);\n      *piVar5 = iVar2;\n      piVar5[1] = (int)(piVar5 + 2);\n      piVar5[3] = 4;\n      piVar5[4] = 0;\n      piVar5[5] = param_5;\n      piVar5[6] = param_6;\n      if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }\n      goto LAB_0007b894;\n    }" ({ "{") (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (if_statement "if (0 < param_2) {\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" (if "if") (parenthesized_expression "(0 < param_2)" (( "(") (binary_expression "0 < param_2" (number_literal "0") (< "<") (identifier "param_2")) () ")")) (compound_statement "{\n        do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);\n      }" ({ "{") (do_statement "do {\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        } while (iVar3 < param_2);" (do "do") (compound_statement "{\n          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);\n          if (sVar4 < 1) goto LAB_0007b872;\n          iVar3 = iVar3 + sVar4;\n        }" ({ "{") (expression_statement "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);" (assignment_expression "sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" (identifier "sVar4") (= "=") (call_expression "write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" (identifier "write") (argument_list "(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3)" (( "(") (identifier "iVar2") (, ",") (cast_expression "(void *)(param_1 + iVar3)" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + iVar3)" (( "(") (binary_expression "param_1 + iVar3" (identifier "param_1") (+ "+") (identifier "iVar3")) () ")"))) (, ",") (binary_expression "param_2 - iVar3" (identifier "param_2") (- "-") (identifier "iVar3")) () ")")))) (; ";")) (if_statement "if (sVar4 < 1) goto LAB_0007b872;" (if "if") (parenthesized_expression "(sVar4 < 1)" (( "(") (binary_expression "sVar4 < 1" (identifier "sVar4") (< "<") (number_literal "1")) () ")")) (goto_statement "goto LAB_0007b872;" (goto "goto") (statement_identifier "LAB_0007b872") (; ";"))) (expression_statement "iVar3 = iVar3 + sVar4;" (assignment_expression "iVar3 = iVar3 + sVar4" (identifier "iVar3") (= "=") (binary_expression "iVar3 + sVar4" (identifier "iVar3") (+ "+") (identifier "sVar4"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar3 < param_2)" (( "(") (binary_expression "iVar3 < param_2" (identifier "iVar3") (< "<") (identifier "param_2")) () ")")) (; ";")) (} "}"))) (expression_statement "piVar5 = (int *)FUN_0001fe90(1,0x1c);" (assignment_expression "piVar5 = (int *)FUN_0001fe90(1,0x1c)" (identifier "piVar5") (= "=") (cast_expression "(int *)FUN_0001fe90(1,0x1c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0001fe90(1,0x1c)" (identifier "FUN_0001fe90") (argument_list "(1,0x1c)" (( "(") (number_literal "1") (, ",") (number_literal "0x1c") () ")"))))) (; ";")) (expression_statement "*piVar5 = iVar2;" (assignment_expression "*piVar5 = iVar2" (pointer_expression "*piVar5" (* "*") (identifier "piVar5")) (= "=") (identifier "iVar2")) (; ";")) (expression_statement "piVar5[1] = (int)(piVar5 + 2);" (assignment_expression "piVar5[1] = (int)(piVar5 + 2)" (subscript_expression "piVar5[1]" (identifier "piVar5") ([ "[") (number_literal "1") (] "]")) (= "=") (cast_expression "(int)(piVar5 + 2)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(piVar5 + 2)" (( "(") (binary_expression "piVar5 + 2" (identifier "piVar5") (+ "+") (number_literal "2")) () ")")))) (; ";")) (expression_statement "piVar5[3] = 4;" (assignment_expression "piVar5[3] = 4" (subscript_expression "piVar5[3]" (identifier "piVar5") ([ "[") (number_literal "3") (] "]")) (= "=") (number_literal "4")) (; ";")) (expression_statement "piVar5[4] = 0;" (assignment_expression "piVar5[4] = 0" (subscript_expression "piVar5[4]" (identifier "piVar5") ([ "[") (number_literal "4") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "piVar5[5] = param_5;" (assignment_expression "piVar5[5] = param_5" (subscript_expression "piVar5[5]" (identifier "piVar5") ([ "[") (number_literal "5") (] "]")) (= "=") (identifier "param_5")) (; ";")) (expression_statement "piVar5[6] = param_6;" (assignment_expression "piVar5[6] = param_6" (subscript_expression "piVar5[6]" (identifier "piVar5") ([ "[") (number_literal "6") (] "]")) (= "=") (identifier "param_6")) (; ";")) (if_statement "if (param_5 == 0) {\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }\n      else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" (if "if") (parenthesized_expression "(param_5 == 0)" (( "(") (binary_expression "param_5 == 0" (identifier "param_5") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        FUN_0007d4d0(iVar2);\n        do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);\n        *param_3 = piVar5[1];\n        *param_4 = piVar5[4];\n        piVar6 = (int *)0x0;\n        FUN_00020030(piVar5);\n      }" ({ "{") (expression_statement "FUN_0007d4d0(iVar2);" (call_expression "FUN_0007d4d0(iVar2)" (identifier "FUN_0007d4d0") (argument_list "(iVar2)" (( "(") (identifier "iVar2") () ")"))) (; ";")) (do_statement "do {\n          iVar2 = FUN_0007b510();\n        } while (iVar2 == 0);" (do "do") (compound_statement "{\n          iVar2 = FUN_0007b510();\n        }" ({ "{") (expression_statement "iVar2 = FUN_0007b510();" (assignment_expression "iVar2 = FUN_0007b510()" (identifier "iVar2") (= "=") (call_expression "FUN_0007b510()" (identifier "FUN_0007b510") (argument_list "()" (( "(") () ")")))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (; ";")) (expression_statement "*param_3 = piVar5[1];" (assignment_expression "*param_3 = piVar5[1]" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (= "=") (subscript_expression "piVar5[1]" (identifier "piVar5") ([ "[") (number_literal "1") (] "]"))) (; ";")) (expression_statement "*param_4 = piVar5[4];" (assignment_expression "*param_4 = piVar5[4]" (pointer_expression "*param_4" (* "*") (identifier "param_4")) (= "=") (subscript_expression "piVar5[4]" (identifier "piVar5") ([ "[") (number_literal "4") (] "]"))) (; ";")) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" (identifier "piVar6") (= "=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "FUN_00020030(piVar5);" (call_expression "FUN_00020030(piVar5)" (identifier "FUN_00020030") (argument_list "(piVar5)" (( "(") (identifier "piVar5") () ")"))) (; ";")) (} "}")) (else_clause "else {\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" (else "else") (compound_statement "{\n        if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }\n        FUN_0007af60(DAT_000c79dc,piVar5);\n        FUN_00083290(iVar2,1,FUN_0007b620);\n        piVar6 = piVar5;\n      }" ({ "{") (if_statement "if (DAT_000c79dc == 0) {\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" (if "if") (parenthesized_expression "(DAT_000c79dc == 0)" (( "(") (binary_expression "DAT_000c79dc == 0" (identifier "DAT_000c79dc") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);\n        }" ({ "{") (expression_statement "DAT_000c79dc = FUN_00077680(FUN_0007b4d0);" (assignment_expression "DAT_000c79dc = FUN_00077680(FUN_0007b4d0)" (identifier "DAT_000c79dc") (= "=") (call_expression "FUN_00077680(FUN_0007b4d0)" (identifier "FUN_00077680") (argument_list "(FUN_0007b4d0)" (( "(") (identifier "FUN_0007b4d0") () ")")))) (; ";")) (} "}"))) (expression_statement "FUN_0007af60(DAT_000c79dc,piVar5);" (call_expression "FUN_0007af60(DAT_000c79dc,piVar5)" (identifier "FUN_0007af60") (argument_list "(DAT_000c79dc,piVar5)" (( "(") (identifier "DAT_000c79dc") (, ",") (identifier "piVar5") () ")"))) (; ";")) (expression_statement "FUN_00083290(iVar2,1,FUN_0007b620);" (call_expression "FUN_00083290(iVar2,1,FUN_0007b620)" (identifier "FUN_00083290") (argument_list "(iVar2,1,FUN_0007b620)" (( "(") (identifier "iVar2") (, ",") (number_literal "1") (, ",") (identifier "FUN_0007b620") () ")"))) (; ";")) (expression_statement "piVar6 = piVar5;" (assignment_expression "piVar6 = piVar5" (identifier "piVar6") (= "=") (identifier "piVar5")) (; ";")) (} "}")))) (goto_statement "goto LAB_0007b894;" (goto "goto") (statement_identifier "LAB_0007b894") (; ";")) (} "}"))) (labeled_statement "LAB_0007b872:\n    close(iVar2);" (statement_identifier "LAB_0007b872") (: ":") (expression_statement "close(iVar2);" (call_expression "close(iVar2)" (identifier "close") (argument_list "(iVar2)" (( "(") (identifier "iVar2") () ")"))) (; ";"))) (} "}"))) (expression_statement "piVar6 = (int *)0x0;" (assignment_expression "piVar6 = (int *)0x0" (identifier "piVar6") (= "=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (= "=") (number_literal "0")) (; ";")) (expression_statement "*param_4 = 0;" (assignment_expression "*param_4 = 0" (pointer_expression "*param_4" (* "*") (identifier "param_4")) (= "=") (number_literal "0")) (; ";")) (labeled_statement "LAB_0007b894:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\n  }" (statement_identifier "LAB_0007b894") (: ":") (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_00089270();\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                    \n    FUN_00089270();\n  }" ({ "{") (expression_statement "FUN_00089270();" (call_expression "FUN_00089270()" (identifier "FUN_00089270") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))) (return_statement "return piVar6;" (return "return") (identifier "piVar6") (; ";")) (} "}")))

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

type_1 *
function_1(void *in,int var_14,void **out,int *outlen,type_2 *var_18,
           void *callback_ctx)

{
  int var_27;
  char *var_3;
  size_t var_5;
  int var_7;
  int var_13;
  ssize_t var_16;
  type_1 *conn;
  type_1 *paVar6;
  int var_1;
  type_3 addr;
  
  var_27 = *(int *)(var_1 + 0x14);
  var_3 = var_2("SSH_AUTH_SOCK");
  if ((var_3 != (char *)0x0) && (var_5 = var_4(var_3), var_5 < 0x6c)) {
    var_7 = var_6(1,1,0);
    if (var_7 < 0) {
      var_8("socket(PF_UNIX)");
                    /* WARNING: Subroutine does not return */
      var_9(1);
    }
    var_10(var_7);
    addr.sun_family = 1;
    var_11(addr.sun_path,var_3,0x6c);
    var_13 = var_12(var_7,(type_4 *)&addr,0x6e);
    if (-1 < var_13) {
      var_13 = 0;
      if (0 < var_14) {
        do {
          var_16 = var_15(var_7,(void *)((int)in + var_13),var_14 - var_13);
          if (var_16 < 1) goto LAB_0007b872;
          var_13 = var_13 + var_16;
        } while (var_13 < var_14);
      }
      conn = (type_1 *)var_17(1,0x1c);
      conn->fd = var_7;
      conn->retbuf = conn->sizebuf;
      conn->retsize = 4;
      conn->retlen = 0;
      conn->var_18 = var_18;
      conn->callback_ctx = callback_ctx;
      if (var_18 == (type_2 *)0x0) {
        var_19(var_7);
        do {
          var_7 = var_20(conn);
        } while (var_7 == 0);
        *out = conn->retbuf;
        *outlen = conn->retlen;
        paVar6 = (type_1 *)0x0;
        var_21(conn);
      }
      else {
        if (var_22 == (type_5 *)0x0) {
          var_22 = var_23(agent_conncmp);
        }
        var_24(var_22,conn);
        var_25(var_7,1,agent_select_result);
        paVar6 = conn;
      }
      goto LAB_0007b894;
    }
LAB_0007b872:
    var_26(var_7);
  }
  paVar6 = (type_1 *)0x0;
  *out = (void *)0x0;
  *outlen = 0;
LAB_0007b894:
  if (var_27 != *(int *)(var_1 + 0x14)) {
                    /* WARNING: Subroutine does not return */
    var_28();
  }
  return paVar6;
}


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

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

int * MASKED(int param_1,int param_2,int *param_3,int *param_4,int param_5,int param_6)

{
  char *__s;
  size_t sVar1;
  int iVar2;
  int iVar3;
  ssize_t sVar4;
  int *piVar5;
  int *piVar6;
  int in_GS_OFFSET;
  sockaddr local_8e [6];
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x7b769;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  __s = getenv("SSH_AUTH_SOCK");
  if ((__s != (char *)0x0) && (sVar1 = strlen(__s), sVar1 < 0x6c)) {
    iVar2 = socket(1,1,0);
    if (iVar2 < 0) {
      perror("socket(PF_UNIX)");
                    /* WARNING: Subroutine does not return */
      exit(1);
    }
    FUN_0007d310(iVar2);
    local_8e[0].sa_family = 1;
    __strcpy_chk(local_8e[0].sa_data,__s,0x6c);
    iVar3 = connect(iVar2,local_8e,0x6e);
    if (-1 < iVar3) {
      iVar3 = 0;
      if (0 < param_2) {
        do {
          sVar4 = write(iVar2,(void *)(param_1 + iVar3),param_2 - iVar3);
          if (sVar4 < 1) goto LAB_0007b872;
          iVar3 = iVar3 + sVar4;
        } while (iVar3 < param_2);
      }
      piVar5 = (int *)FUN_0001fe90(1,0x1c);
      *piVar5 = iVar2;
      piVar5[1] = (int)(piVar5 + 2);
      piVar5[3] = 4;
      piVar5[4] = 0;
      piVar5[5] = param_5;
      piVar5[6] = param_6;
      if (param_5 == 0) {
        FUN_0007d4d0(iVar2);
        do {
          iVar2 = FUN_0007b510();
        } while (iVar2 == 0);
        *param_3 = piVar5[1];
        *param_4 = piVar5[4];
        piVar6 = (int *)0x0;
        FUN_00020030(piVar5);
      }
      else {
        if (DAT_000c79dc == 0) {
          DAT_000c79dc = FUN_00077680(FUN_0007b4d0);
        }
        FUN_0007af60(DAT_000c79dc,piVar5);
        FUN_00083290(iVar2,1,FUN_0007b620);
        piVar6 = piVar5;
      }
      goto LAB_0007b894;
    }
LAB_0007b872:
    close(iVar2);
  }
  piVar6 = (int *)0x0;
  *param_3 = 0;
  *param_4 = 0;
LAB_0007b894:
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_00089270();
  }
  return piVar6;
}

