2 * Copyright 2015 Hans Leidekker for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #ifndef __WINE_NETIOAPI_H
20 #define __WINE_NETIOAPI_H
24 typedef struct _MIB_IF_ROW2
26 NET_LUID InterfaceLuid
;
27 NET_IFINDEX InterfaceIndex
;
29 WCHAR Alias
[IF_MAX_STRING_SIZE
+ 1];
30 WCHAR Description
[IF_MAX_STRING_SIZE
+ 1];
31 ULONG PhysicalAddressLength
;
32 UCHAR PhysicalAddress
[IF_MAX_PHYS_ADDRESS_LENGTH
];
33 UCHAR PermanentPhysicalAddress
[IF_MAX_PHYS_ADDRESS_LENGTH
];
36 TUNNEL_TYPE TunnelType
;
37 NDIS_MEDIUM MediaType
;
38 NDIS_PHYSICAL_MEDIUM PhysicalMediumType
;
39 NET_IF_ACCESS_TYPE AccessType
;
40 NET_IF_DIRECTION_TYPE DirectionType
;
43 BOOLEAN HardwareInterface
: 1;
44 BOOLEAN FilterInterface
: 1;
45 BOOLEAN ConnectorPresent
: 1;
46 BOOLEAN NotAuthenticated
: 1;
47 BOOLEAN NotMediaConnected
: 1;
50 BOOLEAN EndPointInterface
: 1;
51 } InterfaceAndOperStatusFlags
;
52 IF_OPER_STATUS OperStatus
;
53 NET_IF_ADMIN_STATUS AdminStatus
;
54 NET_IF_MEDIA_CONNECT_STATE MediaConnectState
;
55 NET_IF_NETWORK_GUID NetworkGuid
;
56 NET_IF_CONNECTION_TYPE ConnectionType
;
57 ULONG64 TransmitLinkSpeed
;
58 ULONG64 ReceiveLinkSpeed
;
64 ULONG64 InUnknownProtos
;
65 ULONG64 InUcastOctets
;
66 ULONG64 InMulticastOctets
;
67 ULONG64 InBroadcastOctets
;
70 ULONG64 OutNUcastPkts
;
73 ULONG64 OutUcastOctets
;
74 ULONG64 OutMulticastOctets
;
75 ULONG64 OutBroadcastOctets
;
77 } MIB_IF_ROW2
, *PMIB_IF_ROW2
;
79 typedef struct _MIB_IF_TABLE2
83 } MIB_IF_TABLE2
, *PMIB_IF_TABLE2
;
85 DWORD WINAPI
ConvertInterfaceGuidToLuid(const GUID
*,NET_LUID
*);
86 DWORD WINAPI
ConvertInterfaceIndexToLuid(NET_IFINDEX
,NET_LUID
*);
87 DWORD WINAPI
ConvertInterfaceLuidToGuid(const NET_LUID
*,GUID
*);
88 DWORD WINAPI
ConvertInterfaceLuidToIndex(const NET_LUID
*,NET_IFINDEX
*);
89 DWORD WINAPI
ConvertInterfaceLuidToNameA(const NET_LUID
*,char*,SIZE_T
);
90 DWORD WINAPI
ConvertInterfaceLuidToNameW(const NET_LUID
*,WCHAR
*,SIZE_T
);
91 DWORD WINAPI
ConvertInterfaceNameToLuidA(const char*,NET_LUID
*);
92 DWORD WINAPI
ConvertInterfaceNameToLuidW(const WCHAR
*,NET_LUID
*);
93 void WINAPI
FreeMibTable(void*);
94 DWORD WINAPI
GetIfEntry2(MIB_IF_ROW2
*);
96 #endif /* __WINE_NETIOAPI_H */