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.

586 lines
20 KiB

  1. --#comment "Copyright (C) Microsoft Corporation, 1995-1999. All rights reserved."--
  2. --#comment "ASN.1 definitions for Multiport Communication Services (MCS)"--
  3. --#SS.basic slinked-- -- set of and sequence of w/o size constraint
  4. --#SS.sized slinked-- -- set of and sequence of w/ size constraint
  5. -- MCS-PROTOCOL DEFINITIONS ::=
  6. MCSPROT DEFINITIONS ::=
  7. BEGIN
  8. -- Part 1: Fundamental MCS types
  9. ChannelID ::= INTEGER (0..65535) -- range is 16 bits
  10. StaticChannelID ::= ChannelID (1..1000) -- those known permanently
  11. DynamicChannelID::= ChannelID (1001..65535) -- those created and deleted
  12. UserID ::= DynamicChannelID -- created by Attach-User
  13. -- deleted by Detach-User
  14. PrivateChannelID::= DynamicChannelID -- created by Channel-Convene
  15. -- deleted by Channel-Disband
  16. AssignedChannelID::=DynamicChannelID -- created by Channel-Join zero
  17. -- deleted by last Channel-Leave
  18. TokenID ::= INTEGER (1..65535) -- all are known permanently
  19. PDUTokenStatus ::= ENUMERATED
  20. {
  21. not-in-use (0),
  22. self-grabbed (1),
  23. other-grabbed (2),
  24. self-inhibited (3),
  25. other-inhibited (4),
  26. self-recipient (5),
  27. self-giving (6),
  28. other-giving (7)
  29. }
  30. PDUPriority ::= ENUMERATED
  31. {
  32. top (0),
  33. high (1),
  34. medium (2),
  35. low (3)
  36. }
  37. PDUSegmentation ::= BIT STRING
  38. {
  39. begin (0),
  40. end (1)
  41. } (SIZE (2)) --<PADDED--
  42. PDUDomainParameters::= SEQUENCE
  43. {
  44. max-channel-ids INTEGER (0..MAX),
  45. -- a limit on channel ids in use,
  46. -- static + user id + private + assigned
  47. max-user-ids INTEGER (0..MAX),
  48. -- a sublimit on user id channels alone
  49. max-token-ids INTEGER (0..MAX),
  50. -- a limit on token ids in use
  51. -- grabbed + inhibited + giving + ungivable + given
  52. number-priorities INTEGER (0..MAX),
  53. -- the number of TCs in an MCS connection
  54. min-throughput INTEGER (0..MAX),
  55. -- the enforced number of octets per second
  56. max-height INTEGER (0..MAX),
  57. -- a limit on the height of a provider
  58. max-mcspdu-size INTEGER (0..MAX),
  59. -- an octet limit on domain MCSPDUs
  60. protocol-version INTEGER (0..MAX)
  61. }
  62. -- Part 2: Connect provider
  63. ConnectInitialPDU ::= [APPLICATION 101] IMPLICIT SEQUENCE
  64. {
  65. calling-domain-selector OCTET STRING,
  66. called-domain-selector OCTET STRING,
  67. upward-flag BOOLEAN,
  68. -- TRUE if called provider is higher
  69. target-parameters PDUDomainParameters,
  70. minimum-parameters PDUDomainParameters,
  71. maximum-parameters PDUDomainParameters,
  72. user-data OCTET STRING
  73. }
  74. ConnectResponsePDU ::= [APPLICATION 102] IMPLICIT SEQUENCE
  75. {
  76. result PDUResult,
  77. called-connect-id INTEGER (0..MAX),
  78. -- assigned by the called provider
  79. -- to identify additional TCs of
  80. -- the same MCS connection
  81. domain-parameters PDUDomainParameters,
  82. user-data OCTET STRING
  83. }
  84. ConnectAdditionalPDU ::= [APPLICATION 103] IMPLICIT SEQUENCE
  85. {
  86. called-connect-id INTEGER (0..MAX),
  87. data-priority PDUPriority
  88. }
  89. ConnectResultPDU ::= [APPLICATION 104] IMPLICIT SEQUENCE
  90. {
  91. result PDUResult
  92. }
  93. -- Part 3: Merge domain
  94. PlumbDomainIndicationPDU ::= [APPLICATION 0] IMPLICIT SEQUENCE -- plumb domain indication
  95. {
  96. height-limit INTEGER (0..MAX)
  97. -- a restriction on the MCSPDU receiver
  98. }
  99. ErectDomainRequestPDU ::= [APPLICATION 1] IMPLICIT SEQUENCE -- erect domain request
  100. {
  101. sub-height INTEGER (0..MAX),
  102. -- height in domain of the MCSPDU transmitter
  103. sub-interval INTEGER (0..MAX)
  104. -- its throughput enforcement interval in milliseconds
  105. }
  106. PDUChannelAttributes ::= CHOICE
  107. {
  108. channel-attributes-static [0] IMPLICIT SEQUENCE
  109. {
  110. channel-id StaticChannelID
  111. -- joined is implicitly TRUE
  112. } --#type "ChannelAttributesStatic"--,
  113. channel-attributes-user-id [1] IMPLICIT SEQUENCE
  114. {
  115. joined BOOLEAN,
  116. -- TRUE if user is joined to its user id
  117. user-id UserID
  118. } --#type "ChannelAttributesUserID"--,
  119. channel-attributes-private [2] IMPLICIT SEQUENCE
  120. {
  121. joined BOOLEAN,
  122. -- TRUE if channel id is joined below
  123. channel-id PrivateChannelID,
  124. manager UserID,
  125. admitted SetOfUserIDs
  126. -- may span multiple MergeChannelsRequestPDU
  127. } --#type "ChannelAttributesPrivate"--,
  128. channel-attributes-assigned [3] IMPLICIT SEQUENCE
  129. {
  130. channel-id AssignedChannelID
  131. -- joined is implicitly TRUE
  132. } --#type "ChannelAttributesAssigned"--
  133. }
  134. MergeChannelsRequestPDU ::= [APPLICATION 2] IMPLICIT SEQUENCE -- merge channels request
  135. {
  136. merge-channels SetOfPDUChannelAttributes,
  137. purge-channel-ids SetOfChannelIDs
  138. }
  139. MergeChannelsConfirmPDU ::= [APPLICATION 3] IMPLICIT SEQUENCE -- merge channels confirm
  140. {
  141. merge-channels SetOfPDUChannelAttributes,
  142. purge-channel-ids SetOfChannelIDs
  143. }
  144. PurgeChannelIndicationPDU ::= [APPLICATION 4] IMPLICIT SEQUENCE -- purge channels indication
  145. {
  146. detach-user-ids SetOfUserIDs,
  147. -- purge user id channels
  148. purge-channel-ids SetOfChannelIDs
  149. -- purge other channel ids
  150. }
  151. PDUTokenAttributes ::= CHOICE
  152. {
  153. grabbed [0] IMPLICIT SEQUENCE
  154. {
  155. token-id TokenID,
  156. grabber UserID
  157. } --#type "Grabbed"--,
  158. inhibited [1] IMPLICIT SEQUENCE
  159. {
  160. token-id TokenID,
  161. inhibitors SetOfUserIDs
  162. -- may span multiple MergeTokensRequestPDU
  163. } --#type "Inhibited"--,
  164. giving [2] IMPLICIT SEQUENCE
  165. {
  166. token-id TokenID,
  167. grabber UserID,
  168. recipient UserID
  169. } --#type "Giving"--,
  170. ungivable [3] IMPLICIT SEQUENCE
  171. {
  172. token-id TokenID,
  173. grabber UserID
  174. -- recipient has since detached
  175. } --#type "Ungivable"--,
  176. given [4] IMPLICIT SEQUENCE
  177. {
  178. token-id TokenID,
  179. recipient UserID
  180. -- grabber released or detached
  181. } --#type "Given"--
  182. }
  183. -- DataBeam changes to pull out useful types
  184. SetOfUserIDs ::= SET --#type "PSetOfUserIDs"-- OF UserID
  185. SetOfPDUChannelAttributes ::= SET --#type "PSetOfPDUChannelAttributes"-- OF PDUChannelAttributes
  186. SetOfChannelIDs ::= SET --#type "PSetOfChannelIDs"-- OF ChannelID
  187. SetOfPDUTokenAttributes ::= SET --#type "PSetOfPDUTokenAttributes"-- OF PDUTokenAttributes
  188. SetOfTokenIDs ::= SET --#type "PSetOfTokenIDs"-- OF TokenID
  189. MergeTokensRequestPDU ::= [APPLICATION 5] IMPLICIT SEQUENCE -- merge tokens request
  190. {
  191. merge-tokens SetOfPDUTokenAttributes,
  192. purge-token-ids SetOfTokenIDs
  193. }
  194. MergeTokensConfirmPDU ::= [APPLICATION 6] IMPLICIT SEQUENCE -- merge tokens indication
  195. {
  196. merge-tokens SetOfPDUTokenAttributes,
  197. purge-token-ids SetOfTokenIDs
  198. }
  199. PurgeTokenIndicationPDU ::= [APPLICATION 7] IMPLICIT SEQUENCE -- purge tokens indication
  200. {
  201. purge-token-ids SetOfTokenIDs
  202. }
  203. -- Part 4: Disconnect provider
  204. DisconnectProviderUltimatumPDU ::= [APPLICATION 8] IMPLICIT SEQUENCE -- disconnect provider ultimatum
  205. {
  206. reason PDUReason
  207. }
  208. RejectUltimatumPDU ::= [APPLICATION 9] IMPLICIT SEQUENCE -- reject MCSPDU ultimatum
  209. {
  210. diagnostic Diagnostic,
  211. initial-octets OCTET STRING
  212. }
  213. -- Part 5: Attach/Detach user
  214. AttachUserRequestPDU ::= [APPLICATION 10] IMPLICIT SEQUENCE -- attach user request
  215. {
  216. }
  217. AttachUserConfirmPDU ::= [APPLICATION 11] IMPLICIT SEQUENCE -- attach user confirm
  218. {
  219. result PDUResult,
  220. initiator UserID OPTIONAL
  221. }
  222. DetachUserRequestPDU ::= [APPLICATION 12] IMPLICIT SEQUENCE -- detach user request
  223. {
  224. reason PDUReason,
  225. user-ids SetOfUserIDs
  226. }
  227. DetachUserIndicationPDU ::= [APPLICATION 13] IMPLICIT SEQUENCE -- detach user indication
  228. {
  229. reason PDUReason,
  230. user-ids SetOfUserIDs
  231. }
  232. -- Part 6: Channel management
  233. ChannelJoinRequestPDU ::= [APPLICATION 14] IMPLICIT SEQUENCE -- channel join request
  234. {
  235. initiator UserID,
  236. channel-id ChannelID
  237. -- may be zero
  238. }
  239. ChannelJoinConfirmPDU ::= [APPLICATION 15] IMPLICIT SEQUENCE -- channel join confirm
  240. {
  241. result PDUResult,
  242. initiator UserID,
  243. requested ChannelID,
  244. -- may be zero
  245. channel-id ChannelID --#field "join_channel_id"-- OPTIONAL
  246. }
  247. ChannelLeaveRequestPDU ::= [APPLICATION 16] IMPLICIT SEQUENCE -- channel leave request
  248. {
  249. channel-ids SetOfChannelIDs
  250. }
  251. ChannelConveneRequestPDU ::= [APPLICATION 17] IMPLICIT SEQUENCE -- channel convene request
  252. {
  253. initiator UserID
  254. }
  255. ChannelConveneConfirmPDU ::= [APPLICATION 18] IMPLICIT SEQUENCE -- channel convene confirm
  256. {
  257. result PDUResult,
  258. initiator UserID,
  259. channel-id PrivateChannelID --#field "convene_channel_id"-- OPTIONAL
  260. }
  261. ChannelDisbandRequestPDU ::= [APPLICATION 19] IMPLICIT SEQUENCE -- channel disband request
  262. {
  263. initiator UserID,
  264. channel-id PrivateChannelID
  265. }
  266. ChannelDisbandIndicationPDU ::= [APPLICATION 20] IMPLICIT SEQUENCE -- channel disband indication
  267. {
  268. channel-id PrivateChannelID
  269. }
  270. ChannelAdmitRequestPDU ::= [APPLICATION 21] IMPLICIT SEQUENCE -- channel admit request
  271. {
  272. initiator UserID,
  273. channel-id PrivateChannelID,
  274. user-ids SetOfUserIDs
  275. }
  276. ChannelAdmitIndicationPDU ::= [APPLICATION 22] IMPLICIT SEQUENCE -- channel admit indication
  277. {
  278. initiator UserID,
  279. channel-id PrivateChannelID,
  280. user-ids SetOfUserIDs
  281. }
  282. ChannelExpelRequestPDU ::= [APPLICATION 23] IMPLICIT SEQUENCE -- channel expel request
  283. {
  284. initiator UserID,
  285. channel-id PrivateChannelID,
  286. user-ids SetOfUserIDs
  287. }
  288. ChannelExpelIndicationPDU ::= [APPLICATION 24] IMPLICIT SEQUENCE -- channel expel indication
  289. {
  290. channel-id PrivateChannelID,
  291. user-ids SetOfUserIDs
  292. }
  293. -- Part 7: Data transfer
  294. SendDataRequestPDU ::= [APPLICATION 25] IMPLICIT SEQUENCE -- send data request
  295. {
  296. initiator UserID,
  297. channel-id ChannelID,
  298. data-priority PDUPriority,
  299. segmentation PDUSegmentation,
  300. user-data OCTET STRING
  301. }
  302. SendDataIndicationPDU ::= [APPLICATION 26] IMPLICIT SEQUENCE -- send data indication
  303. {
  304. initiator UserID,
  305. channel-id ChannelID,
  306. data-priority PDUPriority,
  307. segmentation PDUSegmentation,
  308. user-data OCTET STRING
  309. }
  310. UniformSendDataRequestPDU ::= [APPLICATION 27] IMPLICIT SEQUENCE -- uniform send data request
  311. {
  312. initiator UserID,
  313. channel-id ChannelID,
  314. data-priority PDUPriority,
  315. segmentation PDUSegmentation,
  316. user-data OCTET STRING
  317. }
  318. UniformSendDataIndicationPDU ::= [APPLICATION 28] IMPLICIT SEQUENCE -- uniform send data indication
  319. {
  320. initiator UserID,
  321. channel-id ChannelID,
  322. data-priority PDUPriority,
  323. segmentation PDUSegmentation,
  324. user-data OCTET STRING
  325. }
  326. -- Part 8: Token management
  327. TokenGrabRequestPDU ::= [APPLICATION 29] IMPLICIT SEQUENCE -- token grab request
  328. {
  329. initiator UserID,
  330. token-id TokenID
  331. }
  332. TokenGrabConfirmPDU ::= [APPLICATION 30] IMPLICIT SEQUENCE -- token grab confirm
  333. {
  334. result PDUResult,
  335. initiator UserID,
  336. token-id TokenID,
  337. token-status PDUTokenStatus
  338. }
  339. TokenInhibitRequestPDU ::= [APPLICATION 31] IMPLICIT SEQUENCE -- token inhibit request
  340. {
  341. initiator UserID,
  342. token-id TokenID
  343. }
  344. TokenInhibitConfirmPDU ::= [APPLICATION 32] IMPLICIT SEQUENCE -- token inhibit confirm
  345. {
  346. result PDUResult,
  347. initiator UserID,
  348. token-id TokenID,
  349. token-status PDUTokenStatus
  350. }
  351. TokenGiveRequestPDU ::= [APPLICATION 33] IMPLICIT SEQUENCE -- token give request
  352. {
  353. initiator UserID,
  354. token-id TokenID,
  355. recipient UserID
  356. }
  357. TokenGiveIndicationPDU ::= [APPLICATION 34] IMPLICIT SEQUENCE -- token give indication
  358. {
  359. initiator UserID,
  360. token-id TokenID,
  361. recipient UserID
  362. }
  363. TokenGiveResponsePDU ::= [APPLICATION 35] IMPLICIT SEQUENCE -- token give response
  364. {
  365. result PDUResult,
  366. recipient UserID,
  367. token-id TokenID
  368. }
  369. TokenGiveConfirmPDU ::= [APPLICATION 36] IMPLICIT SEQUENCE -- token give confirm
  370. {
  371. result PDUResult,
  372. initiator UserID,
  373. token-id TokenID,
  374. token-status PDUTokenStatus
  375. }
  376. TokenPleaseRequestPDU ::= [APPLICATION 37] IMPLICIT SEQUENCE -- token please request
  377. {
  378. initiator UserID,
  379. token-id TokenID
  380. }
  381. TokenPleaseIndicationPDU ::= [APPLICATION 38] IMPLICIT SEQUENCE -- token please indication
  382. {
  383. initiator UserID,
  384. token-id TokenID
  385. }
  386. TokenReleaseRequestPDU ::= [APPLICATION 39] IMPLICIT SEQUENCE -- token release request
  387. {
  388. initiator UserID,
  389. token-id TokenID
  390. }
  391. TokenReleaseConfirmPDU ::= [APPLICATION 40] IMPLICIT SEQUENCE -- token release confirm
  392. {
  393. result PDUResult,
  394. initiator UserID,
  395. token-id TokenID,
  396. token-status PDUTokenStatus
  397. }
  398. TokenTestRequestPDU ::= [APPLICATION 41] IMPLICIT SEQUENCE -- token test request
  399. {
  400. initiator UserID,
  401. token-id TokenID
  402. }
  403. TokenTestConfirmPDU ::= [APPLICATION 42] IMPLICIT SEQUENCE -- token test confirm
  404. {
  405. initiator UserID,
  406. token-id TokenID,
  407. token-status PDUTokenStatus
  408. }
  409. -- Part 9: Status codes
  410. PDUReason ::= ENUMERATED -- in DisconnectProviderUltimatumPDU, DetachUserRequestPDU, DetachUserIndicationPDU
  411. {
  412. rn-domain-disconnected (0),
  413. rn-provider-initiated (1),
  414. rn-token-purged (2),
  415. rn-user-requested (3),
  416. rn-channel-purged (4)
  417. }
  418. PDUResult ::= ENUMERATED -- in Connect, response, confirm
  419. {
  420. rt-successful (0),
  421. rt-domain-merging (1),
  422. rt-domain-not-hierarchical (2),
  423. rt-no-such-channel (3),
  424. rt-no-such-domain (4),
  425. rt-no-such-user (5),
  426. rt-not-admitted (6),
  427. rt-other-user-id (7),
  428. rt-parameters-unacceptable (8),
  429. rt-token-not-available (9),
  430. rt-token-not-possessed (10),
  431. rt-too-many-channels (11),
  432. rt-too-many-tokens (12),
  433. rt-too-many-users (13),
  434. rt-unspecified-failure (14),
  435. rt-user-rejected (15)
  436. }
  437. Diagnostic ::= ENUMERATED -- in RejectUltimatumPDU
  438. {
  439. dc-inconsistent-merge (0),
  440. dc-forbidden-pdu-downward (1),
  441. dc-forbidden-pdu-upward (2),
  442. dc-invalid-ber-encoding (3),
  443. dc-invalid-per-encoding (4),
  444. dc-misrouted-user (5),
  445. dc-unrequested-confirm (6),
  446. dc-wrong-transport-priority (7),
  447. dc-channel-id-conflict (8),
  448. dc-token-id-conflict (9),
  449. dc-not-user-id-channel (10),
  450. dc-too-many-channels (11),
  451. dc-too-many-tokens (12),
  452. dc-too-many-users (13)
  453. }
  454. -- Part 10: MCSPDU repertoire
  455. ConnectMCSPDU ::= CHOICE
  456. {
  457. connect-initial ConnectInitialPDU,
  458. connect-response ConnectResponsePDU,
  459. connect-additional ConnectAdditionalPDU,
  460. connect-result ConnectResultPDU
  461. }
  462. DomainMCSPDU ::= CHOICE
  463. {
  464. plumb-domain-indication PlumbDomainIndicationPDU,
  465. erect-domain-request ErectDomainRequestPDU,
  466. merge-channels-request MergeChannelsRequestPDU,
  467. merge-channels-confirm MergeChannelsConfirmPDU,
  468. purge-channel-indication PurgeChannelIndicationPDU,
  469. merge-tokens-request MergeTokensRequestPDU,
  470. merge-tokens-confirm MergeTokensConfirmPDU,
  471. purge-token-indication PurgeTokenIndicationPDU,
  472. disconnect-provider-ultimatum DisconnectProviderUltimatumPDU,
  473. reject-user-ultimatum RejectUltimatumPDU,
  474. attach-user-request AttachUserRequestPDU,
  475. attach-user-confirm AttachUserConfirmPDU,
  476. detach-user-request DetachUserRequestPDU,
  477. detach-user-indication DetachUserIndicationPDU,
  478. channel-join-request ChannelJoinRequestPDU,
  479. channel-join-confirm ChannelJoinConfirmPDU,
  480. channel-leave-request ChannelLeaveRequestPDU,
  481. channel-convene-request ChannelConveneRequestPDU,
  482. channel-convene-confirm ChannelConveneConfirmPDU,
  483. channel-disband-request ChannelDisbandRequestPDU,
  484. channel-disband-indication ChannelDisbandIndicationPDU,
  485. channel-admit-request ChannelAdmitRequestPDU,
  486. channel-admit-indication ChannelAdmitIndicationPDU,
  487. channel-expel-request ChannelExpelRequestPDU,
  488. channel-expel-indication ChannelExpelIndicationPDU,
  489. send-data-request SendDataRequestPDU,
  490. send-data-indication SendDataIndicationPDU,
  491. uniform-send-data-request UniformSendDataRequestPDU,
  492. uniform-send-data-indication UniformSendDataIndicationPDU,
  493. token-grab-request TokenGrabRequestPDU,
  494. token-grab-confirm TokenGrabConfirmPDU,
  495. token-inhibit-request TokenInhibitRequestPDU,
  496. token-inhibit-confirm TokenInhibitConfirmPDU,
  497. token-give-request TokenGiveRequestPDU,
  498. token-give-indication TokenGiveIndicationPDU,
  499. token-give-response TokenGiveResponsePDU,
  500. token-give-confirm TokenGiveConfirmPDU,
  501. token-please-request TokenPleaseRequestPDU,
  502. token-please-indication TokenPleaseIndicationPDU,
  503. token-release-request TokenReleaseRequestPDU,
  504. token-release-confirm TokenReleaseConfirmPDU,
  505. token-test-request TokenTestRequestPDU,
  506. token-test-confirm TokenTestConfirmPDU
  507. }
  508. END