Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

102 lines
6.0 KiB

  1. //+----------------------------------------------------------------------------
  2. //
  3. // File: raslink.cpp
  4. //
  5. // Module: CMDIAL32.DLL AND CMUTOA.DLL
  6. //
  7. // Synopsis: Declaration of the function name lists that are used for RAS
  8. // linkage.
  9. //
  10. // Copyright (c) 1999 Microsoft Corporation
  11. //
  12. // Author: quintinb Created Header 08/19/99
  13. //
  14. //+----------------------------------------------------------------------------
  15. // The RAS linkage system in CM is somewhat complicated. Unfortunately, RAS is different
  16. // on pretty much every version of the OS we have ever shipped. There are APIs on the NT
  17. // family that don't exist on the Win9x side and vice versa. In order for CM to dynamically
  18. // allocate the correct functions without too much work, we have created the following
  19. // arrays of function names used by LinkToRas. To further complicate matters, we have
  20. // the ANSI versus Unicode problem. Thus you will notice that we have three sets of
  21. // function lists. The c_ArrayOfRasFuncsA is actually used by Cmutoa.dll to load the
  22. // real ANSI RAS functions that it calls after converting the parameters from Unicode to
  23. // ANSI in its UA functions, which is why we have the c_ArrayOfRasFuncsUA list. These
  24. // functions are the wrappers exported by cmutoa.dll that cmdial32.dll links to on Win9x
  25. // instead of the W APIs located in c_ArrayOfRasFuncsW that it uses on NT. Please look
  26. // at LinkToRas in cmdial\ras.cpp and InitCmRasUtoA in uapi\cmutoa.cpp. If you change
  27. // anything here you will probably have to change the structs in raslink.h and probably
  28. // even the code in the two functions above. Changer Beware!
  29. #ifdef _CMUTOA_MODULE
  30. static LPCSTR c_ArrayOfRasFuncsA[] = { "RasDeleteEntryA",
  31. "RasGetEntryPropertiesA",
  32. "RasSetEntryPropertiesA",
  33. "RasGetEntryDialParamsA",
  34. "RasSetEntryDialParamsA",
  35. "RasEnumDevicesA",
  36. "RasDialA",
  37. "RasHangUpA",
  38. "RasGetErrorStringA",
  39. "RasGetConnectStatusA",
  40. "RasSetSubEntryPropertiesA",
  41. "RasDeleteSubEntryA",
  42. NULL, //"RasSetCustomAuthDataA",
  43. NULL, //"RasGetEapUserIdentityA",
  44. NULL, //"RasFreeEapUserIdentityA",
  45. NULL, //"RasInvokeEapUI",
  46. NULL, //"RasGetCredentials",
  47. NULL, //"RasSetCredentials",
  48. NULL
  49. };
  50. #else
  51. static LPCSTR c_ArrayOfRasFuncsUA[] = { "RasDeleteEntryUA",
  52. "RasGetEntryPropertiesUA",
  53. "RasSetEntryPropertiesUA",
  54. "RasGetEntryDialParamsUA",
  55. "RasSetEntryDialParamsUA",
  56. "RasEnumDevicesUA",
  57. "RasDialUA",
  58. "RasHangUpUA",
  59. "RasGetErrorStringUA",
  60. "RasGetConnectStatusUA",
  61. "RasSetSubEntryPropertiesUA",
  62. "RasDeleteSubEntryUA",
  63. NULL, //"RasSetCustomAuthDataUA",
  64. NULL, //"RasGetEapUserIdentityUA",
  65. NULL, //"RasFreeEapUserIdentityUA",
  66. NULL, //"RasInvokeEapUI",
  67. NULL, //"RasGetCredentials",
  68. NULL, //"RasSetCredentials",
  69. NULL
  70. };
  71. static LPCSTR c_ArrayOfRasFuncsW[] = { "RasDeleteEntryW",
  72. "RasGetEntryPropertiesW",
  73. "RasSetEntryPropertiesW",
  74. "RasGetEntryDialParamsW",
  75. "RasSetEntryDialParamsW",
  76. "RasEnumDevicesW",
  77. "RasDialW",
  78. "RasHangUpW",
  79. "RasGetErrorStringW",
  80. "RasGetConnectStatusW",
  81. "RasSetSubEntryPropertiesW",
  82. "RasDeleteSubEntryW",
  83. "RasSetCustomAuthDataW",
  84. "RasGetEapUserIdentityW",
  85. "RasFreeEapUserIdentityW",
  86. "RasInvokeEapUI",
  87. "RasGetCredentialsW",
  88. "RasSetCredentialsW",
  89. NULL
  90. };
  91. #endif
  92. // Regarding DwDeleteSubEntry and RasDeleteSubEntry - NT5 shipped first
  93. // with DwDeleteSubEntry, a private API. Millennium shipped next, by
  94. // which time it looked like this was going to have to be made public,
  95. // so it was prefixed with Ras. NT5.1 made the corresponding name change
  96. // on the NT side, which we handle within LinkToRas (along with all other such
  97. // cases).