summaryrefslogtreecommitdiffstats
path: root/public/sdk/inc/dhcpcext.h
blob: 69c9e02b091ff4241cde3c7c972e6382a322d68e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
/*++

Copyright (c) 1993-1995  Microsoft Corporation All rights reserved

Module Name:

   dhcpcext.h 

Abstract:

    defines, typedefs, prototypes to enable clients to interface with
    dhcp client  

Author:

   Pradeepb               12/3/95 

Revision History:

Notes:

 Currently used by SHIVA for their RAS client.  Currently, contains 
 stuff relevant only to poking DHCP client so that it notifies nbt (on WFW).

--*/

#ifndef _DHCPEXT_
#define _DHCPEXT_
//
// Pass in the following for Type when you want to poke vdhcp with the
// ip address and any options that you get from the RAS server. The function
// to use is DhcpSetInfo or DhcpSetInfoR (used by SHIVA's RAS client).
//
#define DHCP_PPP_PARAMETER_SET                2
#define MAX_HARDWARE_ADDRESS_LENGTH           16

//
//  Note: IpAddr should be in network order (like what the IP driver returns)
//

TDI_STATUS DhcpSetInfoR( UINT      Type,
                         ULONG     IpAddr,  //new ip address
                         PNIC_INFO pNicInfo, 
                         PVOID     pBuff,
                         UINT      Size ) ;


typedef struct _NIC_INFO {
               ULONG IfIndex;      //interface index 
               ULONG SubnetMask;   //subnet mask  in network order
               ULONG OldIpAddress; //old ip address in network order
               } NIC_INFO, *PNIC_INFO;




typedef struct _HARDWARE_ADDRESS {
    DWORD Length;                  //length of hardware address in array below
    CHAR Address[MAX_HARDWARE_ADDRESS_LENGTH];
} HARDWARE_ADDRESS, *PHARDWARE_ADDRESS;

//
// define PPP parameter set info buffer structure.  Specify one option, its
// length and value.  
//

typedef struct _PPP_SET_INFO {
    HARDWARE_ADDRESS HardwareAddress;  //specify your hardware address
    DWORD ParameterOpCode;             //ex. 44 for NBNS, 6 for DNS (#s are
                                       // in dhcp rfc 
    DWORD ParameterLength;             //length of Parameter Value in 
                                       //RawParmeter below
    BYTE RawParameter[1];
}  PPP_SET_INFO, *LP_PPP_SET_INFO;

#endif // _DHCPEXT_