Sync with trunk r63502.
[reactos.git] / include / psdk / ras.h
1 #ifndef _RAS_H
2 #define _RAS_H
3
4 #ifdef __cplusplus
5 extern "C"
6 {
7 #endif
8
9 #ifndef _LMCONS_H
10 #include <lmcons.h>
11 #endif
12
13 /* TODO
14 include <basetsd.h> from winnt.h so that this typedef is not necessary
15 */
16 #ifndef _BASETSD_H_
17 typedef unsigned long ULONG_PTR, *PULONG_PTR;
18 #endif
19
20 #include <pshpack4.h>
21
22 #define RAS_MaxDeviceType 16
23 #define RAS_MaxPhoneNumber 128
24 #define RAS_MaxIpAddress 15
25 #define RAS_MaxIpxAddress 21
26 #define RAS_MaxEntryName 256
27 #define RAS_MaxDeviceName 128
28 #define RAS_MaxCallbackNumber RAS_MaxPhoneNumber
29 #define RAS_MaxAreaCode 10
30 #define RAS_MaxPadType 32
31 #define RAS_MaxX25Address 200
32 #define RAS_MaxFacilities 200
33 #define RAS_MaxUserData 200
34 #define RAS_MaxReplyMessage 1024
35 #define RAS_MaxDnsSuffix 256
36 #if (WINVER >= 0x501)
37 #define RASCF_AllUsers 0x00000001
38 #define RASCF_GlobalCreds 0x00000002
39 #endif /*(WINVER >= 0x501)*/
40 #define RDEOPT_UsePrefixSuffix 0x00000001
41 #define RDEOPT_PausedStates 0x00000002
42 #define RDEOPT_IgnoreModemSpeaker 0x00000004
43 #define RDEOPT_SetModemSpeaker 0x00000008
44 #define RDEOPT_IgnoreSoftwareCompression 0x00000010
45 #define RDEOPT_SetSoftwareCompression 0x00000020
46 #define RDEOPT_DisableConnectedUI 0x00000040
47 #define RDEOPT_DisableReconnectUI 0x00000080
48 #define RDEOPT_DisableReconnect 0x00000100
49 #define RDEOPT_NoUser 0x00000200
50 #define RDEOPT_PauseOnScript 0x00000400
51 #define RDEOPT_Router 0x00000800
52 #define REN_User 0x00000000
53 #define REN_AllUsers 0x00000001
54 #define VS_Default 0
55 #define VS_PptpOnly 1
56 #define VS_PptpFirst 2
57 #define VS_L2tpOnly 3
58 #define VS_L2tpFirst 4
59 #define RASDIALEVENT "RasDialEvent"
60 #define WM_RASDIALEVENT 0xCCCD
61 #define RASEO_UseCountryAndAreaCodes 0x00000001
62 #define RASEO_SpecificIpAddr 0x00000002
63 #define RASEO_SpecificNameServers 0x00000004
64 #define RASEO_IpHeaderCompression 0x00000008
65 #define RASEO_RemoteDefaultGateway 0x00000010
66 #define RASEO_DisableLcpExtensions 0x00000020
67 #define RASEO_TerminalBeforeDial 0x00000040
68 #define RASEO_TerminalAfterDial 0x00000080
69 #define RASEO_ModemLights 0x00000100
70 #define RASEO_SwCompression 0x00000200
71 #define RASEO_RequireEncryptedPw 0x00000400
72 #define RASEO_RequireMsEncryptedPw 0x00000800
73 #define RASEO_RequireDataEncryption 0x00001000
74 #define RASEO_NetworkLogon 0x00002000
75 #define RASEO_UseLogonCredentials 0x00004000
76 #define RASEO_PromoteAlternates 0x00008000
77 #define RASNP_NetBEUI 0x00000001
78 #define RASNP_Ipx 0x00000002
79 #define RASNP_Ip 0x00000004
80 #define RASFP_Ppp 0x00000001
81 #define RASFP_Slip 0x00000002
82 #define RASFP_Ras 0x00000004
83 #define RASDT_Direct TEXT("direct")
84 #define RASDT_Modem TEXT("modem")
85 #define RASDT_Isdn TEXT("isdn")
86 #define RASDT_X25 TEXT("x25")
87 #define RASDT_Vpn TEXT("vpn")
88 #define RASDT_Pad TEXT("pad")
89 #define RASDT_Generic TEXT("GENERIC")
90 #define RASDT_Serial TEXT("SERIAL")
91 #define RASDT_FrameRelay TEXT("FRAMERELAY")
92 #define RASDT_Atm TEXT("ATM")
93 #define RASDT_Sonet TEXT("SONET")
94 #define RASDT_SW56 TEXT("SW56")
95 #define RASDT_Irda TEXT("IRDA")
96 #define RASDT_Parallel TEXT("PARALLEL")
97 #if (WINVER >= 0x501)
98 #define RASDT_PPPoE TEXT("PPPoE")
99 #endif
100 #define RASET_Phone 1
101 #define RASET_Vpn 2
102 #define RASET_Direct 3
103 #define RASET_Internet 4
104 #if (WINVER >= 0x501)
105 #define RASET_Broadband 5
106 #endif
107 #if (WINVER >= 0x401)
108 #define RASEO_SecureLocalFiles 0x00010000
109 #define RASCN_Connection 0x00000001
110 #define RASCN_Disconnection 0x00000002
111 #define RASCN_BandwidthAdded 0x00000004
112 #define RASCN_BandwidthRemoved 0x00000008
113 #define RASEDM_DialAll 1
114 #define RASEDM_DialAsNeeded 2
115 #define RASIDS_Disabled 0xffffffff
116 #define RASIDS_UseGlobalValue 0
117 #define RASADFLG_PositionDlg 0x00000001
118 #define RASCM_UserName 0x00000001
119 #define RASCM_Password 0x00000002
120 #define RASCM_Domain 0x00000004
121 #define RASADP_DisableConnectionQuery 0
122 #define RASADP_LoginSessionDisable 1
123 #define RASADP_SavedAddressesLimit 2
124 #define RASADP_FailedConnectionTimeout 3
125 #define RASADP_ConnectionQueryTimeout 4
126 #endif /* (WINVER >= 0x401) */
127 #if (WINVER >= 0x500)
128 #define RDEOPT_CustomDial 0x00001000
129 #if (WINVER >= 0x501)
130 #define RDEOPT_UseCustomScripting 0x00002000
131 #define RASCM_DefaultCreds 0x00000008
132 #define RASCM_PreSharedKey 0x00000010
133 #define RASCM_ServerPreSharedKey 0x00000020
134 #define RASCM_DDMPreSharedKey 0x00000040
135 #endif /*(WINVER >= 0x501)*/
136 #define RASLCPAP_PAP 0xC023
137 #define RASLCPAP_SPAP 0xC027
138 #define RASLCPAP_CHAP 0xC223
139 #define RASLCPAP_EAP 0xC227
140 #define RASLCPAD_CHAP_MD5 0x05
141 #define RASLCPAD_CHAP_MS 0x80
142 #define RASLCPAD_CHAP_MSV2 0x81
143 #define RASLCPO_PFC 0x00000001
144 #define RASLCPO_ACFC 0x00000002
145 #define RASLCPO_SSHF 0x00000004
146 #define RASLCPO_DES_56 0x00000008
147 #define RASLCPO_3_DES 0x00000010
148 #define RASCCPCA_MPPC 0x00000006
149 #define RASCCPCA_STAC 0x00000005
150 #define RASCCPO_Compression 0x00000001
151 #define RASCCPO_HistoryLess 0x00000002
152 #define RASCCPO_Encryption56bit 0x00000010
153 #define RASCCPO_Encryption40bit 0x00000020
154 #define RASCCPO_Encryption128bit 0x00000040
155 #define RASEO_RequireEAP 0x00020000
156 #define RASEO_RequirePAP 0x00040000
157 #define RASEO_RequireSPAP 0x00080000
158 #define RASEO_Custom 0x00100000
159 #define RASEO_PreviewPhoneNumber 0x00200000
160 #define RASEO_SharedPhoneNumbers 0x00800000
161 #define RASEO_PreviewUserPw 0x01000000
162 #define RASEO_PreviewDomain 0x02000000
163 #define RASEO_ShowDialingProgress 0x04000000
164 #define RASEO_RequireCHAP 0x08000000
165 #define RASEO_RequireMsCHAP 0x10000000
166 #define RASEO_RequireMsCHAP2 0x20000000
167 #define RASEO_RequireW95MSCHAP 0x40000000
168 #define RASEO_CustomScript 0x80000000
169 #define RASIPO_VJ 0x00000001
170 #define RCD_SingleUser 0
171 #define RCD_AllUsers 0x00000001
172 #define RCD_Eap 0x00000002
173 #define RASEAPF_NonInteractive 0x00000002
174 #define RASEAPF_Logon 0x00000004
175 #define RASEAPF_Preview 0x00000008
176 #define ET_40Bit 1
177 #define ET_128Bit 2
178 #define ET_None 0
179 #define ET_Require 1
180 #define ET_RequireMax 2
181 #define ET_Optional 3
182 #endif /* (WINVER >= 0x500) */
183 #if (WINVER >= 0x501)
184 #define RASEO2_SecureFileAndPrint 0x00000001
185 #define RASEO2_SecureClientForMSNet 0x00000002
186 #define RASEO2_DontNegotiateMultilink 0x00000004
187 #define RASEO2_DontUseRasCredentials 0x00000008
188 #define RASEO2_UsePreSharedKey 0x00000010
189 #define RASEO2_Internet 0x00000020
190 #define RASEO2_DisableNbtOverIP 0x00000040
191 #define RASEO2_UseGlobalDeviceSettings 0x00000080
192 #define RASEO2_ReconnectIfDropped 0x00000100
193 #define RASEO2_SharePhoneNumbers 0x00000200
194 #endif /*(WINVER >= 0x501)*/
195
196 #define RASCS_PAUSED 0x1000
197 #define RASCS_DONE 0x2000
198 typedef enum tagRASCONNSTATE {
199 RASCS_OpenPort = 0,
200 RASCS_PortOpened,
201 RASCS_ConnectDevice,
202 RASCS_DeviceConnected,
203 RASCS_AllDevicesConnected,
204 RASCS_Authenticate,
205 RASCS_AuthNotify,
206 RASCS_AuthRetry,
207 RASCS_AuthCallback,
208 RASCS_AuthChangePassword,
209 RASCS_AuthProject,
210 RASCS_AuthLinkSpeed,
211 RASCS_AuthAck,
212 RASCS_ReAuthenticate,
213 RASCS_Authenticated,
214 RASCS_PrepareForCallback,
215 RASCS_WaitForModemReset,
216 RASCS_WaitForCallback,
217 RASCS_Projected,
218 RASCS_StartAuthentication,
219 RASCS_CallbackComplete,
220 RASCS_LogonNetwork,
221 RASCS_SubEntryConnected,
222 RASCS_SubEntryDisconnected,
223 RASCS_Interactive = RASCS_PAUSED,
224 RASCS_RetryAuthentication,
225 RASCS_CallbackSetByCaller,
226 RASCS_PasswordExpired,
227 #if (WINVER >= 0x500)
228 RASCS_InvokeEapUI,
229 #endif
230 RASCS_Connected = RASCS_DONE,
231 RASCS_Disconnected
232 } RASCONNSTATE, *LPRASCONNSTATE;
233
234 typedef enum tagRASPROJECTION {
235 RASP_Amb = 0x10000,
236 RASP_PppNbf = 0x803F,
237 RASP_PppIpx = 0x802B,
238 RASP_PppIp = 0x8021,
239 #if (WINVER >= 0x500)
240 RASP_PppCcp = 0x80FD,
241 #endif
242 RASP_PppLcp = 0xC021,
243 RASP_Slip = 0x20000
244 } RASPROJECTION, *LPRASPROJECTION;
245
246 DECLARE_HANDLE (HRASCONN);
247 typedef HRASCONN* LPHRASCONN;
248
249 typedef struct tagRASCONNW {
250 DWORD dwSize;
251 HRASCONN hrasconn;
252 WCHAR szEntryName[RAS_MaxEntryName + 1];
253 #if (WINVER >= 0x400)
254 WCHAR szDeviceType[RAS_MaxDeviceType + 1];
255 WCHAR szDeviceName[RAS_MaxDeviceName + 1];
256 #endif
257 #if (WINVER >= 0x401)
258 WCHAR szPhonebook[MAX_PATH];
259 DWORD dwSubEntry;
260 #endif
261 #if (WINVER >= 0x500)
262 GUID guidEntry;
263 #endif
264 #if (WINVER >= 0x501)
265 DWORD dwSessionId;
266 DWORD dwFlags;
267 LUID luid;
268 #endif
269 } RASCONNW, *LPRASCONNW;
270
271 typedef struct tagRASCONNA {
272 DWORD dwSize;
273 HRASCONN hrasconn;
274 CHAR szEntryName[RAS_MaxEntryName + 1];
275 #if (WINVER >= 0x400)
276 CHAR szDeviceType[RAS_MaxDeviceType + 1];
277 CHAR szDeviceName[RAS_MaxDeviceName + 1];
278 #endif
279 #if (WINVER >= 0x401)
280 CHAR szPhonebook[MAX_PATH];
281 DWORD dwSubEntry;
282 #endif
283 #if (WINVER >= 0x500)
284 GUID guidEntry;
285 #endif
286 #if (WINVER >= 0x501)
287 DWORD dwSessionId;
288 DWORD dwFlags;
289 LUID luid;
290 #endif
291 } RASCONNA, *LPRASCONNA;
292
293 typedef struct tagRASCONNSTATUSW {
294 DWORD dwSize;
295 RASCONNSTATE rasconnstate;
296 DWORD dwError;
297 WCHAR szDeviceType[RAS_MaxDeviceType + 1];
298 WCHAR szDeviceName[RAS_MaxDeviceName + 1];
299 #if (WINVER >= 0x401)
300 WCHAR szPhoneNumber[RAS_MaxPhoneNumber + 1];
301 #endif
302 } RASCONNSTATUSW, *LPRASCONNSTATUSW;
303
304 typedef struct tagRASCONNSTATUSA {
305 DWORD dwSize;
306 RASCONNSTATE rasconnstate;
307 DWORD dwError;
308 CHAR szDeviceType[RAS_MaxDeviceType + 1];
309 CHAR szDeviceName[RAS_MaxDeviceName + 1];
310 #if (WINVER >= 0x401)
311 CHAR szPhoneNumber[RAS_MaxPhoneNumber + 1];
312 #endif
313 } RASCONNSTATUSA, *LPRASCONNSTATUSA;
314
315 typedef struct tagRASDIALPARAMSW {
316 DWORD dwSize;
317 WCHAR szEntryName[RAS_MaxEntryName + 1];
318 WCHAR szPhoneNumber[RAS_MaxPhoneNumber + 1];
319 WCHAR szCallbackNumber[RAS_MaxCallbackNumber + 1];
320 WCHAR szUserName[UNLEN + 1];
321 WCHAR szPassword[PWLEN + 1];
322 WCHAR szDomain[DNLEN + 1];
323 #if (WINVER >= 0x401)
324 DWORD dwSubEntry;
325 ULONG_PTR dwCallbackId;
326 #endif
327 } RASDIALPARAMSW, *LPRASDIALPARAMSW;
328
329 typedef struct tagRASDIALPARAMSA {
330 DWORD dwSize;
331 CHAR szEntryName[RAS_MaxEntryName + 1];
332 CHAR szPhoneNumber[RAS_MaxPhoneNumber + 1];
333 CHAR szCallbackNumber[RAS_MaxCallbackNumber + 1];
334 CHAR szUserName[UNLEN + 1];
335 CHAR szPassword[PWLEN + 1];
336 CHAR szDomain[DNLEN + 1];
337 #if (WINVER >= 0x401)
338 DWORD dwSubEntry;
339 ULONG_PTR dwCallbackId;
340 #endif
341 } RASDIALPARAMSA, *LPRASDIALPARAMSA;
342
343 #if (WINVER >= 0x500)
344 typedef struct tagRASEAPINFO {
345 DWORD dwSizeofEapInfo;
346 BYTE *pbEapInfo;
347 } RASEAPINFO;
348 #endif
349
350 typedef struct tagRASDIALEXTENSIONS {
351 DWORD dwSize;
352 DWORD dwfOptions;
353 HWND hwndParent;
354 ULONG_PTR reserved;
355 #if (WINVER >= 0x500)
356 ULONG_PTR reserved1;
357 RASEAPINFO RasEapInfo;
358 #endif
359 } RASDIALEXTENSIONS, *LPRASDIALEXTENSIONS;
360
361 typedef struct tagRASENTRYNAMEW {
362 DWORD dwSize;
363 WCHAR szEntryName[RAS_MaxEntryName + 1];
364 #if (WINVER >= 0x500)
365 DWORD dwFlags;
366 WCHAR szPhonebookPath[MAX_PATH + 1];
367 #endif
368 } RASENTRYNAMEW, *LPRASENTRYNAMEW;
369
370 typedef struct tagRASENTRYNAMEA {
371 DWORD dwSize;
372 CHAR szEntryName[RAS_MaxEntryName + 1];
373 #if (WINVER >= 0x500)
374 DWORD dwFlags;
375 CHAR szPhonebookPath[MAX_PATH + 1];
376 #endif
377 } RASENTRYNAMEA, *LPRASENTRYNAMEA;
378
379 typedef struct tagRASAMBW {
380 DWORD dwSize;
381 DWORD dwError;
382 WCHAR szNetBiosError[NETBIOS_NAME_LEN + 1];
383 BYTE bLana;
384 } RASAMBW, *LPRASAMBW;
385
386 typedef struct tagRASAMBA {
387 DWORD dwSize;
388 DWORD dwError;
389 CHAR szNetBiosError[NETBIOS_NAME_LEN + 1];
390 BYTE bLana;
391 } RASAMBA, *LPRASAMBA;
392
393 typedef struct tagRASPPPNBFW {
394 DWORD dwSize;
395 DWORD dwError;
396 DWORD dwNetBiosError;
397 WCHAR szNetBiosError[NETBIOS_NAME_LEN + 1];
398 WCHAR szWorkstationName[NETBIOS_NAME_LEN + 1];
399 BYTE bLana;
400 } RASPPPNBFW, *LPRASPPPNBFW;
401
402 typedef struct tagRASPPPNBFA {
403 DWORD dwSize;
404 DWORD dwError;
405 DWORD dwNetBiosError;
406 CHAR szNetBiosError[NETBIOS_NAME_LEN + 1];
407 CHAR szWorkstationName[NETBIOS_NAME_LEN + 1];
408 BYTE bLana;
409 } RASPPPNBFA, *LPRASPPPNBFA;
410
411 typedef struct tagRASIPXW {
412 DWORD dwSize;
413 DWORD dwError;
414 WCHAR szIpxAddress[RAS_MaxIpxAddress + 1];
415 } RASPPPIPXW, *LPRASPPPIPXW;
416
417 typedef struct tagRASIPXA {
418 DWORD dwSize;
419 DWORD dwError;
420 CHAR szIpxAddress[RAS_MaxIpxAddress + 1];
421 } RASPPPIPXA, *LPRASPPPIPXA;
422
423 typedef struct tagRASPPPIPW {
424 DWORD dwSize;
425 DWORD dwError;
426 WCHAR szIpAddress[RAS_MaxIpAddress + 1];
427 #ifndef WINNT35COMPATIBLE
428 WCHAR szServerIpAddress[RAS_MaxIpAddress + 1];
429 #endif
430 #if (WINVER >= 0x500)
431 DWORD dwOptions;
432 DWORD dwServerOptions;
433 #endif
434 } RASPPPIPW, *LPRASPPPIPW;
435
436 typedef struct tagRASPPPIPA {
437 DWORD dwSize;
438 DWORD dwError;
439 CHAR szIpAddress[RAS_MaxIpAddress + 1];
440 #ifndef WINNT35COMPATIBLE
441 CHAR szServerIpAddress[RAS_MaxIpAddress + 1];
442 #endif
443 #if (WINVER >= 0x500)
444 DWORD dwOptions;
445 DWORD dwServerOptions;
446 #endif
447 } RASPPPIPA, *LPRASPPPIPA;
448
449 typedef struct tagRASPPPLCPW {
450 DWORD dwSize;
451 BOOL fBundled;
452 #if (WINVER >= 0x500)
453 DWORD dwError;
454 DWORD dwAuthenticationProtocol;
455 DWORD dwAuthenticationData;
456 DWORD dwEapTypeId;
457 DWORD dwServerAuthenticationProtocol;
458 DWORD dwServerAuthenticationData;
459 DWORD dwServerEapTypeId;
460 BOOL fMultilink;
461 DWORD dwTerminateReason;
462 DWORD dwServerTerminateReason;
463 WCHAR szReplyMessage[RAS_MaxReplyMessage];
464 DWORD dwOptions;
465 DWORD dwServerOptions;
466 #endif
467 } RASPPPLCPW, *LPRASPPPLCPW;
468
469 typedef struct tagRASPPPLCPA {
470 DWORD dwSize;
471 BOOL fBundled;
472 #if (WINVER >= 0x500)
473 DWORD dwError;
474 DWORD dwAuthenticationProtocol;
475 DWORD dwAuthenticationData;
476 DWORD dwEapTypeId;
477 DWORD dwServerAuthenticationProtocol;
478 DWORD dwServerAuthenticationData;
479 DWORD dwServerEapTypeId;
480 BOOL fMultilink;
481 DWORD dwTerminateReason;
482 DWORD dwServerTerminateReason;
483 CHAR szReplyMessage[RAS_MaxReplyMessage];
484 DWORD dwOptions;
485 DWORD dwServerOptions;
486 #endif
487 } RASPPPLCPA, *LPRASPPPLCPA;
488
489 typedef struct tagRASSLIPW {
490 DWORD dwSize;
491 DWORD dwError;
492 WCHAR szIpAddress[RAS_MaxIpAddress + 1];
493 } RASSLIPW, *LPRASSLIPW;
494
495
496 typedef struct tagRASSLIPA {
497 DWORD dwSize;
498 DWORD dwError;
499 CHAR szIpAddress[RAS_MaxIpAddress + 1];
500 } RASSLIPA, *LPRASSLIPA;
501
502 typedef struct tagRASDEVINFOW {
503 DWORD dwSize;
504 WCHAR szDeviceType[RAS_MaxDeviceType + 1];
505 WCHAR szDeviceName[RAS_MaxDeviceName + 1];
506 } RASDEVINFOW, *LPRASDEVINFOW;
507
508 typedef struct tagRASDEVINFOA {
509 DWORD dwSize;
510 CHAR szDeviceType[RAS_MaxDeviceType + 1];
511 CHAR szDeviceName[RAS_MaxDeviceName + 1];
512 } RASDEVINFOA, *LPRASDEVINFOA;
513
514 typedef struct tagRASCTRYINFO {
515 DWORD dwSize;
516 DWORD dwCountryID;
517 DWORD dwNextCountryID;
518 DWORD dwCountryCode;
519 DWORD dwCountryNameOffset;
520 } RASCTRYINFO, *LPRASCTRYINFO;
521
522 typedef RASCTRYINFO RASCTRYINFOW, *LPRASCTRYINFOW;
523 typedef RASCTRYINFO RASCTRYINFOA, *LPRASCTRYINFOA;
524
525 typedef struct tagRASIPADDR {
526 BYTE a;
527 BYTE b;
528 BYTE c;
529 BYTE d;
530 } RASIPADDR;
531
532 typedef struct tagRASENTRYW {
533 DWORD dwSize;
534 DWORD dwfOptions;
535 DWORD dwCountryID;
536 DWORD dwCountryCode;
537 WCHAR szAreaCode[RAS_MaxAreaCode + 1];
538 WCHAR szLocalPhoneNumber[RAS_MaxPhoneNumber + 1];
539 DWORD dwAlternateOffset;
540 RASIPADDR ipaddr;
541 RASIPADDR ipaddrDns;
542 RASIPADDR ipaddrDnsAlt;
543 RASIPADDR ipaddrWins;
544 RASIPADDR ipaddrWinsAlt;
545 DWORD dwFrameSize;
546 DWORD dwfNetProtocols;
547 DWORD dwFramingProtocol;
548 WCHAR szScript[MAX_PATH];
549 WCHAR szAutodialDll[MAX_PATH];
550 WCHAR szAutodialFunc[MAX_PATH];
551 WCHAR szDeviceType[RAS_MaxDeviceType + 1];
552 WCHAR szDeviceName[RAS_MaxDeviceName + 1];
553 WCHAR szX25PadType[RAS_MaxPadType + 1];
554 WCHAR szX25Address[RAS_MaxX25Address + 1];
555 WCHAR szX25Facilities[RAS_MaxFacilities + 1];
556 WCHAR szX25UserData[RAS_MaxUserData + 1];
557 DWORD dwChannels;
558 DWORD dwReserved1;
559 DWORD dwReserved2;
560 #if (WINVER >= 0x401)
561 DWORD dwSubEntries;
562 DWORD dwDialMode;
563 DWORD dwDialExtraPercent;
564 DWORD dwDialExtraSampleSeconds;
565 DWORD dwHangUpExtraPercent;
566 DWORD dwHangUpExtraSampleSeconds;
567 DWORD dwIdleDisconnectSeconds;
568 #endif
569 #if (WINVER >= 0x500)
570 DWORD dwType;
571 DWORD dwEncryptionType;
572 DWORD dwCustomAuthKey;
573 GUID guidId;
574 WCHAR szCustomDialDll[MAX_PATH];
575 DWORD dwVpnStrategy;
576 #endif
577 #if (WINVER >= 0x501)
578 DWORD dwfOptions2;
579 DWORD dwfOptions3;
580 WCHAR szDnsSuffix[RAS_MaxDnsSuffix];
581 DWORD dwTcpWindowSize;
582 WCHAR szPrerequisitePbk[MAX_PATH];
583 WCHAR szPrerequisiteEntry[RAS_MaxEntryName + 1];
584 DWORD dwRedialCount;
585 DWORD dwRedialPause;
586 #endif /*(WINVER >= 0x501)*/
587 } RASENTRYW, *LPRASENTRYW;
588
589 typedef struct tagRASENTRYA {
590 DWORD dwSize;
591 DWORD dwfOptions;
592 DWORD dwCountryID;
593 DWORD dwCountryCode;
594 CHAR szAreaCode[RAS_MaxAreaCode + 1];
595 CHAR szLocalPhoneNumber[RAS_MaxPhoneNumber + 1];
596 DWORD dwAlternateOffset;
597 RASIPADDR ipaddr;
598 RASIPADDR ipaddrDns;
599 RASIPADDR ipaddrDnsAlt;
600 RASIPADDR ipaddrWins;
601 RASIPADDR ipaddrWinsAlt;
602 DWORD dwFrameSize;
603 DWORD dwfNetProtocols;
604 DWORD dwFramingProtocol;
605 CHAR szScript[MAX_PATH];
606 CHAR szAutodialDll[MAX_PATH];
607 CHAR szAutodialFunc[MAX_PATH];
608 CHAR szDeviceType[RAS_MaxDeviceType + 1];
609 CHAR szDeviceName[RAS_MaxDeviceName + 1];
610 CHAR szX25PadType[RAS_MaxPadType + 1];
611 CHAR szX25Address[RAS_MaxX25Address + 1];
612 CHAR szX25Facilities[RAS_MaxFacilities + 1];
613 CHAR szX25UserData[RAS_MaxUserData + 1];
614 DWORD dwChannels;
615 DWORD dwReserved1;
616 DWORD dwReserved2;
617 #if (WINVER >= 0x401)
618 DWORD dwSubEntries;
619 DWORD dwDialMode;
620 DWORD dwDialExtraPercent;
621 DWORD dwDialExtraSampleSeconds;
622 DWORD dwHangUpExtraPercent;
623 DWORD dwHangUpExtraSampleSeconds;
624 DWORD dwIdleDisconnectSeconds;
625 #endif
626 #if (WINVER >= 0x500)
627 DWORD dwType;
628 DWORD dwEncryptionType;
629 DWORD dwCustomAuthKey;
630 GUID guidId;
631 CHAR szCustomDialDll[MAX_PATH];
632 DWORD dwVpnStrategy;
633 #endif
634 #if (WINVER >= 0x501)
635 DWORD dwfOptions2;
636 DWORD dwfOptions3;
637 CHAR szDnsSuffix[RAS_MaxDnsSuffix];
638 DWORD dwTcpWindowSize;
639 CHAR szPrerequisitePbk[MAX_PATH];
640 CHAR szPrerequisiteEntry[RAS_MaxEntryName + 1];
641 DWORD dwRedialCount;
642 DWORD dwRedialPause;
643 #endif /*(WINVER >= 0x501)*/
644 } RASENTRYA, *LPRASENTRYA;
645
646
647 #if (WINVER >= 0x401)
648 typedef struct tagRASADPARAMS {
649 DWORD dwSize;
650 HWND hwndOwner;
651 DWORD dwFlags;
652 LONG xDlg;
653 LONG yDlg;
654 } RASADPARAMS, *LPRASADPARAMS;
655
656 typedef struct tagRASSUBENTRYW {
657 DWORD dwSize;
658 DWORD dwfFlags;
659 WCHAR szDeviceType[RAS_MaxDeviceType + 1];
660 WCHAR szDeviceName[RAS_MaxDeviceName + 1];
661 WCHAR szLocalPhoneNumber[RAS_MaxPhoneNumber + 1];
662 DWORD dwAlternateOffset;
663 } RASSUBENTRYW, *LPRASSUBENTRYW;
664
665 typedef struct tagRASSUBENTRYA {
666 DWORD dwSize;
667 DWORD dwfFlags;
668 CHAR szDeviceType[RAS_MaxDeviceType + 1];
669 CHAR szDeviceName[RAS_MaxDeviceName + 1];
670 CHAR szLocalPhoneNumber[RAS_MaxPhoneNumber + 1];
671 DWORD dwAlternateOffset;
672 } RASSUBENTRYA, *LPRASSUBENTRYA;
673
674 typedef struct tagRASCREDENTIALSW {
675 DWORD dwSize;
676 DWORD dwMask;
677 WCHAR szUserName[UNLEN + 1];
678 WCHAR szPassword[PWLEN + 1];
679 WCHAR szDomain[DNLEN + 1];
680 } RASCREDENTIALSW, *LPRASCREDENTIALSW;
681
682 typedef struct tagRASCREDENTIALSA {
683 DWORD dwSize;
684 DWORD dwMask;
685 CHAR szUserName[UNLEN + 1];
686 CHAR szPassword[PWLEN + 1];
687 CHAR szDomain[DNLEN + 1];
688 } RASCREDENTIALSA, *LPRASCREDENTIALSA;
689
690 typedef struct tagRASAUTODIALENTRYW {
691 DWORD dwSize;
692 DWORD dwFlags;
693 DWORD dwDialingLocation;
694 WCHAR szEntry[RAS_MaxEntryName + 1];
695 } RASAUTODIALENTRYW, *LPRASAUTODIALENTRYW;
696
697 typedef struct tagRASAUTODIALENTRYA {
698 DWORD dwSize;
699 DWORD dwFlags;
700 DWORD dwDialingLocation;
701 CHAR szEntry[RAS_MaxEntryName + 1];
702 } RASAUTODIALENTRYA, *LPRASAUTODIALENTRYA;
703 #endif /* (WINVER >= 0x401) */
704
705 #if (WINVER >= 0x500)
706 typedef struct tagRASPPPCCP {
707 DWORD dwSize;
708 DWORD dwError;
709 DWORD dwCompressionAlgorithm;
710 DWORD dwOptions;
711 DWORD dwServerCompressionAlgorithm;
712 DWORD dwServerOptions;
713 } RASPPPCCP, *LPRASPPPCCP;
714
715 typedef struct tagRASEAPUSERIDENTITYW {
716 WCHAR szUserName[UNLEN + 1];
717 DWORD dwSizeofEapInfo;
718 BYTE pbEapInfo[1];
719 } RASEAPUSERIDENTITYW, *LPRASEAPUSERIDENTITYW;
720
721 typedef struct tagRASEAPUSERIDENTITYA {
722 CHAR szUserName[UNLEN + 1];
723 DWORD dwSizeofEapInfo;
724 BYTE pbEapInfo[1];
725 } RASEAPUSERIDENTITYA, *LPRASEAPUSERIDENTITYA;
726
727 typedef struct tagRAS_STATS {
728 DWORD dwSize;
729 DWORD dwBytesXmited;
730 DWORD dwBytesRcved;
731 DWORD dwFramesXmited;
732 DWORD dwFramesRcved;
733 DWORD dwCrcErr;
734 DWORD dwTimeoutErr;
735 DWORD dwAlignmentErr;
736 DWORD dwHardwareOverrunErr;
737 DWORD dwFramingErr;
738 DWORD dwBufferOverrunErr;
739 DWORD dwCompressionRatioIn;
740 DWORD dwCompressionRatioOut;
741 DWORD dwBps;
742 DWORD dwConnectDuration;
743 } RAS_STATS, *PRAS_STATS;
744 #endif /* (WINVER >= 0x500) */
745
746
747 /* UNICODE typedefs for structures*/
748 #ifdef UNICODE
749 typedef RASCONNW RASCONN, *LPRASCONN;
750 typedef RASENTRYW RASENTRY, *LPRASENTRY;
751 typedef RASCONNSTATUSW RASCONNSTATUS, *LPRASCONNSTATUS;
752 typedef RASDIALPARAMSW RASDIALPARAMS, *LPRASDIALPARAMS;
753 typedef RASAMBW RASAMB, *LPRASAM;
754 typedef RASPPPNBFW RASPPPNBF, *LPRASPPPNBF;
755 typedef RASPPPIPXW RASPPPIPX, *LPRASPPPIPX;
756 typedef RASPPPIPW RASPPPIP, *LPRASPPPIP;
757 typedef RASPPPLCPW RASPPPLCP, *LPRASPPPLCP;
758 typedef RASSLIPW RASSLIP, *LPRASSLIP;
759 typedef RASDEVINFOW RASDEVINFO, *LPRASDEVINFO;
760 typedef RASENTRYNAMEW RASENTRYNAME, *LPRASENTRYNAME;
761
762 #if (WINVER >= 0x401)
763 typedef RASSUBENTRYW RASSUBENTRY, *LPRASSUBENTRY;
764 typedef RASCREDENTIALSW RASCREDENTIALS, *LPRASCREDENTIALS;
765 typedef RASAUTODIALENTRYW RASAUTODIALENTRY, *LPRASAUTODIALENTRY;
766 #endif /* (WINVER >= 0x401) */
767
768 #if (WINVER >= 0x500)
769 typedef RASEAPUSERIDENTITYW RASEAPUSERIDENTITY, *LPRASEAPUSERIDENTITY;
770 typedef DWORD (WINAPI *PFNRASGETBUFFER) (PBYTE *ppBuffer, PDWORD pdwSize);
771 typedef DWORD (WINAPI *PFNRASFREEBUFFER) (PBYTE pBuffer);
772 typedef DWORD (WINAPI *PFNRASSENDBUFFER) (HANDLE hPort, PBYTE pBuffer, DWORD dwSize);
773 typedef DWORD (WINAPI *PFNRASRECEIVEBUFFER) (HANDLE hPort, PBYTE pBuffer, PDWORD pdwSize, DWORD dwTimeOut, HANDLE hEvent);
774 typedef DWORD (WINAPI *PFNRASRETRIEVEBUFFER) (HANDLE hPort, PBYTE pBuffer, PDWORD pdwSize);
775 typedef DWORD (WINAPI *RasCustomScriptExecuteFn) (HANDLE hPort, LPCWSTR lpszPhonebook, LPCWSTR lpszEntryName, PFNRASGETBUFFER pfnRasGetBuffer, PFNRASFREEBUFFER pfnRasFreeBuffer, PFNRASSENDBUFFER pfnRasSendBuffer, PFNRASRECEIVEBUFFER pfnRasReceiveBuffer, PFNRASRETRIEVEBUFFER pfnRasRetrieveBuffer, HWND hWnd, RASDIALPARAMS *pRasDialParams, PVOID pvReserved);
776 #endif /* (WINVER >= 0x500) */
777
778 #if (WINVER >= 0x501)
779 typedef struct tagRASCOMMSETTINGS
780 {
781 DWORD dwSize;
782 BYTE bParity;
783 BYTE bStop;
784 BYTE bByteSize;
785 BYTE bAlign;
786 } RASCOMMSETTINGS;
787 typedef DWORD (WINAPI *PFNRASSETCOMMSETTINGS) (HANDLE hPort,RASCOMMSETTINGS *pRasCommSettings,PVOID pvReserved);
788 typedef struct tagRASCUSTOMSCRIPTEXTENSIONS
789 {
790 DWORD dwSize;
791 PFNRASSETCOMMSETTINGS pfnRasSetCommSettings;
792 } RASCUSTOMSCRIPTEXTENSIONS;
793 #endif /*(WINVER >= 0x501)*/
794
795 #else /* ! defined UNICODE */
796 typedef RASCONNA RASCONN, *LPRASCONN;
797 typedef RASENTRYA RASENTRY, *LPRASENTRY;
798 typedef RASCONNSTATUSA RASCONNSTATUS, *LPRASCONNSTATUS;
799 typedef RASDIALPARAMSA RASDIALPARAMS, *LPRASDIALPARAMS;
800 typedef RASAMBA RASAMB, *LPRASAM;
801 typedef RASPPPNBFA RASPPPNBF, *LPRASPPPNBF;
802 typedef RASPPPIPXA RASPPPIPX, *LPRASPPPIPX;
803 typedef RASPPPIPA RASPPPIP, *LPRASPPPIP;
804 typedef RASPPPLCPA RASPPPLCP, *LPRASPPPLCP;
805 typedef RASSLIPA RASSLIP, *LPRASSLIP;
806 typedef RASDEVINFOA RASDEVINFO, *LPRASDEVINFO;
807 typedef RASENTRYNAMEA RASENTRYNAME, *LPRASENTRYNAME;
808
809 #if (WINVER >= 0x401)
810 typedef RASSUBENTRYA RASSUBENTRY, *LPRASSUBENTRY;
811 typedef RASCREDENTIALSA RASCREDENTIALS, *LPRASCREDENTIALS;
812 typedef RASAUTODIALENTRYA RASAUTODIALENTRY, *LPRASAUTODIALENTRY;
813 #endif /*(WINVER >= 0x401)*/
814 #if (WINVER >= 0x500)
815 typedef RASEAPUSERIDENTITYA RASEAPUSERIDENTITY, *LPRASEAPUSERIDENTITY;
816 #endif /* (WINVER >= 0x500) */
817 #endif /* ! UNICODE */
818
819 /* Callback prototypes */
820 typedef BOOL (WINAPI * ORASADFUNC) (HWND, LPSTR, DWORD, LPDWORD); /* deprecated */
821 typedef VOID (WINAPI * RASDIALFUNC) (UINT, RASCONNSTATE, DWORD);
822 typedef VOID (WINAPI * RASDIALFUNC1) (HRASCONN, UINT, RASCONNSTATE, DWORD, DWORD);
823 typedef DWORD (WINAPI * RASDIALFUNC2) (ULONG_PTR, DWORD, HRASCONN, UINT, RASCONNSTATE, DWORD, DWORD);
824
825 /* External functions */
826 DWORD APIENTRY RasDialA (LPRASDIALEXTENSIONS, LPCSTR, LPRASDIALPARAMSA, DWORD, LPVOID, LPHRASCONN);
827 DWORD APIENTRY RasDialW (LPRASDIALEXTENSIONS, LPCWSTR, LPRASDIALPARAMSW, DWORD, LPVOID, LPHRASCONN);
828 DWORD APIENTRY RasEnumConnectionsA (LPRASCONNA, LPDWORD, LPDWORD);
829 DWORD APIENTRY RasEnumConnectionsW (LPRASCONNW, LPDWORD, LPDWORD);
830 DWORD APIENTRY RasEnumEntriesA (LPCSTR, LPCSTR, LPRASENTRYNAMEA, LPDWORD, LPDWORD);
831 DWORD APIENTRY RasEnumEntriesW (LPCWSTR, LPCWSTR, LPRASENTRYNAMEW, LPDWORD, LPDWORD);
832 DWORD APIENTRY RasGetConnectStatusA (HRASCONN, LPRASCONNSTATUSA);
833 DWORD APIENTRY RasGetConnectStatusW (HRASCONN, LPRASCONNSTATUSW);
834 DWORD APIENTRY RasGetErrorStringA (UINT, LPSTR, DWORD);
835 DWORD APIENTRY RasGetErrorStringW (UINT, LPWSTR, DWORD);
836 DWORD APIENTRY RasHangUpA (HRASCONN);
837 DWORD APIENTRY RasHangUpW (HRASCONN);
838 DWORD APIENTRY RasGetProjectionInfoA (HRASCONN, RASPROJECTION, LPVOID, LPDWORD);
839 DWORD APIENTRY RasGetProjectionInfoW (HRASCONN, RASPROJECTION, LPVOID, LPDWORD);
840 DWORD APIENTRY RasCreatePhonebookEntryA (HWND, LPCSTR);
841 DWORD APIENTRY RasCreatePhonebookEntryW (HWND, LPCWSTR);
842 DWORD APIENTRY RasEditPhonebookEntryA (HWND, LPCSTR, LPCSTR);
843 DWORD APIENTRY RasEditPhonebookEntryW (HWND, LPCWSTR, LPCWSTR);
844 DWORD APIENTRY RasSetEntryDialParamsA (LPCSTR, LPRASDIALPARAMSA, BOOL);
845 DWORD APIENTRY RasSetEntryDialParamsW (LPCWSTR, LPRASDIALPARAMSW, BOOL);
846 DWORD APIENTRY RasGetEntryDialParamsA (LPCSTR, LPRASDIALPARAMSA, LPBOOL);
847 DWORD APIENTRY RasGetEntryDialParamsW (LPCWSTR, LPRASDIALPARAMSW, LPBOOL);
848 DWORD APIENTRY RasEnumDevicesA (LPRASDEVINFOA, LPDWORD, LPDWORD);
849 DWORD APIENTRY RasEnumDevicesW (LPRASDEVINFOW, LPDWORD, LPDWORD);
850 DWORD APIENTRY RasGetCountryInfoA (LPRASCTRYINFOA, LPDWORD);
851 DWORD APIENTRY RasGetCountryInfoW (LPRASCTRYINFOW, LPDWORD);
852 DWORD APIENTRY RasGetEntryPropertiesA (LPCSTR, LPCSTR, LPRASENTRYA, LPDWORD, LPBYTE, LPDWORD);
853 DWORD APIENTRY RasGetEntryPropertiesW (LPCWSTR, LPCWSTR, LPRASENTRYW, LPDWORD, LPBYTE, LPDWORD);
854 DWORD APIENTRY RasSetEntryPropertiesA (LPCSTR, LPCSTR, LPRASENTRYA, DWORD, LPBYTE, DWORD);
855 DWORD APIENTRY RasSetEntryPropertiesW (LPCWSTR, LPCWSTR, LPRASENTRYW, DWORD, LPBYTE, DWORD);
856 DWORD APIENTRY RasRenameEntryA (LPCSTR, LPCSTR, LPCSTR);
857 DWORD APIENTRY RasRenameEntryW (LPCWSTR, LPCWSTR, LPCWSTR);
858 DWORD APIENTRY RasDeleteEntryA (LPCSTR, LPCSTR);
859 DWORD APIENTRY RasDeleteEntryW (LPCWSTR, LPCWSTR);
860 DWORD APIENTRY RasValidateEntryNameA (LPCSTR, LPCSTR);
861 DWORD APIENTRY RasValidateEntryNameW (LPCWSTR, LPCWSTR);
862
863 #if (WINVER >= 0x401)
864 typedef BOOL (WINAPI * RASADFUNCA) (LPSTR, LPSTR, LPRASADPARAMS, LPDWORD);
865 typedef BOOL (WINAPI * RASADFUNCW) (LPWSTR, LPWSTR, LPRASADPARAMS, LPDWORD);
866
867 DWORD APIENTRY RasGetSubEntryHandleA (HRASCONN, DWORD, LPHRASCONN);
868 DWORD APIENTRY RasGetSubEntryHandleW (HRASCONN, DWORD, LPHRASCONN);
869 DWORD APIENTRY RasGetCredentialsA (LPCSTR, LPCSTR, LPRASCREDENTIALSA);
870 DWORD APIENTRY RasGetCredentialsW (LPCWSTR, LPCWSTR, LPRASCREDENTIALSW);
871 DWORD APIENTRY RasSetCredentialsA (LPCSTR, LPCSTR, LPRASCREDENTIALSA, BOOL);
872 DWORD APIENTRY RasSetCredentialsW (LPCWSTR, LPCWSTR, LPRASCREDENTIALSW, BOOL);
873 DWORD APIENTRY RasConnectionNotificationA (HRASCONN, HANDLE, DWORD);
874 DWORD APIENTRY RasConnectionNotificationW (HRASCONN, HANDLE, DWORD);
875 DWORD APIENTRY RasGetSubEntryPropertiesA (LPCSTR, LPCSTR, DWORD,
876 LPRASSUBENTRYA, LPDWORD, LPBYTE, LPDWORD);
877 DWORD APIENTRY RasGetSubEntryPropertiesW (LPCWSTR, LPCWSTR, DWORD,
878 LPRASSUBENTRYW, LPDWORD, LPBYTE, LPDWORD);
879 DWORD APIENTRY RasSetSubEntryPropertiesA (LPCSTR, LPCSTR, DWORD,
880 LPRASSUBENTRYA, DWORD, LPBYTE, DWORD);
881 DWORD APIENTRY RasSetSubEntryPropertiesW (LPCWSTR, LPCWSTR, DWORD,
882 LPRASSUBENTRYW, DWORD, LPBYTE, DWORD);
883 DWORD APIENTRY RasGetAutodialAddressA (LPCSTR, LPDWORD, LPRASAUTODIALENTRYA,
884 LPDWORD, LPDWORD);
885 DWORD APIENTRY RasGetAutodialAddressW (LPCWSTR, LPDWORD,
886 LPRASAUTODIALENTRYW, LPDWORD, LPDWORD);
887 DWORD APIENTRY RasSetAutodialAddressA (LPCSTR, DWORD, LPRASAUTODIALENTRYA,
888 DWORD, DWORD);
889 DWORD APIENTRY RasSetAutodialAddressW (LPCWSTR, DWORD, LPRASAUTODIALENTRYW,
890 DWORD, DWORD);
891 DWORD APIENTRY RasEnumAutodialAddressesA (LPSTR *, LPDWORD, LPDWORD);
892 DWORD APIENTRY RasEnumAutodialAddressesW (LPWSTR *, LPDWORD, LPDWORD);
893 DWORD APIENTRY RasGetAutodialEnableA (DWORD, LPBOOL);
894 DWORD APIENTRY RasGetAutodialEnableW (DWORD, LPBOOL);
895 DWORD APIENTRY RasSetAutodialEnableA (DWORD, BOOL);
896 DWORD APIENTRY RasSetAutodialEnableW (DWORD, BOOL);
897 DWORD APIENTRY RasGetAutodialParamA (DWORD, LPVOID, LPDWORD);
898 DWORD APIENTRY RasGetAutodialParamW (DWORD, LPVOID, LPDWORD);
899 DWORD APIENTRY RasSetAutodialParamA (DWORD, LPVOID, DWORD);
900 DWORD APIENTRY RasSetAutodialParamW (DWORD, LPVOID, DWORD);
901 #endif
902
903 #if (WINVER >= 0x500)
904 typedef DWORD (WINAPI * RasCustomHangUpFn) (HRASCONN);
905 typedef DWORD (WINAPI * RasCustomDeleteEntryNotifyFn) (LPCTSTR, LPCTSTR, DWORD);
906 typedef DWORD (WINAPI * RasCustomDialFn) (HINSTANCE, LPRASDIALEXTENSIONS,
907 LPCTSTR, LPRASDIALPARAMS, DWORD, LPVOID, LPHRASCONN, DWORD);
908
909 DWORD APIENTRY RasInvokeEapUI (HRASCONN, DWORD, LPRASDIALEXTENSIONS, HWND);
910 DWORD APIENTRY RasGetLinkStatistics (HRASCONN, DWORD, RAS_STATS*);
911 DWORD APIENTRY RasGetConnectionStatistics (HRASCONN, RAS_STATS*);
912 DWORD APIENTRY RasClearLinkStatistics (HRASCONN, DWORD);
913 DWORD APIENTRY RasClearConnectionStatistics (HRASCONN);
914 DWORD APIENTRY RasGetEapUserDataA (HANDLE, LPCSTR, LPCSTR, BYTE*, DWORD*);
915 DWORD APIENTRY RasGetEapUserDataW (HANDLE, LPCWSTR, LPCWSTR, BYTE*, DWORD*);
916 DWORD APIENTRY RasSetEapUserDataA (HANDLE, LPCSTR, LPCSTR, BYTE*, DWORD);
917 DWORD APIENTRY RasSetEapUserDataW (HANDLE, LPCWSTR, LPCWSTR, BYTE*, DWORD);
918 DWORD APIENTRY RasGetCustomAuthDataA (LPCSTR, LPCSTR, BYTE*, DWORD*);
919 DWORD APIENTRY RasGetCustomAuthDataW (LPCWSTR, LPCWSTR, BYTE*, DWORD*);
920 DWORD APIENTRY RasSetCustomAuthDataA (LPCSTR, LPCSTR, BYTE*, DWORD);
921 DWORD APIENTRY RasSetCustomAuthDataW (LPCWSTR, LPCWSTR, BYTE*, DWORD);
922 DWORD APIENTRY RasGetEapUserIdentityW (LPCWSTR, LPCWSTR, DWORD, HWND, LPRASEAPUSERIDENTITYW*);
923 DWORD APIENTRY RasGetEapUserIdentityA (LPCSTR, LPCSTR, DWORD, HWND, LPRASEAPUSERIDENTITYA*);
924 VOID APIENTRY RasFreeEapUserIdentityW (LPRASEAPUSERIDENTITYW);
925 VOID APIENTRY RasFreeEapUserIdentityA (LPRASEAPUSERIDENTITYA);
926 #endif /* (WINVER >= 0x500) */
927 #if (WINVER >=0x501)
928 DWORD APIENTRY RasDeleteSubEntryA(LPCSTR pszPhonebook, LPCSTR pszEntry, DWORD dwSubentryId);
929 DWORD APIENTRY RasDeleteSubEntryW(LPCWSTR pszPhonebook, LPCWSTR pszEntry, DWORD dwSubEntryId);
930 #endif // (WINVER >=0x501)
931
932
933 /* UNICODE defines for functions */
934 #ifdef UNICODE
935 #define RasDial RasDialW
936 #define RasEnumConnections RasEnumConnectionsW
937 #define RasEnumEntries RasEnumEntriesW
938 #define RasGetConnectStatus RasGetConnectStatusW
939 #define RasGetErrorString RasGetErrorStringW
940 #define RasHangUp RasHangUpW
941 #define RasGetProjectionInfo RasGetProjectionInfoW
942 #define RasCreatePhonebookEntry RasCreatePhonebookEntryW
943 #define RasEditPhonebookEntry RasEditPhonebookEntryW
944 #define RasSetEntryDialParams RasSetEntryDialParamsW
945 #define RasGetEntryDialParams RasGetEntryDialParamsW
946 #define RasEnumDevices RasEnumDevicesW
947 #define RasGetCountryInfo RasGetCountryInfoW
948 #define RasGetEntryProperties RasGetEntryPropertiesW
949 #define RasSetEntryProperties RasSetEntryPropertiesW
950 #define RasRenameEntry RasRenameEntryW
951 #define RasDeleteEntry RasDeleteEntryW
952 #define RasValidateEntryName RasValidateEntryNameW
953 #if (WINVER >= 0x401)
954 #define RASADFUNC RASADFUNCW
955 #define RasGetSubEntryHandle RasGetSubEntryHandleW
956 #define RasConnectionNotification RasConnectionNotificationW
957 #define RasGetSubEntryProperties RasGetSubEntryPropertiesW
958 #define RasSetSubEntryProperties RasSetSubEntryPropertiesW
959 #define RasGetCredentials RasGetCredentialsW
960 #define RasSetCredentials RasSetCredentialsW
961 #define RasGetAutodialAddress RasGetAutodialAddressW
962 #define RasSetAutodialAddress RasSetAutodialAddressW
963 #define RasEnumAutodialAddresses RasEnumAutodialAddressesW
964 #define RasGetAutodialEnable RasGetAutodialEnableW
965 #define RasSetAutodialEnable RasSetAutodialEnableW
966 #define RasGetAutodialParam RasGetAutodialParamW
967 #define RasSetAutodialParam RasSetAutodialParamW
968 #endif /* (WINVER >= 0x401) */
969 #if (WINVER >= 0x500)
970 #define RasGetEapUserData RasGetEapUserDataW
971 #define RasSetEapUserData RasSetEapUserDataW
972 #define RasGetCustomAuthData RasGetCustomAuthDataW
973 #define RasSetCustomAuthData RasSetCustomAuthDataW
974 #define RasGetEapUserIdentity RasGetEapUserIdentityW
975 #define RasFreeEapUserIdentity RasFreeEapUserIdentityW
976 #endif /* (WINVER >= 0x500) */
977 #if (WINVER >= 0x501)
978 #define RasDeleteSubEntry RasDeleteSubEntryW
979 #endif /*(WINVER >= 0x501)*/
980
981 #else /* ! defined UNICODE */
982 #define RasDial RasDialA
983 #define RasEnumConnections RasEnumConnectionsA
984 #define RasEnumEntries RasEnumEntriesA
985 #define RasGetConnectStatus RasGetConnectStatusA
986 #define RasGetErrorString RasGetErrorStringA
987 #define RasHangUp RasHangUpA
988 #define RasGetProjectionInfo RasGetProjectionInfoA
989 #define RasCreatePhonebookEntry RasCreatePhonebookEntryA
990 #define RasEditPhonebookEntry RasEditPhonebookEntryA
991 #define RasSetEntryDialParams RasSetEntryDialParamsA
992 #define RasGetEntryDialParams RasGetEntryDialParamsA
993 #define RasEnumDevices RasEnumDevicesA
994 #define RasGetCountryInfo RasGetCountryInfoA
995 #define RasGetEntryProperties RasGetEntryPropertiesA
996 #define RasSetEntryProperties RasSetEntryPropertiesA
997 #define RasRenameEntry RasRenameEntryA
998 #define RasDeleteEntry RasDeleteEntryA
999 #define RasValidateEntryName RasValidateEntryNameA
1000
1001 #if (WINVER >= 0x401)
1002 #define RASADFUNC RASADFUNCA
1003 #define RasGetSubEntryHandle RasGetSubEntryHandleA
1004 #define RasConnectionNotification RasConnectionNotificationA
1005 #define RasGetSubEntryProperties RasGetSubEntryPropertiesA
1006 #define RasSetSubEntryProperties RasSetSubEntryPropertiesA
1007 #define RasGetCredentials RasGetCredentialsA
1008 #define RasSetCredentials RasSetCredentialsA
1009 #define RasGetAutodialAddress RasGetAutodialAddressA
1010 #define RasSetAutodialAddress RasSetAutodialAddressA
1011 #define RasEnumAutodialAddressesRasEnumAutodialAddressesA
1012 #define RasGetAutodialEnable RasGetAutodialEnableA
1013 #define RasSetAutodialEnable RasSetAutodialEnableA
1014 #define RasGetAutodialParam RasGetAutodialParamA
1015 #define RasSetAutodialParam RasSetAutodialParamA
1016 #endif /*(WINVER >= 0x401)*/
1017
1018 #if (WINVER >= 0x500)
1019 #define RasGetEapUserData RasGetEapUserDataA
1020 #define RasSetEapUserData RasSetEapUserDataA
1021 #define RasGetCustomAuthData RasGetCustomAuthDataA
1022 #define RasSetCustomAuthData RasSetCustomAuthDataA
1023 #define RasGetEapUserIdentity RasGetEapUserIdentityA
1024 #define RasFreeEapUserIdentity RasFreeEapUserIdentityA
1025 #endif /* (WINVER >= 0x500) */
1026 #if (WINVER >= 0x501)
1027 #define RasDeleteSubEntry RasDeleteSubEntryA
1028 #endif /*(WINVER >= 0x501)*/
1029 #endif /* ! UNICODE */
1030
1031 #ifdef __cplusplus
1032 }
1033 #endif
1034 #include <poppack.h>
1035 #endif /* _RAS_H */