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.

1220 lines
28 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. //
  578. // Replicator API.
  579. //
  580. #ifdef INCL_NETREPL
  581. DLL_BASED
  582. APIERR MNetReplGetInfo(
  583. const TCHAR FAR * pszServer,
  584. UINT Level,
  585. BYTE FAR ** ppbBuffer );
  586. DLL_BASED
  587. APIERR MNetReplSetInfo(
  588. const TCHAR FAR * pszServer,
  589. UINT Level,
  590. BYTE FAR * pbBuffer );
  591. DLL_BASED
  592. APIERR MNetReplExportDirAdd(
  593. const TCHAR FAR * pszServer,
  594. UINT Level,
  595. BYTE FAR * pbBuffer );
  596. DLL_BASED
  597. APIERR MNetReplExportDirDel(
  598. const TCHAR FAR * pszServer,
  599. const TCHAR FAR * pszDirectory );
  600. DLL_BASED
  601. APIERR MNetReplExportDirEnum(
  602. const TCHAR FAR * pszServer,
  603. UINT Level,
  604. BYTE FAR ** ppbBuffer,
  605. UINT FAR * pcEntriesRead );
  606. DLL_BASED
  607. APIERR MNetReplExportDirGetInfo(
  608. const TCHAR FAR * pszServer,
  609. const TCHAR FAR * pszDirectory,
  610. UINT Level,
  611. BYTE FAR ** ppbBuffer );
  612. DLL_BASED
  613. APIERR MNetReplExportDirSetInfo(
  614. const TCHAR FAR * pszServer,
  615. const TCHAR FAR * pszDirectory,
  616. UINT Level,
  617. BYTE FAR * pbBuffer );
  618. DLL_BASED
  619. APIERR MNetReplExportDirLock(
  620. const TCHAR FAR * pszServer,
  621. const TCHAR FAR * pszDirectory );
  622. DLL_BASED
  623. APIERR MNetReplExportDirUnlock(
  624. const TCHAR FAR * pszServer,
  625. const TCHAR FAR * pszDirectory,
  626. UINT Force );
  627. DLL_BASED
  628. APIERR MNetReplImportDirAdd(
  629. const TCHAR FAR * pszServer,
  630. UINT Level,
  631. BYTE FAR * pbBuffer );
  632. DLL_BASED
  633. APIERR MNetReplImportDirDel(
  634. const TCHAR FAR * pszServer,
  635. const TCHAR FAR * pszDirectory );
  636. DLL_BASED
  637. APIERR MNetReplImportDirEnum(
  638. const TCHAR FAR * pszServer,
  639. UINT Level,
  640. BYTE FAR ** ppbBuffer,
  641. UINT FAR * pcEntriesRead );
  642. DLL_BASED
  643. APIERR MNetReplImportDirGetInfo(
  644. const TCHAR FAR * pszServer,
  645. const TCHAR FAR * pszDirectory,
  646. UINT Level,
  647. BYTE FAR ** ppbBuffer );
  648. DLL_BASED
  649. APIERR MNetReplImportDirLock(
  650. const TCHAR FAR * pszServer,
  651. const TCHAR FAR * pszDirectory );
  652. DLL_BASED
  653. APIERR MNetReplImportDirUnlock(
  654. const TCHAR FAR * pszServer,
  655. const TCHAR FAR * pszDirectory,
  656. UINT Force );
  657. #endif // INCL_NETREPL
  658. //
  659. // Server API.
  660. //
  661. #ifdef INCL_NETSERVER
  662. DLL_BASED
  663. APIERR MNetServerAdminCommand(
  664. const TCHAR FAR * pszServer,
  665. const TCHAR FAR * pszCommand,
  666. UINT FAR * psResult,
  667. BYTE FAR * pbBuffer,
  668. UINT cbBuffer,
  669. UINT FAR * pcbReturned,
  670. UINT FAR * pcbTotalAvail );
  671. DLL_BASED
  672. APIERR MNetServerDiskEnum(
  673. const TCHAR FAR * pszServer,
  674. UINT Level,
  675. BYTE FAR ** ppbBuffer,
  676. UINT FAR * pcEntriesRead );
  677. DLL_BASED
  678. APIERR MNetServerEnum(
  679. const TCHAR FAR * pszServer,
  680. UINT Level,
  681. BYTE FAR ** ppbBuffer,
  682. UINT FAR * pcEntriesRead,
  683. ULONG flServerType,
  684. TCHAR FAR * pszDomain );
  685. DLL_BASED
  686. APIERR MNetServerGetInfo(
  687. const TCHAR FAR * pszServer,
  688. UINT Level,
  689. BYTE FAR ** ppbBuffer );
  690. DLL_BASED
  691. APIERR MNetServerSetInfo(
  692. const TCHAR FAR * pszServer,
  693. UINT Level,
  694. BYTE FAR * pbBuffer,
  695. UINT cbBuffer,
  696. UINT ParmNum );
  697. #endif // INCL_NETSERVER
  698. //
  699. // Service API.
  700. //
  701. #ifdef INCL_NETSERVICE
  702. DLL_BASED
  703. APIERR MNetServiceControl(
  704. const TCHAR FAR * pszServer,
  705. const TCHAR FAR * pszService,
  706. UINT OpCode,
  707. UINT Arg,
  708. BYTE FAR ** ppbBuffer );
  709. DLL_BASED
  710. APIERR MNetServiceEnum(
  711. const TCHAR FAR * pszServer,
  712. UINT Level,
  713. BYTE FAR ** ppbBuffer,
  714. UINT FAR * pcEntriesRead );
  715. DLL_BASED
  716. APIERR MNetServiceGetInfo(
  717. const TCHAR FAR * pszServer,
  718. const TCHAR FAR * pszService,
  719. UINT Level,
  720. BYTE FAR ** ppbBuffer );
  721. DLL_BASED
  722. APIERR MNetServiceInstall(
  723. const TCHAR FAR * pszServer,
  724. const TCHAR FAR * pszService,
  725. const TCHAR FAR * pszCmdArgs,
  726. BYTE FAR ** ppbBuffer );
  727. DLL_BASED
  728. APIERR MNetServiceStatus(
  729. BYTE FAR * pbBuffer,
  730. UINT cbBuffer );
  731. #endif // INCL_NETSERVICE
  732. //
  733. // Session API.
  734. //
  735. #ifdef INCL_NETSESSION
  736. DLL_BASED
  737. APIERR MNetSessionDel(
  738. const TCHAR FAR * pszServer,
  739. const TCHAR FAR * pszClientName,
  740. const TCHAR FAR * pszUserName );
  741. DLL_BASED
  742. APIERR MNetSessionEnum(
  743. const TCHAR FAR * pszServer,
  744. UINT Level,
  745. BYTE FAR ** ppbBuffer,
  746. UINT FAR * pcEntriesRead );
  747. DLL_BASED
  748. APIERR MNetSessionGetInfo(
  749. const TCHAR FAR * pszServer,
  750. const TCHAR FAR * pszClientName,
  751. UINT Level,
  752. BYTE FAR ** ppbBuffer );
  753. #endif // INCL_NETSESSION
  754. //
  755. // Share API.
  756. //
  757. #ifdef INCL_NETSHARE
  758. DLL_BASED
  759. APIERR MNetShareAdd(
  760. const TCHAR FAR * pszServer,
  761. UINT Level,
  762. BYTE FAR * pbBuffer,
  763. UINT cbBuffer );
  764. DLL_BASED
  765. APIERR MNetShareCheck(
  766. const TCHAR FAR * pszServer,
  767. const TCHAR FAR * pszDeviceName,
  768. UINT FAR * pType );
  769. DLL_BASED
  770. APIERR MNetShareDel(
  771. const TCHAR FAR * pszServer,
  772. const TCHAR FAR * pszNetName,
  773. UINT Reserved );
  774. DLL_BASED
  775. APIERR MNetShareDelSticky(
  776. const TCHAR FAR * pszServer,
  777. const TCHAR FAR * pszNetName,
  778. UINT Reserved );
  779. DLL_BASED
  780. APIERR MNetShareEnum(
  781. const TCHAR FAR * pszServer,
  782. UINT Level,
  783. BYTE FAR ** ppbBuffer,
  784. UINT FAR * pcEntriesRead );
  785. DLL_BASED
  786. APIERR MNetShareEnumSticky(
  787. const TCHAR FAR * pszServer,
  788. UINT Level,
  789. BYTE FAR ** ppbBuffer,
  790. UINT FAR * pcEntriesRead );
  791. DLL_BASED
  792. APIERR MNetShareGetInfo(
  793. const TCHAR FAR * pszServer,
  794. const TCHAR FAR * pszNetName,
  795. UINT Level,
  796. BYTE FAR ** ppbBuffer );
  797. DLL_BASED
  798. APIERR MNetShareSetInfo(
  799. const TCHAR FAR * pszServer,
  800. const TCHAR FAR * pszNetName,
  801. UINT Level,
  802. BYTE FAR * pbBuffer,
  803. UINT cbBuffer,
  804. UINT ParmNum );
  805. #endif // INCL_NETSHARE
  806. //
  807. // Statistics API.
  808. //
  809. #ifdef INCL_NETSTATS
  810. DLL_BASED
  811. APIERR MNetStatisticsClear(
  812. const TCHAR FAR * pszServer );
  813. DLL_BASED
  814. APIERR MNetStatisticsGet(
  815. const TCHAR FAR * pszServer,
  816. const TCHAR FAR * pszService,
  817. ULONG ulReserved,
  818. UINT Level,
  819. ULONG flOptions,
  820. BYTE FAR ** ppbBuffer );
  821. #endif // INCL_NETSTATS
  822. //
  823. // Use API.
  824. //
  825. #ifdef INCL_NETUSE
  826. DLL_BASED
  827. APIERR MNetUseAdd(
  828. const TCHAR FAR * pszServer,
  829. UINT Level,
  830. BYTE FAR * pbBuffer,
  831. UINT cbBuffer );
  832. DLL_BASED
  833. APIERR MNetUseDel(
  834. const TCHAR FAR * pszServer,
  835. const TCHAR FAR * pszDeviceName,
  836. UINT Force );
  837. DLL_BASED
  838. APIERR MNetUseEnum(
  839. const TCHAR FAR * pszServer,
  840. UINT Level,
  841. BYTE FAR ** ppbBuffer,
  842. UINT FAR * pcEntriesRead );
  843. DLL_BASED
  844. APIERR MNetUseGetInfo(
  845. const TCHAR FAR * pszServer,
  846. const TCHAR FAR * pszUseName,
  847. UINT Level,
  848. BYTE FAR ** ppbBuffer );
  849. #endif // INCL_NETUSE
  850. //
  851. // User API.
  852. //
  853. #ifdef INCL_NETUSER
  854. DLL_BASED
  855. APIERR MNetUserAdd(
  856. const TCHAR FAR * pszServer,
  857. UINT Level,
  858. BYTE FAR * pbBuffer,
  859. UINT cbBuffer );
  860. DLL_BASED
  861. APIERR MNetUserDel(
  862. const TCHAR FAR * pszServer,
  863. TCHAR FAR * pszUserName );
  864. DLL_BASED
  865. APIERR MNetUserEnum(
  866. const TCHAR FAR * pszServer,
  867. UINT Level,
  868. UINT Filter,
  869. BYTE FAR ** ppbBuffer,
  870. ULONG ulMaxPreferred,
  871. UINT FAR * pcEntriesRead,
  872. UINT FAR * pcTotalEntries,
  873. VOID FAR * pResumeKey );
  874. DLL_BASED
  875. APIERR MNetUserGetGroups(
  876. const TCHAR FAR * pszServer,
  877. const TCHAR FAR * pszUserName,
  878. UINT Level,
  879. BYTE FAR ** ppbBuffer,
  880. UINT FAR * pcEntriesRead );
  881. DLL_BASED
  882. APIERR MNetUserGetInfo(
  883. const TCHAR FAR * pszServer,
  884. TCHAR FAR * pszUserName,
  885. UINT Level,
  886. BYTE FAR ** ppbBuffer );
  887. DLL_BASED
  888. APIERR MNetUserModalsGet(
  889. const TCHAR FAR * pszServer,
  890. UINT Level,
  891. BYTE FAR ** ppbBuffer );
  892. DLL_BASED
  893. APIERR MNetUserModalsSet(
  894. const TCHAR FAR * pszServer,
  895. UINT Level,
  896. BYTE FAR * pbBuffer,
  897. UINT cbBuffer,
  898. UINT ParmNum );
  899. DLL_BASED
  900. APIERR MNetUserPasswordSet(
  901. const TCHAR FAR * pszServer,
  902. TCHAR FAR * pszUserName,
  903. TCHAR FAR * pszOldPassword,
  904. TCHAR FAR * pszNewPassword );
  905. DLL_BASED
  906. APIERR MNetUserSetGroups(
  907. const TCHAR FAR * pszServer,
  908. const TCHAR FAR * pszUserName,
  909. UINT Level,
  910. BYTE FAR * pbBuffer,
  911. UINT cbBuffer,
  912. UINT cEntries );
  913. DLL_BASED
  914. APIERR MNetUserSetInfo(
  915. const TCHAR FAR * pszServer,
  916. TCHAR FAR * pszUserName,
  917. UINT Level,
  918. BYTE FAR * pbBuffer,
  919. UINT cbBuffer,
  920. UINT ParmNum );
  921. DLL_BASED
  922. APIERR MNetUserValidate(
  923. TCHAR FAR * pszReserved1,
  924. UINT Level,
  925. BYTE FAR ** ppbBuffer,
  926. UINT Reserved2 );
  927. #endif // INCL_NETUSER
  928. //
  929. // Workstation API.
  930. //
  931. #ifdef INCL_NETWKSTA
  932. DLL_BASED
  933. APIERR MNetWkstaGetInfo(
  934. const TCHAR FAR * pszServer,
  935. UINT Level,
  936. BYTE FAR ** ppbBuffer );
  937. DLL_BASED
  938. APIERR MNetWkstaSetInfo(
  939. const TCHAR FAR * pszServer,
  940. UINT Level,
  941. BYTE FAR * pbBuffer,
  942. UINT cbBuffer );
  943. DLL_BASED
  944. APIERR MNetWkstaSetUID(
  945. TCHAR FAR * pszReserved,
  946. TCHAR FAR * pszDomain,
  947. TCHAR FAR * pszUserName,
  948. TCHAR FAR * pszPassword,
  949. TCHAR FAR * pszParms,
  950. UINT LogoffForce,
  951. UINT Level,
  952. BYTE FAR * pbBuffer,
  953. UINT cbBuffer,
  954. UINT FAR * pcbTotalAvail );
  955. DLL_BASED
  956. APIERR MNetWkstaUserEnum(
  957. const TCHAR FAR * pszServer,
  958. UINT Level,
  959. BYTE FAR ** ppbBuffer,
  960. UINT FAR * pcEntriesRead );
  961. DLL_BASED
  962. APIERR MNetWkstaUserGetInfo(
  963. const TCHAR FAR * pszReserved, // Must Be Zero
  964. UINT Level,
  965. BYTE FAR ** ppbBuffer );
  966. #endif // INCL_NETWKSTA
  967. DLL_BASED
  968. APIERR IsSlowTransport (
  969. const TCHAR FAR * pszServer,
  970. BOOL FAR * pfSlowTransport );
  971. #ifdef __cplusplus
  972. }
  973. #endif
  974. #endif // _MNET_H_