NtCreateNamedPipeFile

NTSTATUS __stdcall NtCreateNamedPipeFile(
        VOID **FileHandle,
        UINT64 DesiredAccess,
        _OBJECT_ATTRIBUTES *ObjectAttributes,
        _IO_STATUS_BLOCK *IoStatusBlock,
        UINT64 ShareAccess,
        UINT64 CreateDisposition,
        UINT64 CreateOptions,
        UINT64 NamedPipeType,
        UINT64 ReadMode,
        UINT64 CompletionMode,
        UINT64 MaximumInstances,
        UINT64 InboundQuota,
        UINT64 OutboundQuota,
        _LARGE_INTEGER *DefaultTimeout){
  UINT64 FileAttributes; 
  UINT64 v16; 
  UINT64 Disposition; 
  UINT64 v18; 
  UINT64 EaLength; 
  UINT64 Options; 
  int InternalParameters[6]; 
  LONGLONG QuadPart; 
  char v23; 
  int v24; 
  __int16 v25; 
  char v26; 

  QuadPart = 0i64;
  v24 = 0;
  v25 = 0;
  v26 = 0;
  if( DefaultTimeout )
  {
    v23 = 1;
    if( KeGetCurrentThread()->PreviousMode )
    {
      if( ((unsigned __int8)DefaultTimeout & 3) != 0 )
        ExRaiseDatatypeMisalignment();
      QuadPart = DefaultTimeout->QuadPart;
    }
    else
    {
      QuadPart = DefaultTimeout->QuadPart;
    }
  }
  else
  {
    v23 = 0;
  }
  InternalParameters[0] = NamedPipeType;
  InternalParameters[1] = ReadMode;
  InternalParameters[2] = CompletionMode;
  InternalParameters[3] = MaximumInstances;
  InternalParameters[4] = InboundQuota;
  InternalParameters[5] = OutboundQuota;
  LODWORD(Options) = 0;
  LODWORD(EaLength) = 0;
  LODWORD(v18) = CreateOptions;
  LODWORD(Disposition) = CreateDisposition;
  LODWORD(v16) = ShareAccess;
  LODWORD(FileAttributes) = 0;
  return IoCreateFile(
           FileHandle,
           (unsigned int)DesiredAccess,
           ObjectAttributes,
           IoStatusBlock,
           0i64,
           FileAttributes,
           v16,
           Disposition,
           v18,
           0i64,
           EaLength,
           CreateFileTypeNamedPipe,
           InternalParameters,
           Options);
}

Referenced by:

No references.