Leaked source code of windows server 2003
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.

1223 lines
30 KiB

  1. /**********************************************************************/
  2. /** Microsoft Windows/NT **/
  3. /** Copyright(c) Microsoft Corp., 1991 **/
  4. /**********************************************************************/
  5. /*
  6. mnet.h
  7. <Single line synopsis>
  8. <Multi-Line, more detailed synopsis>
  9. FILE HISTORY:
  10. KeithMo 13-Oct-1991 Created from DanHi's private port1632.h.
  11. JonN 22-Oct-1991 Split off mnettype.h
  12. KeithMo 28-Oct-1991 Changed to "sane" typedefs.
  13. KeithMo 30-Oct-1991 Added MNetApiBufferReAlloc and
  14. MNetApiBufferSize, removed obsolete
  15. MNetAuditOpen() and MNetErrorLogOpen() API.
  16. KeithMo 25-Feb-1992 Added NetReplXxx APIs.
  17. KeithMo 08-Feb-1993 Added I_MNetComputerNameCompare API.
  18. CongpaY 10-March-1993 Add IsNetSlow.
  19. */
  20. #ifndef _MNET_H_
  21. #define _MNET_H_
  22. #include "mnettype.h"
  23. #define NAMETYPE_COMMENT 500
  24. #ifdef __cplusplus
  25. extern "C" {
  26. #endif
  27. //
  28. // API buffer manipulation.
  29. //
  30. DLL_BASED
  31. BYTE FAR * MNetApiBufferAlloc(
  32. UINT cbBuffer );
  33. DLL_BASED
  34. VOID MNetApiBufferFree(
  35. BYTE FAR ** ppbBuffer );
  36. DLL_BASED
  37. APIERR MNetApiBufferReAlloc(
  38. BYTE FAR ** ppbBuffer,
  39. UINT cbBuffer );
  40. DLL_BASED
  41. APIERR MNetApiBufferSize(
  42. BYTE FAR * pbBuffer,
  43. UINT FAR * pcbBuffer );
  44. //
  45. // Internal API.
  46. //
  47. DLL_BASED
  48. APIERR I_MNetNameCanonicalize(
  49. const TCHAR FAR * pszServer,
  50. const TCHAR FAR * pszPath,
  51. TCHAR FAR * pszOutput,
  52. UINT cbOutput,
  53. UINT NameType,
  54. ULONG flFlags );
  55. DLL_BASED
  56. APIERR I_MNetNameCompare(
  57. const TCHAR FAR * pszServer,
  58. const TCHAR FAR * pszPath1,
  59. const TCHAR FAR * pszPath2,
  60. UINT NameType,
  61. ULONG flFlags );
  62. DLL_BASED
  63. APIERR I_MNetNameValidate(
  64. const TCHAR FAR * pszServer,
  65. const TCHAR FAR * pszName,
  66. UINT NameType,
  67. ULONG flFlags );
  68. DLL_BASED
  69. APIERR I_MNetPathCanonicalize(
  70. const TCHAR FAR * pszServer,
  71. const TCHAR FAR * pszPath,
  72. TCHAR FAR * pszOutput,
  73. UINT cbOutput,
  74. const TCHAR FAR * pszPrefix,
  75. ULONG FAR * pflPathType,
  76. ULONG flFlags );
  77. DLL_BASED
  78. APIERR I_MNetPathCompare(
  79. const TCHAR FAR * pszServer,
  80. const TCHAR FAR * pszPath1,
  81. const TCHAR FAR * pszPath2,
  82. ULONG flPathType,
  83. ULONG flFlags );
  84. DLL_BASED
  85. APIERR I_MNetPathType(
  86. const TCHAR FAR * pszServer,
  87. const TCHAR FAR * pszPath,
  88. ULONG FAR * pflPathType,
  89. ULONG flFlags );
  90. DLL_BASED
  91. INT I_MNetComputerNameCompare(
  92. const TCHAR FAR * pszComputer1,
  93. const TCHAR FAR * pszComputer2 );
  94. //
  95. // BUGBUG!
  96. //
  97. // This API is pretty bogus, but 16-bit SrvMgr needs it,
  98. // so here it is. Handling this API correctly under NT
  99. // will be a real challenge.
  100. //
  101. DLL_BASED
  102. APIERR MDosPrintQEnum(
  103. const TCHAR FAR * pszServer,
  104. UINT Level,
  105. BYTE FAR ** ppBuffer,
  106. UINT FAR * pcEntriesRead );
  107. //
  108. // Access API.
  109. //
  110. #ifdef INCL_NETACCESS
  111. DLL_BASED
  112. APIERR MNetAccessAdd(
  113. const TCHAR FAR * pszServer,
  114. UINT Level,
  115. BYTE FAR * pbBuffer,
  116. UINT cbBuffer );
  117. DLL_BASED
  118. APIERR MNetAccessCheck(
  119. TCHAR FAR * pszReserved,
  120. TCHAR FAR * pszUserName,
  121. TCHAR FAR * pszResource,
  122. UINT Operation,
  123. UINT FAR * pResult );
  124. DLL_BASED
  125. APIERR MNetAccessDel(
  126. const TCHAR FAR * pszServer,
  127. TCHAR FAR * pszResource );
  128. DLL_BASED
  129. APIERR MNetAccessEnum(
  130. const TCHAR FAR * pszServer,
  131. TCHAR FAR * pszBasePath,
  132. UINT fRecursive,
  133. UINT Level,
  134. BYTE FAR ** ppbBuffer,
  135. UINT FAR * pcEntriesRead );
  136. DLL_BASED
  137. APIERR MNetAccessGetInfo(
  138. const TCHAR FAR * pszServer,
  139. TCHAR FAR * pszResource,
  140. UINT Level,
  141. BYTE FAR ** ppbBuffer );
  142. DLL_BASED
  143. APIERR MNetAccessGetUserPerms(
  144. TCHAR FAR * pszServer,
  145. TCHAR FAR * pszUgName,
  146. TCHAR FAR * pszResource,
  147. UINT FAR * pPerms );
  148. DLL_BASED
  149. APIERR MNetAccessSetInfo(
  150. const TCHAR FAR * pszServer,
  151. TCHAR FAR * pszResource,
  152. UINT Level,
  153. BYTE FAR * pbBuffer,
  154. UINT cbBuffer,
  155. UINT ParmNum );
  156. #endif // INCL_NETACCESS
  157. //
  158. // Alert API.
  159. //
  160. #ifdef INCL_NETALERT
  161. DLL_BASED
  162. APIERR MNetAlertRaise(
  163. const TCHAR FAR * pszEvent,
  164. BYTE FAR * pbBuffer,
  165. UINT cbBuffer,
  166. ULONG ulTimeout );
  167. DLL_BASED
  168. APIERR MNetAlertStart(
  169. const TCHAR FAR * pszEvent,
  170. const TCHAR FAR * pszRecipient,
  171. UINT cbMaxData );
  172. DLL_BASED
  173. APIERR MNetAlertStop(
  174. const TCHAR FAR * pszEvent,
  175. const TCHAR FAR * pszRecipient );
  176. #endif // INCL_NETALERT
  177. //
  178. // Audit API.
  179. //
  180. #ifdef INCL_NETAUDIT
  181. DLL_BASED
  182. APIERR MNetAuditClear(
  183. const TCHAR FAR * pszServer,
  184. const TCHAR FAR * pszBackupFile,
  185. TCHAR FAR * pszService );
  186. DLL_BASED
  187. APIERR MNetAuditRead(
  188. const TCHAR FAR * pszServer,
  189. const TCHAR FAR * pszService,
  190. HLOG FAR * phAuditLog,
  191. ULONG ulOffset,
  192. UINT FAR * pReserved2,
  193. ULONG ulReserved3,
  194. ULONG flOffset,
  195. BYTE FAR ** ppbBuffer,
  196. ULONG ulMaxPreferred,
  197. UINT FAR * pcbReturned,
  198. UINT FAR * pcbTotalAvail );
  199. DLL_BASED
  200. APIERR MNetAuditWrite(
  201. UINT Type,
  202. BYTE FAR * pbBuffer,
  203. UINT cbBuffer,
  204. TCHAR FAR * pszService,
  205. TCHAR FAR * pszReserved );
  206. #endif // INCL_NETAUDIT
  207. //
  208. // NetBIOS API.
  209. //
  210. #ifdef INCL_NETBIOS
  211. struct ncb; // forward declaration
  212. DLL_BASED
  213. APIERR MNetBiosClose(
  214. UINT hDevName,
  215. UINT Reserved );
  216. DLL_BASED
  217. APIERR MNetBiosEnum(
  218. const TCHAR FAR * pszServer,
  219. UINT Level,
  220. BYTE FAR ** pbBuffer,
  221. UINT FAR * pcEntriesRead );
  222. DLL_BASED
  223. APIERR MNetBiosGetInfo(
  224. const TCHAR FAR * pszServer,
  225. const TCHAR FAR * pszNetBiosName,
  226. UINT Level,
  227. BYTE FAR ** ppbBuffer );
  228. DLL_BASED
  229. APIERR MNetBiosOpen(
  230. TCHAR FAR * pszDevName,
  231. TCHAR FAR * pszReserved,
  232. UINT OpenOpt,
  233. UINT FAR * phDevName );
  234. DLL_BASED
  235. APIERR MNetBiosSubmit(
  236. UINT hDevName,
  237. UINT NcbOpt,
  238. struct ncb FAR * pNCB );
  239. #endif // INCL_NETBIOS
  240. //
  241. // CharDev API.
  242. //
  243. #ifdef INCL_NETCHARDEV
  244. DLL_BASED
  245. APIERR MNetCharDevControl(
  246. const TCHAR FAR * pszServer,
  247. const TCHAR FAR * pszDevName,
  248. UINT OpCode );
  249. DLL_BASED
  250. APIERR MNetCharDevEnum(
  251. const TCHAR FAR * pszServer,
  252. UINT Level,
  253. BYTE FAR ** ppbBuffer,
  254. UINT FAR * pcEntriesRead );
  255. DLL_BASED
  256. APIERR MNetCharDevGetInfo(
  257. const TCHAR FAR * pszServer,
  258. const TCHAR FAR * pszDevName,
  259. UINT Level,
  260. BYTE FAR ** ppbBuffer );
  261. DLL_BASED
  262. APIERR MNetCharDevQEnum(
  263. const TCHAR FAR * pszServer,
  264. const TCHAR FAR * pszUserName,
  265. UINT Level,
  266. BYTE FAR ** ppbBuffer,
  267. UINT FAR * pcEntriesRead );
  268. DLL_BASED
  269. APIERR MNetCharDevQGetInfo(
  270. const TCHAR FAR * pszServer,
  271. const TCHAR FAR * pszQueueName,
  272. const TCHAR FAR * pszUserName,
  273. UINT Level,
  274. BYTE FAR ** ppbBuffer );
  275. DLL_BASED
  276. APIERR MNetCharDevQPurge(
  277. const TCHAR FAR * pszServer,
  278. const TCHAR FAR * pszQueueName );
  279. DLL_BASED
  280. APIERR MNetCharDevQPurgeSelf(
  281. const TCHAR FAR * pszServer,
  282. const TCHAR FAR * pszQueueName,
  283. const TCHAR FAR * pszComputerName );
  284. DLL_BASED
  285. APIERR MNetCharDevQSetInfo(
  286. const TCHAR FAR * pszServer,
  287. const TCHAR FAR * pszQueueName,
  288. UINT Level,
  289. BYTE FAR * pbBuffer,
  290. UINT cbBuffer,
  291. UINT ParmNum );
  292. #endif // INCL_NETCHARDEV
  293. //
  294. // Configuration API.
  295. //
  296. #ifdef INCL_NETCONFIG
  297. DLL_BASED
  298. APIERR MNetConfigGet(
  299. const TCHAR FAR * pszServer,
  300. const TCHAR FAR * pszReserved,
  301. const TCHAR FAR * pszComponent,
  302. const TCHAR FAR * pszParameter,
  303. BYTE FAR ** ppbBuffer );
  304. DLL_BASED
  305. APIERR MNetConfigGetAll(
  306. const TCHAR FAR * pszServer,
  307. const TCHAR FAR * pszReserved,
  308. const TCHAR FAR * pszComponent,
  309. BYTE FAR ** ppbBuffer);
  310. DLL_BASED
  311. APIERR MNetConfigSet(
  312. const TCHAR FAR * pszServer,
  313. const TCHAR FAR * pszComponent,
  314. const TCHAR FAR * pszKey,
  315. const TCHAR FAR * pszData );
  316. #endif // INCL_NETCONFIG
  317. //
  318. // Connection API.
  319. //
  320. #ifdef INCL_NETCONNECTION
  321. DLL_BASED
  322. APIERR MNetConnectionEnum(
  323. const TCHAR FAR * pszServer,
  324. const TCHAR FAR * pszQualifier,
  325. UINT Level,
  326. BYTE FAR ** ppbBuffer,
  327. UINT FAR * pcEntriesRead );
  328. #endif // INCL_NETCONNECTION
  329. //
  330. // Domain API.
  331. //
  332. #ifdef INCL_NETDOMAIN
  333. DLL_BASED
  334. APIERR MNetGetDCName(
  335. const TCHAR FAR * pszServer,
  336. const TCHAR FAR * pszDomain,
  337. BYTE FAR ** ppbBuffer );
  338. DLL_BASED
  339. APIERR MNetLogonEnum(
  340. const TCHAR FAR * pszServer,
  341. UINT Level,
  342. BYTE FAR ** ppbBuffer,
  343. UINT FAR * pcEntriesRead );
  344. DLL_BASED
  345. APIERR I_MNetLogonControl(
  346. const TCHAR FAR * pszServer,
  347. ULONG FunctionCode,
  348. ULONG Level,
  349. BYTE FAR ** ppbBuffer );
  350. #endif // INCL_NETDOMAIN
  351. //
  352. // ErrorLog API.
  353. //
  354. #ifdef INCL_NETERRORLOG
  355. DLL_BASED
  356. APIERR MNetErrorLogClear(
  357. const TCHAR FAR * pszServer,
  358. const TCHAR FAR * pszBackupFile,
  359. TCHAR FAR * pszReserved );
  360. DLL_BASED
  361. APIERR MNetErrorLogRead(
  362. const TCHAR FAR * pszServer,
  363. const TCHAR FAR * pszReserved1,
  364. HLOG FAR * phErrorLog,
  365. ULONG ulOffset,
  366. UINT FAR * pReserved2,
  367. ULONG ulReserved3,
  368. ULONG flOffset,
  369. BYTE FAR ** ppbBuffer,
  370. ULONG ulMaxPreferred,
  371. UINT FAR * pcbReturned,
  372. UINT FAR * pcbTotalAvail );
  373. DLL_BASED
  374. APIERR MNetErrorLogWrite(
  375. TCHAR FAR * pszReserved1,
  376. UINT Code,
  377. const TCHAR FAR * pszComponent,
  378. BYTE FAR * pbBuffer,
  379. UINT cbBuffer,
  380. const TCHAR FAR * pszStrBuf,
  381. UINT cStrBuf,
  382. TCHAR FAR * pszReserved2 );
  383. #endif // INCL_NETERRORLOG
  384. //
  385. // File API.
  386. //
  387. #ifdef INCL_NETFILE
  388. DLL_BASED
  389. APIERR MNetFileClose(
  390. const TCHAR FAR * pszServer,
  391. ULONG ulFileId );
  392. DLL_BASED
  393. APIERR MNetFileEnum(
  394. const TCHAR FAR * pszServer,
  395. const TCHAR FAR * pszBasePath,
  396. const TCHAR FAR * pszUserName,
  397. UINT Level,
  398. BYTE FAR ** ppbBuffer,
  399. ULONG ulMaxPreferred,
  400. UINT FAR * pcEntriesRead,
  401. UINT FAR * pcTotalAvail,
  402. VOID FAR * pResumeKey );
  403. DLL_BASED
  404. APIERR MNetFileGetInfo(
  405. const TCHAR FAR * pszServer,
  406. ULONG ulFileId,
  407. UINT Level,
  408. BYTE FAR ** ppbBuffer );
  409. #endif // INCL_NETFILE
  410. //
  411. // Group API.
  412. //
  413. #ifdef INCL_NETGROUP
  414. DLL_BASED
  415. APIERR MNetGroupAdd(
  416. const TCHAR FAR * pszServer,
  417. UINT Level,
  418. BYTE FAR * pbBuffer,
  419. UINT cbBuffer );
  420. DLL_BASED
  421. APIERR MNetGroupAddUser(
  422. const TCHAR FAR * pszServer,
  423. TCHAR FAR * pszGroupName,
  424. TCHAR FAR * pszUserName );
  425. DLL_BASED
  426. APIERR MNetGroupDel(
  427. const TCHAR FAR * pszServer,
  428. TCHAR FAR * pszGroupName );
  429. DLL_BASED
  430. APIERR MNetGroupDelUser(
  431. const TCHAR FAR * pszServer,
  432. TCHAR FAR * pszGroupName,
  433. TCHAR FAR * pszUserName );
  434. DLL_BASED
  435. APIERR MNetGroupEnum(
  436. const TCHAR FAR * pszServer,
  437. UINT Level,
  438. BYTE FAR ** ppbBuffer,
  439. UINT FAR * pcEntriesRead );
  440. DLL_BASED
  441. APIERR MNetGroupGetInfo(
  442. const TCHAR FAR * pszServer,
  443. TCHAR FAR * pszGroupName,
  444. UINT Level,
  445. BYTE FAR ** ppbBuffer );
  446. DLL_BASED
  447. APIERR MNetGroupGetUsers(
  448. const TCHAR FAR * pszServer,
  449. const TCHAR FAR * pszGroupName,
  450. UINT Level,
  451. BYTE FAR ** ppbBuffer,
  452. UINT FAR * pcEntriesRead );
  453. DLL_BASED
  454. APIERR MNetGroupSetInfo(
  455. const TCHAR FAR * pszServer,
  456. TCHAR FAR * pszGroupName,
  457. UINT Level,
  458. BYTE FAR * pbBuffer,
  459. UINT cbBuffer,
  460. UINT ParmNum );
  461. DLL_BASED
  462. APIERR MNetGroupSetUsers(
  463. const TCHAR FAR * pszServer,
  464. const TCHAR FAR * pszGroupName,
  465. UINT Level,
  466. BYTE FAR * pbBuffer,
  467. UINT cbBuffer,
  468. UINT cEntries );
  469. DLL_BASED
  470. APIERR MNetLocalGroupAddMember(
  471. const TCHAR FAR * pszServer,
  472. const TCHAR FAR * pszGroupName,
  473. PSID psidMember );
  474. #endif // INCL_NETGROUP
  475. //
  476. // Handle API.
  477. //
  478. #ifdef INCL_NETHANDLE
  479. DLL_BASED
  480. APIERR MNetHandleGetInfo(
  481. UINT hHandle,
  482. UINT Level,
  483. BYTE FAR ** ppbBuffer );
  484. DLL_BASED
  485. APIERR MNetHandleSetInfo(
  486. UINT hHandle,
  487. UINT Level,
  488. BYTE FAR * pbBuffer,
  489. UINT cbBuffer,
  490. UINT ParmNum );
  491. #endif // INCL_NETHANDLE
  492. //
  493. // Message API.
  494. //
  495. #ifdef INCL_NETMESSAGE
  496. DLL_BASED
  497. APIERR MNetMessageBufferSend(
  498. const TCHAR FAR * pszServer,
  499. TCHAR FAR * pszRecipient,
  500. BYTE FAR * pbBuffer,
  501. UINT cbBuffer );
  502. DLL_BASED
  503. APIERR MNetMessageFileSend(
  504. const TCHAR FAR * pszServer,
  505. TCHAR FAR * pszRecipient,
  506. TCHAR FAR * pszFileSpec );
  507. DLL_BASED
  508. APIERR MNetMessageLogFileGet(
  509. const TCHAR FAR * pszServer,
  510. BYTE FAR ** ppbBuffer,
  511. UINT FAR * pfsEnabled );
  512. DLL_BASED
  513. APIERR MNetMessageLogFileSet(
  514. const TCHAR FAR * pszServer,
  515. TCHAR FAR * pszFileSpec,
  516. UINT fsEnabled );
  517. DLL_BASED
  518. APIERR MNetMessageNameAdd(
  519. const TCHAR FAR * pszServer,
  520. const TCHAR FAR * pszMessageName,
  521. UINT fsFwdAction );
  522. DLL_BASED
  523. APIERR MNetMessageNameDel(
  524. const TCHAR FAR * pszServer,
  525. const TCHAR FAR * pszMessageName,
  526. UINT fsFwdAction );
  527. DLL_BASED
  528. APIERR MNetMessageNameEnum(
  529. const TCHAR FAR * pszServer,
  530. UINT Level,
  531. BYTE FAR ** ppbBuffer,
  532. UINT FAR * pcEntriesRead );
  533. DLL_BASED
  534. APIERR MNetMessageNameFwd(
  535. const TCHAR FAR * pszServer,
  536. const TCHAR FAR * pszMessageName,
  537. const TCHAR FAR * pszForwardName,
  538. UINT fsDelFwdName );
  539. DLL_BASED
  540. APIERR MNetMessageNameGetInfo(
  541. const TCHAR FAR * pszServer,
  542. const TCHAR FAR * pszMessageName,
  543. UINT Level,
  544. BYTE FAR ** ppbBuffer );
  545. DLL_BASED
  546. APIERR MNetMessageNameUnFwd(
  547. const TCHAR FAR * pszServer,
  548. const TCHAR FAR * pszMessageName );
  549. #endif // INCL_NETMESSAGE
  550. //
  551. // Remote API.
  552. //
  553. #ifdef INCL_NETREMUTIL
  554. DLL_BASED
  555. APIERR MNetRemoteCopy(
  556. const TCHAR FAR * pszSourcePath,
  557. const TCHAR FAR * pszDestPath,
  558. const TCHAR FAR * pszSourcePasswd,
  559. const TCHAR FAR * pszDestPasswd,
  560. UINT fsOpen,
  561. UINT fsCopy,
  562. BYTE FAR ** ppbBuffer );
  563. DLL_BASED
  564. APIERR MNetRemoteMove(
  565. const TCHAR FAR * pszSourcePath,
  566. const TCHAR FAR * pszDestPath,
  567. const TCHAR FAR * pszSourcePasswd,
  568. const TCHAR FAR * pszDestPasswd,
  569. UINT fsOpen,
  570. UINT fsMove,
  571. BYTE FAR ** ppbBuffer );
  572. DLL_BASED
  573. APIERR MNetRemoteTOD(
  574. const TCHAR FAR * pszServer,
  575. BYTE FAR ** ppbBuffer );
  576. #endif // INCL_NETREMUTIL
  577. // 585780-2002/04/17-JonN MNetRepl APIs no longer used
  578. /*
  579. //
  580. // Replicator API.
  581. //
  582. #ifdef INCL_NETREPL
  583. DLL_BASED
  584. APIERR MNetReplGetInfo(
  585. const TCHAR FAR * pszServer,
  586. UINT Level,
  587. BYTE FAR ** ppbBuffer );
  588. DLL_BASED
  589. APIERR MNetReplSetInfo(
  590. const TCHAR FAR * pszServer,
  591. UINT Level,
  592. BYTE FAR * pbBuffer );
  593. DLL_BASED
  594. APIERR MNetReplExportDirAdd(
  595. const TCHAR FAR * pszServer,
  596. UINT Level,
  597. BYTE FAR * pbBuffer );
  598. DLL_BASED
  599. APIERR MNetReplExportDirDel(
  600. const TCHAR FAR * pszServer,
  601. const TCHAR FAR * pszDirectory );
  602. DLL_BASED
  603. APIERR MNetReplExportDirEnum(
  604. const TCHAR FAR * pszServer,
  605. UINT Level,
  606. BYTE FAR ** ppbBuffer,
  607. UINT FAR * pcEntriesRead );
  608. DLL_BASED
  609. APIERR MNetReplExportDirGetInfo(
  610. const TCHAR FAR * pszServer,
  611. const TCHAR FAR * pszDirectory,
  612. UINT Level,
  613. BYTE FAR ** ppbBuffer );
  614. DLL_BASED
  615. APIERR MNetReplExportDirSetInfo(
  616. const TCHAR FAR * pszServer,
  617. const TCHAR FAR * pszDirectory,
  618. UINT Level,
  619. BYTE FAR * pbBuffer );
  620. DLL_BASED
  621. APIERR MNetReplExportDirLock(
  622. const TCHAR FAR * pszServer,
  623. const TCHAR FAR * pszDirectory );
  624. DLL_BASED
  625. APIERR MNetReplExportDirUnlock(
  626. const TCHAR FAR * pszServer,
  627. const TCHAR FAR * pszDirectory,
  628. UINT Force );
  629. DLL_BASED
  630. APIERR MNetReplImportDirAdd(
  631. const TCHAR FAR * pszServer,
  632. UINT Level,
  633. BYTE FAR * pbBuffer );
  634. DLL_BASED
  635. APIERR MNetReplImportDirDel(
  636. const TCHAR FAR * pszServer,
  637. const TCHAR FAR * pszDirectory );
  638. DLL_BASED
  639. APIERR MNetReplImportDirEnum(
  640. const TCHAR FAR * pszServer,
  641. UINT Level,
  642. BYTE FAR ** ppbBuffer,
  643. UINT FAR * pcEntriesRead );
  644. DLL_BASED
  645. APIERR MNetReplImportDirGetInfo(
  646. const TCHAR FAR * pszServer,
  647. const TCHAR FAR * pszDirectory,
  648. UINT Level,
  649. BYTE FAR ** ppbBuffer );
  650. DLL_BASED
  651. APIERR MNetReplImportDirLock(
  652. const TCHAR FAR * pszServer,
  653. const TCHAR FAR * pszDirectory );
  654. DLL_BASED
  655. APIERR MNetReplImportDirUnlock(
  656. const TCHAR FAR * pszServer,
  657. const TCHAR FAR * pszDirectory,
  658. UINT Force );
  659. #endif // INCL_NETREPL
  660. */
  661. //
  662. // Server API.
  663. //
  664. #ifdef INCL_NETSERVER
  665. DLL_BASED
  666. APIERR MNetServerAdminCommand(
  667. const TCHAR FAR * pszServer,
  668. const TCHAR FAR * pszCommand,
  669. UINT FAR * psResult,
  670. BYTE FAR * pbBuffer,
  671. UINT cbBuffer,
  672. UINT FAR * pcbReturned,
  673. UINT FAR * pcbTotalAvail );
  674. DLL_BASED
  675. APIERR MNetServerDiskEnum(
  676. const TCHAR FAR * pszServer,
  677. UINT Level,
  678. BYTE FAR ** ppbBuffer,
  679. UINT FAR * pcEntriesRead );
  680. DLL_BASED
  681. APIERR MNetServerEnum(
  682. const TCHAR FAR * pszServer,
  683. UINT Level,
  684. BYTE FAR ** ppbBuffer,
  685. UINT FAR * pcEntriesRead,
  686. ULONG flServerType,
  687. TCHAR FAR * pszDomain );
  688. DLL_BASED
  689. APIERR MNetServerGetInfo(
  690. const TCHAR FAR * pszServer,
  691. UINT Level,
  692. BYTE FAR ** ppbBuffer );
  693. DLL_BASED
  694. APIERR MNetServerSetInfo(
  695. const TCHAR FAR * pszServer,
  696. UINT Level,
  697. BYTE FAR * pbBuffer,
  698. UINT cbBuffer,
  699. UINT ParmNum );
  700. #endif // INCL_NETSERVER
  701. //
  702. // Service API.
  703. //
  704. #ifdef INCL_NETSERVICE
  705. DLL_BASED
  706. APIERR MNetServiceControl(
  707. const TCHAR FAR * pszServer,
  708. const TCHAR FAR * pszService,
  709. UINT OpCode,
  710. UINT Arg,
  711. BYTE FAR ** ppbBuffer );
  712. DLL_BASED
  713. APIERR MNetServiceEnum(
  714. const TCHAR FAR * pszServer,
  715. UINT Level,
  716. BYTE FAR ** ppbBuffer,
  717. UINT FAR * pcEntriesRead );
  718. DLL_BASED
  719. APIERR MNetServiceGetInfo(
  720. const TCHAR FAR * pszServer,
  721. const TCHAR FAR * pszService,
  722. UINT Level,
  723. BYTE FAR ** ppbBuffer );
  724. DLL_BASED
  725. APIERR MNetServiceInstall(
  726. const TCHAR FAR * pszServer,
  727. const TCHAR FAR * pszService,
  728. const TCHAR FAR * pszCmdArgs,
  729. BYTE FAR ** ppbBuffer );
  730. DLL_BASED
  731. APIERR MNetServiceStatus(
  732. BYTE FAR * pbBuffer,
  733. UINT cbBuffer );
  734. #endif // INCL_NETSERVICE
  735. //
  736. // Session API.
  737. //
  738. #ifdef INCL_NETSESSION
  739. DLL_BASED
  740. APIERR MNetSessionDel(
  741. const TCHAR FAR * pszServer,
  742. const TCHAR FAR * pszClientName,
  743. const TCHAR FAR * pszUserName );
  744. DLL_BASED
  745. APIERR MNetSessionEnum(
  746. const TCHAR FAR * pszServer,
  747. UINT Level,
  748. BYTE FAR ** ppbBuffer,
  749. UINT FAR * pcEntriesRead );
  750. DLL_BASED
  751. APIERR MNetSessionGetInfo(
  752. const TCHAR FAR * pszServer,
  753. const TCHAR FAR * pszClientName,
  754. UINT Level,
  755. BYTE FAR ** ppbBuffer );
  756. #endif // INCL_NETSESSION
  757. //
  758. // Share API.
  759. //
  760. #ifdef INCL_NETSHARE
  761. DLL_BASED
  762. APIERR MNetShareAdd(
  763. const TCHAR FAR * pszServer,
  764. UINT Level,
  765. BYTE FAR * pbBuffer,
  766. UINT cbBuffer );
  767. DLL_BASED
  768. APIERR MNetShareCheck(
  769. const TCHAR FAR * pszServer,
  770. const TCHAR FAR * pszDeviceName,
  771. UINT FAR * pType );
  772. DLL_BASED
  773. APIERR MNetShareDel(
  774. const TCHAR FAR * pszServer,
  775. const TCHAR FAR * pszNetName,
  776. UINT Reserved );
  777. DLL_BASED
  778. APIERR MNetShareDelSticky(
  779. const TCHAR FAR * pszServer,
  780. const TCHAR FAR * pszNetName,
  781. UINT Reserved );
  782. DLL_BASED
  783. APIERR MNetShareEnum(
  784. const TCHAR FAR * pszServer,
  785. UINT Level,
  786. BYTE FAR ** ppbBuffer,
  787. UINT FAR * pcEntriesRead );
  788. DLL_BASED
  789. APIERR MNetShareEnumSticky(
  790. const TCHAR FAR * pszServer,
  791. UINT Level,
  792. BYTE FAR ** ppbBuffer,
  793. UINT FAR * pcEntriesRead );
  794. DLL_BASED
  795. APIERR MNetShareGetInfo(
  796. const TCHAR FAR * pszServer,
  797. const TCHAR FAR * pszNetName,
  798. UINT Level,
  799. BYTE FAR ** ppbBuffer );
  800. DLL_BASED
  801. APIERR MNetShareSetInfo(
  802. const TCHAR FAR * pszServer,
  803. const TCHAR FAR * pszNetName,
  804. UINT Level,
  805. BYTE FAR * pbBuffer,
  806. UINT cbBuffer,
  807. UINT ParmNum );
  808. #endif // INCL_NETSHARE
  809. //
  810. // Statistics API.
  811. //
  812. #ifdef INCL_NETSTATS
  813. DLL_BASED
  814. APIERR MNetStatisticsClear(
  815. const TCHAR FAR * pszServer );
  816. DLL_BASED
  817. APIERR MNetStatisticsGet(
  818. const TCHAR FAR * pszServer,
  819. const TCHAR FAR * pszService,
  820. ULONG ulReserved,
  821. UINT Level,
  822. ULONG flOptions,
  823. BYTE FAR ** ppbBuffer );
  824. #endif // INCL_NETSTATS
  825. //
  826. // Use API.
  827. //
  828. #ifdef INCL_NETUSE
  829. DLL_BASED
  830. APIERR MNetUseAdd(
  831. const TCHAR FAR * pszServer,
  832. UINT Level,
  833. BYTE FAR * pbBuffer,
  834. UINT cbBuffer );
  835. DLL_BASED
  836. APIERR MNetUseDel(
  837. const TCHAR FAR * pszServer,
  838. const TCHAR FAR * pszDeviceName,
  839. UINT Force );
  840. DLL_BASED
  841. APIERR MNetUseEnum(
  842. const TCHAR FAR * pszServer,
  843. UINT Level,
  844. BYTE FAR ** ppbBuffer,
  845. UINT FAR * pcEntriesRead );
  846. DLL_BASED
  847. APIERR MNetUseGetInfo(
  848. const TCHAR FAR * pszServer,
  849. const TCHAR FAR * pszUseName,
  850. UINT Level,
  851. BYTE FAR ** ppbBuffer );
  852. #endif // INCL_NETUSE
  853. //
  854. // User API.
  855. //
  856. #ifdef INCL_NETUSER
  857. DLL_BASED
  858. APIERR MNetUserAdd(
  859. const TCHAR FAR * pszServer,
  860. UINT Level,
  861. BYTE FAR * pbBuffer,
  862. UINT cbBuffer );
  863. DLL_BASED
  864. APIERR MNetUserDel(
  865. const TCHAR FAR * pszServer,
  866. TCHAR FAR * pszUserName );
  867. DLL_BASED
  868. APIERR MNetUserEnum(
  869. const TCHAR FAR * pszServer,
  870. UINT Level,
  871. UINT Filter,
  872. BYTE FAR ** ppbBuffer,
  873. ULONG ulMaxPreferred,
  874. UINT FAR * pcEntriesRead,
  875. UINT FAR * pcTotalEntries,
  876. VOID FAR * pResumeKey );
  877. DLL_BASED
  878. APIERR MNetUserGetGroups(
  879. const TCHAR FAR * pszServer,
  880. const TCHAR FAR * pszUserName,
  881. UINT Level,
  882. BYTE FAR ** ppbBuffer,
  883. UINT FAR * pcEntriesRead );
  884. DLL_BASED
  885. APIERR MNetUserGetInfo(
  886. const TCHAR FAR * pszServer,
  887. TCHAR FAR * pszUserName,
  888. UINT Level,
  889. BYTE FAR ** ppbBuffer );
  890. DLL_BASED
  891. APIERR MNetUserModalsGet(
  892. const TCHAR FAR * pszServer,
  893. UINT Level,
  894. BYTE FAR ** ppbBuffer );
  895. DLL_BASED
  896. APIERR MNetUserModalsSet(
  897. const TCHAR FAR * pszServer,
  898. UINT Level,
  899. BYTE FAR * pbBuffer,
  900. UINT cbBuffer,
  901. UINT ParmNum );
  902. DLL_BASED
  903. APIERR MNetUserPasswordSet(
  904. const TCHAR FAR * pszServer,
  905. TCHAR FAR * pszUserName,
  906. TCHAR FAR * pszOldPassword,
  907. TCHAR FAR * pszNewPassword );
  908. DLL_BASED
  909. APIERR MNetUserSetGroups(
  910. const TCHAR FAR * pszServer,
  911. const TCHAR FAR * pszUserName,
  912. UINT Level,
  913. BYTE FAR * pbBuffer,
  914. UINT cbBuffer,
  915. UINT cEntries );
  916. DLL_BASED
  917. APIERR MNetUserSetInfo(
  918. const TCHAR FAR * pszServer,
  919. TCHAR FAR * pszUserName,
  920. UINT Level,
  921. BYTE FAR * pbBuffer,
  922. UINT cbBuffer,
  923. UINT ParmNum );
  924. DLL_BASED
  925. APIERR MNetUserValidate(
  926. TCHAR FAR * pszReserved1,
  927. UINT Level,
  928. BYTE FAR ** ppbBuffer,
  929. UINT Reserved2 );
  930. #endif // INCL_NETUSER
  931. //
  932. // Workstation API.
  933. //
  934. #ifdef INCL_NETWKSTA
  935. DLL_BASED
  936. APIERR MNetWkstaGetInfo(
  937. const TCHAR FAR * pszServer,
  938. UINT Level,
  939. BYTE FAR ** ppbBuffer );
  940. DLL_BASED
  941. APIERR MNetWkstaSetInfo(
  942. const TCHAR FAR * pszServer,
  943. UINT Level,
  944. BYTE FAR * pbBuffer,
  945. UINT cbBuffer );
  946. DLL_BASED
  947. APIERR MNetWkstaSetUID(
  948. TCHAR FAR * pszReserved,
  949. TCHAR FAR * pszDomain,
  950. TCHAR FAR * pszUserName,
  951. TCHAR FAR * pszPassword,
  952. TCHAR FAR * pszParms,
  953. UINT LogoffForce,
  954. UINT Level,
  955. BYTE FAR * pbBuffer,
  956. UINT cbBuffer,
  957. UINT FAR * pcbTotalAvail );
  958. DLL_BASED
  959. APIERR MNetWkstaUserEnum(
  960. const TCHAR FAR * pszServer,
  961. UINT Level,
  962. BYTE FAR ** ppbBuffer,
  963. UINT FAR * pcEntriesRead );
  964. DLL_BASED
  965. APIERR MNetWkstaUserGetInfo(
  966. const TCHAR FAR * pszReserved, // Must Be Zero
  967. UINT Level,
  968. BYTE FAR ** ppbBuffer );
  969. #endif // INCL_NETWKSTA
  970. DLL_BASED
  971. APIERR IsSlowTransport (
  972. const TCHAR FAR * pszServer,
  973. BOOL FAR * pfSlowTransport );
  974. #ifdef __cplusplus
  975. }
  976. #endif
  977. #endif // _MNET_H_