C# Класс dlech.SshAgentLib.WinInternals

Показать файл Открыть проект

Открытые методы

Метод Описание
FindProcessWithMatchingHandle ( MemoryMappedFile mmf ) : Process

Iterates all open handles on the system (using internal system call) to find the other process that has a handle open to the same memtory mapped file.

Code based on http://forum.sysinternals.com/overview-handle-enumeration_topic14546.html

GetProcessForTcpPort ( IPEndPoint localEndpoint, IPEndPoint remoteEndpoint ) : Process

Searches all current TCP connections (IPv4 only) for the matching port (local port of the connection).

Приватные методы

Метод Описание
GetExtendedTcpTable ( IntPtr pTcpTable, UInt32 &pdwSize, System.Boolean bOrder, UInt32 ulAf, TCP_TABLE_CLASS TableClass, UInt32 Reserved ) : UInt32
NtQuerySystemInformation ( SYSTEM_INFORMATION_CLASS SystemInformationClass, IntPtr SystemInformation, UInt32 Length, UInt32 &ResultLength ) : NTSTATUS

Описание методов

FindProcessWithMatchingHandle() публичный статический Метод

Iterates all open handles on the system (using internal system call) to find the other process that has a handle open to the same memtory mapped file.
Code based on http://forum.sysinternals.com/overview-handle-enumeration_topic14546.html
public static FindProcessWithMatchingHandle ( MemoryMappedFile mmf ) : Process
mmf System.IO.MemoryMappedFiles.MemoryMappedFile
Результат System.Diagnostics.Process

GetProcessForTcpPort() публичный статический Метод

Searches all current TCP connections (IPv4 only) for the matching port (local port of the connection).
public static GetProcessForTcpPort ( IPEndPoint localEndpoint, IPEndPoint remoteEndpoint ) : Process
localEndpoint System.Net.IPEndPoint
remoteEndpoint System.Net.IPEndPoint
Результат System.Diagnostics.Process