[1166] | 1 | /**
|
---|
| 2 | * This file has no copyright assigned and is placed in the Public Domain.
|
---|
| 3 | * This file is part of the mingw-w64 runtime package.
|
---|
| 4 | * No warranty is given; refer to the file DISCLAIMER.PD within this package.
|
---|
| 5 | */
|
---|
| 6 | #ifndef _DHCPCSDK_
|
---|
| 7 | #define _DHCPCSDK_
|
---|
| 8 |
|
---|
| 9 | #ifdef __cplusplus
|
---|
| 10 | extern "C" {
|
---|
| 11 | #endif
|
---|
| 12 |
|
---|
| 13 | #ifndef DHCP_OPTIONS_DEFINED
|
---|
| 14 | #define DHCP_OPTIONS_DEFINED
|
---|
| 15 |
|
---|
| 16 | #define OPTION_PAD 0
|
---|
| 17 | #define OPTION_SUBNET_MASK 1
|
---|
| 18 | #define OPTION_TIME_OFFSET 2
|
---|
| 19 | #define OPTION_ROUTER_ADDRESS 3
|
---|
| 20 | #define OPTION_TIME_SERVERS 4
|
---|
| 21 | #define OPTION_IEN116_NAME_SERVERS 5
|
---|
| 22 | #define OPTION_DOMAIN_NAME_SERVERS 6
|
---|
| 23 | #define OPTION_LOG_SERVERS 7
|
---|
| 24 | #define OPTION_COOKIE_SERVERS 8
|
---|
| 25 | #define OPTION_LPR_SERVERS 9
|
---|
| 26 | #define OPTION_IMPRESS_SERVERS 10
|
---|
| 27 | #define OPTION_RLP_SERVERS 11
|
---|
| 28 | #define OPTION_HOST_NAME 12
|
---|
| 29 | #define OPTION_BOOT_FILE_SIZE 13
|
---|
| 30 | #define OPTION_MERIT_DUMP_FILE 14
|
---|
| 31 | #define OPTION_DOMAIN_NAME 15
|
---|
| 32 | #define OPTION_SWAP_SERVER 16
|
---|
| 33 | #define OPTION_ROOT_DISK 17
|
---|
| 34 | #define OPTION_EXTENSIONS_PATH 18
|
---|
| 35 |
|
---|
| 36 | #define OPTION_BE_A_ROUTER 19
|
---|
| 37 | #define OPTION_NON_LOCAL_SOURCE_ROUTING 20
|
---|
| 38 | #define OPTION_POLICY_FILTER_FOR_NLSR 21
|
---|
| 39 | #define OPTION_MAX_REASSEMBLY_SIZE 22
|
---|
| 40 | #define OPTION_DEFAULT_TTL 23
|
---|
| 41 | #define OPTION_PMTU_AGING_TIMEOUT 24
|
---|
| 42 | #define OPTION_PMTU_PLATEAU_TABLE 25
|
---|
| 43 |
|
---|
| 44 | #define OPTION_MTU 26
|
---|
| 45 | #define OPTION_ALL_SUBNETS_MTU 27
|
---|
| 46 | #define OPTION_BROADCAST_ADDRESS 28
|
---|
| 47 | #define OPTION_PERFORM_MASK_DISCOVERY 29
|
---|
| 48 | #define OPTION_BE_A_MASK_SUPPLIER 30
|
---|
| 49 | #define OPTION_PERFORM_ROUTER_DISCOVERY 31
|
---|
| 50 | #define OPTION_ROUTER_SOLICITATION_ADDR 32
|
---|
| 51 | #define OPTION_STATIC_ROUTES 33
|
---|
| 52 | #define OPTION_TRAILERS 34
|
---|
| 53 | #define OPTION_ARP_CACHE_TIMEOUT 35
|
---|
| 54 | #define OPTION_ETHERNET_ENCAPSULATION 36
|
---|
| 55 |
|
---|
| 56 | #define OPTION_TTL 37
|
---|
| 57 | #define OPTION_KEEP_ALIVE_INTERVAL 38
|
---|
| 58 | #define OPTION_KEEP_ALIVE_DATA_SIZE 39
|
---|
| 59 |
|
---|
| 60 | #define OPTION_NETWORK_INFO_SERVICE_DOM 40
|
---|
| 61 | #define OPTION_NETWORK_INFO_SERVERS 41
|
---|
| 62 | #define OPTION_NETWORK_TIME_SERVERS 42
|
---|
| 63 |
|
---|
| 64 | #define OPTION_VENDOR_SPEC_INFO 43
|
---|
| 65 |
|
---|
| 66 | #define OPTION_NETBIOS_NAME_SERVER 44
|
---|
| 67 | #define OPTION_NETBIOS_DATAGRAM_SERVER 45
|
---|
| 68 | #define OPTION_NETBIOS_NODE_TYPE 46
|
---|
| 69 | #define OPTION_NETBIOS_SCOPE_OPTION 47
|
---|
| 70 |
|
---|
| 71 | #define OPTION_XWINDOW_FONT_SERVER 48
|
---|
| 72 | #define OPTION_XWINDOW_DISPLAY_MANAGER 49
|
---|
| 73 |
|
---|
| 74 | #define OPTION_REQUESTED_ADDRESS 50
|
---|
| 75 | #define OPTION_LEASE_TIME 51
|
---|
| 76 | #define OPTION_OK_TO_OVERLAY 52
|
---|
| 77 | #define OPTION_MESSAGE_TYPE 53
|
---|
| 78 | #define OPTION_SERVER_IDENTIFIER 54
|
---|
| 79 | #define OPTION_PARAMETER_REQUEST_LIST 55
|
---|
| 80 | #define OPTION_MESSAGE 56
|
---|
| 81 | #define OPTION_MESSAGE_LENGTH 57
|
---|
| 82 | #define OPTION_RENEWAL_TIME 58
|
---|
| 83 | #define OPTION_REBIND_TIME 59
|
---|
| 84 | #define OPTION_CLIENT_CLASS_INFO 60
|
---|
| 85 | #define OPTION_CLIENT_ID 61
|
---|
| 86 |
|
---|
| 87 | #define OPTION_TFTP_SERVER_NAME 66
|
---|
| 88 | #define OPTION_BOOTFILE_NAME 67
|
---|
| 89 |
|
---|
| 90 | #define OPTION_END 255
|
---|
| 91 | #endif
|
---|
| 92 |
|
---|
| 93 | #ifndef DHCPAPI_PARAMS_DEFINED
|
---|
| 94 | #define DHCPAPI_PARAMS_DEFINED
|
---|
| 95 | typedef struct _DHCPAPI_PARAMS {
|
---|
| 96 | ULONG Flags;
|
---|
| 97 | ULONG OptionId;
|
---|
| 98 | WINBOOL IsVendor;
|
---|
| 99 | LPBYTE Data;
|
---|
| 100 | DWORD nBytesData;
|
---|
| 101 | } DHCPAPI_PARAMS,*PDHCPAPI_PARAMS,*LPDHCPAPI_PARAMS;
|
---|
| 102 | #endif
|
---|
| 103 |
|
---|
| 104 | typedef struct _DHCPAPI_PARAMS DHCPCAPI_PARAMS,*PDHCPCAPI_PARAMS,*LPDHCPCAPI_PARAMS;
|
---|
| 105 |
|
---|
| 106 | typedef struct _DHCPCAPI_PARAMS_ARARAY {
|
---|
| 107 | ULONG nParams;
|
---|
| 108 | LPDHCPCAPI_PARAMS Params;
|
---|
| 109 | } DHCPCAPI_PARAMS_ARRAY,*PDHCPCAPI_PARAMS_ARRAY,*LPDHCPCAPI_PARAMS_ARRAY;
|
---|
| 110 |
|
---|
| 111 | typedef struct _DHCPCAPI_CLASSID {
|
---|
| 112 | ULONG Flags;
|
---|
| 113 | LPBYTE Data;
|
---|
| 114 | ULONG nBytesData;
|
---|
| 115 | } DHCPCAPI_CLASSID,*PDHCPCAPI_CLASSID,*LPDHCPCAPI_CLASSID;
|
---|
| 116 |
|
---|
| 117 | #define DHCPCAPI_REQUEST_PERSISTENT 0x01
|
---|
| 118 | #define DHCPCAPI_REQUEST_SYNCHRONOUS 0x02
|
---|
| 119 | #define DHCPCAPI_REQUEST_ASYNCHRONOUS 0x04
|
---|
| 120 | #define DHCPCAPI_REQUEST_CANCEL 0x08
|
---|
| 121 | #define DHCPCAPI_REQUEST_MASK 0x0F
|
---|
| 122 |
|
---|
| 123 | DWORD WINAPI DhcpCApiInitialize(LPDWORD Version);
|
---|
| 124 | VOID WINAPI DhcpCApiCleanup(VOID);
|
---|
| 125 | DWORD WINAPI DhcpRequestParams(DWORD Flags,LPVOID Reserved,LPWSTR AdapterName,LPDHCPCAPI_CLASSID ClassId,DHCPCAPI_PARAMS_ARRAY SendParams,DHCPCAPI_PARAMS_ARRAY RecdParams,LPBYTE Buffer,LPDWORD pSize,LPWSTR RequestIdStr);
|
---|
| 126 | DWORD WINAPI DhcpUndoRequestParams(DWORD Flags,LPVOID Reserved,LPWSTR AdapterName,LPWSTR RequestIdStr);
|
---|
| 127 |
|
---|
| 128 | #define DHCPCAPI_REGISTER_HANDLE_EVENT 0x01
|
---|
| 129 | DWORD WINAPI DhcpRegisterParamChange(DWORD Flags,LPVOID Reserved,LPWSTR AdapterName,LPDHCPCAPI_CLASSID ClassId,DHCPCAPI_PARAMS_ARRAY Params,LPVOID Handle);
|
---|
| 130 |
|
---|
| 131 | #define DHCPCAPI_DEREGISTER_HANDLE_EVENT 0x01
|
---|
| 132 | DWORD WINAPI DhcpDeRegisterParamChange(DWORD Flags,LPVOID Reserved,LPVOID Event);
|
---|
| 133 | DWORD WINAPI DhcpRemoveDNSRegistrations(VOID);
|
---|
| 134 |
|
---|
| 135 | #ifdef __cplusplus
|
---|
| 136 | }
|
---|
| 137 | #endif
|
---|
| 138 | #endif
|
---|