diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2008-07-14 15:55:48 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2008-07-14 15:55:48 +0000 |
commit | c0bb6b5bd611885d9576a01c6cc57a2c8d205640 (patch) | |
tree | cb18226e1b0c7d5e0d96e2863195c6e73868f66d /winsup | |
parent | 5a0c7f1df9585c63a5438a07480afccb661a706d (diff) | |
download | cygnal-c0bb6b5bd611885d9576a01c6cc57a2c8d205640.tar.gz cygnal-c0bb6b5bd611885d9576a01c6cc57a2c8d205640.tar.bz2 cygnal-c0bb6b5bd611885d9576a01c6cc57a2c8d205640.zip |
* include/iphlpapi.h (GetExtendedTcpTable): Add prototype.
* include/iprtrmib.h (TCP_TABLE_CLASS, MIB_TCPROW_OWNER_PID,
MIB_TCPTABLE_OWNER_PID, MIB_TCP6ROW_OWNER_PID,
MIB_TCP6TABLE_OWNER_PID): Define.
* lib/iphlpapi.def (GetExtendedTcpTable): Export.
Diffstat (limited to 'winsup')
-rw-r--r-- | winsup/w32api/ChangeLog | 8 | ||||
-rw-r--r-- | winsup/w32api/include/iphlpapi.h | 3 | ||||
-rw-r--r-- | winsup/w32api/include/iprtrmib.h | 37 | ||||
-rw-r--r-- | winsup/w32api/lib/iphlpapi.def | 1 |
4 files changed, 49 insertions, 0 deletions
diff --git a/winsup/w32api/ChangeLog b/winsup/w32api/ChangeLog index a35405e5b..d478254fc 100644 --- a/winsup/w32api/ChangeLog +++ b/winsup/w32api/ChangeLog @@ -1,3 +1,11 @@ +2008-07-14 Corinna Vinschen <corinna@vinschen.de> + + * include/iphlpapi.h (GetExtendedTcpTable): Add prototype. + * include/iprtrmib.h (TCP_TABLE_CLASS, MIB_TCPROW_OWNER_PID, + MIB_TCPTABLE_OWNER_PID, MIB_TCP6ROW_OWNER_PID, + MIB_TCP6TABLE_OWNER_PID): Define. + * lib/iphlpapi.def (GetExtendedTcpTable): Export. + 2008-06-25 Brandon Sneed <nivenh@sourceware.org> * include/winbase.h (GetProcessHandleCount, GetSystemRegistryQuota, diff --git a/winsup/w32api/include/iphlpapi.h b/winsup/w32api/include/iphlpapi.h index 6fd976af4..c35c4950d 100644 --- a/winsup/w32api/include/iphlpapi.h +++ b/winsup/w32api/include/iphlpapi.h @@ -37,6 +37,9 @@ DWORD WINAPI GetAdapterIndex(LPWSTR,PULONG); DWORD WINAPI GetAdaptersInfo(PIP_ADAPTER_INFO,PULONG); DWORD WINAPI GetBestInterface(IPAddr,PDWORD); DWORD WINAPI GetBestRoute(DWORD,DWORD,PMIB_IPFORWARDROW); +#if (_WIN32_WINNT >= 0x0501) +DWORD WINAPI GetExtendedTcpTable (PVOID,PDWORD,BOOL,ULONG,TCP_TABLE_CLASS,ULONG); +#endif DWORD WINAPI GetFriendlyIfIndex(DWORD); DWORD WINAPI GetIcmpStatistics(PMIB_ICMP); DWORD WINAPI GetIfEntry(PMIB_IFROW); diff --git a/winsup/w32api/include/iprtrmib.h b/winsup/w32api/include/iprtrmib.h index f897ecbfa..3b32f45b9 100644 --- a/winsup/w32api/include/iprtrmib.h +++ b/winsup/w32api/include/iprtrmib.h @@ -39,6 +39,17 @@ extern "C" { #define MIB_USE_CURRENT_TTL ((DWORD)-1) #define MIB_USE_CURRENT_FORWARDING ((DWORD)-1) #define MIB_TCP_MAXCONN_DYNAMIC ((DWORD)-1) +typedef enum { + TCP_TABLE_BASIC_LISTENER, + TCP_TABLE_BASIC_CONNECTIONS, + TCP_TABLE_BASIC_ALL, + TCP_TABLE_OWNER_PID_LISTENER, + TCP_TABLE_OWNER_PID_CONNECTIONS, + TCP_TABLE_OWNER_PID_ALL, + TCP_TABLE_OWNER_MODULE_LISTENER, + TCP_TABLE_OWNER_MODULE_CONNECTIONS, + TCP_TABLE_OWNER_MODULE_ALL +} TCP_TABLE_CLASS, *PTCP_TABLE_CLASS; typedef struct { DWORD dwAddr; DWORD dwIndex; @@ -189,6 +200,18 @@ typedef struct { MIB_TCPROW table[ANY_SIZE]; } MIB_TCPTABLE, *PMIB_TCPTABLE; typedef struct { + DWORD dwState; + DWORD dwLocalAddr; + DWORD dwLocalPort; + DWORD dwRemoteAddr; + DWORD dwRemotePort; + DWORD dwOwningPid; +} MIB_TCPROW_OWNER_PID, *PMIB_TCPROW_OWNER_PID; +typedef struct { + DWORD dwNumEntries; + MIB_TCPROW_OWNER_PID table[ANY_SIZE]; +} MIB_TCPTABLE_OWNER_PID, *PMIB_TCPTABLE_OWNER_PID; +typedef struct { DWORD dwInDatagrams; DWORD dwNoPorts; DWORD dwInErrors; @@ -203,6 +226,20 @@ typedef struct { DWORD dwNumEntries; MIB_UDPROW table[ANY_SIZE]; } MIB_UDPTABLE, *PMIB_UDPTABLE; +typedef struct { + UCHAR ucLocalAddr[16]; + DWORD dwLocalScopeId; + DWORD dwLocalPort; + UCHAR ucRemoteAddr[16]; + DWORD dwRemoteScopeId; + DWORD dwRemotePort; + DWORD dwState; + DWORD dwOwningPid; +} MIB_TCP6ROW_OWNER_PID, *PMIB_TCP6ROW_OWNER_PID; +typedef struct { + DWORD dwNumEntries; + MIB_TCP6ROW_OWNER_PID table[ANY_SIZE]; +} MIB_TCP6TABLE_OWNER_PID, *PMIB_TCP6TABLE_OWNER_PID; #ifdef __cplusplus } #endif diff --git a/winsup/w32api/lib/iphlpapi.def b/winsup/w32api/lib/iphlpapi.def index 6fccc64b3..e01624382 100644 --- a/winsup/w32api/lib/iphlpapi.def +++ b/winsup/w32api/lib/iphlpapi.def @@ -15,6 +15,7 @@ GetAdapterIndex@8 GetAdaptersInfo@8 GetBestInterface@8 GetBestRoute@12 +GetExtendedTcpTable@24 GetFriendlyIfIndex@4 GetIcmpStatistics@4 GetIfEntry@4 |