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.

6726 lines
199 KiB

  1. #include <windows.h>
  2. #include "h4503pp.h"
  3. #pragma warning ( disable: 4133 )
  4. ASN1module_t H4503PP_Module = NULL;
  5. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute_routing(ASN1encoding_t enc, TransportAddress_ipSourceRoute_routing *val);
  6. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute_route(ASN1encoding_t enc, PTransportAddress_ipSourceRoute_route *val);
  7. static int ASN1CALL ASN1Enc_TransportAddress_ip6Address(ASN1encoding_t enc, TransportAddress_ip6Address *val);
  8. static int ASN1CALL ASN1Enc_TransportAddress_ipxAddress(ASN1encoding_t enc, TransportAddress_ipxAddress *val);
  9. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute(ASN1encoding_t enc, TransportAddress_ipSourceRoute *val);
  10. static int ASN1CALL ASN1Enc_TransportAddress_ipAddress(ASN1encoding_t enc, TransportAddress_ipAddress *val);
  11. static int ASN1CALL ASN1Enc_Reject_problem(ASN1encoding_t enc, Reject_problem *val);
  12. static int ASN1CALL ASN1Enc_EntityType(ASN1encoding_t enc, EntityType *val);
  13. static int ASN1CALL ASN1Enc_InterpretationApdu(ASN1encoding_t enc, InterpretationApdu *val);
  14. static int ASN1CALL ASN1Enc_ServiceApdus(ASN1encoding_t enc, ServiceApdus *val);
  15. static int ASN1CALL ASN1Enc_Reject(ASN1encoding_t enc, Reject *val);
  16. static int ASN1CALL ASN1Enc_EXTENSION(ASN1encoding_t enc, EXTENSION *val);
  17. static int ASN1CALL ASN1Enc_GroupIndicationOnRes(ASN1encoding_t enc, GroupIndicationOnRes *val);
  18. static int ASN1CALL ASN1Enc_GroupIndicationOffRes(ASN1encoding_t enc, GroupIndicationOffRes *val);
  19. static int ASN1CALL ASN1Enc_PickupRes(ASN1encoding_t enc, PickupRes *val);
  20. static int ASN1CALL ASN1Enc_PickExeRes(ASN1encoding_t enc, PickExeRes *val);
  21. static int ASN1CALL ASN1Enc_UserSpecifiedSubaddress(ASN1encoding_t enc, UserSpecifiedSubaddress *val);
  22. static int ASN1CALL ASN1Enc_CODE(ASN1encoding_t enc, CODE *val);
  23. static int ASN1CALL ASN1Enc_H221NonStandard(ASN1encoding_t enc, H221NonStandard *val);
  24. static int ASN1CALL ASN1Enc_H225NonStandardIdentifier(ASN1encoding_t enc, H225NonStandardIdentifier *val);
  25. static int ASN1CALL ASN1Enc_PublicTypeOfNumber(ASN1encoding_t enc, PublicTypeOfNumber *val);
  26. static int ASN1CALL ASN1Enc_PrivateTypeOfNumber(ASN1encoding_t enc, PrivateTypeOfNumber *val);
  27. static int ASN1CALL ASN1Enc_CallIdentifier(ASN1encoding_t enc, CallIdentifier *val);
  28. static int ASN1CALL ASN1Enc_ReturnResult_result(ASN1encoding_t enc, ReturnResult_result *val);
  29. static int ASN1CALL ASN1Enc_Invoke(ASN1encoding_t enc, Invoke *val);
  30. static int ASN1CALL ASN1Enc_ReturnResult(ASN1encoding_t enc, ReturnResult *val);
  31. static int ASN1CALL ASN1Enc_ReturnError(ASN1encoding_t enc, ReturnError *val);
  32. static int ASN1CALL ASN1Enc_ExtensionSeq(ASN1encoding_t enc, PExtensionSeq *val);
  33. static int ASN1CALL ASN1Enc_PickrequRes(ASN1encoding_t enc, PickrequRes *val);
  34. static int ASN1CALL ASN1Enc_PartySubaddress(ASN1encoding_t enc, PartySubaddress *val);
  35. static int ASN1CALL ASN1Enc_H225NonStandardParameter(ASN1encoding_t enc, H225NonStandardParameter *val);
  36. static int ASN1CALL ASN1Enc_PublicPartyNumber(ASN1encoding_t enc, PublicPartyNumber *val);
  37. static int ASN1CALL ASN1Enc_PrivatePartyNumber(ASN1encoding_t enc, PrivatePartyNumber *val);
  38. static int ASN1CALL ASN1Enc_TransportAddress(ASN1encoding_t enc, TransportAddress *val);
  39. static int ASN1CALL ASN1Enc_CTActiveArg_argumentExtension(ASN1encoding_t enc, CTActiveArg_argumentExtension *val);
  40. static int ASN1CALL ASN1Enc_CTCompleteArg_argumentExtension(ASN1encoding_t enc, CTCompleteArg_argumentExtension *val);
  41. static int ASN1CALL ASN1Enc_SubaddressTransferArg_argumentExtension(ASN1encoding_t enc, SubaddressTransferArg_argumentExtension *val);
  42. static int ASN1CALL ASN1Enc_CTUpdateArg_argumentExtension(ASN1encoding_t enc, CTUpdateArg_argumentExtension *val);
  43. static int ASN1CALL ASN1Enc_CTIdentifyRes_resultExtension(ASN1encoding_t enc, CTIdentifyRes_resultExtension *val);
  44. static int ASN1CALL ASN1Enc_CTSetupArg_argumentExtension(ASN1encoding_t enc, CTSetupArg_argumentExtension *val);
  45. static int ASN1CALL ASN1Enc_CTInitiateArg_argumentExtension(ASN1encoding_t enc, CTInitiateArg_argumentExtension *val);
  46. static int ASN1CALL ASN1Enc_IntResult_extension(ASN1encoding_t enc, IntResult_extension *val);
  47. static int ASN1CALL ASN1Enc_DivertingLegInformation4Argument_extension(ASN1encoding_t enc, DivertingLegInformation4Argument_extension *val);
  48. static int ASN1CALL ASN1Enc_DivertingLegInformation3Argument_extension(ASN1encoding_t enc, DivertingLegInformation3Argument_extension *val);
  49. static int ASN1CALL ASN1Enc_DivertingLegInformation2Argument_extension(ASN1encoding_t enc, DivertingLegInformation2Argument_extension *val);
  50. static int ASN1CALL ASN1Enc_DivertingLegInformation1Argument_extension(ASN1encoding_t enc, DivertingLegInformation1Argument_extension *val);
  51. static int ASN1CALL ASN1Enc_CallReroutingArgument_extension(ASN1encoding_t enc, CallReroutingArgument_extension *val);
  52. static int ASN1CALL ASN1Enc_CheckRestrictionArgument_extension(ASN1encoding_t enc, CheckRestrictionArgument_extension *val);
  53. static int ASN1CALL ASN1Enc_InterrogateDiversionQArgument_extension(ASN1encoding_t enc, InterrogateDiversionQArgument_extension *val);
  54. static int ASN1CALL ASN1Enc_DeactivateDiversionQArgument_extension(ASN1encoding_t enc, DeactivateDiversionQArgument_extension *val);
  55. static int ASN1CALL ASN1Enc_ActivateDiversionQArgument_extension(ASN1encoding_t enc, ActivateDiversionQArgument_extension *val);
  56. static int ASN1CALL ASN1Enc_H4503ROS(ASN1encoding_t enc, H4503ROS *val);
  57. static int ASN1CALL ASN1Enc_DummyArg(ASN1encoding_t enc, DummyArg *val);
  58. static int ASN1CALL ASN1Enc_DummyRes(ASN1encoding_t enc, DummyRes *val);
  59. static int ASN1CALL ASN1Enc_SubaddressTransferArg(ASN1encoding_t enc, SubaddressTransferArg *val);
  60. static int ASN1CALL ASN1Enc_MixedExtension(ASN1encoding_t enc, MixedExtension *val);
  61. static int ASN1CALL ASN1Enc_PartyNumber(ASN1encoding_t enc, PartyNumber *val);
  62. static int ASN1CALL ASN1Enc_CpickupNotifyArg_extensionArg(ASN1encoding_t enc, PCpickupNotifyArg_extensionArg *val);
  63. static int ASN1CALL ASN1Enc_CpNotifyArg_extensionArg(ASN1encoding_t enc, PCpNotifyArg_extensionArg *val);
  64. static int ASN1CALL ASN1Enc_PickExeRes_extensionRes(ASN1encoding_t enc, PPickExeRes_extensionRes *val);
  65. static int ASN1CALL ASN1Enc_PickExeArg_extensionArg(ASN1encoding_t enc, PPickExeArg_extensionArg *val);
  66. static int ASN1CALL ASN1Enc_PickupRes_extensionRes(ASN1encoding_t enc, PPickupRes_extensionRes *val);
  67. static int ASN1CALL ASN1Enc_PickupArg_extensionArg(ASN1encoding_t enc, PPickupArg_extensionArg *val);
  68. static int ASN1CALL ASN1Enc_PickrequRes_extensionRes(ASN1encoding_t enc, PPickrequRes_extensionRes *val);
  69. static int ASN1CALL ASN1Enc_PickrequArg_extensionArg(ASN1encoding_t enc, PPickrequArg_extensionArg *val);
  70. static int ASN1CALL ASN1Enc_GroupIndicationOffRes_extensionRes(ASN1encoding_t enc, PGroupIndicationOffRes_extensionRes *val);
  71. static int ASN1CALL ASN1Enc_GroupIndicationOffArg_extensionArg(ASN1encoding_t enc, PGroupIndicationOffArg_extensionArg *val);
  72. static int ASN1CALL ASN1Enc_GroupIndicationOnRes_extensionRes(ASN1encoding_t enc, PGroupIndicationOnRes_extensionRes *val);
  73. static int ASN1CALL ASN1Enc_GroupIndicationOnArg_extensionArg(ASN1encoding_t enc, PGroupIndicationOnArg_extensionArg *val);
  74. static int ASN1CALL ASN1Enc_CpSetupRes_extensionRes(ASN1encoding_t enc, PCpSetupRes_extensionRes *val);
  75. static int ASN1CALL ASN1Enc_CpSetupArg_extensionArg(ASN1encoding_t enc, PCpSetupArg_extensionArg *val);
  76. static int ASN1CALL ASN1Enc_CpRequestRes_extensionRes(ASN1encoding_t enc, PCpRequestRes_extensionRes *val);
  77. static int ASN1CALL ASN1Enc_CpRequestArg_extensionArg(ASN1encoding_t enc, PCpRequestArg_extensionArg *val);
  78. static int ASN1CALL ASN1Enc_ServiceApdus_rosApdus(ASN1encoding_t enc, PServiceApdus_rosApdus *val);
  79. static int ASN1CALL ASN1Enc_AliasAddress(ASN1encoding_t enc, AliasAddress *val);
  80. static int ASN1CALL ASN1Enc_EndpointAddress_destinationAddress(ASN1encoding_t enc, PEndpointAddress_destinationAddress *val);
  81. static int ASN1CALL ASN1Enc_AddressInformation(ASN1encoding_t enc, AddressInformation *val);
  82. static int ASN1CALL ASN1Enc_EndpointAddress(ASN1encoding_t enc, EndpointAddress *val);
  83. static int ASN1CALL ASN1Enc_NetworkFacilityExtension(ASN1encoding_t enc, NetworkFacilityExtension *val);
  84. static int ASN1CALL ASN1Enc_ActivateDiversionQArgument(ASN1encoding_t enc, ActivateDiversionQArgument *val);
  85. static int ASN1CALL ASN1Enc_DeactivateDiversionQArgument(ASN1encoding_t enc, DeactivateDiversionQArgument *val);
  86. static int ASN1CALL ASN1Enc_InterrogateDiversionQArgument(ASN1encoding_t enc, InterrogateDiversionQArgument *val);
  87. static int ASN1CALL ASN1Enc_CheckRestrictionArgument(ASN1encoding_t enc, CheckRestrictionArgument *val);
  88. static int ASN1CALL ASN1Enc_CallReroutingArgument(ASN1encoding_t enc, CallReroutingArgument *val);
  89. static int ASN1CALL ASN1Enc_DivertingLegInformation1Argument(ASN1encoding_t enc, DivertingLegInformation1Argument *val);
  90. static int ASN1CALL ASN1Enc_DivertingLegInformation2Argument(ASN1encoding_t enc, DivertingLegInformation2Argument *val);
  91. static int ASN1CALL ASN1Enc_DivertingLegInformation3Argument(ASN1encoding_t enc, DivertingLegInformation3Argument *val);
  92. static int ASN1CALL ASN1Enc_DivertingLegInformation4Argument(ASN1encoding_t enc, DivertingLegInformation4Argument *val);
  93. static int ASN1CALL ASN1Enc_IntResult(ASN1encoding_t enc, IntResult *val);
  94. static int ASN1CALL ASN1Enc_CTInitiateArg(ASN1encoding_t enc, CTInitiateArg *val);
  95. static int ASN1CALL ASN1Enc_CTSetupArg(ASN1encoding_t enc, CTSetupArg *val);
  96. static int ASN1CALL ASN1Enc_CTIdentifyRes(ASN1encoding_t enc, CTIdentifyRes *val);
  97. static int ASN1CALL ASN1Enc_CTUpdateArg(ASN1encoding_t enc, CTUpdateArg *val);
  98. static int ASN1CALL ASN1Enc_CTCompleteArg(ASN1encoding_t enc, CTCompleteArg *val);
  99. static int ASN1CALL ASN1Enc_CTActiveArg(ASN1encoding_t enc, CTActiveArg *val);
  100. static int ASN1CALL ASN1Enc_CpRequestArg(ASN1encoding_t enc, CpRequestArg *val);
  101. static int ASN1CALL ASN1Enc_CpRequestRes(ASN1encoding_t enc, CpRequestRes *val);
  102. static int ASN1CALL ASN1Enc_CpSetupArg(ASN1encoding_t enc, CpSetupArg *val);
  103. static int ASN1CALL ASN1Enc_CpSetupRes(ASN1encoding_t enc, CpSetupRes *val);
  104. static int ASN1CALL ASN1Enc_GroupIndicationOnArg(ASN1encoding_t enc, GroupIndicationOnArg *val);
  105. static int ASN1CALL ASN1Enc_GroupIndicationOffArg(ASN1encoding_t enc, GroupIndicationOffArg *val);
  106. static int ASN1CALL ASN1Enc_PickrequArg(ASN1encoding_t enc, PickrequArg *val);
  107. static int ASN1CALL ASN1Enc_PickupArg(ASN1encoding_t enc, PickupArg *val);
  108. static int ASN1CALL ASN1Enc_PickExeArg(ASN1encoding_t enc, PickExeArg *val);
  109. static int ASN1CALL ASN1Enc_CpNotifyArg(ASN1encoding_t enc, CpNotifyArg *val);
  110. static int ASN1CALL ASN1Enc_CpickupNotifyArg(ASN1encoding_t enc, CpickupNotifyArg *val);
  111. static int ASN1CALL ASN1Enc_H4501SupplementaryService(ASN1encoding_t enc, H4501SupplementaryService *val);
  112. static int ASN1CALL ASN1Enc_IntResultList(ASN1encoding_t enc, IntResultList *val);
  113. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute_routing(ASN1decoding_t dec, TransportAddress_ipSourceRoute_routing *val);
  114. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute_route(ASN1decoding_t dec, PTransportAddress_ipSourceRoute_route *val);
  115. static int ASN1CALL ASN1Dec_TransportAddress_ip6Address(ASN1decoding_t dec, TransportAddress_ip6Address *val);
  116. static int ASN1CALL ASN1Dec_TransportAddress_ipxAddress(ASN1decoding_t dec, TransportAddress_ipxAddress *val);
  117. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute(ASN1decoding_t dec, TransportAddress_ipSourceRoute *val);
  118. static int ASN1CALL ASN1Dec_TransportAddress_ipAddress(ASN1decoding_t dec, TransportAddress_ipAddress *val);
  119. static int ASN1CALL ASN1Dec_Reject_problem(ASN1decoding_t dec, Reject_problem *val);
  120. static int ASN1CALL ASN1Dec_EntityType(ASN1decoding_t dec, EntityType *val);
  121. static int ASN1CALL ASN1Dec_InterpretationApdu(ASN1decoding_t dec, InterpretationApdu *val);
  122. static int ASN1CALL ASN1Dec_ServiceApdus(ASN1decoding_t dec, ServiceApdus *val);
  123. static int ASN1CALL ASN1Dec_Reject(ASN1decoding_t dec, Reject *val);
  124. static int ASN1CALL ASN1Dec_EXTENSION(ASN1decoding_t dec, EXTENSION *val);
  125. static int ASN1CALL ASN1Dec_GroupIndicationOnRes(ASN1decoding_t dec, GroupIndicationOnRes *val);
  126. static int ASN1CALL ASN1Dec_GroupIndicationOffRes(ASN1decoding_t dec, GroupIndicationOffRes *val);
  127. static int ASN1CALL ASN1Dec_PickupRes(ASN1decoding_t dec, PickupRes *val);
  128. static int ASN1CALL ASN1Dec_PickExeRes(ASN1decoding_t dec, PickExeRes *val);
  129. static int ASN1CALL ASN1Dec_UserSpecifiedSubaddress(ASN1decoding_t dec, UserSpecifiedSubaddress *val);
  130. static int ASN1CALL ASN1Dec_CODE(ASN1decoding_t dec, CODE *val);
  131. static int ASN1CALL ASN1Dec_H221NonStandard(ASN1decoding_t dec, H221NonStandard *val);
  132. static int ASN1CALL ASN1Dec_H225NonStandardIdentifier(ASN1decoding_t dec, H225NonStandardIdentifier *val);
  133. static int ASN1CALL ASN1Dec_PublicTypeOfNumber(ASN1decoding_t dec, PublicTypeOfNumber *val);
  134. static int ASN1CALL ASN1Dec_PrivateTypeOfNumber(ASN1decoding_t dec, PrivateTypeOfNumber *val);
  135. static int ASN1CALL ASN1Dec_CallIdentifier(ASN1decoding_t dec, CallIdentifier *val);
  136. static int ASN1CALL ASN1Dec_ReturnResult_result(ASN1decoding_t dec, ReturnResult_result *val);
  137. static int ASN1CALL ASN1Dec_Invoke(ASN1decoding_t dec, Invoke *val);
  138. static int ASN1CALL ASN1Dec_ReturnResult(ASN1decoding_t dec, ReturnResult *val);
  139. static int ASN1CALL ASN1Dec_ReturnError(ASN1decoding_t dec, ReturnError *val);
  140. static int ASN1CALL ASN1Dec_ExtensionSeq(ASN1decoding_t dec, PExtensionSeq *val);
  141. static int ASN1CALL ASN1Dec_PickrequRes(ASN1decoding_t dec, PickrequRes *val);
  142. static int ASN1CALL ASN1Dec_PartySubaddress(ASN1decoding_t dec, PartySubaddress *val);
  143. static int ASN1CALL ASN1Dec_H225NonStandardParameter(ASN1decoding_t dec, H225NonStandardParameter *val);
  144. static int ASN1CALL ASN1Dec_PublicPartyNumber(ASN1decoding_t dec, PublicPartyNumber *val);
  145. static int ASN1CALL ASN1Dec_PrivatePartyNumber(ASN1decoding_t dec, PrivatePartyNumber *val);
  146. static int ASN1CALL ASN1Dec_TransportAddress(ASN1decoding_t dec, TransportAddress *val);
  147. static int ASN1CALL ASN1Dec_CTActiveArg_argumentExtension(ASN1decoding_t dec, CTActiveArg_argumentExtension *val);
  148. static int ASN1CALL ASN1Dec_CTCompleteArg_argumentExtension(ASN1decoding_t dec, CTCompleteArg_argumentExtension *val);
  149. static int ASN1CALL ASN1Dec_SubaddressTransferArg_argumentExtension(ASN1decoding_t dec, SubaddressTransferArg_argumentExtension *val);
  150. static int ASN1CALL ASN1Dec_CTUpdateArg_argumentExtension(ASN1decoding_t dec, CTUpdateArg_argumentExtension *val);
  151. static int ASN1CALL ASN1Dec_CTIdentifyRes_resultExtension(ASN1decoding_t dec, CTIdentifyRes_resultExtension *val);
  152. static int ASN1CALL ASN1Dec_CTSetupArg_argumentExtension(ASN1decoding_t dec, CTSetupArg_argumentExtension *val);
  153. static int ASN1CALL ASN1Dec_CTInitiateArg_argumentExtension(ASN1decoding_t dec, CTInitiateArg_argumentExtension *val);
  154. static int ASN1CALL ASN1Dec_IntResult_extension(ASN1decoding_t dec, IntResult_extension *val);
  155. static int ASN1CALL ASN1Dec_DivertingLegInformation4Argument_extension(ASN1decoding_t dec, DivertingLegInformation4Argument_extension *val);
  156. static int ASN1CALL ASN1Dec_DivertingLegInformation3Argument_extension(ASN1decoding_t dec, DivertingLegInformation3Argument_extension *val);
  157. static int ASN1CALL ASN1Dec_DivertingLegInformation2Argument_extension(ASN1decoding_t dec, DivertingLegInformation2Argument_extension *val);
  158. static int ASN1CALL ASN1Dec_DivertingLegInformation1Argument_extension(ASN1decoding_t dec, DivertingLegInformation1Argument_extension *val);
  159. static int ASN1CALL ASN1Dec_CallReroutingArgument_extension(ASN1decoding_t dec, CallReroutingArgument_extension *val);
  160. static int ASN1CALL ASN1Dec_CheckRestrictionArgument_extension(ASN1decoding_t dec, CheckRestrictionArgument_extension *val);
  161. static int ASN1CALL ASN1Dec_InterrogateDiversionQArgument_extension(ASN1decoding_t dec, InterrogateDiversionQArgument_extension *val);
  162. static int ASN1CALL ASN1Dec_DeactivateDiversionQArgument_extension(ASN1decoding_t dec, DeactivateDiversionQArgument_extension *val);
  163. static int ASN1CALL ASN1Dec_ActivateDiversionQArgument_extension(ASN1decoding_t dec, ActivateDiversionQArgument_extension *val);
  164. static int ASN1CALL ASN1Dec_H4503ROS(ASN1decoding_t dec, H4503ROS *val);
  165. static int ASN1CALL ASN1Dec_DummyArg(ASN1decoding_t dec, DummyArg *val);
  166. static int ASN1CALL ASN1Dec_DummyRes(ASN1decoding_t dec, DummyRes *val);
  167. static int ASN1CALL ASN1Dec_SubaddressTransferArg(ASN1decoding_t dec, SubaddressTransferArg *val);
  168. static int ASN1CALL ASN1Dec_MixedExtension(ASN1decoding_t dec, MixedExtension *val);
  169. static int ASN1CALL ASN1Dec_PartyNumber(ASN1decoding_t dec, PartyNumber *val);
  170. static int ASN1CALL ASN1Dec_CpickupNotifyArg_extensionArg(ASN1decoding_t dec, PCpickupNotifyArg_extensionArg *val);
  171. static int ASN1CALL ASN1Dec_CpNotifyArg_extensionArg(ASN1decoding_t dec, PCpNotifyArg_extensionArg *val);
  172. static int ASN1CALL ASN1Dec_PickExeRes_extensionRes(ASN1decoding_t dec, PPickExeRes_extensionRes *val);
  173. static int ASN1CALL ASN1Dec_PickExeArg_extensionArg(ASN1decoding_t dec, PPickExeArg_extensionArg *val);
  174. static int ASN1CALL ASN1Dec_PickupRes_extensionRes(ASN1decoding_t dec, PPickupRes_extensionRes *val);
  175. static int ASN1CALL ASN1Dec_PickupArg_extensionArg(ASN1decoding_t dec, PPickupArg_extensionArg *val);
  176. static int ASN1CALL ASN1Dec_PickrequRes_extensionRes(ASN1decoding_t dec, PPickrequRes_extensionRes *val);
  177. static int ASN1CALL ASN1Dec_PickrequArg_extensionArg(ASN1decoding_t dec, PPickrequArg_extensionArg *val);
  178. static int ASN1CALL ASN1Dec_GroupIndicationOffRes_extensionRes(ASN1decoding_t dec, PGroupIndicationOffRes_extensionRes *val);
  179. static int ASN1CALL ASN1Dec_GroupIndicationOffArg_extensionArg(ASN1decoding_t dec, PGroupIndicationOffArg_extensionArg *val);
  180. static int ASN1CALL ASN1Dec_GroupIndicationOnRes_extensionRes(ASN1decoding_t dec, PGroupIndicationOnRes_extensionRes *val);
  181. static int ASN1CALL ASN1Dec_GroupIndicationOnArg_extensionArg(ASN1decoding_t dec, PGroupIndicationOnArg_extensionArg *val);
  182. static int ASN1CALL ASN1Dec_CpSetupRes_extensionRes(ASN1decoding_t dec, PCpSetupRes_extensionRes *val);
  183. static int ASN1CALL ASN1Dec_CpSetupArg_extensionArg(ASN1decoding_t dec, PCpSetupArg_extensionArg *val);
  184. static int ASN1CALL ASN1Dec_CpRequestRes_extensionRes(ASN1decoding_t dec, PCpRequestRes_extensionRes *val);
  185. static int ASN1CALL ASN1Dec_CpRequestArg_extensionArg(ASN1decoding_t dec, PCpRequestArg_extensionArg *val);
  186. static int ASN1CALL ASN1Dec_ServiceApdus_rosApdus(ASN1decoding_t dec, PServiceApdus_rosApdus *val);
  187. static int ASN1CALL ASN1Dec_AliasAddress(ASN1decoding_t dec, AliasAddress *val);
  188. static int ASN1CALL ASN1Dec_EndpointAddress_destinationAddress(ASN1decoding_t dec, PEndpointAddress_destinationAddress *val);
  189. static int ASN1CALL ASN1Dec_AddressInformation(ASN1decoding_t dec, AddressInformation *val);
  190. static int ASN1CALL ASN1Dec_EndpointAddress(ASN1decoding_t dec, EndpointAddress *val);
  191. static int ASN1CALL ASN1Dec_NetworkFacilityExtension(ASN1decoding_t dec, NetworkFacilityExtension *val);
  192. static int ASN1CALL ASN1Dec_ActivateDiversionQArgument(ASN1decoding_t dec, ActivateDiversionQArgument *val);
  193. static int ASN1CALL ASN1Dec_DeactivateDiversionQArgument(ASN1decoding_t dec, DeactivateDiversionQArgument *val);
  194. static int ASN1CALL ASN1Dec_InterrogateDiversionQArgument(ASN1decoding_t dec, InterrogateDiversionQArgument *val);
  195. static int ASN1CALL ASN1Dec_CheckRestrictionArgument(ASN1decoding_t dec, CheckRestrictionArgument *val);
  196. static int ASN1CALL ASN1Dec_CallReroutingArgument(ASN1decoding_t dec, CallReroutingArgument *val);
  197. static int ASN1CALL ASN1Dec_DivertingLegInformation1Argument(ASN1decoding_t dec, DivertingLegInformation1Argument *val);
  198. static int ASN1CALL ASN1Dec_DivertingLegInformation2Argument(ASN1decoding_t dec, DivertingLegInformation2Argument *val);
  199. static int ASN1CALL ASN1Dec_DivertingLegInformation3Argument(ASN1decoding_t dec, DivertingLegInformation3Argument *val);
  200. static int ASN1CALL ASN1Dec_DivertingLegInformation4Argument(ASN1decoding_t dec, DivertingLegInformation4Argument *val);
  201. static int ASN1CALL ASN1Dec_IntResult(ASN1decoding_t dec, IntResult *val);
  202. static int ASN1CALL ASN1Dec_CTInitiateArg(ASN1decoding_t dec, CTInitiateArg *val);
  203. static int ASN1CALL ASN1Dec_CTSetupArg(ASN1decoding_t dec, CTSetupArg *val);
  204. static int ASN1CALL ASN1Dec_CTIdentifyRes(ASN1decoding_t dec, CTIdentifyRes *val);
  205. static int ASN1CALL ASN1Dec_CTUpdateArg(ASN1decoding_t dec, CTUpdateArg *val);
  206. static int ASN1CALL ASN1Dec_CTCompleteArg(ASN1decoding_t dec, CTCompleteArg *val);
  207. static int ASN1CALL ASN1Dec_CTActiveArg(ASN1decoding_t dec, CTActiveArg *val);
  208. static int ASN1CALL ASN1Dec_CpRequestArg(ASN1decoding_t dec, CpRequestArg *val);
  209. static int ASN1CALL ASN1Dec_CpRequestRes(ASN1decoding_t dec, CpRequestRes *val);
  210. static int ASN1CALL ASN1Dec_CpSetupArg(ASN1decoding_t dec, CpSetupArg *val);
  211. static int ASN1CALL ASN1Dec_CpSetupRes(ASN1decoding_t dec, CpSetupRes *val);
  212. static int ASN1CALL ASN1Dec_GroupIndicationOnArg(ASN1decoding_t dec, GroupIndicationOnArg *val);
  213. static int ASN1CALL ASN1Dec_GroupIndicationOffArg(ASN1decoding_t dec, GroupIndicationOffArg *val);
  214. static int ASN1CALL ASN1Dec_PickrequArg(ASN1decoding_t dec, PickrequArg *val);
  215. static int ASN1CALL ASN1Dec_PickupArg(ASN1decoding_t dec, PickupArg *val);
  216. static int ASN1CALL ASN1Dec_PickExeArg(ASN1decoding_t dec, PickExeArg *val);
  217. static int ASN1CALL ASN1Dec_CpNotifyArg(ASN1decoding_t dec, CpNotifyArg *val);
  218. static int ASN1CALL ASN1Dec_CpickupNotifyArg(ASN1decoding_t dec, CpickupNotifyArg *val);
  219. static int ASN1CALL ASN1Dec_H4501SupplementaryService(ASN1decoding_t dec, H4501SupplementaryService *val);
  220. static int ASN1CALL ASN1Dec_IntResultList(ASN1decoding_t dec, IntResultList *val);
  221. static void ASN1CALL ASN1Free_TransportAddress_ipSourceRoute_route(PTransportAddress_ipSourceRoute_route *val);
  222. static void ASN1CALL ASN1Free_TransportAddress_ip6Address(TransportAddress_ip6Address *val);
  223. static void ASN1CALL ASN1Free_TransportAddress_ipxAddress(TransportAddress_ipxAddress *val);
  224. static void ASN1CALL ASN1Free_TransportAddress_ipSourceRoute(TransportAddress_ipSourceRoute *val);
  225. static void ASN1CALL ASN1Free_TransportAddress_ipAddress(TransportAddress_ipAddress *val);
  226. static void ASN1CALL ASN1Free_ServiceApdus(ServiceApdus *val);
  227. static void ASN1CALL ASN1Free_EXTENSION(EXTENSION *val);
  228. static void ASN1CALL ASN1Free_GroupIndicationOnRes(GroupIndicationOnRes *val);
  229. static void ASN1CALL ASN1Free_GroupIndicationOffRes(GroupIndicationOffRes *val);
  230. static void ASN1CALL ASN1Free_PickupRes(PickupRes *val);
  231. static void ASN1CALL ASN1Free_PickExeRes(PickExeRes *val);
  232. static void ASN1CALL ASN1Free_UserSpecifiedSubaddress(UserSpecifiedSubaddress *val);
  233. static void ASN1CALL ASN1Free_CODE(CODE *val);
  234. static void ASN1CALL ASN1Free_H225NonStandardIdentifier(H225NonStandardIdentifier *val);
  235. static void ASN1CALL ASN1Free_CallIdentifier(CallIdentifier *val);
  236. static void ASN1CALL ASN1Free_ReturnResult_result(ReturnResult_result *val);
  237. static void ASN1CALL ASN1Free_Invoke(Invoke *val);
  238. static void ASN1CALL ASN1Free_ReturnResult(ReturnResult *val);
  239. static void ASN1CALL ASN1Free_ReturnError(ReturnError *val);
  240. static void ASN1CALL ASN1Free_ExtensionSeq(PExtensionSeq *val);
  241. static void ASN1CALL ASN1Free_PickrequRes(PickrequRes *val);
  242. static void ASN1CALL ASN1Free_PartySubaddress(PartySubaddress *val);
  243. static void ASN1CALL ASN1Free_H225NonStandardParameter(H225NonStandardParameter *val);
  244. static void ASN1CALL ASN1Free_PublicPartyNumber(PublicPartyNumber *val);
  245. static void ASN1CALL ASN1Free_PrivatePartyNumber(PrivatePartyNumber *val);
  246. static void ASN1CALL ASN1Free_TransportAddress(TransportAddress *val);
  247. static void ASN1CALL ASN1Free_CTActiveArg_argumentExtension(CTActiveArg_argumentExtension *val);
  248. static void ASN1CALL ASN1Free_CTCompleteArg_argumentExtension(CTCompleteArg_argumentExtension *val);
  249. static void ASN1CALL ASN1Free_SubaddressTransferArg_argumentExtension(SubaddressTransferArg_argumentExtension *val);
  250. static void ASN1CALL ASN1Free_CTUpdateArg_argumentExtension(CTUpdateArg_argumentExtension *val);
  251. static void ASN1CALL ASN1Free_CTIdentifyRes_resultExtension(CTIdentifyRes_resultExtension *val);
  252. static void ASN1CALL ASN1Free_CTSetupArg_argumentExtension(CTSetupArg_argumentExtension *val);
  253. static void ASN1CALL ASN1Free_CTInitiateArg_argumentExtension(CTInitiateArg_argumentExtension *val);
  254. static void ASN1CALL ASN1Free_IntResult_extension(IntResult_extension *val);
  255. static void ASN1CALL ASN1Free_DivertingLegInformation4Argument_extension(DivertingLegInformation4Argument_extension *val);
  256. static void ASN1CALL ASN1Free_DivertingLegInformation3Argument_extension(DivertingLegInformation3Argument_extension *val);
  257. static void ASN1CALL ASN1Free_DivertingLegInformation2Argument_extension(DivertingLegInformation2Argument_extension *val);
  258. static void ASN1CALL ASN1Free_DivertingLegInformation1Argument_extension(DivertingLegInformation1Argument_extension *val);
  259. static void ASN1CALL ASN1Free_CallReroutingArgument_extension(CallReroutingArgument_extension *val);
  260. static void ASN1CALL ASN1Free_CheckRestrictionArgument_extension(CheckRestrictionArgument_extension *val);
  261. static void ASN1CALL ASN1Free_InterrogateDiversionQArgument_extension(InterrogateDiversionQArgument_extension *val);
  262. static void ASN1CALL ASN1Free_DeactivateDiversionQArgument_extension(DeactivateDiversionQArgument_extension *val);
  263. static void ASN1CALL ASN1Free_ActivateDiversionQArgument_extension(ActivateDiversionQArgument_extension *val);
  264. static void ASN1CALL ASN1Free_H4503ROS(H4503ROS *val);
  265. static void ASN1CALL ASN1Free_DummyArg(DummyArg *val);
  266. static void ASN1CALL ASN1Free_DummyRes(DummyRes *val);
  267. static void ASN1CALL ASN1Free_SubaddressTransferArg(SubaddressTransferArg *val);
  268. static void ASN1CALL ASN1Free_MixedExtension(MixedExtension *val);
  269. static void ASN1CALL ASN1Free_PartyNumber(PartyNumber *val);
  270. static void ASN1CALL ASN1Free_CpickupNotifyArg_extensionArg(PCpickupNotifyArg_extensionArg *val);
  271. static void ASN1CALL ASN1Free_CpNotifyArg_extensionArg(PCpNotifyArg_extensionArg *val);
  272. static void ASN1CALL ASN1Free_PickExeRes_extensionRes(PPickExeRes_extensionRes *val);
  273. static void ASN1CALL ASN1Free_PickExeArg_extensionArg(PPickExeArg_extensionArg *val);
  274. static void ASN1CALL ASN1Free_PickupRes_extensionRes(PPickupRes_extensionRes *val);
  275. static void ASN1CALL ASN1Free_PickupArg_extensionArg(PPickupArg_extensionArg *val);
  276. static void ASN1CALL ASN1Free_PickrequRes_extensionRes(PPickrequRes_extensionRes *val);
  277. static void ASN1CALL ASN1Free_PickrequArg_extensionArg(PPickrequArg_extensionArg *val);
  278. static void ASN1CALL ASN1Free_GroupIndicationOffRes_extensionRes(PGroupIndicationOffRes_extensionRes *val);
  279. static void ASN1CALL ASN1Free_GroupIndicationOffArg_extensionArg(PGroupIndicationOffArg_extensionArg *val);
  280. static void ASN1CALL ASN1Free_GroupIndicationOnRes_extensionRes(PGroupIndicationOnRes_extensionRes *val);
  281. static void ASN1CALL ASN1Free_GroupIndicationOnArg_extensionArg(PGroupIndicationOnArg_extensionArg *val);
  282. static void ASN1CALL ASN1Free_CpSetupRes_extensionRes(PCpSetupRes_extensionRes *val);
  283. static void ASN1CALL ASN1Free_CpSetupArg_extensionArg(PCpSetupArg_extensionArg *val);
  284. static void ASN1CALL ASN1Free_CpRequestRes_extensionRes(PCpRequestRes_extensionRes *val);
  285. static void ASN1CALL ASN1Free_CpRequestArg_extensionArg(PCpRequestArg_extensionArg *val);
  286. static void ASN1CALL ASN1Free_ServiceApdus_rosApdus(PServiceApdus_rosApdus *val);
  287. static void ASN1CALL ASN1Free_AliasAddress(AliasAddress *val);
  288. static void ASN1CALL ASN1Free_EndpointAddress_destinationAddress(PEndpointAddress_destinationAddress *val);
  289. static void ASN1CALL ASN1Free_AddressInformation(AddressInformation *val);
  290. static void ASN1CALL ASN1Free_EndpointAddress(EndpointAddress *val);
  291. static void ASN1CALL ASN1Free_NetworkFacilityExtension(NetworkFacilityExtension *val);
  292. static void ASN1CALL ASN1Free_ActivateDiversionQArgument(ActivateDiversionQArgument *val);
  293. static void ASN1CALL ASN1Free_DeactivateDiversionQArgument(DeactivateDiversionQArgument *val);
  294. static void ASN1CALL ASN1Free_InterrogateDiversionQArgument(InterrogateDiversionQArgument *val);
  295. static void ASN1CALL ASN1Free_CheckRestrictionArgument(CheckRestrictionArgument *val);
  296. static void ASN1CALL ASN1Free_CallReroutingArgument(CallReroutingArgument *val);
  297. static void ASN1CALL ASN1Free_DivertingLegInformation1Argument(DivertingLegInformation1Argument *val);
  298. static void ASN1CALL ASN1Free_DivertingLegInformation2Argument(DivertingLegInformation2Argument *val);
  299. static void ASN1CALL ASN1Free_DivertingLegInformation3Argument(DivertingLegInformation3Argument *val);
  300. static void ASN1CALL ASN1Free_DivertingLegInformation4Argument(DivertingLegInformation4Argument *val);
  301. static void ASN1CALL ASN1Free_IntResult(IntResult *val);
  302. static void ASN1CALL ASN1Free_CTInitiateArg(CTInitiateArg *val);
  303. static void ASN1CALL ASN1Free_CTSetupArg(CTSetupArg *val);
  304. static void ASN1CALL ASN1Free_CTIdentifyRes(CTIdentifyRes *val);
  305. static void ASN1CALL ASN1Free_CTUpdateArg(CTUpdateArg *val);
  306. static void ASN1CALL ASN1Free_CTCompleteArg(CTCompleteArg *val);
  307. static void ASN1CALL ASN1Free_CTActiveArg(CTActiveArg *val);
  308. static void ASN1CALL ASN1Free_CpRequestArg(CpRequestArg *val);
  309. static void ASN1CALL ASN1Free_CpRequestRes(CpRequestRes *val);
  310. static void ASN1CALL ASN1Free_CpSetupArg(CpSetupArg *val);
  311. static void ASN1CALL ASN1Free_CpSetupRes(CpSetupRes *val);
  312. static void ASN1CALL ASN1Free_GroupIndicationOnArg(GroupIndicationOnArg *val);
  313. static void ASN1CALL ASN1Free_GroupIndicationOffArg(GroupIndicationOffArg *val);
  314. static void ASN1CALL ASN1Free_PickrequArg(PickrequArg *val);
  315. static void ASN1CALL ASN1Free_PickupArg(PickupArg *val);
  316. static void ASN1CALL ASN1Free_PickExeArg(PickExeArg *val);
  317. static void ASN1CALL ASN1Free_CpNotifyArg(CpNotifyArg *val);
  318. static void ASN1CALL ASN1Free_CpickupNotifyArg(CpickupNotifyArg *val);
  319. static void ASN1CALL ASN1Free_H4501SupplementaryService(H4501SupplementaryService *val);
  320. static void ASN1CALL ASN1Free_IntResultList(IntResultList *val);
  321. typedef ASN1PerEncFun_t ASN1EncFun_t;
  322. static const ASN1EncFun_t encfntab[36] = {
  323. (ASN1EncFun_t) ASN1Enc_GroupIndicationOnRes,
  324. (ASN1EncFun_t) ASN1Enc_GroupIndicationOffRes,
  325. (ASN1EncFun_t) ASN1Enc_PickupRes,
  326. (ASN1EncFun_t) ASN1Enc_PickExeRes,
  327. (ASN1EncFun_t) ASN1Enc_PickrequRes,
  328. (ASN1EncFun_t) ASN1Enc_DummyArg,
  329. (ASN1EncFun_t) ASN1Enc_DummyRes,
  330. (ASN1EncFun_t) ASN1Enc_SubaddressTransferArg,
  331. (ASN1EncFun_t) ASN1Enc_ActivateDiversionQArgument,
  332. (ASN1EncFun_t) ASN1Enc_DeactivateDiversionQArgument,
  333. (ASN1EncFun_t) ASN1Enc_InterrogateDiversionQArgument,
  334. (ASN1EncFun_t) ASN1Enc_CheckRestrictionArgument,
  335. (ASN1EncFun_t) ASN1Enc_CallReroutingArgument,
  336. (ASN1EncFun_t) ASN1Enc_DivertingLegInformation1Argument,
  337. (ASN1EncFun_t) ASN1Enc_DivertingLegInformation2Argument,
  338. (ASN1EncFun_t) ASN1Enc_DivertingLegInformation3Argument,
  339. (ASN1EncFun_t) ASN1Enc_DivertingLegInformation4Argument,
  340. (ASN1EncFun_t) ASN1Enc_CTInitiateArg,
  341. (ASN1EncFun_t) ASN1Enc_CTSetupArg,
  342. (ASN1EncFun_t) ASN1Enc_CTIdentifyRes,
  343. (ASN1EncFun_t) ASN1Enc_CTUpdateArg,
  344. (ASN1EncFun_t) ASN1Enc_CTCompleteArg,
  345. (ASN1EncFun_t) ASN1Enc_CTActiveArg,
  346. (ASN1EncFun_t) ASN1Enc_CpRequestArg,
  347. (ASN1EncFun_t) ASN1Enc_CpRequestRes,
  348. (ASN1EncFun_t) ASN1Enc_CpSetupArg,
  349. (ASN1EncFun_t) ASN1Enc_CpSetupRes,
  350. (ASN1EncFun_t) ASN1Enc_GroupIndicationOnArg,
  351. (ASN1EncFun_t) ASN1Enc_GroupIndicationOffArg,
  352. (ASN1EncFun_t) ASN1Enc_PickrequArg,
  353. (ASN1EncFun_t) ASN1Enc_PickupArg,
  354. (ASN1EncFun_t) ASN1Enc_PickExeArg,
  355. (ASN1EncFun_t) ASN1Enc_CpNotifyArg,
  356. (ASN1EncFun_t) ASN1Enc_CpickupNotifyArg,
  357. (ASN1EncFun_t) ASN1Enc_H4501SupplementaryService,
  358. (ASN1EncFun_t) ASN1Enc_IntResultList,
  359. };
  360. typedef ASN1PerDecFun_t ASN1DecFun_t;
  361. static const ASN1DecFun_t decfntab[36] = {
  362. (ASN1DecFun_t) ASN1Dec_GroupIndicationOnRes,
  363. (ASN1DecFun_t) ASN1Dec_GroupIndicationOffRes,
  364. (ASN1DecFun_t) ASN1Dec_PickupRes,
  365. (ASN1DecFun_t) ASN1Dec_PickExeRes,
  366. (ASN1DecFun_t) ASN1Dec_PickrequRes,
  367. (ASN1DecFun_t) ASN1Dec_DummyArg,
  368. (ASN1DecFun_t) ASN1Dec_DummyRes,
  369. (ASN1DecFun_t) ASN1Dec_SubaddressTransferArg,
  370. (ASN1DecFun_t) ASN1Dec_ActivateDiversionQArgument,
  371. (ASN1DecFun_t) ASN1Dec_DeactivateDiversionQArgument,
  372. (ASN1DecFun_t) ASN1Dec_InterrogateDiversionQArgument,
  373. (ASN1DecFun_t) ASN1Dec_CheckRestrictionArgument,
  374. (ASN1DecFun_t) ASN1Dec_CallReroutingArgument,
  375. (ASN1DecFun_t) ASN1Dec_DivertingLegInformation1Argument,
  376. (ASN1DecFun_t) ASN1Dec_DivertingLegInformation2Argument,
  377. (ASN1DecFun_t) ASN1Dec_DivertingLegInformation3Argument,
  378. (ASN1DecFun_t) ASN1Dec_DivertingLegInformation4Argument,
  379. (ASN1DecFun_t) ASN1Dec_CTInitiateArg,
  380. (ASN1DecFun_t) ASN1Dec_CTSetupArg,
  381. (ASN1DecFun_t) ASN1Dec_CTIdentifyRes,
  382. (ASN1DecFun_t) ASN1Dec_CTUpdateArg,
  383. (ASN1DecFun_t) ASN1Dec_CTCompleteArg,
  384. (ASN1DecFun_t) ASN1Dec_CTActiveArg,
  385. (ASN1DecFun_t) ASN1Dec_CpRequestArg,
  386. (ASN1DecFun_t) ASN1Dec_CpRequestRes,
  387. (ASN1DecFun_t) ASN1Dec_CpSetupArg,
  388. (ASN1DecFun_t) ASN1Dec_CpSetupRes,
  389. (ASN1DecFun_t) ASN1Dec_GroupIndicationOnArg,
  390. (ASN1DecFun_t) ASN1Dec_GroupIndicationOffArg,
  391. (ASN1DecFun_t) ASN1Dec_PickrequArg,
  392. (ASN1DecFun_t) ASN1Dec_PickupArg,
  393. (ASN1DecFun_t) ASN1Dec_PickExeArg,
  394. (ASN1DecFun_t) ASN1Dec_CpNotifyArg,
  395. (ASN1DecFun_t) ASN1Dec_CpickupNotifyArg,
  396. (ASN1DecFun_t) ASN1Dec_H4501SupplementaryService,
  397. (ASN1DecFun_t) ASN1Dec_IntResultList,
  398. };
  399. static const ASN1FreeFun_t freefntab[36] = {
  400. (ASN1FreeFun_t) ASN1Free_GroupIndicationOnRes,
  401. (ASN1FreeFun_t) ASN1Free_GroupIndicationOffRes,
  402. (ASN1FreeFun_t) ASN1Free_PickupRes,
  403. (ASN1FreeFun_t) ASN1Free_PickExeRes,
  404. (ASN1FreeFun_t) ASN1Free_PickrequRes,
  405. (ASN1FreeFun_t) ASN1Free_DummyArg,
  406. (ASN1FreeFun_t) ASN1Free_DummyRes,
  407. (ASN1FreeFun_t) ASN1Free_SubaddressTransferArg,
  408. (ASN1FreeFun_t) ASN1Free_ActivateDiversionQArgument,
  409. (ASN1FreeFun_t) ASN1Free_DeactivateDiversionQArgument,
  410. (ASN1FreeFun_t) ASN1Free_InterrogateDiversionQArgument,
  411. (ASN1FreeFun_t) ASN1Free_CheckRestrictionArgument,
  412. (ASN1FreeFun_t) ASN1Free_CallReroutingArgument,
  413. (ASN1FreeFun_t) ASN1Free_DivertingLegInformation1Argument,
  414. (ASN1FreeFun_t) ASN1Free_DivertingLegInformation2Argument,
  415. (ASN1FreeFun_t) ASN1Free_DivertingLegInformation3Argument,
  416. (ASN1FreeFun_t) ASN1Free_DivertingLegInformation4Argument,
  417. (ASN1FreeFun_t) ASN1Free_CTInitiateArg,
  418. (ASN1FreeFun_t) ASN1Free_CTSetupArg,
  419. (ASN1FreeFun_t) ASN1Free_CTIdentifyRes,
  420. (ASN1FreeFun_t) ASN1Free_CTUpdateArg,
  421. (ASN1FreeFun_t) ASN1Free_CTCompleteArg,
  422. (ASN1FreeFun_t) ASN1Free_CTActiveArg,
  423. (ASN1FreeFun_t) ASN1Free_CpRequestArg,
  424. (ASN1FreeFun_t) ASN1Free_CpRequestRes,
  425. (ASN1FreeFun_t) ASN1Free_CpSetupArg,
  426. (ASN1FreeFun_t) ASN1Free_CpSetupRes,
  427. (ASN1FreeFun_t) ASN1Free_GroupIndicationOnArg,
  428. (ASN1FreeFun_t) ASN1Free_GroupIndicationOffArg,
  429. (ASN1FreeFun_t) ASN1Free_PickrequArg,
  430. (ASN1FreeFun_t) ASN1Free_PickupArg,
  431. (ASN1FreeFun_t) ASN1Free_PickExeArg,
  432. (ASN1FreeFun_t) ASN1Free_CpNotifyArg,
  433. (ASN1FreeFun_t) ASN1Free_CpickupNotifyArg,
  434. (ASN1FreeFun_t) ASN1Free_H4501SupplementaryService,
  435. (ASN1FreeFun_t) ASN1Free_IntResultList,
  436. };
  437. static const ULONG sizetab[36] = {
  438. SIZE_H4503PP_Module_PDU_0,
  439. SIZE_H4503PP_Module_PDU_1,
  440. SIZE_H4503PP_Module_PDU_2,
  441. SIZE_H4503PP_Module_PDU_3,
  442. SIZE_H4503PP_Module_PDU_4,
  443. SIZE_H4503PP_Module_PDU_5,
  444. SIZE_H4503PP_Module_PDU_6,
  445. SIZE_H4503PP_Module_PDU_7,
  446. SIZE_H4503PP_Module_PDU_8,
  447. SIZE_H4503PP_Module_PDU_9,
  448. SIZE_H4503PP_Module_PDU_10,
  449. SIZE_H4503PP_Module_PDU_11,
  450. SIZE_H4503PP_Module_PDU_12,
  451. SIZE_H4503PP_Module_PDU_13,
  452. SIZE_H4503PP_Module_PDU_14,
  453. SIZE_H4503PP_Module_PDU_15,
  454. SIZE_H4503PP_Module_PDU_16,
  455. SIZE_H4503PP_Module_PDU_17,
  456. SIZE_H4503PP_Module_PDU_18,
  457. SIZE_H4503PP_Module_PDU_19,
  458. SIZE_H4503PP_Module_PDU_20,
  459. SIZE_H4503PP_Module_PDU_21,
  460. SIZE_H4503PP_Module_PDU_22,
  461. SIZE_H4503PP_Module_PDU_23,
  462. SIZE_H4503PP_Module_PDU_24,
  463. SIZE_H4503PP_Module_PDU_25,
  464. SIZE_H4503PP_Module_PDU_26,
  465. SIZE_H4503PP_Module_PDU_27,
  466. SIZE_H4503PP_Module_PDU_28,
  467. SIZE_H4503PP_Module_PDU_29,
  468. SIZE_H4503PP_Module_PDU_30,
  469. SIZE_H4503PP_Module_PDU_31,
  470. SIZE_H4503PP_Module_PDU_32,
  471. SIZE_H4503PP_Module_PDU_33,
  472. SIZE_H4503PP_Module_PDU_34,
  473. SIZE_H4503PP_Module_PDU_35,
  474. };
  475. /* forward declarations of values: */
  476. /* definitions of value components: */
  477. /* definitions of values: */
  478. CallStatus CTCompleteArg_callStatus_default = 0;
  479. ASN1bool_t IntResult_remoteEnabled_default = 0;
  480. BasicService InterrogateDiversionQArgument_basicService_default = 0;
  481. void ASN1CALL H4503PP_Module_Startup(void)
  482. {
  483. H4503PP_Module = ASN1_CreateModule(0x10000, ASN1_PER_RULE_ALIGNED, ASN1FLAGS_NONE, 36, (const ASN1GenericFun_t *) encfntab, (const ASN1GenericFun_t *) decfntab, freefntab, sizetab, 0x30353468);
  484. }
  485. void ASN1CALL H4503PP_Module_Cleanup(void)
  486. {
  487. ASN1_CloseModule(H4503PP_Module);
  488. H4503PP_Module = NULL;
  489. }
  490. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute_routing(ASN1encoding_t enc, TransportAddress_ipSourceRoute_routing *val)
  491. {
  492. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 1))
  493. return 0;
  494. return 1;
  495. }
  496. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute_routing(ASN1decoding_t dec, TransportAddress_ipSourceRoute_routing *val)
  497. {
  498. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 1))
  499. return 0;
  500. return 1;
  501. }
  502. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute_route(ASN1encoding_t enc, PTransportAddress_ipSourceRoute_route *val)
  503. {
  504. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_TransportAddress_ipSourceRoute_route_ElmFn);
  505. }
  506. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute_route_ElmFn(ASN1encoding_t enc, PTransportAddress_ipSourceRoute_route val)
  507. {
  508. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &val->value, 4))
  509. return 0;
  510. return 1;
  511. }
  512. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute_route(ASN1decoding_t dec, PTransportAddress_ipSourceRoute_route *val)
  513. {
  514. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_TransportAddress_ipSourceRoute_route_ElmFn, sizeof(**val));
  515. }
  516. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute_route_ElmFn(ASN1decoding_t dec, PTransportAddress_ipSourceRoute_route val)
  517. {
  518. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &val->value, 4))
  519. return 0;
  520. return 1;
  521. }
  522. static void ASN1CALL ASN1Free_TransportAddress_ipSourceRoute_route(PTransportAddress_ipSourceRoute_route *val)
  523. {
  524. if (val) {
  525. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_TransportAddress_ipSourceRoute_route_ElmFn);
  526. }
  527. }
  528. static void ASN1CALL ASN1Free_TransportAddress_ipSourceRoute_route_ElmFn(PTransportAddress_ipSourceRoute_route val)
  529. {
  530. if (val) {
  531. }
  532. }
  533. static int ASN1CALL ASN1Enc_TransportAddress_ip6Address(ASN1encoding_t enc, TransportAddress_ip6Address *val)
  534. {
  535. if (!ASN1PEREncExtensionBitClear(enc))
  536. return 0;
  537. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->ip, 16))
  538. return 0;
  539. if (!ASN1PEREncUnsignedShort(enc, (val)->port))
  540. return 0;
  541. return 1;
  542. }
  543. static int ASN1CALL ASN1Dec_TransportAddress_ip6Address(ASN1decoding_t dec, TransportAddress_ip6Address *val)
  544. {
  545. ASN1uint32_t y;
  546. if (!ASN1PERDecExtensionBit(dec, &y))
  547. return 0;
  548. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->ip, 16))
  549. return 0;
  550. if (!ASN1PERDecUnsignedShort(dec, &(val)->port))
  551. return 0;
  552. if (y) {
  553. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  554. return 0;
  555. }
  556. return 1;
  557. }
  558. static void ASN1CALL ASN1Free_TransportAddress_ip6Address(TransportAddress_ip6Address *val)
  559. {
  560. if (val) {
  561. }
  562. }
  563. static int ASN1CALL ASN1Enc_TransportAddress_ipxAddress(ASN1encoding_t enc, TransportAddress_ipxAddress *val)
  564. {
  565. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->node, 6))
  566. return 0;
  567. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->netnum, 4))
  568. return 0;
  569. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->port, 2))
  570. return 0;
  571. return 1;
  572. }
  573. static int ASN1CALL ASN1Dec_TransportAddress_ipxAddress(ASN1decoding_t dec, TransportAddress_ipxAddress *val)
  574. {
  575. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->node, 6))
  576. return 0;
  577. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->netnum, 4))
  578. return 0;
  579. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->port, 2))
  580. return 0;
  581. return 1;
  582. }
  583. static void ASN1CALL ASN1Free_TransportAddress_ipxAddress(TransportAddress_ipxAddress *val)
  584. {
  585. if (val) {
  586. }
  587. }
  588. static int ASN1CALL ASN1Enc_TransportAddress_ipSourceRoute(ASN1encoding_t enc, TransportAddress_ipSourceRoute *val)
  589. {
  590. if (!ASN1PEREncExtensionBitClear(enc))
  591. return 0;
  592. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->ip, 4))
  593. return 0;
  594. if (!ASN1PEREncUnsignedShort(enc, (val)->port))
  595. return 0;
  596. if (!ASN1Enc_TransportAddress_ipSourceRoute_route(enc, &(val)->route))
  597. return 0;
  598. if (!ASN1Enc_TransportAddress_ipSourceRoute_routing(enc, &(val)->routing))
  599. return 0;
  600. return 1;
  601. }
  602. static int ASN1CALL ASN1Dec_TransportAddress_ipSourceRoute(ASN1decoding_t dec, TransportAddress_ipSourceRoute *val)
  603. {
  604. ASN1uint32_t y;
  605. if (!ASN1PERDecExtensionBit(dec, &y))
  606. return 0;
  607. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->ip, 4))
  608. return 0;
  609. if (!ASN1PERDecUnsignedShort(dec, &(val)->port))
  610. return 0;
  611. if (!ASN1Dec_TransportAddress_ipSourceRoute_route(dec, &(val)->route))
  612. return 0;
  613. if (!ASN1Dec_TransportAddress_ipSourceRoute_routing(dec, &(val)->routing))
  614. return 0;
  615. if (y) {
  616. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  617. return 0;
  618. }
  619. return 1;
  620. }
  621. static void ASN1CALL ASN1Free_TransportAddress_ipSourceRoute(TransportAddress_ipSourceRoute *val)
  622. {
  623. if (val) {
  624. ASN1Free_TransportAddress_ipSourceRoute_route(&(val)->route);
  625. }
  626. }
  627. static int ASN1CALL ASN1Enc_TransportAddress_ipAddress(ASN1encoding_t enc, TransportAddress_ipAddress *val)
  628. {
  629. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->ip, 4))
  630. return 0;
  631. if (!ASN1PEREncUnsignedShort(enc, (val)->port))
  632. return 0;
  633. return 1;
  634. }
  635. static int ASN1CALL ASN1Dec_TransportAddress_ipAddress(ASN1decoding_t dec, TransportAddress_ipAddress *val)
  636. {
  637. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->ip, 4))
  638. return 0;
  639. if (!ASN1PERDecUnsignedShort(dec, &(val)->port))
  640. return 0;
  641. return 1;
  642. }
  643. static void ASN1CALL ASN1Free_TransportAddress_ipAddress(TransportAddress_ipAddress *val)
  644. {
  645. if (val) {
  646. }
  647. }
  648. static int ASN1CALL ASN1Enc_Reject_problem(ASN1encoding_t enc, Reject_problem *val)
  649. {
  650. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 2))
  651. return 0;
  652. switch ((val)->choice) {
  653. case 1:
  654. if (!ASN1PEREncInteger(enc, (val)->u.general))
  655. return 0;
  656. break;
  657. case 2:
  658. if (!ASN1PEREncInteger(enc, (val)->u.invoke))
  659. return 0;
  660. break;
  661. case 3:
  662. if (!ASN1PEREncInteger(enc, (val)->u.returnResult))
  663. return 0;
  664. break;
  665. case 4:
  666. if (!ASN1PEREncInteger(enc, (val)->u.returnError))
  667. return 0;
  668. break;
  669. default:
  670. /* impossible */
  671. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  672. return 0;
  673. }
  674. return 1;
  675. }
  676. static int ASN1CALL ASN1Dec_Reject_problem(ASN1decoding_t dec, Reject_problem *val)
  677. {
  678. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 2))
  679. return 0;
  680. switch ((val)->choice) {
  681. case 1:
  682. if (!ASN1PERDecInteger(dec, &(val)->u.general))
  683. return 0;
  684. break;
  685. case 2:
  686. if (!ASN1PERDecInteger(dec, &(val)->u.invoke))
  687. return 0;
  688. break;
  689. case 3:
  690. if (!ASN1PERDecInteger(dec, &(val)->u.returnResult))
  691. return 0;
  692. break;
  693. case 4:
  694. if (!ASN1PERDecInteger(dec, &(val)->u.returnError))
  695. return 0;
  696. break;
  697. default:
  698. /* impossible */
  699. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  700. return 0;
  701. }
  702. return 1;
  703. }
  704. static int ASN1CALL ASN1Enc_EntityType(ASN1encoding_t enc, EntityType *val)
  705. {
  706. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 1))
  707. return 0;
  708. return 1;
  709. }
  710. static int ASN1CALL ASN1Dec_EntityType(ASN1decoding_t dec, EntityType *val)
  711. {
  712. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 1))
  713. return 0;
  714. return 1;
  715. }
  716. static int ASN1CALL ASN1Enc_InterpretationApdu(ASN1encoding_t enc, InterpretationApdu *val)
  717. {
  718. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 2))
  719. return 0;
  720. return 1;
  721. }
  722. static int ASN1CALL ASN1Dec_InterpretationApdu(ASN1decoding_t dec, InterpretationApdu *val)
  723. {
  724. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 2))
  725. return 0;
  726. return 1;
  727. }
  728. static int ASN1CALL ASN1Enc_ServiceApdus(ASN1encoding_t enc, ServiceApdus *val)
  729. {
  730. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 0))
  731. return 0;
  732. switch ((val)->choice) {
  733. case 1:
  734. if (!ASN1Enc_ServiceApdus_rosApdus(enc, &(val)->u.rosApdus))
  735. return 0;
  736. break;
  737. default:
  738. /* impossible */
  739. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  740. return 0;
  741. }
  742. return 1;
  743. }
  744. static int ASN1CALL ASN1Dec_ServiceApdus(ASN1decoding_t dec, ServiceApdus *val)
  745. {
  746. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 0))
  747. return 0;
  748. switch ((val)->choice) {
  749. case 1:
  750. if (!ASN1Dec_ServiceApdus_rosApdus(dec, &(val)->u.rosApdus))
  751. return 0;
  752. break;
  753. case 0:
  754. /* extension case */
  755. if (!ASN1PERDecSkipFragmented(dec, 8))
  756. return 0;
  757. break;
  758. default:
  759. /* impossible */
  760. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  761. return 0;
  762. }
  763. return 1;
  764. }
  765. static void ASN1CALL ASN1Free_ServiceApdus(ServiceApdus *val)
  766. {
  767. if (val) {
  768. switch ((val)->choice) {
  769. case 1:
  770. ASN1Free_ServiceApdus_rosApdus(&(val)->u.rosApdus);
  771. break;
  772. }
  773. }
  774. }
  775. static int ASN1CALL ASN1Enc_Reject(ASN1encoding_t enc, Reject *val)
  776. {
  777. if (!ASN1PEREncInteger(enc, (val)->invokeId))
  778. return 0;
  779. if (!ASN1Enc_Reject_problem(enc, &(val)->problem))
  780. return 0;
  781. return 1;
  782. }
  783. static int ASN1CALL ASN1Dec_Reject(ASN1decoding_t dec, Reject *val)
  784. {
  785. if (!ASN1PERDecInteger(dec, &(val)->invokeId))
  786. return 0;
  787. if (!ASN1Dec_Reject_problem(dec, &(val)->problem))
  788. return 0;
  789. return 1;
  790. }
  791. static int ASN1CALL ASN1Enc_EXTENSION(ASN1encoding_t enc, EXTENSION *val)
  792. {
  793. if (!ASN1PEREncBits(enc, 1, (val)->o))
  794. return 0;
  795. if ((val)->o[0] & 0x80) {
  796. if (!ASN1PEREncUnsignedShort(enc, (val)->argumentType - 1))
  797. return 0;
  798. }
  799. if (!ASN1PEREncObjectIdentifier(enc, &(val)->extensionID))
  800. return 0;
  801. return 1;
  802. }
  803. static int ASN1CALL ASN1Dec_EXTENSION(ASN1decoding_t dec, EXTENSION *val)
  804. {
  805. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  806. return 0;
  807. if ((val)->o[0] & 0x80) {
  808. if (!ASN1PERDecUnsignedShort(dec, &(val)->argumentType))
  809. return 0;
  810. (val)->argumentType += 1;
  811. }
  812. if (!ASN1PERDecObjectIdentifier(dec, &(val)->extensionID))
  813. return 0;
  814. return 1;
  815. }
  816. static void ASN1CALL ASN1Free_EXTENSION(EXTENSION *val)
  817. {
  818. if (val) {
  819. ASN1objectidentifier_free(&(val)->extensionID);
  820. }
  821. }
  822. static int ASN1CALL ASN1Enc_GroupIndicationOnRes(ASN1encoding_t enc, GroupIndicationOnRes *val)
  823. {
  824. if (!ASN1PEREncExtensionBitClear(enc))
  825. return 0;
  826. if (!ASN1PEREncBits(enc, 1, (val)->o))
  827. return 0;
  828. if ((val)->o[0] & 0x80) {
  829. if (!ASN1Enc_GroupIndicationOnRes_extensionRes(enc, &(val)->extensionRes))
  830. return 0;
  831. }
  832. return 1;
  833. }
  834. static int ASN1CALL ASN1Dec_GroupIndicationOnRes(ASN1decoding_t dec, GroupIndicationOnRes *val)
  835. {
  836. ASN1uint32_t y;
  837. if (!ASN1PERDecExtensionBit(dec, &y))
  838. return 0;
  839. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  840. return 0;
  841. if ((val)->o[0] & 0x80) {
  842. if (!ASN1Dec_GroupIndicationOnRes_extensionRes(dec, &(val)->extensionRes))
  843. return 0;
  844. }
  845. if (y) {
  846. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  847. return 0;
  848. }
  849. return 1;
  850. }
  851. static void ASN1CALL ASN1Free_GroupIndicationOnRes(GroupIndicationOnRes *val)
  852. {
  853. if (val) {
  854. if ((val)->o[0] & 0x80) {
  855. ASN1Free_GroupIndicationOnRes_extensionRes(&(val)->extensionRes);
  856. }
  857. }
  858. }
  859. static int ASN1CALL ASN1Enc_GroupIndicationOffRes(ASN1encoding_t enc, GroupIndicationOffRes *val)
  860. {
  861. if (!ASN1PEREncExtensionBitClear(enc))
  862. return 0;
  863. if (!ASN1PEREncBits(enc, 1, (val)->o))
  864. return 0;
  865. if ((val)->o[0] & 0x80) {
  866. if (!ASN1Enc_GroupIndicationOffRes_extensionRes(enc, &(val)->extensionRes))
  867. return 0;
  868. }
  869. return 1;
  870. }
  871. static int ASN1CALL ASN1Dec_GroupIndicationOffRes(ASN1decoding_t dec, GroupIndicationOffRes *val)
  872. {
  873. ASN1uint32_t y;
  874. if (!ASN1PERDecExtensionBit(dec, &y))
  875. return 0;
  876. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  877. return 0;
  878. if ((val)->o[0] & 0x80) {
  879. if (!ASN1Dec_GroupIndicationOffRes_extensionRes(dec, &(val)->extensionRes))
  880. return 0;
  881. }
  882. if (y) {
  883. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  884. return 0;
  885. }
  886. return 1;
  887. }
  888. static void ASN1CALL ASN1Free_GroupIndicationOffRes(GroupIndicationOffRes *val)
  889. {
  890. if (val) {
  891. if ((val)->o[0] & 0x80) {
  892. ASN1Free_GroupIndicationOffRes_extensionRes(&(val)->extensionRes);
  893. }
  894. }
  895. }
  896. static int ASN1CALL ASN1Enc_PickupRes(ASN1encoding_t enc, PickupRes *val)
  897. {
  898. if (!ASN1PEREncExtensionBitClear(enc))
  899. return 0;
  900. if (!ASN1PEREncBits(enc, 1, (val)->o))
  901. return 0;
  902. if ((val)->o[0] & 0x80) {
  903. if (!ASN1Enc_PickupRes_extensionRes(enc, &(val)->extensionRes))
  904. return 0;
  905. }
  906. return 1;
  907. }
  908. static int ASN1CALL ASN1Dec_PickupRes(ASN1decoding_t dec, PickupRes *val)
  909. {
  910. ASN1uint32_t y;
  911. if (!ASN1PERDecExtensionBit(dec, &y))
  912. return 0;
  913. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  914. return 0;
  915. if ((val)->o[0] & 0x80) {
  916. if (!ASN1Dec_PickupRes_extensionRes(dec, &(val)->extensionRes))
  917. return 0;
  918. }
  919. if (y) {
  920. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  921. return 0;
  922. }
  923. return 1;
  924. }
  925. static void ASN1CALL ASN1Free_PickupRes(PickupRes *val)
  926. {
  927. if (val) {
  928. if ((val)->o[0] & 0x80) {
  929. ASN1Free_PickupRes_extensionRes(&(val)->extensionRes);
  930. }
  931. }
  932. }
  933. static int ASN1CALL ASN1Enc_PickExeRes(ASN1encoding_t enc, PickExeRes *val)
  934. {
  935. if (!ASN1PEREncExtensionBitClear(enc))
  936. return 0;
  937. if (!ASN1PEREncBits(enc, 1, (val)->o))
  938. return 0;
  939. if ((val)->o[0] & 0x80) {
  940. if (!ASN1Enc_PickExeRes_extensionRes(enc, &(val)->extensionRes))
  941. return 0;
  942. }
  943. return 1;
  944. }
  945. static int ASN1CALL ASN1Dec_PickExeRes(ASN1decoding_t dec, PickExeRes *val)
  946. {
  947. ASN1uint32_t y;
  948. if (!ASN1PERDecExtensionBit(dec, &y))
  949. return 0;
  950. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  951. return 0;
  952. if ((val)->o[0] & 0x80) {
  953. if (!ASN1Dec_PickExeRes_extensionRes(dec, &(val)->extensionRes))
  954. return 0;
  955. }
  956. if (y) {
  957. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  958. return 0;
  959. }
  960. return 1;
  961. }
  962. static void ASN1CALL ASN1Free_PickExeRes(PickExeRes *val)
  963. {
  964. if (val) {
  965. if ((val)->o[0] & 0x80) {
  966. ASN1Free_PickExeRes_extensionRes(&(val)->extensionRes);
  967. }
  968. }
  969. }
  970. static int ASN1CALL ASN1Enc_UserSpecifiedSubaddress(ASN1encoding_t enc, UserSpecifiedSubaddress *val)
  971. {
  972. if (!ASN1PEREncExtensionBitClear(enc))
  973. return 0;
  974. if (!ASN1PEREncBits(enc, 1, (val)->o))
  975. return 0;
  976. if (!ASN1PEREncOctetString_VarSize(enc, (ASN1octetstring2_t *) &(val)->subaddressInformation, 1, 20, 5))
  977. return 0;
  978. if ((val)->o[0] & 0x80) {
  979. if (!ASN1PEREncBoolean(enc, (val)->oddCountIndicator))
  980. return 0;
  981. }
  982. return 1;
  983. }
  984. static int ASN1CALL ASN1Dec_UserSpecifiedSubaddress(ASN1decoding_t dec, UserSpecifiedSubaddress *val)
  985. {
  986. ASN1uint32_t y;
  987. if (!ASN1PERDecExtensionBit(dec, &y))
  988. return 0;
  989. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  990. return 0;
  991. if (!ASN1PERDecOctetString_VarSize(dec, (ASN1octetstring2_t *) &(val)->subaddressInformation, 1, 20, 5))
  992. return 0;
  993. if ((val)->o[0] & 0x80) {
  994. if (!ASN1PERDecBoolean(dec, &(val)->oddCountIndicator))
  995. return 0;
  996. }
  997. if (y) {
  998. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  999. return 0;
  1000. }
  1001. return 1;
  1002. }
  1003. static void ASN1CALL ASN1Free_UserSpecifiedSubaddress(UserSpecifiedSubaddress *val)
  1004. {
  1005. if (val) {
  1006. }
  1007. }
  1008. static int ASN1CALL ASN1Enc_CODE(ASN1encoding_t enc, CODE *val)
  1009. {
  1010. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1011. return 0;
  1012. switch ((val)->choice) {
  1013. case 1:
  1014. if (!ASN1PEREncInteger(enc, (val)->u.local))
  1015. return 0;
  1016. break;
  1017. case 2:
  1018. if (!ASN1PEREncObjectIdentifier(enc, &(val)->u.global))
  1019. return 0;
  1020. break;
  1021. default:
  1022. /* impossible */
  1023. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1024. return 0;
  1025. }
  1026. return 1;
  1027. }
  1028. static int ASN1CALL ASN1Dec_CODE(ASN1decoding_t dec, CODE *val)
  1029. {
  1030. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1031. return 0;
  1032. switch ((val)->choice) {
  1033. case 1:
  1034. if (!ASN1PERDecInteger(dec, &(val)->u.local))
  1035. return 0;
  1036. break;
  1037. case 2:
  1038. if (!ASN1PERDecObjectIdentifier(dec, &(val)->u.global))
  1039. return 0;
  1040. break;
  1041. default:
  1042. /* impossible */
  1043. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1044. return 0;
  1045. }
  1046. return 1;
  1047. }
  1048. static void ASN1CALL ASN1Free_CODE(CODE *val)
  1049. {
  1050. if (val) {
  1051. switch ((val)->choice) {
  1052. case 2:
  1053. ASN1objectidentifier_free(&(val)->u.global);
  1054. break;
  1055. }
  1056. }
  1057. }
  1058. static int ASN1CALL ASN1Enc_H221NonStandard(ASN1encoding_t enc, H221NonStandard *val)
  1059. {
  1060. if (!ASN1PEREncExtensionBitClear(enc))
  1061. return 0;
  1062. ASN1PEREncAlignment(enc);
  1063. if (!ASN1PEREncBitVal(enc, 8, (val)->t35CountryCode))
  1064. return 0;
  1065. ASN1PEREncAlignment(enc);
  1066. if (!ASN1PEREncBitVal(enc, 8, (val)->t35Extension))
  1067. return 0;
  1068. if (!ASN1PEREncUnsignedShort(enc, (val)->manufacturerCode))
  1069. return 0;
  1070. return 1;
  1071. }
  1072. static int ASN1CALL ASN1Dec_H221NonStandard(ASN1decoding_t dec, H221NonStandard *val)
  1073. {
  1074. ASN1uint32_t y;
  1075. if (!ASN1PERDecExtensionBit(dec, &y))
  1076. return 0;
  1077. ASN1PERDecAlignment(dec);
  1078. if (!ASN1PERDecU16Val(dec, 8, &(val)->t35CountryCode))
  1079. return 0;
  1080. ASN1PERDecAlignment(dec);
  1081. if (!ASN1PERDecU16Val(dec, 8, &(val)->t35Extension))
  1082. return 0;
  1083. if (!ASN1PERDecUnsignedShort(dec, &(val)->manufacturerCode))
  1084. return 0;
  1085. if (y) {
  1086. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  1087. return 0;
  1088. }
  1089. return 1;
  1090. }
  1091. static int ASN1CALL ASN1Enc_H225NonStandardIdentifier(ASN1encoding_t enc, H225NonStandardIdentifier *val)
  1092. {
  1093. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 1))
  1094. return 0;
  1095. switch ((val)->choice) {
  1096. case 1:
  1097. if (!ASN1PEREncObjectIdentifier(enc, &(val)->u.object))
  1098. return 0;
  1099. break;
  1100. case 2:
  1101. if (!ASN1Enc_H221NonStandard(enc, &(val)->u.h221NonStandard))
  1102. return 0;
  1103. break;
  1104. default:
  1105. /* impossible */
  1106. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1107. return 0;
  1108. }
  1109. return 1;
  1110. }
  1111. static int ASN1CALL ASN1Dec_H225NonStandardIdentifier(ASN1decoding_t dec, H225NonStandardIdentifier *val)
  1112. {
  1113. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 1))
  1114. return 0;
  1115. switch ((val)->choice) {
  1116. case 1:
  1117. if (!ASN1PERDecObjectIdentifier(dec, &(val)->u.object))
  1118. return 0;
  1119. break;
  1120. case 2:
  1121. if (!ASN1Dec_H221NonStandard(dec, &(val)->u.h221NonStandard))
  1122. return 0;
  1123. break;
  1124. case 0:
  1125. /* extension case */
  1126. if (!ASN1PERDecSkipFragmented(dec, 8))
  1127. return 0;
  1128. break;
  1129. default:
  1130. /* impossible */
  1131. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1132. return 0;
  1133. }
  1134. return 1;
  1135. }
  1136. static void ASN1CALL ASN1Free_H225NonStandardIdentifier(H225NonStandardIdentifier *val)
  1137. {
  1138. if (val) {
  1139. switch ((val)->choice) {
  1140. case 1:
  1141. ASN1objectidentifier_free(&(val)->u.object);
  1142. break;
  1143. }
  1144. }
  1145. }
  1146. static int ASN1CALL ASN1Enc_PublicTypeOfNumber(ASN1encoding_t enc, PublicTypeOfNumber *val)
  1147. {
  1148. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 3))
  1149. return 0;
  1150. return 1;
  1151. }
  1152. static int ASN1CALL ASN1Dec_PublicTypeOfNumber(ASN1decoding_t dec, PublicTypeOfNumber *val)
  1153. {
  1154. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 3))
  1155. return 0;
  1156. return 1;
  1157. }
  1158. static int ASN1CALL ASN1Enc_PrivateTypeOfNumber(ASN1encoding_t enc, PrivateTypeOfNumber *val)
  1159. {
  1160. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 3))
  1161. return 0;
  1162. return 1;
  1163. }
  1164. static int ASN1CALL ASN1Dec_PrivateTypeOfNumber(ASN1decoding_t dec, PrivateTypeOfNumber *val)
  1165. {
  1166. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 3))
  1167. return 0;
  1168. return 1;
  1169. }
  1170. static int ASN1CALL ASN1Enc_CallIdentifier(ASN1encoding_t enc, CallIdentifier *val)
  1171. {
  1172. if (!ASN1PEREncExtensionBitClear(enc))
  1173. return 0;
  1174. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->guid, 16))
  1175. return 0;
  1176. return 1;
  1177. }
  1178. static int ASN1CALL ASN1Dec_CallIdentifier(ASN1decoding_t dec, CallIdentifier *val)
  1179. {
  1180. ASN1uint32_t y;
  1181. if (!ASN1PERDecExtensionBit(dec, &y))
  1182. return 0;
  1183. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->guid, 16))
  1184. return 0;
  1185. if (y) {
  1186. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  1187. return 0;
  1188. }
  1189. return 1;
  1190. }
  1191. static void ASN1CALL ASN1Free_CallIdentifier(CallIdentifier *val)
  1192. {
  1193. if (val) {
  1194. }
  1195. }
  1196. static int ASN1CALL ASN1Enc_ReturnResult_result(ASN1encoding_t enc, ReturnResult_result *val)
  1197. {
  1198. if (!ASN1Enc_CODE(enc, &(val)->opcode))
  1199. return 0;
  1200. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->result))
  1201. return 0;
  1202. return 1;
  1203. }
  1204. static int ASN1CALL ASN1Dec_ReturnResult_result(ASN1decoding_t dec, ReturnResult_result *val)
  1205. {
  1206. if (!ASN1Dec_CODE(dec, &(val)->opcode))
  1207. return 0;
  1208. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->result))
  1209. return 0;
  1210. return 1;
  1211. }
  1212. static void ASN1CALL ASN1Free_ReturnResult_result(ReturnResult_result *val)
  1213. {
  1214. if (val) {
  1215. ASN1Free_CODE(&(val)->opcode);
  1216. ASN1octetstring_free(&(val)->result);
  1217. }
  1218. }
  1219. static int ASN1CALL ASN1Enc_Invoke(ASN1encoding_t enc, Invoke *val)
  1220. {
  1221. if (!ASN1PEREncBits(enc, 2, (val)->o))
  1222. return 0;
  1223. if (!ASN1PEREncUnsignedShort(enc, (val)->invokeId))
  1224. return 0;
  1225. if ((val)->o[0] & 0x80) {
  1226. if (!ASN1PEREncInteger(enc, (val)->linkedId))
  1227. return 0;
  1228. }
  1229. if (!ASN1Enc_CODE(enc, &(val)->opcode))
  1230. return 0;
  1231. if ((val)->o[0] & 0x40) {
  1232. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->argument))
  1233. return 0;
  1234. }
  1235. return 1;
  1236. }
  1237. static int ASN1CALL ASN1Dec_Invoke(ASN1decoding_t dec, Invoke *val)
  1238. {
  1239. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  1240. return 0;
  1241. if (!ASN1PERDecUnsignedShort(dec, &(val)->invokeId))
  1242. return 0;
  1243. if ((val)->o[0] & 0x80) {
  1244. if (!ASN1PERDecInteger(dec, &(val)->linkedId))
  1245. return 0;
  1246. }
  1247. if (!ASN1Dec_CODE(dec, &(val)->opcode))
  1248. return 0;
  1249. if ((val)->o[0] & 0x40) {
  1250. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->argument))
  1251. return 0;
  1252. }
  1253. return 1;
  1254. }
  1255. static void ASN1CALL ASN1Free_Invoke(Invoke *val)
  1256. {
  1257. if (val) {
  1258. ASN1Free_CODE(&(val)->opcode);
  1259. if ((val)->o[0] & 0x40) {
  1260. ASN1octetstring_free(&(val)->argument);
  1261. }
  1262. }
  1263. }
  1264. static int ASN1CALL ASN1Enc_ReturnResult(ASN1encoding_t enc, ReturnResult *val)
  1265. {
  1266. if (!ASN1PEREncBits(enc, 1, (val)->o))
  1267. return 0;
  1268. if (!ASN1PEREncInteger(enc, (val)->invokeId))
  1269. return 0;
  1270. if ((val)->o[0] & 0x80) {
  1271. if (!ASN1Enc_ReturnResult_result(enc, &(val)->result))
  1272. return 0;
  1273. }
  1274. return 1;
  1275. }
  1276. static int ASN1CALL ASN1Dec_ReturnResult(ASN1decoding_t dec, ReturnResult *val)
  1277. {
  1278. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  1279. return 0;
  1280. if (!ASN1PERDecInteger(dec, &(val)->invokeId))
  1281. return 0;
  1282. if ((val)->o[0] & 0x80) {
  1283. if (!ASN1Dec_ReturnResult_result(dec, &(val)->result))
  1284. return 0;
  1285. }
  1286. return 1;
  1287. }
  1288. static void ASN1CALL ASN1Free_ReturnResult(ReturnResult *val)
  1289. {
  1290. if (val) {
  1291. if ((val)->o[0] & 0x80) {
  1292. ASN1Free_ReturnResult_result(&(val)->result);
  1293. }
  1294. }
  1295. }
  1296. static int ASN1CALL ASN1Enc_ReturnError(ASN1encoding_t enc, ReturnError *val)
  1297. {
  1298. if (!ASN1PEREncBits(enc, 1, (val)->o))
  1299. return 0;
  1300. if (!ASN1PEREncInteger(enc, (val)->invokeId))
  1301. return 0;
  1302. if (!ASN1Enc_CODE(enc, &(val)->errcode))
  1303. return 0;
  1304. if ((val)->o[0] & 0x80) {
  1305. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->parameter))
  1306. return 0;
  1307. }
  1308. return 1;
  1309. }
  1310. static int ASN1CALL ASN1Dec_ReturnError(ASN1decoding_t dec, ReturnError *val)
  1311. {
  1312. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  1313. return 0;
  1314. if (!ASN1PERDecInteger(dec, &(val)->invokeId))
  1315. return 0;
  1316. if (!ASN1Dec_CODE(dec, &(val)->errcode))
  1317. return 0;
  1318. if ((val)->o[0] & 0x80) {
  1319. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->parameter))
  1320. return 0;
  1321. }
  1322. return 1;
  1323. }
  1324. static void ASN1CALL ASN1Free_ReturnError(ReturnError *val)
  1325. {
  1326. if (val) {
  1327. ASN1Free_CODE(&(val)->errcode);
  1328. if ((val)->o[0] & 0x80) {
  1329. ASN1octetstring_free(&(val)->parameter);
  1330. }
  1331. }
  1332. }
  1333. static int ASN1CALL ASN1Enc_ExtensionSeq(ASN1encoding_t enc, PExtensionSeq *val)
  1334. {
  1335. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_ExtensionSeq_ElmFn);
  1336. }
  1337. static int ASN1CALL ASN1Enc_ExtensionSeq_ElmFn(ASN1encoding_t enc, PExtensionSeq val)
  1338. {
  1339. if (!ASN1Enc_EXTENSION(enc, &val->value))
  1340. return 0;
  1341. return 1;
  1342. }
  1343. static int ASN1CALL ASN1Dec_ExtensionSeq(ASN1decoding_t dec, PExtensionSeq *val)
  1344. {
  1345. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_ExtensionSeq_ElmFn, sizeof(**val));
  1346. }
  1347. static int ASN1CALL ASN1Dec_ExtensionSeq_ElmFn(ASN1decoding_t dec, PExtensionSeq val)
  1348. {
  1349. if (!ASN1Dec_EXTENSION(dec, &val->value))
  1350. return 0;
  1351. return 1;
  1352. }
  1353. static void ASN1CALL ASN1Free_ExtensionSeq(PExtensionSeq *val)
  1354. {
  1355. if (val) {
  1356. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_ExtensionSeq_ElmFn);
  1357. }
  1358. }
  1359. static void ASN1CALL ASN1Free_ExtensionSeq_ElmFn(PExtensionSeq val)
  1360. {
  1361. if (val) {
  1362. ASN1Free_EXTENSION(&val->value);
  1363. }
  1364. }
  1365. static int ASN1CALL ASN1Enc_PickrequRes(ASN1encoding_t enc, PickrequRes *val)
  1366. {
  1367. if (!ASN1PEREncExtensionBitClear(enc))
  1368. return 0;
  1369. if (!ASN1PEREncBits(enc, 1, (val)->o))
  1370. return 0;
  1371. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  1372. return 0;
  1373. if ((val)->o[0] & 0x80) {
  1374. if (!ASN1Enc_PickrequRes_extensionRes(enc, &(val)->extensionRes))
  1375. return 0;
  1376. }
  1377. return 1;
  1378. }
  1379. static int ASN1CALL ASN1Dec_PickrequRes(ASN1decoding_t dec, PickrequRes *val)
  1380. {
  1381. ASN1uint32_t y;
  1382. if (!ASN1PERDecExtensionBit(dec, &y))
  1383. return 0;
  1384. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  1385. return 0;
  1386. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  1387. return 0;
  1388. if ((val)->o[0] & 0x80) {
  1389. if (!ASN1Dec_PickrequRes_extensionRes(dec, &(val)->extensionRes))
  1390. return 0;
  1391. }
  1392. if (y) {
  1393. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  1394. return 0;
  1395. }
  1396. return 1;
  1397. }
  1398. static void ASN1CALL ASN1Free_PickrequRes(PickrequRes *val)
  1399. {
  1400. if (val) {
  1401. ASN1Free_CallIdentifier(&(val)->callPickupId);
  1402. if ((val)->o[0] & 0x80) {
  1403. ASN1Free_PickrequRes_extensionRes(&(val)->extensionRes);
  1404. }
  1405. }
  1406. }
  1407. static int ASN1CALL ASN1Enc_PartySubaddress(ASN1encoding_t enc, PartySubaddress *val)
  1408. {
  1409. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 1))
  1410. return 0;
  1411. switch ((val)->choice) {
  1412. case 1:
  1413. if (!ASN1Enc_UserSpecifiedSubaddress(enc, &(val)->u.userSpecifiedSubaddress))
  1414. return 0;
  1415. break;
  1416. case 2:
  1417. if (!ASN1PEREncOctetString_VarSize(enc, (ASN1octetstring2_t *) &(val)->u.nsapSubaddress, 1, 20, 5))
  1418. return 0;
  1419. break;
  1420. default:
  1421. /* impossible */
  1422. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1423. return 0;
  1424. }
  1425. return 1;
  1426. }
  1427. static int ASN1CALL ASN1Dec_PartySubaddress(ASN1decoding_t dec, PartySubaddress *val)
  1428. {
  1429. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 1))
  1430. return 0;
  1431. switch ((val)->choice) {
  1432. case 1:
  1433. if (!ASN1Dec_UserSpecifiedSubaddress(dec, &(val)->u.userSpecifiedSubaddress))
  1434. return 0;
  1435. break;
  1436. case 2:
  1437. if (!ASN1PERDecOctetString_VarSize(dec, (ASN1octetstring2_t *) &(val)->u.nsapSubaddress, 1, 20, 5))
  1438. return 0;
  1439. break;
  1440. case 0:
  1441. /* extension case */
  1442. if (!ASN1PERDecSkipFragmented(dec, 8))
  1443. return 0;
  1444. break;
  1445. default:
  1446. /* impossible */
  1447. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1448. return 0;
  1449. }
  1450. return 1;
  1451. }
  1452. static void ASN1CALL ASN1Free_PartySubaddress(PartySubaddress *val)
  1453. {
  1454. if (val) {
  1455. switch ((val)->choice) {
  1456. case 1:
  1457. ASN1Free_UserSpecifiedSubaddress(&(val)->u.userSpecifiedSubaddress);
  1458. break;
  1459. case 2:
  1460. break;
  1461. }
  1462. }
  1463. }
  1464. static int ASN1CALL ASN1Enc_H225NonStandardParameter(ASN1encoding_t enc, H225NonStandardParameter *val)
  1465. {
  1466. if (!ASN1Enc_H225NonStandardIdentifier(enc, &(val)->nonStandardIdentifier))
  1467. return 0;
  1468. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->data))
  1469. return 0;
  1470. return 1;
  1471. }
  1472. static int ASN1CALL ASN1Dec_H225NonStandardParameter(ASN1decoding_t dec, H225NonStandardParameter *val)
  1473. {
  1474. if (!ASN1Dec_H225NonStandardIdentifier(dec, &(val)->nonStandardIdentifier))
  1475. return 0;
  1476. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->data))
  1477. return 0;
  1478. return 1;
  1479. }
  1480. static void ASN1CALL ASN1Free_H225NonStandardParameter(H225NonStandardParameter *val)
  1481. {
  1482. if (val) {
  1483. ASN1Free_H225NonStandardIdentifier(&(val)->nonStandardIdentifier);
  1484. ASN1octetstring_free(&(val)->data);
  1485. }
  1486. }
  1487. static ASN1stringtableentry_t PublicPartyNumber_publicNumberDigits_StringTableEntries[] = {
  1488. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  1489. { 48, 57, 3 },
  1490. };
  1491. static ASN1stringtable_t PublicPartyNumber_publicNumberDigits_StringTable = {
  1492. 4, PublicPartyNumber_publicNumberDigits_StringTableEntries
  1493. };
  1494. static int ASN1CALL ASN1Enc_PublicPartyNumber(ASN1encoding_t enc, PublicPartyNumber *val)
  1495. {
  1496. ASN1uint32_t t;
  1497. if (!ASN1Enc_PublicTypeOfNumber(enc, &(val)->publicTypeOfNumber))
  1498. return 0;
  1499. t = lstrlenA((val)->publicNumberDigits);
  1500. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  1501. return 0;
  1502. ASN1PEREncAlignment(enc);
  1503. if (!ASN1PEREncTableCharString(enc, t, (val)->publicNumberDigits, 4, &PublicPartyNumber_publicNumberDigits_StringTable))
  1504. return 0;
  1505. return 1;
  1506. }
  1507. static int ASN1CALL ASN1Dec_PublicPartyNumber(ASN1decoding_t dec, PublicPartyNumber *val)
  1508. {
  1509. ASN1uint32_t l;
  1510. if (!ASN1Dec_PublicTypeOfNumber(dec, &(val)->publicTypeOfNumber))
  1511. return 0;
  1512. if (!ASN1PERDecU32Val(dec, 7, &l))
  1513. return 0;
  1514. l += 1;
  1515. ASN1PERDecAlignment(dec);
  1516. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->publicNumberDigits, 4, &PublicPartyNumber_publicNumberDigits_StringTable))
  1517. return 0;
  1518. return 1;
  1519. }
  1520. static void ASN1CALL ASN1Free_PublicPartyNumber(PublicPartyNumber *val)
  1521. {
  1522. if (val) {
  1523. }
  1524. }
  1525. static ASN1stringtableentry_t PrivatePartyNumber_privateNumberDigits_StringTableEntries[] = {
  1526. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  1527. { 48, 57, 3 },
  1528. };
  1529. static ASN1stringtable_t PrivatePartyNumber_privateNumberDigits_StringTable = {
  1530. 4, PrivatePartyNumber_privateNumberDigits_StringTableEntries
  1531. };
  1532. static int ASN1CALL ASN1Enc_PrivatePartyNumber(ASN1encoding_t enc, PrivatePartyNumber *val)
  1533. {
  1534. ASN1uint32_t t;
  1535. if (!ASN1Enc_PrivateTypeOfNumber(enc, &(val)->privateTypeOfNumber))
  1536. return 0;
  1537. t = lstrlenA((val)->privateNumberDigits);
  1538. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  1539. return 0;
  1540. ASN1PEREncAlignment(enc);
  1541. if (!ASN1PEREncTableCharString(enc, t, (val)->privateNumberDigits, 4, &PrivatePartyNumber_privateNumberDigits_StringTable))
  1542. return 0;
  1543. return 1;
  1544. }
  1545. static int ASN1CALL ASN1Dec_PrivatePartyNumber(ASN1decoding_t dec, PrivatePartyNumber *val)
  1546. {
  1547. ASN1uint32_t l;
  1548. if (!ASN1Dec_PrivateTypeOfNumber(dec, &(val)->privateTypeOfNumber))
  1549. return 0;
  1550. if (!ASN1PERDecU32Val(dec, 7, &l))
  1551. return 0;
  1552. l += 1;
  1553. ASN1PERDecAlignment(dec);
  1554. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->privateNumberDigits, 4, &PrivatePartyNumber_privateNumberDigits_StringTable))
  1555. return 0;
  1556. return 1;
  1557. }
  1558. static void ASN1CALL ASN1Free_PrivatePartyNumber(PrivatePartyNumber *val)
  1559. {
  1560. if (val) {
  1561. }
  1562. }
  1563. static int ASN1CALL ASN1Enc_TransportAddress(ASN1encoding_t enc, TransportAddress *val)
  1564. {
  1565. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 3))
  1566. return 0;
  1567. switch ((val)->choice) {
  1568. case 1:
  1569. if (!ASN1Enc_TransportAddress_ipAddress(enc, &(val)->u.ipAddress))
  1570. return 0;
  1571. break;
  1572. case 2:
  1573. if (!ASN1Enc_TransportAddress_ipSourceRoute(enc, &(val)->u.ipSourceRoute))
  1574. return 0;
  1575. break;
  1576. case 3:
  1577. if (!ASN1Enc_TransportAddress_ipxAddress(enc, &(val)->u.ipxAddress))
  1578. return 0;
  1579. break;
  1580. case 4:
  1581. if (!ASN1Enc_TransportAddress_ip6Address(enc, &(val)->u.ip6Address))
  1582. return 0;
  1583. break;
  1584. case 5:
  1585. if (!ASN1PEREncOctetString_FixedSize(enc, (ASN1octetstring2_t *) &(val)->u.netBios, 16))
  1586. return 0;
  1587. break;
  1588. case 6:
  1589. if (!ASN1PEREncOctetString_VarSize(enc, (ASN1octetstring2_t *) &(val)->u.nsap, 1, 20, 5))
  1590. return 0;
  1591. break;
  1592. case 7:
  1593. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardAddress))
  1594. return 0;
  1595. break;
  1596. default:
  1597. /* impossible */
  1598. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1599. return 0;
  1600. }
  1601. return 1;
  1602. }
  1603. static int ASN1CALL ASN1Dec_TransportAddress(ASN1decoding_t dec, TransportAddress *val)
  1604. {
  1605. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 3))
  1606. return 0;
  1607. switch ((val)->choice) {
  1608. case 1:
  1609. if (!ASN1Dec_TransportAddress_ipAddress(dec, &(val)->u.ipAddress))
  1610. return 0;
  1611. break;
  1612. case 2:
  1613. if (!ASN1Dec_TransportAddress_ipSourceRoute(dec, &(val)->u.ipSourceRoute))
  1614. return 0;
  1615. break;
  1616. case 3:
  1617. if (!ASN1Dec_TransportAddress_ipxAddress(dec, &(val)->u.ipxAddress))
  1618. return 0;
  1619. break;
  1620. case 4:
  1621. if (!ASN1Dec_TransportAddress_ip6Address(dec, &(val)->u.ip6Address))
  1622. return 0;
  1623. break;
  1624. case 5:
  1625. if (!ASN1PERDecOctetString_FixedSize(dec, (ASN1octetstring2_t *) &(val)->u.netBios, 16))
  1626. return 0;
  1627. break;
  1628. case 6:
  1629. if (!ASN1PERDecOctetString_VarSize(dec, (ASN1octetstring2_t *) &(val)->u.nsap, 1, 20, 5))
  1630. return 0;
  1631. break;
  1632. case 7:
  1633. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardAddress))
  1634. return 0;
  1635. break;
  1636. case 0:
  1637. /* extension case */
  1638. if (!ASN1PERDecSkipFragmented(dec, 8))
  1639. return 0;
  1640. break;
  1641. default:
  1642. /* impossible */
  1643. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1644. return 0;
  1645. }
  1646. return 1;
  1647. }
  1648. static void ASN1CALL ASN1Free_TransportAddress(TransportAddress *val)
  1649. {
  1650. if (val) {
  1651. switch ((val)->choice) {
  1652. case 1:
  1653. ASN1Free_TransportAddress_ipAddress(&(val)->u.ipAddress);
  1654. break;
  1655. case 2:
  1656. ASN1Free_TransportAddress_ipSourceRoute(&(val)->u.ipSourceRoute);
  1657. break;
  1658. case 3:
  1659. ASN1Free_TransportAddress_ipxAddress(&(val)->u.ipxAddress);
  1660. break;
  1661. case 4:
  1662. ASN1Free_TransportAddress_ip6Address(&(val)->u.ip6Address);
  1663. break;
  1664. case 5:
  1665. break;
  1666. case 6:
  1667. break;
  1668. case 7:
  1669. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardAddress);
  1670. break;
  1671. }
  1672. }
  1673. }
  1674. static int ASN1CALL ASN1Enc_CTActiveArg_argumentExtension(ASN1encoding_t enc, CTActiveArg_argumentExtension *val)
  1675. {
  1676. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1677. return 0;
  1678. switch ((val)->choice) {
  1679. case 1:
  1680. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1681. return 0;
  1682. break;
  1683. case 2:
  1684. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1685. return 0;
  1686. break;
  1687. default:
  1688. /* impossible */
  1689. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1690. return 0;
  1691. }
  1692. return 1;
  1693. }
  1694. static int ASN1CALL ASN1Dec_CTActiveArg_argumentExtension(ASN1decoding_t dec, CTActiveArg_argumentExtension *val)
  1695. {
  1696. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1697. return 0;
  1698. switch ((val)->choice) {
  1699. case 1:
  1700. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1701. return 0;
  1702. break;
  1703. case 2:
  1704. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1705. return 0;
  1706. break;
  1707. default:
  1708. /* impossible */
  1709. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1710. return 0;
  1711. }
  1712. return 1;
  1713. }
  1714. static void ASN1CALL ASN1Free_CTActiveArg_argumentExtension(CTActiveArg_argumentExtension *val)
  1715. {
  1716. if (val) {
  1717. switch ((val)->choice) {
  1718. case 1:
  1719. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1720. break;
  1721. case 2:
  1722. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1723. break;
  1724. }
  1725. }
  1726. }
  1727. static int ASN1CALL ASN1Enc_CTCompleteArg_argumentExtension(ASN1encoding_t enc, CTCompleteArg_argumentExtension *val)
  1728. {
  1729. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1730. return 0;
  1731. switch ((val)->choice) {
  1732. case 1:
  1733. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1734. return 0;
  1735. break;
  1736. case 2:
  1737. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1738. return 0;
  1739. break;
  1740. default:
  1741. /* impossible */
  1742. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1743. return 0;
  1744. }
  1745. return 1;
  1746. }
  1747. static int ASN1CALL ASN1Dec_CTCompleteArg_argumentExtension(ASN1decoding_t dec, CTCompleteArg_argumentExtension *val)
  1748. {
  1749. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1750. return 0;
  1751. switch ((val)->choice) {
  1752. case 1:
  1753. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1754. return 0;
  1755. break;
  1756. case 2:
  1757. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1758. return 0;
  1759. break;
  1760. default:
  1761. /* impossible */
  1762. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1763. return 0;
  1764. }
  1765. return 1;
  1766. }
  1767. static void ASN1CALL ASN1Free_CTCompleteArg_argumentExtension(CTCompleteArg_argumentExtension *val)
  1768. {
  1769. if (val) {
  1770. switch ((val)->choice) {
  1771. case 1:
  1772. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1773. break;
  1774. case 2:
  1775. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1776. break;
  1777. }
  1778. }
  1779. }
  1780. static int ASN1CALL ASN1Enc_SubaddressTransferArg_argumentExtension(ASN1encoding_t enc, SubaddressTransferArg_argumentExtension *val)
  1781. {
  1782. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1783. return 0;
  1784. switch ((val)->choice) {
  1785. case 1:
  1786. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1787. return 0;
  1788. break;
  1789. case 2:
  1790. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1791. return 0;
  1792. break;
  1793. default:
  1794. /* impossible */
  1795. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1796. return 0;
  1797. }
  1798. return 1;
  1799. }
  1800. static int ASN1CALL ASN1Dec_SubaddressTransferArg_argumentExtension(ASN1decoding_t dec, SubaddressTransferArg_argumentExtension *val)
  1801. {
  1802. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1803. return 0;
  1804. switch ((val)->choice) {
  1805. case 1:
  1806. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1807. return 0;
  1808. break;
  1809. case 2:
  1810. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1811. return 0;
  1812. break;
  1813. default:
  1814. /* impossible */
  1815. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1816. return 0;
  1817. }
  1818. return 1;
  1819. }
  1820. static void ASN1CALL ASN1Free_SubaddressTransferArg_argumentExtension(SubaddressTransferArg_argumentExtension *val)
  1821. {
  1822. if (val) {
  1823. switch ((val)->choice) {
  1824. case 1:
  1825. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1826. break;
  1827. case 2:
  1828. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1829. break;
  1830. }
  1831. }
  1832. }
  1833. static int ASN1CALL ASN1Enc_CTUpdateArg_argumentExtension(ASN1encoding_t enc, CTUpdateArg_argumentExtension *val)
  1834. {
  1835. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1836. return 0;
  1837. switch ((val)->choice) {
  1838. case 1:
  1839. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1840. return 0;
  1841. break;
  1842. case 2:
  1843. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1844. return 0;
  1845. break;
  1846. default:
  1847. /* impossible */
  1848. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1849. return 0;
  1850. }
  1851. return 1;
  1852. }
  1853. static int ASN1CALL ASN1Dec_CTUpdateArg_argumentExtension(ASN1decoding_t dec, CTUpdateArg_argumentExtension *val)
  1854. {
  1855. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1856. return 0;
  1857. switch ((val)->choice) {
  1858. case 1:
  1859. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1860. return 0;
  1861. break;
  1862. case 2:
  1863. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1864. return 0;
  1865. break;
  1866. default:
  1867. /* impossible */
  1868. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1869. return 0;
  1870. }
  1871. return 1;
  1872. }
  1873. static void ASN1CALL ASN1Free_CTUpdateArg_argumentExtension(CTUpdateArg_argumentExtension *val)
  1874. {
  1875. if (val) {
  1876. switch ((val)->choice) {
  1877. case 1:
  1878. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1879. break;
  1880. case 2:
  1881. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1882. break;
  1883. }
  1884. }
  1885. }
  1886. static int ASN1CALL ASN1Enc_CTIdentifyRes_resultExtension(ASN1encoding_t enc, CTIdentifyRes_resultExtension *val)
  1887. {
  1888. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1889. return 0;
  1890. switch ((val)->choice) {
  1891. case 1:
  1892. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1893. return 0;
  1894. break;
  1895. case 2:
  1896. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1897. return 0;
  1898. break;
  1899. default:
  1900. /* impossible */
  1901. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1902. return 0;
  1903. }
  1904. return 1;
  1905. }
  1906. static int ASN1CALL ASN1Dec_CTIdentifyRes_resultExtension(ASN1decoding_t dec, CTIdentifyRes_resultExtension *val)
  1907. {
  1908. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1909. return 0;
  1910. switch ((val)->choice) {
  1911. case 1:
  1912. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1913. return 0;
  1914. break;
  1915. case 2:
  1916. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1917. return 0;
  1918. break;
  1919. default:
  1920. /* impossible */
  1921. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1922. return 0;
  1923. }
  1924. return 1;
  1925. }
  1926. static void ASN1CALL ASN1Free_CTIdentifyRes_resultExtension(CTIdentifyRes_resultExtension *val)
  1927. {
  1928. if (val) {
  1929. switch ((val)->choice) {
  1930. case 1:
  1931. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1932. break;
  1933. case 2:
  1934. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1935. break;
  1936. }
  1937. }
  1938. }
  1939. static int ASN1CALL ASN1Enc_CTSetupArg_argumentExtension(ASN1encoding_t enc, CTSetupArg_argumentExtension *val)
  1940. {
  1941. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1942. return 0;
  1943. switch ((val)->choice) {
  1944. case 1:
  1945. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1946. return 0;
  1947. break;
  1948. case 2:
  1949. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  1950. return 0;
  1951. break;
  1952. default:
  1953. /* impossible */
  1954. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  1955. return 0;
  1956. }
  1957. return 1;
  1958. }
  1959. static int ASN1CALL ASN1Dec_CTSetupArg_argumentExtension(ASN1decoding_t dec, CTSetupArg_argumentExtension *val)
  1960. {
  1961. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  1962. return 0;
  1963. switch ((val)->choice) {
  1964. case 1:
  1965. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  1966. return 0;
  1967. break;
  1968. case 2:
  1969. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  1970. return 0;
  1971. break;
  1972. default:
  1973. /* impossible */
  1974. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  1975. return 0;
  1976. }
  1977. return 1;
  1978. }
  1979. static void ASN1CALL ASN1Free_CTSetupArg_argumentExtension(CTSetupArg_argumentExtension *val)
  1980. {
  1981. if (val) {
  1982. switch ((val)->choice) {
  1983. case 1:
  1984. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  1985. break;
  1986. case 2:
  1987. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  1988. break;
  1989. }
  1990. }
  1991. }
  1992. static int ASN1CALL ASN1Enc_CTInitiateArg_argumentExtension(ASN1encoding_t enc, CTInitiateArg_argumentExtension *val)
  1993. {
  1994. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  1995. return 0;
  1996. switch ((val)->choice) {
  1997. case 1:
  1998. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  1999. return 0;
  2000. break;
  2001. case 2:
  2002. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2003. return 0;
  2004. break;
  2005. default:
  2006. /* impossible */
  2007. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2008. return 0;
  2009. }
  2010. return 1;
  2011. }
  2012. static int ASN1CALL ASN1Dec_CTInitiateArg_argumentExtension(ASN1decoding_t dec, CTInitiateArg_argumentExtension *val)
  2013. {
  2014. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2015. return 0;
  2016. switch ((val)->choice) {
  2017. case 1:
  2018. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2019. return 0;
  2020. break;
  2021. case 2:
  2022. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2023. return 0;
  2024. break;
  2025. default:
  2026. /* impossible */
  2027. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2028. return 0;
  2029. }
  2030. return 1;
  2031. }
  2032. static void ASN1CALL ASN1Free_CTInitiateArg_argumentExtension(CTInitiateArg_argumentExtension *val)
  2033. {
  2034. if (val) {
  2035. switch ((val)->choice) {
  2036. case 1:
  2037. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2038. break;
  2039. case 2:
  2040. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2041. break;
  2042. }
  2043. }
  2044. }
  2045. static int ASN1CALL ASN1Enc_IntResult_extension(ASN1encoding_t enc, IntResult_extension *val)
  2046. {
  2047. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2048. return 0;
  2049. switch ((val)->choice) {
  2050. case 1:
  2051. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2052. return 0;
  2053. break;
  2054. case 2:
  2055. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2056. return 0;
  2057. break;
  2058. default:
  2059. /* impossible */
  2060. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2061. return 0;
  2062. }
  2063. return 1;
  2064. }
  2065. static int ASN1CALL ASN1Dec_IntResult_extension(ASN1decoding_t dec, IntResult_extension *val)
  2066. {
  2067. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2068. return 0;
  2069. switch ((val)->choice) {
  2070. case 1:
  2071. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2072. return 0;
  2073. break;
  2074. case 2:
  2075. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2076. return 0;
  2077. break;
  2078. default:
  2079. /* impossible */
  2080. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2081. return 0;
  2082. }
  2083. return 1;
  2084. }
  2085. static void ASN1CALL ASN1Free_IntResult_extension(IntResult_extension *val)
  2086. {
  2087. if (val) {
  2088. switch ((val)->choice) {
  2089. case 1:
  2090. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2091. break;
  2092. case 2:
  2093. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2094. break;
  2095. }
  2096. }
  2097. }
  2098. static int ASN1CALL ASN1Enc_DivertingLegInformation4Argument_extension(ASN1encoding_t enc, DivertingLegInformation4Argument_extension *val)
  2099. {
  2100. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2101. return 0;
  2102. switch ((val)->choice) {
  2103. case 1:
  2104. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2105. return 0;
  2106. break;
  2107. case 2:
  2108. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2109. return 0;
  2110. break;
  2111. default:
  2112. /* impossible */
  2113. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2114. return 0;
  2115. }
  2116. return 1;
  2117. }
  2118. static int ASN1CALL ASN1Dec_DivertingLegInformation4Argument_extension(ASN1decoding_t dec, DivertingLegInformation4Argument_extension *val)
  2119. {
  2120. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2121. return 0;
  2122. switch ((val)->choice) {
  2123. case 1:
  2124. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2125. return 0;
  2126. break;
  2127. case 2:
  2128. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2129. return 0;
  2130. break;
  2131. default:
  2132. /* impossible */
  2133. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2134. return 0;
  2135. }
  2136. return 1;
  2137. }
  2138. static void ASN1CALL ASN1Free_DivertingLegInformation4Argument_extension(DivertingLegInformation4Argument_extension *val)
  2139. {
  2140. if (val) {
  2141. switch ((val)->choice) {
  2142. case 1:
  2143. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2144. break;
  2145. case 2:
  2146. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2147. break;
  2148. }
  2149. }
  2150. }
  2151. static int ASN1CALL ASN1Enc_DivertingLegInformation3Argument_extension(ASN1encoding_t enc, DivertingLegInformation3Argument_extension *val)
  2152. {
  2153. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2154. return 0;
  2155. switch ((val)->choice) {
  2156. case 1:
  2157. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2158. return 0;
  2159. break;
  2160. case 2:
  2161. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2162. return 0;
  2163. break;
  2164. default:
  2165. /* impossible */
  2166. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2167. return 0;
  2168. }
  2169. return 1;
  2170. }
  2171. static int ASN1CALL ASN1Dec_DivertingLegInformation3Argument_extension(ASN1decoding_t dec, DivertingLegInformation3Argument_extension *val)
  2172. {
  2173. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2174. return 0;
  2175. switch ((val)->choice) {
  2176. case 1:
  2177. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2178. return 0;
  2179. break;
  2180. case 2:
  2181. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2182. return 0;
  2183. break;
  2184. default:
  2185. /* impossible */
  2186. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2187. return 0;
  2188. }
  2189. return 1;
  2190. }
  2191. static void ASN1CALL ASN1Free_DivertingLegInformation3Argument_extension(DivertingLegInformation3Argument_extension *val)
  2192. {
  2193. if (val) {
  2194. switch ((val)->choice) {
  2195. case 1:
  2196. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2197. break;
  2198. case 2:
  2199. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2200. break;
  2201. }
  2202. }
  2203. }
  2204. static int ASN1CALL ASN1Enc_DivertingLegInformation2Argument_extension(ASN1encoding_t enc, DivertingLegInformation2Argument_extension *val)
  2205. {
  2206. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2207. return 0;
  2208. switch ((val)->choice) {
  2209. case 1:
  2210. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2211. return 0;
  2212. break;
  2213. case 2:
  2214. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2215. return 0;
  2216. break;
  2217. default:
  2218. /* impossible */
  2219. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2220. return 0;
  2221. }
  2222. return 1;
  2223. }
  2224. static int ASN1CALL ASN1Dec_DivertingLegInformation2Argument_extension(ASN1decoding_t dec, DivertingLegInformation2Argument_extension *val)
  2225. {
  2226. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2227. return 0;
  2228. switch ((val)->choice) {
  2229. case 1:
  2230. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2231. return 0;
  2232. break;
  2233. case 2:
  2234. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2235. return 0;
  2236. break;
  2237. default:
  2238. /* impossible */
  2239. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2240. return 0;
  2241. }
  2242. return 1;
  2243. }
  2244. static void ASN1CALL ASN1Free_DivertingLegInformation2Argument_extension(DivertingLegInformation2Argument_extension *val)
  2245. {
  2246. if (val) {
  2247. switch ((val)->choice) {
  2248. case 1:
  2249. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2250. break;
  2251. case 2:
  2252. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2253. break;
  2254. }
  2255. }
  2256. }
  2257. static int ASN1CALL ASN1Enc_DivertingLegInformation1Argument_extension(ASN1encoding_t enc, DivertingLegInformation1Argument_extension *val)
  2258. {
  2259. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2260. return 0;
  2261. switch ((val)->choice) {
  2262. case 1:
  2263. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2264. return 0;
  2265. break;
  2266. case 2:
  2267. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2268. return 0;
  2269. break;
  2270. default:
  2271. /* impossible */
  2272. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2273. return 0;
  2274. }
  2275. return 1;
  2276. }
  2277. static int ASN1CALL ASN1Dec_DivertingLegInformation1Argument_extension(ASN1decoding_t dec, DivertingLegInformation1Argument_extension *val)
  2278. {
  2279. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2280. return 0;
  2281. switch ((val)->choice) {
  2282. case 1:
  2283. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2284. return 0;
  2285. break;
  2286. case 2:
  2287. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2288. return 0;
  2289. break;
  2290. default:
  2291. /* impossible */
  2292. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2293. return 0;
  2294. }
  2295. return 1;
  2296. }
  2297. static void ASN1CALL ASN1Free_DivertingLegInformation1Argument_extension(DivertingLegInformation1Argument_extension *val)
  2298. {
  2299. if (val) {
  2300. switch ((val)->choice) {
  2301. case 1:
  2302. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2303. break;
  2304. case 2:
  2305. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2306. break;
  2307. }
  2308. }
  2309. }
  2310. static int ASN1CALL ASN1Enc_CallReroutingArgument_extension(ASN1encoding_t enc, CallReroutingArgument_extension *val)
  2311. {
  2312. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2313. return 0;
  2314. switch ((val)->choice) {
  2315. case 1:
  2316. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2317. return 0;
  2318. break;
  2319. case 2:
  2320. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2321. return 0;
  2322. break;
  2323. default:
  2324. /* impossible */
  2325. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2326. return 0;
  2327. }
  2328. return 1;
  2329. }
  2330. static int ASN1CALL ASN1Dec_CallReroutingArgument_extension(ASN1decoding_t dec, CallReroutingArgument_extension *val)
  2331. {
  2332. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2333. return 0;
  2334. switch ((val)->choice) {
  2335. case 1:
  2336. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2337. return 0;
  2338. break;
  2339. case 2:
  2340. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2341. return 0;
  2342. break;
  2343. default:
  2344. /* impossible */
  2345. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2346. return 0;
  2347. }
  2348. return 1;
  2349. }
  2350. static void ASN1CALL ASN1Free_CallReroutingArgument_extension(CallReroutingArgument_extension *val)
  2351. {
  2352. if (val) {
  2353. switch ((val)->choice) {
  2354. case 1:
  2355. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2356. break;
  2357. case 2:
  2358. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2359. break;
  2360. }
  2361. }
  2362. }
  2363. static int ASN1CALL ASN1Enc_CheckRestrictionArgument_extension(ASN1encoding_t enc, CheckRestrictionArgument_extension *val)
  2364. {
  2365. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2366. return 0;
  2367. switch ((val)->choice) {
  2368. case 1:
  2369. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2370. return 0;
  2371. break;
  2372. case 2:
  2373. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2374. return 0;
  2375. break;
  2376. default:
  2377. /* impossible */
  2378. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2379. return 0;
  2380. }
  2381. return 1;
  2382. }
  2383. static int ASN1CALL ASN1Dec_CheckRestrictionArgument_extension(ASN1decoding_t dec, CheckRestrictionArgument_extension *val)
  2384. {
  2385. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2386. return 0;
  2387. switch ((val)->choice) {
  2388. case 1:
  2389. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2390. return 0;
  2391. break;
  2392. case 2:
  2393. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2394. return 0;
  2395. break;
  2396. default:
  2397. /* impossible */
  2398. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2399. return 0;
  2400. }
  2401. return 1;
  2402. }
  2403. static void ASN1CALL ASN1Free_CheckRestrictionArgument_extension(CheckRestrictionArgument_extension *val)
  2404. {
  2405. if (val) {
  2406. switch ((val)->choice) {
  2407. case 1:
  2408. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2409. break;
  2410. case 2:
  2411. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2412. break;
  2413. }
  2414. }
  2415. }
  2416. static int ASN1CALL ASN1Enc_InterrogateDiversionQArgument_extension(ASN1encoding_t enc, InterrogateDiversionQArgument_extension *val)
  2417. {
  2418. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2419. return 0;
  2420. switch ((val)->choice) {
  2421. case 1:
  2422. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2423. return 0;
  2424. break;
  2425. case 2:
  2426. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2427. return 0;
  2428. break;
  2429. default:
  2430. /* impossible */
  2431. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2432. return 0;
  2433. }
  2434. return 1;
  2435. }
  2436. static int ASN1CALL ASN1Dec_InterrogateDiversionQArgument_extension(ASN1decoding_t dec, InterrogateDiversionQArgument_extension *val)
  2437. {
  2438. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2439. return 0;
  2440. switch ((val)->choice) {
  2441. case 1:
  2442. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2443. return 0;
  2444. break;
  2445. case 2:
  2446. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2447. return 0;
  2448. break;
  2449. default:
  2450. /* impossible */
  2451. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2452. return 0;
  2453. }
  2454. return 1;
  2455. }
  2456. static void ASN1CALL ASN1Free_InterrogateDiversionQArgument_extension(InterrogateDiversionQArgument_extension *val)
  2457. {
  2458. if (val) {
  2459. switch ((val)->choice) {
  2460. case 1:
  2461. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2462. break;
  2463. case 2:
  2464. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2465. break;
  2466. }
  2467. }
  2468. }
  2469. static int ASN1CALL ASN1Enc_DeactivateDiversionQArgument_extension(ASN1encoding_t enc, DeactivateDiversionQArgument_extension *val)
  2470. {
  2471. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2472. return 0;
  2473. switch ((val)->choice) {
  2474. case 1:
  2475. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2476. return 0;
  2477. break;
  2478. case 2:
  2479. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2480. return 0;
  2481. break;
  2482. default:
  2483. /* impossible */
  2484. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2485. return 0;
  2486. }
  2487. return 1;
  2488. }
  2489. static int ASN1CALL ASN1Dec_DeactivateDiversionQArgument_extension(ASN1decoding_t dec, DeactivateDiversionQArgument_extension *val)
  2490. {
  2491. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2492. return 0;
  2493. switch ((val)->choice) {
  2494. case 1:
  2495. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2496. return 0;
  2497. break;
  2498. case 2:
  2499. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2500. return 0;
  2501. break;
  2502. default:
  2503. /* impossible */
  2504. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2505. return 0;
  2506. }
  2507. return 1;
  2508. }
  2509. static void ASN1CALL ASN1Free_DeactivateDiversionQArgument_extension(DeactivateDiversionQArgument_extension *val)
  2510. {
  2511. if (val) {
  2512. switch ((val)->choice) {
  2513. case 1:
  2514. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2515. break;
  2516. case 2:
  2517. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2518. break;
  2519. }
  2520. }
  2521. }
  2522. static int ASN1CALL ASN1Enc_ActivateDiversionQArgument_extension(ASN1encoding_t enc, ActivateDiversionQArgument_extension *val)
  2523. {
  2524. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2525. return 0;
  2526. switch ((val)->choice) {
  2527. case 1:
  2528. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2529. return 0;
  2530. break;
  2531. case 2:
  2532. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2533. return 0;
  2534. break;
  2535. default:
  2536. /* impossible */
  2537. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2538. return 0;
  2539. }
  2540. return 1;
  2541. }
  2542. static int ASN1CALL ASN1Dec_ActivateDiversionQArgument_extension(ASN1decoding_t dec, ActivateDiversionQArgument_extension *val)
  2543. {
  2544. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2545. return 0;
  2546. switch ((val)->choice) {
  2547. case 1:
  2548. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2549. return 0;
  2550. break;
  2551. case 2:
  2552. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2553. return 0;
  2554. break;
  2555. default:
  2556. /* impossible */
  2557. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2558. return 0;
  2559. }
  2560. return 1;
  2561. }
  2562. static void ASN1CALL ASN1Free_ActivateDiversionQArgument_extension(ActivateDiversionQArgument_extension *val)
  2563. {
  2564. if (val) {
  2565. switch ((val)->choice) {
  2566. case 1:
  2567. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2568. break;
  2569. case 2:
  2570. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2571. break;
  2572. }
  2573. }
  2574. }
  2575. static int ASN1CALL ASN1Enc_H4503ROS(ASN1encoding_t enc, H4503ROS *val)
  2576. {
  2577. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 2))
  2578. return 0;
  2579. switch ((val)->choice) {
  2580. case 1:
  2581. if (!ASN1Enc_Invoke(enc, &(val)->u.invoke))
  2582. return 0;
  2583. break;
  2584. case 2:
  2585. if (!ASN1Enc_ReturnResult(enc, &(val)->u.returnResult))
  2586. return 0;
  2587. break;
  2588. case 3:
  2589. if (!ASN1Enc_ReturnError(enc, &(val)->u.returnError))
  2590. return 0;
  2591. break;
  2592. case 4:
  2593. if (!ASN1Enc_Reject(enc, &(val)->u.reject))
  2594. return 0;
  2595. break;
  2596. default:
  2597. /* impossible */
  2598. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2599. return 0;
  2600. }
  2601. return 1;
  2602. }
  2603. static int ASN1CALL ASN1Dec_H4503ROS(ASN1decoding_t dec, H4503ROS *val)
  2604. {
  2605. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 2))
  2606. return 0;
  2607. switch ((val)->choice) {
  2608. case 1:
  2609. if (!ASN1Dec_Invoke(dec, &(val)->u.invoke))
  2610. return 0;
  2611. break;
  2612. case 2:
  2613. if (!ASN1Dec_ReturnResult(dec, &(val)->u.returnResult))
  2614. return 0;
  2615. break;
  2616. case 3:
  2617. if (!ASN1Dec_ReturnError(dec, &(val)->u.returnError))
  2618. return 0;
  2619. break;
  2620. case 4:
  2621. if (!ASN1Dec_Reject(dec, &(val)->u.reject))
  2622. return 0;
  2623. break;
  2624. default:
  2625. /* impossible */
  2626. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2627. return 0;
  2628. }
  2629. return 1;
  2630. }
  2631. static void ASN1CALL ASN1Free_H4503ROS(H4503ROS *val)
  2632. {
  2633. if (val) {
  2634. switch ((val)->choice) {
  2635. case 1:
  2636. ASN1Free_Invoke(&(val)->u.invoke);
  2637. break;
  2638. case 2:
  2639. ASN1Free_ReturnResult(&(val)->u.returnResult);
  2640. break;
  2641. case 3:
  2642. ASN1Free_ReturnError(&(val)->u.returnError);
  2643. break;
  2644. }
  2645. }
  2646. }
  2647. static int ASN1CALL ASN1Enc_DummyArg(ASN1encoding_t enc, DummyArg *val)
  2648. {
  2649. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2650. return 0;
  2651. switch ((val)->choice) {
  2652. case 1:
  2653. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2654. return 0;
  2655. break;
  2656. case 2:
  2657. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2658. return 0;
  2659. break;
  2660. default:
  2661. /* impossible */
  2662. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2663. return 0;
  2664. }
  2665. return 1;
  2666. }
  2667. static int ASN1CALL ASN1Dec_DummyArg(ASN1decoding_t dec, DummyArg *val)
  2668. {
  2669. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2670. return 0;
  2671. switch ((val)->choice) {
  2672. case 1:
  2673. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2674. return 0;
  2675. break;
  2676. case 2:
  2677. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2678. return 0;
  2679. break;
  2680. default:
  2681. /* impossible */
  2682. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2683. return 0;
  2684. }
  2685. return 1;
  2686. }
  2687. static void ASN1CALL ASN1Free_DummyArg(DummyArg *val)
  2688. {
  2689. if (val) {
  2690. switch ((val)->choice) {
  2691. case 1:
  2692. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2693. break;
  2694. case 2:
  2695. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2696. break;
  2697. }
  2698. }
  2699. }
  2700. static int ASN1CALL ASN1Enc_DummyRes(ASN1encoding_t enc, DummyRes *val)
  2701. {
  2702. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2703. return 0;
  2704. switch ((val)->choice) {
  2705. case 1:
  2706. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2707. return 0;
  2708. break;
  2709. case 2:
  2710. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2711. return 0;
  2712. break;
  2713. default:
  2714. /* impossible */
  2715. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2716. return 0;
  2717. }
  2718. return 1;
  2719. }
  2720. static int ASN1CALL ASN1Dec_DummyRes(ASN1decoding_t dec, DummyRes *val)
  2721. {
  2722. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2723. return 0;
  2724. switch ((val)->choice) {
  2725. case 1:
  2726. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2727. return 0;
  2728. break;
  2729. case 2:
  2730. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2731. return 0;
  2732. break;
  2733. default:
  2734. /* impossible */
  2735. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2736. return 0;
  2737. }
  2738. return 1;
  2739. }
  2740. static void ASN1CALL ASN1Free_DummyRes(DummyRes *val)
  2741. {
  2742. if (val) {
  2743. switch ((val)->choice) {
  2744. case 1:
  2745. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2746. break;
  2747. case 2:
  2748. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2749. break;
  2750. }
  2751. }
  2752. }
  2753. static int ASN1CALL ASN1Enc_SubaddressTransferArg(ASN1encoding_t enc, SubaddressTransferArg *val)
  2754. {
  2755. if (!ASN1PEREncExtensionBitClear(enc))
  2756. return 0;
  2757. if (!ASN1PEREncBits(enc, 1, (val)->o))
  2758. return 0;
  2759. if (!ASN1Enc_PartySubaddress(enc, &(val)->redirectionSubaddress))
  2760. return 0;
  2761. if ((val)->o[0] & 0x80) {
  2762. if (!ASN1Enc_SubaddressTransferArg_argumentExtension(enc, &(val)->argumentExtension))
  2763. return 0;
  2764. }
  2765. return 1;
  2766. }
  2767. static int ASN1CALL ASN1Dec_SubaddressTransferArg(ASN1decoding_t dec, SubaddressTransferArg *val)
  2768. {
  2769. ASN1uint32_t y;
  2770. if (!ASN1PERDecExtensionBit(dec, &y))
  2771. return 0;
  2772. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  2773. return 0;
  2774. if (!ASN1Dec_PartySubaddress(dec, &(val)->redirectionSubaddress))
  2775. return 0;
  2776. if ((val)->o[0] & 0x80) {
  2777. if (!ASN1Dec_SubaddressTransferArg_argumentExtension(dec, &(val)->argumentExtension))
  2778. return 0;
  2779. }
  2780. if (y) {
  2781. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  2782. return 0;
  2783. }
  2784. return 1;
  2785. }
  2786. static void ASN1CALL ASN1Free_SubaddressTransferArg(SubaddressTransferArg *val)
  2787. {
  2788. if (val) {
  2789. ASN1Free_PartySubaddress(&(val)->redirectionSubaddress);
  2790. if ((val)->o[0] & 0x80) {
  2791. ASN1Free_SubaddressTransferArg_argumentExtension(&(val)->argumentExtension);
  2792. }
  2793. }
  2794. }
  2795. static int ASN1CALL ASN1Enc_MixedExtension(ASN1encoding_t enc, MixedExtension *val)
  2796. {
  2797. if (!ASN1PEREncSimpleChoice(enc, (val)->choice, 1))
  2798. return 0;
  2799. switch ((val)->choice) {
  2800. case 1:
  2801. if (!ASN1Enc_ExtensionSeq(enc, &(val)->u.extensionSeq))
  2802. return 0;
  2803. break;
  2804. case 2:
  2805. if (!ASN1Enc_H225NonStandardParameter(enc, &(val)->u.nonStandardData))
  2806. return 0;
  2807. break;
  2808. default:
  2809. /* impossible */
  2810. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2811. return 0;
  2812. }
  2813. return 1;
  2814. }
  2815. static int ASN1CALL ASN1Dec_MixedExtension(ASN1decoding_t dec, MixedExtension *val)
  2816. {
  2817. if (!ASN1PERDecSimpleChoice(dec, &(val)->choice, 1))
  2818. return 0;
  2819. switch ((val)->choice) {
  2820. case 1:
  2821. if (!ASN1Dec_ExtensionSeq(dec, &(val)->u.extensionSeq))
  2822. return 0;
  2823. break;
  2824. case 2:
  2825. if (!ASN1Dec_H225NonStandardParameter(dec, &(val)->u.nonStandardData))
  2826. return 0;
  2827. break;
  2828. default:
  2829. /* impossible */
  2830. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2831. return 0;
  2832. }
  2833. return 1;
  2834. }
  2835. static void ASN1CALL ASN1Free_MixedExtension(MixedExtension *val)
  2836. {
  2837. if (val) {
  2838. switch ((val)->choice) {
  2839. case 1:
  2840. ASN1Free_ExtensionSeq(&(val)->u.extensionSeq);
  2841. break;
  2842. case 2:
  2843. ASN1Free_H225NonStandardParameter(&(val)->u.nonStandardData);
  2844. break;
  2845. }
  2846. }
  2847. }
  2848. static ASN1stringtableentry_t PartyNumber_dataPartyNumber_StringTableEntries[] = {
  2849. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  2850. { 48, 57, 3 },
  2851. };
  2852. static ASN1stringtable_t PartyNumber_dataPartyNumber_StringTable = {
  2853. 4, PartyNumber_dataPartyNumber_StringTableEntries
  2854. };
  2855. static ASN1stringtableentry_t PartyNumber_telexPartyNumber_StringTableEntries[] = {
  2856. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  2857. { 48, 57, 3 },
  2858. };
  2859. static ASN1stringtable_t PartyNumber_telexPartyNumber_StringTable = {
  2860. 4, PartyNumber_telexPartyNumber_StringTableEntries
  2861. };
  2862. static ASN1stringtableentry_t PartyNumber_nationalStandardPartyNumber_StringTableEntries[] = {
  2863. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  2864. { 48, 57, 3 },
  2865. };
  2866. static ASN1stringtable_t PartyNumber_nationalStandardPartyNumber_StringTable = {
  2867. 4, PartyNumber_nationalStandardPartyNumber_StringTableEntries
  2868. };
  2869. static int ASN1CALL ASN1Enc_PartyNumber(ASN1encoding_t enc, PartyNumber *val)
  2870. {
  2871. ASN1uint32_t t;
  2872. if (!ASN1PEREncSimpleChoiceEx(enc, (val)->choice, 3))
  2873. return 0;
  2874. switch ((val)->choice) {
  2875. case 1:
  2876. if (!ASN1Enc_PublicPartyNumber(enc, &(val)->u.publicNumber))
  2877. return 0;
  2878. break;
  2879. case 2:
  2880. t = lstrlenA((val)->u.dataPartyNumber);
  2881. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  2882. return 0;
  2883. ASN1PEREncAlignment(enc);
  2884. if (!ASN1PEREncTableCharString(enc, t, (val)->u.dataPartyNumber, 4, &PartyNumber_dataPartyNumber_StringTable))
  2885. return 0;
  2886. break;
  2887. case 3:
  2888. t = lstrlenA((val)->u.telexPartyNumber);
  2889. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  2890. return 0;
  2891. ASN1PEREncAlignment(enc);
  2892. if (!ASN1PEREncTableCharString(enc, t, (val)->u.telexPartyNumber, 4, &PartyNumber_telexPartyNumber_StringTable))
  2893. return 0;
  2894. break;
  2895. case 4:
  2896. if (!ASN1Enc_PrivatePartyNumber(enc, &(val)->u.privateNumber))
  2897. return 0;
  2898. break;
  2899. case 5:
  2900. t = lstrlenA((val)->u.nationalStandardPartyNumber);
  2901. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  2902. return 0;
  2903. ASN1PEREncAlignment(enc);
  2904. if (!ASN1PEREncTableCharString(enc, t, (val)->u.nationalStandardPartyNumber, 4, &PartyNumber_nationalStandardPartyNumber_StringTable))
  2905. return 0;
  2906. break;
  2907. default:
  2908. /* impossible */
  2909. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  2910. return 0;
  2911. }
  2912. return 1;
  2913. }
  2914. static int ASN1CALL ASN1Dec_PartyNumber(ASN1decoding_t dec, PartyNumber *val)
  2915. {
  2916. ASN1uint32_t l;
  2917. if (!ASN1PERDecSimpleChoiceEx(dec, &(val)->choice, 3))
  2918. return 0;
  2919. switch ((val)->choice) {
  2920. case 1:
  2921. if (!ASN1Dec_PublicPartyNumber(dec, &(val)->u.publicNumber))
  2922. return 0;
  2923. break;
  2924. case 2:
  2925. if (!ASN1PERDecU32Val(dec, 7, &l))
  2926. return 0;
  2927. l += 1;
  2928. ASN1PERDecAlignment(dec);
  2929. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->u.dataPartyNumber, 4, &PartyNumber_dataPartyNumber_StringTable))
  2930. return 0;
  2931. break;
  2932. case 3:
  2933. if (!ASN1PERDecU32Val(dec, 7, &l))
  2934. return 0;
  2935. l += 1;
  2936. ASN1PERDecAlignment(dec);
  2937. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->u.telexPartyNumber, 4, &PartyNumber_telexPartyNumber_StringTable))
  2938. return 0;
  2939. break;
  2940. case 4:
  2941. if (!ASN1Dec_PrivatePartyNumber(dec, &(val)->u.privateNumber))
  2942. return 0;
  2943. break;
  2944. case 5:
  2945. if (!ASN1PERDecU32Val(dec, 7, &l))
  2946. return 0;
  2947. l += 1;
  2948. ASN1PERDecAlignment(dec);
  2949. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->u.nationalStandardPartyNumber, 4, &PartyNumber_nationalStandardPartyNumber_StringTable))
  2950. return 0;
  2951. break;
  2952. case 0:
  2953. /* extension case */
  2954. if (!ASN1PERDecSkipFragmented(dec, 8))
  2955. return 0;
  2956. break;
  2957. default:
  2958. /* impossible */
  2959. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  2960. return 0;
  2961. }
  2962. return 1;
  2963. }
  2964. static void ASN1CALL ASN1Free_PartyNumber(PartyNumber *val)
  2965. {
  2966. if (val) {
  2967. switch ((val)->choice) {
  2968. case 1:
  2969. ASN1Free_PublicPartyNumber(&(val)->u.publicNumber);
  2970. break;
  2971. case 2:
  2972. break;
  2973. case 3:
  2974. break;
  2975. case 4:
  2976. ASN1Free_PrivatePartyNumber(&(val)->u.privateNumber);
  2977. break;
  2978. case 5:
  2979. break;
  2980. }
  2981. }
  2982. }
  2983. static int ASN1CALL ASN1Enc_CpickupNotifyArg_extensionArg(ASN1encoding_t enc, PCpickupNotifyArg_extensionArg *val)
  2984. {
  2985. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpickupNotifyArg_extensionArg_ElmFn);
  2986. }
  2987. static int ASN1CALL ASN1Enc_CpickupNotifyArg_extensionArg_ElmFn(ASN1encoding_t enc, PCpickupNotifyArg_extensionArg val)
  2988. {
  2989. if (!ASN1Enc_MixedExtension(enc, &val->value))
  2990. return 0;
  2991. return 1;
  2992. }
  2993. static int ASN1CALL ASN1Dec_CpickupNotifyArg_extensionArg(ASN1decoding_t dec, PCpickupNotifyArg_extensionArg *val)
  2994. {
  2995. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpickupNotifyArg_extensionArg_ElmFn, sizeof(**val));
  2996. }
  2997. static int ASN1CALL ASN1Dec_CpickupNotifyArg_extensionArg_ElmFn(ASN1decoding_t dec, PCpickupNotifyArg_extensionArg val)
  2998. {
  2999. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3000. return 0;
  3001. return 1;
  3002. }
  3003. static void ASN1CALL ASN1Free_CpickupNotifyArg_extensionArg(PCpickupNotifyArg_extensionArg *val)
  3004. {
  3005. if (val) {
  3006. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpickupNotifyArg_extensionArg_ElmFn);
  3007. }
  3008. }
  3009. static void ASN1CALL ASN1Free_CpickupNotifyArg_extensionArg_ElmFn(PCpickupNotifyArg_extensionArg val)
  3010. {
  3011. if (val) {
  3012. ASN1Free_MixedExtension(&val->value);
  3013. }
  3014. }
  3015. static int ASN1CALL ASN1Enc_CpNotifyArg_extensionArg(ASN1encoding_t enc, PCpNotifyArg_extensionArg *val)
  3016. {
  3017. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpNotifyArg_extensionArg_ElmFn);
  3018. }
  3019. static int ASN1CALL ASN1Enc_CpNotifyArg_extensionArg_ElmFn(ASN1encoding_t enc, PCpNotifyArg_extensionArg val)
  3020. {
  3021. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3022. return 0;
  3023. return 1;
  3024. }
  3025. static int ASN1CALL ASN1Dec_CpNotifyArg_extensionArg(ASN1decoding_t dec, PCpNotifyArg_extensionArg *val)
  3026. {
  3027. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpNotifyArg_extensionArg_ElmFn, sizeof(**val));
  3028. }
  3029. static int ASN1CALL ASN1Dec_CpNotifyArg_extensionArg_ElmFn(ASN1decoding_t dec, PCpNotifyArg_extensionArg val)
  3030. {
  3031. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3032. return 0;
  3033. return 1;
  3034. }
  3035. static void ASN1CALL ASN1Free_CpNotifyArg_extensionArg(PCpNotifyArg_extensionArg *val)
  3036. {
  3037. if (val) {
  3038. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpNotifyArg_extensionArg_ElmFn);
  3039. }
  3040. }
  3041. static void ASN1CALL ASN1Free_CpNotifyArg_extensionArg_ElmFn(PCpNotifyArg_extensionArg val)
  3042. {
  3043. if (val) {
  3044. ASN1Free_MixedExtension(&val->value);
  3045. }
  3046. }
  3047. static int ASN1CALL ASN1Enc_PickExeRes_extensionRes(ASN1encoding_t enc, PPickExeRes_extensionRes *val)
  3048. {
  3049. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickExeRes_extensionRes_ElmFn);
  3050. }
  3051. static int ASN1CALL ASN1Enc_PickExeRes_extensionRes_ElmFn(ASN1encoding_t enc, PPickExeRes_extensionRes val)
  3052. {
  3053. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3054. return 0;
  3055. return 1;
  3056. }
  3057. static int ASN1CALL ASN1Dec_PickExeRes_extensionRes(ASN1decoding_t dec, PPickExeRes_extensionRes *val)
  3058. {
  3059. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickExeRes_extensionRes_ElmFn, sizeof(**val));
  3060. }
  3061. static int ASN1CALL ASN1Dec_PickExeRes_extensionRes_ElmFn(ASN1decoding_t dec, PPickExeRes_extensionRes val)
  3062. {
  3063. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3064. return 0;
  3065. return 1;
  3066. }
  3067. static void ASN1CALL ASN1Free_PickExeRes_extensionRes(PPickExeRes_extensionRes *val)
  3068. {
  3069. if (val) {
  3070. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickExeRes_extensionRes_ElmFn);
  3071. }
  3072. }
  3073. static void ASN1CALL ASN1Free_PickExeRes_extensionRes_ElmFn(PPickExeRes_extensionRes val)
  3074. {
  3075. if (val) {
  3076. ASN1Free_MixedExtension(&val->value);
  3077. }
  3078. }
  3079. static int ASN1CALL ASN1Enc_PickExeArg_extensionArg(ASN1encoding_t enc, PPickExeArg_extensionArg *val)
  3080. {
  3081. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickExeArg_extensionArg_ElmFn);
  3082. }
  3083. static int ASN1CALL ASN1Enc_PickExeArg_extensionArg_ElmFn(ASN1encoding_t enc, PPickExeArg_extensionArg val)
  3084. {
  3085. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3086. return 0;
  3087. return 1;
  3088. }
  3089. static int ASN1CALL ASN1Dec_PickExeArg_extensionArg(ASN1decoding_t dec, PPickExeArg_extensionArg *val)
  3090. {
  3091. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickExeArg_extensionArg_ElmFn, sizeof(**val));
  3092. }
  3093. static int ASN1CALL ASN1Dec_PickExeArg_extensionArg_ElmFn(ASN1decoding_t dec, PPickExeArg_extensionArg val)
  3094. {
  3095. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3096. return 0;
  3097. return 1;
  3098. }
  3099. static void ASN1CALL ASN1Free_PickExeArg_extensionArg(PPickExeArg_extensionArg *val)
  3100. {
  3101. if (val) {
  3102. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickExeArg_extensionArg_ElmFn);
  3103. }
  3104. }
  3105. static void ASN1CALL ASN1Free_PickExeArg_extensionArg_ElmFn(PPickExeArg_extensionArg val)
  3106. {
  3107. if (val) {
  3108. ASN1Free_MixedExtension(&val->value);
  3109. }
  3110. }
  3111. static int ASN1CALL ASN1Enc_PickupRes_extensionRes(ASN1encoding_t enc, PPickupRes_extensionRes *val)
  3112. {
  3113. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickupRes_extensionRes_ElmFn);
  3114. }
  3115. static int ASN1CALL ASN1Enc_PickupRes_extensionRes_ElmFn(ASN1encoding_t enc, PPickupRes_extensionRes val)
  3116. {
  3117. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3118. return 0;
  3119. return 1;
  3120. }
  3121. static int ASN1CALL ASN1Dec_PickupRes_extensionRes(ASN1decoding_t dec, PPickupRes_extensionRes *val)
  3122. {
  3123. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickupRes_extensionRes_ElmFn, sizeof(**val));
  3124. }
  3125. static int ASN1CALL ASN1Dec_PickupRes_extensionRes_ElmFn(ASN1decoding_t dec, PPickupRes_extensionRes val)
  3126. {
  3127. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3128. return 0;
  3129. return 1;
  3130. }
  3131. static void ASN1CALL ASN1Free_PickupRes_extensionRes(PPickupRes_extensionRes *val)
  3132. {
  3133. if (val) {
  3134. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickupRes_extensionRes_ElmFn);
  3135. }
  3136. }
  3137. static void ASN1CALL ASN1Free_PickupRes_extensionRes_ElmFn(PPickupRes_extensionRes val)
  3138. {
  3139. if (val) {
  3140. ASN1Free_MixedExtension(&val->value);
  3141. }
  3142. }
  3143. static int ASN1CALL ASN1Enc_PickupArg_extensionArg(ASN1encoding_t enc, PPickupArg_extensionArg *val)
  3144. {
  3145. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickupArg_extensionArg_ElmFn);
  3146. }
  3147. static int ASN1CALL ASN1Enc_PickupArg_extensionArg_ElmFn(ASN1encoding_t enc, PPickupArg_extensionArg val)
  3148. {
  3149. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3150. return 0;
  3151. return 1;
  3152. }
  3153. static int ASN1CALL ASN1Dec_PickupArg_extensionArg(ASN1decoding_t dec, PPickupArg_extensionArg *val)
  3154. {
  3155. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickupArg_extensionArg_ElmFn, sizeof(**val));
  3156. }
  3157. static int ASN1CALL ASN1Dec_PickupArg_extensionArg_ElmFn(ASN1decoding_t dec, PPickupArg_extensionArg val)
  3158. {
  3159. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3160. return 0;
  3161. return 1;
  3162. }
  3163. static void ASN1CALL ASN1Free_PickupArg_extensionArg(PPickupArg_extensionArg *val)
  3164. {
  3165. if (val) {
  3166. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickupArg_extensionArg_ElmFn);
  3167. }
  3168. }
  3169. static void ASN1CALL ASN1Free_PickupArg_extensionArg_ElmFn(PPickupArg_extensionArg val)
  3170. {
  3171. if (val) {
  3172. ASN1Free_MixedExtension(&val->value);
  3173. }
  3174. }
  3175. static int ASN1CALL ASN1Enc_PickrequRes_extensionRes(ASN1encoding_t enc, PPickrequRes_extensionRes *val)
  3176. {
  3177. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickrequRes_extensionRes_ElmFn);
  3178. }
  3179. static int ASN1CALL ASN1Enc_PickrequRes_extensionRes_ElmFn(ASN1encoding_t enc, PPickrequRes_extensionRes val)
  3180. {
  3181. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3182. return 0;
  3183. return 1;
  3184. }
  3185. static int ASN1CALL ASN1Dec_PickrequRes_extensionRes(ASN1decoding_t dec, PPickrequRes_extensionRes *val)
  3186. {
  3187. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickrequRes_extensionRes_ElmFn, sizeof(**val));
  3188. }
  3189. static int ASN1CALL ASN1Dec_PickrequRes_extensionRes_ElmFn(ASN1decoding_t dec, PPickrequRes_extensionRes val)
  3190. {
  3191. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3192. return 0;
  3193. return 1;
  3194. }
  3195. static void ASN1CALL ASN1Free_PickrequRes_extensionRes(PPickrequRes_extensionRes *val)
  3196. {
  3197. if (val) {
  3198. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickrequRes_extensionRes_ElmFn);
  3199. }
  3200. }
  3201. static void ASN1CALL ASN1Free_PickrequRes_extensionRes_ElmFn(PPickrequRes_extensionRes val)
  3202. {
  3203. if (val) {
  3204. ASN1Free_MixedExtension(&val->value);
  3205. }
  3206. }
  3207. static int ASN1CALL ASN1Enc_PickrequArg_extensionArg(ASN1encoding_t enc, PPickrequArg_extensionArg *val)
  3208. {
  3209. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_PickrequArg_extensionArg_ElmFn);
  3210. }
  3211. static int ASN1CALL ASN1Enc_PickrequArg_extensionArg_ElmFn(ASN1encoding_t enc, PPickrequArg_extensionArg val)
  3212. {
  3213. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3214. return 0;
  3215. return 1;
  3216. }
  3217. static int ASN1CALL ASN1Dec_PickrequArg_extensionArg(ASN1decoding_t dec, PPickrequArg_extensionArg *val)
  3218. {
  3219. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_PickrequArg_extensionArg_ElmFn, sizeof(**val));
  3220. }
  3221. static int ASN1CALL ASN1Dec_PickrequArg_extensionArg_ElmFn(ASN1decoding_t dec, PPickrequArg_extensionArg val)
  3222. {
  3223. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3224. return 0;
  3225. return 1;
  3226. }
  3227. static void ASN1CALL ASN1Free_PickrequArg_extensionArg(PPickrequArg_extensionArg *val)
  3228. {
  3229. if (val) {
  3230. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_PickrequArg_extensionArg_ElmFn);
  3231. }
  3232. }
  3233. static void ASN1CALL ASN1Free_PickrequArg_extensionArg_ElmFn(PPickrequArg_extensionArg val)
  3234. {
  3235. if (val) {
  3236. ASN1Free_MixedExtension(&val->value);
  3237. }
  3238. }
  3239. static int ASN1CALL ASN1Enc_GroupIndicationOffRes_extensionRes(ASN1encoding_t enc, PGroupIndicationOffRes_extensionRes *val)
  3240. {
  3241. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_GroupIndicationOffRes_extensionRes_ElmFn);
  3242. }
  3243. static int ASN1CALL ASN1Enc_GroupIndicationOffRes_extensionRes_ElmFn(ASN1encoding_t enc, PGroupIndicationOffRes_extensionRes val)
  3244. {
  3245. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3246. return 0;
  3247. return 1;
  3248. }
  3249. static int ASN1CALL ASN1Dec_GroupIndicationOffRes_extensionRes(ASN1decoding_t dec, PGroupIndicationOffRes_extensionRes *val)
  3250. {
  3251. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_GroupIndicationOffRes_extensionRes_ElmFn, sizeof(**val));
  3252. }
  3253. static int ASN1CALL ASN1Dec_GroupIndicationOffRes_extensionRes_ElmFn(ASN1decoding_t dec, PGroupIndicationOffRes_extensionRes val)
  3254. {
  3255. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3256. return 0;
  3257. return 1;
  3258. }
  3259. static void ASN1CALL ASN1Free_GroupIndicationOffRes_extensionRes(PGroupIndicationOffRes_extensionRes *val)
  3260. {
  3261. if (val) {
  3262. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_GroupIndicationOffRes_extensionRes_ElmFn);
  3263. }
  3264. }
  3265. static void ASN1CALL ASN1Free_GroupIndicationOffRes_extensionRes_ElmFn(PGroupIndicationOffRes_extensionRes val)
  3266. {
  3267. if (val) {
  3268. ASN1Free_MixedExtension(&val->value);
  3269. }
  3270. }
  3271. static int ASN1CALL ASN1Enc_GroupIndicationOffArg_extensionArg(ASN1encoding_t enc, PGroupIndicationOffArg_extensionArg *val)
  3272. {
  3273. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_GroupIndicationOffArg_extensionArg_ElmFn);
  3274. }
  3275. static int ASN1CALL ASN1Enc_GroupIndicationOffArg_extensionArg_ElmFn(ASN1encoding_t enc, PGroupIndicationOffArg_extensionArg val)
  3276. {
  3277. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3278. return 0;
  3279. return 1;
  3280. }
  3281. static int ASN1CALL ASN1Dec_GroupIndicationOffArg_extensionArg(ASN1decoding_t dec, PGroupIndicationOffArg_extensionArg *val)
  3282. {
  3283. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_GroupIndicationOffArg_extensionArg_ElmFn, sizeof(**val));
  3284. }
  3285. static int ASN1CALL ASN1Dec_GroupIndicationOffArg_extensionArg_ElmFn(ASN1decoding_t dec, PGroupIndicationOffArg_extensionArg val)
  3286. {
  3287. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3288. return 0;
  3289. return 1;
  3290. }
  3291. static void ASN1CALL ASN1Free_GroupIndicationOffArg_extensionArg(PGroupIndicationOffArg_extensionArg *val)
  3292. {
  3293. if (val) {
  3294. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_GroupIndicationOffArg_extensionArg_ElmFn);
  3295. }
  3296. }
  3297. static void ASN1CALL ASN1Free_GroupIndicationOffArg_extensionArg_ElmFn(PGroupIndicationOffArg_extensionArg val)
  3298. {
  3299. if (val) {
  3300. ASN1Free_MixedExtension(&val->value);
  3301. }
  3302. }
  3303. static int ASN1CALL ASN1Enc_GroupIndicationOnRes_extensionRes(ASN1encoding_t enc, PGroupIndicationOnRes_extensionRes *val)
  3304. {
  3305. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_GroupIndicationOnRes_extensionRes_ElmFn);
  3306. }
  3307. static int ASN1CALL ASN1Enc_GroupIndicationOnRes_extensionRes_ElmFn(ASN1encoding_t enc, PGroupIndicationOnRes_extensionRes val)
  3308. {
  3309. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3310. return 0;
  3311. return 1;
  3312. }
  3313. static int ASN1CALL ASN1Dec_GroupIndicationOnRes_extensionRes(ASN1decoding_t dec, PGroupIndicationOnRes_extensionRes *val)
  3314. {
  3315. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_GroupIndicationOnRes_extensionRes_ElmFn, sizeof(**val));
  3316. }
  3317. static int ASN1CALL ASN1Dec_GroupIndicationOnRes_extensionRes_ElmFn(ASN1decoding_t dec, PGroupIndicationOnRes_extensionRes val)
  3318. {
  3319. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3320. return 0;
  3321. return 1;
  3322. }
  3323. static void ASN1CALL ASN1Free_GroupIndicationOnRes_extensionRes(PGroupIndicationOnRes_extensionRes *val)
  3324. {
  3325. if (val) {
  3326. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_GroupIndicationOnRes_extensionRes_ElmFn);
  3327. }
  3328. }
  3329. static void ASN1CALL ASN1Free_GroupIndicationOnRes_extensionRes_ElmFn(PGroupIndicationOnRes_extensionRes val)
  3330. {
  3331. if (val) {
  3332. ASN1Free_MixedExtension(&val->value);
  3333. }
  3334. }
  3335. static int ASN1CALL ASN1Enc_GroupIndicationOnArg_extensionArg(ASN1encoding_t enc, PGroupIndicationOnArg_extensionArg *val)
  3336. {
  3337. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_GroupIndicationOnArg_extensionArg_ElmFn);
  3338. }
  3339. static int ASN1CALL ASN1Enc_GroupIndicationOnArg_extensionArg_ElmFn(ASN1encoding_t enc, PGroupIndicationOnArg_extensionArg val)
  3340. {
  3341. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3342. return 0;
  3343. return 1;
  3344. }
  3345. static int ASN1CALL ASN1Dec_GroupIndicationOnArg_extensionArg(ASN1decoding_t dec, PGroupIndicationOnArg_extensionArg *val)
  3346. {
  3347. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_GroupIndicationOnArg_extensionArg_ElmFn, sizeof(**val));
  3348. }
  3349. static int ASN1CALL ASN1Dec_GroupIndicationOnArg_extensionArg_ElmFn(ASN1decoding_t dec, PGroupIndicationOnArg_extensionArg val)
  3350. {
  3351. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3352. return 0;
  3353. return 1;
  3354. }
  3355. static void ASN1CALL ASN1Free_GroupIndicationOnArg_extensionArg(PGroupIndicationOnArg_extensionArg *val)
  3356. {
  3357. if (val) {
  3358. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_GroupIndicationOnArg_extensionArg_ElmFn);
  3359. }
  3360. }
  3361. static void ASN1CALL ASN1Free_GroupIndicationOnArg_extensionArg_ElmFn(PGroupIndicationOnArg_extensionArg val)
  3362. {
  3363. if (val) {
  3364. ASN1Free_MixedExtension(&val->value);
  3365. }
  3366. }
  3367. static int ASN1CALL ASN1Enc_CpSetupRes_extensionRes(ASN1encoding_t enc, PCpSetupRes_extensionRes *val)
  3368. {
  3369. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpSetupRes_extensionRes_ElmFn);
  3370. }
  3371. static int ASN1CALL ASN1Enc_CpSetupRes_extensionRes_ElmFn(ASN1encoding_t enc, PCpSetupRes_extensionRes val)
  3372. {
  3373. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3374. return 0;
  3375. return 1;
  3376. }
  3377. static int ASN1CALL ASN1Dec_CpSetupRes_extensionRes(ASN1decoding_t dec, PCpSetupRes_extensionRes *val)
  3378. {
  3379. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpSetupRes_extensionRes_ElmFn, sizeof(**val));
  3380. }
  3381. static int ASN1CALL ASN1Dec_CpSetupRes_extensionRes_ElmFn(ASN1decoding_t dec, PCpSetupRes_extensionRes val)
  3382. {
  3383. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3384. return 0;
  3385. return 1;
  3386. }
  3387. static void ASN1CALL ASN1Free_CpSetupRes_extensionRes(PCpSetupRes_extensionRes *val)
  3388. {
  3389. if (val) {
  3390. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpSetupRes_extensionRes_ElmFn);
  3391. }
  3392. }
  3393. static void ASN1CALL ASN1Free_CpSetupRes_extensionRes_ElmFn(PCpSetupRes_extensionRes val)
  3394. {
  3395. if (val) {
  3396. ASN1Free_MixedExtension(&val->value);
  3397. }
  3398. }
  3399. static int ASN1CALL ASN1Enc_CpSetupArg_extensionArg(ASN1encoding_t enc, PCpSetupArg_extensionArg *val)
  3400. {
  3401. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpSetupArg_extensionArg_ElmFn);
  3402. }
  3403. static int ASN1CALL ASN1Enc_CpSetupArg_extensionArg_ElmFn(ASN1encoding_t enc, PCpSetupArg_extensionArg val)
  3404. {
  3405. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3406. return 0;
  3407. return 1;
  3408. }
  3409. static int ASN1CALL ASN1Dec_CpSetupArg_extensionArg(ASN1decoding_t dec, PCpSetupArg_extensionArg *val)
  3410. {
  3411. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpSetupArg_extensionArg_ElmFn, sizeof(**val));
  3412. }
  3413. static int ASN1CALL ASN1Dec_CpSetupArg_extensionArg_ElmFn(ASN1decoding_t dec, PCpSetupArg_extensionArg val)
  3414. {
  3415. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3416. return 0;
  3417. return 1;
  3418. }
  3419. static void ASN1CALL ASN1Free_CpSetupArg_extensionArg(PCpSetupArg_extensionArg *val)
  3420. {
  3421. if (val) {
  3422. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpSetupArg_extensionArg_ElmFn);
  3423. }
  3424. }
  3425. static void ASN1CALL ASN1Free_CpSetupArg_extensionArg_ElmFn(PCpSetupArg_extensionArg val)
  3426. {
  3427. if (val) {
  3428. ASN1Free_MixedExtension(&val->value);
  3429. }
  3430. }
  3431. static int ASN1CALL ASN1Enc_CpRequestRes_extensionRes(ASN1encoding_t enc, PCpRequestRes_extensionRes *val)
  3432. {
  3433. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpRequestRes_extensionRes_ElmFn);
  3434. }
  3435. static int ASN1CALL ASN1Enc_CpRequestRes_extensionRes_ElmFn(ASN1encoding_t enc, PCpRequestRes_extensionRes val)
  3436. {
  3437. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3438. return 0;
  3439. return 1;
  3440. }
  3441. static int ASN1CALL ASN1Dec_CpRequestRes_extensionRes(ASN1decoding_t dec, PCpRequestRes_extensionRes *val)
  3442. {
  3443. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpRequestRes_extensionRes_ElmFn, sizeof(**val));
  3444. }
  3445. static int ASN1CALL ASN1Dec_CpRequestRes_extensionRes_ElmFn(ASN1decoding_t dec, PCpRequestRes_extensionRes val)
  3446. {
  3447. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3448. return 0;
  3449. return 1;
  3450. }
  3451. static void ASN1CALL ASN1Free_CpRequestRes_extensionRes(PCpRequestRes_extensionRes *val)
  3452. {
  3453. if (val) {
  3454. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpRequestRes_extensionRes_ElmFn);
  3455. }
  3456. }
  3457. static void ASN1CALL ASN1Free_CpRequestRes_extensionRes_ElmFn(PCpRequestRes_extensionRes val)
  3458. {
  3459. if (val) {
  3460. ASN1Free_MixedExtension(&val->value);
  3461. }
  3462. }
  3463. static int ASN1CALL ASN1Enc_CpRequestArg_extensionArg(ASN1encoding_t enc, PCpRequestArg_extensionArg *val)
  3464. {
  3465. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_CpRequestArg_extensionArg_ElmFn);
  3466. }
  3467. static int ASN1CALL ASN1Enc_CpRequestArg_extensionArg_ElmFn(ASN1encoding_t enc, PCpRequestArg_extensionArg val)
  3468. {
  3469. if (!ASN1Enc_MixedExtension(enc, &val->value))
  3470. return 0;
  3471. return 1;
  3472. }
  3473. static int ASN1CALL ASN1Dec_CpRequestArg_extensionArg(ASN1decoding_t dec, PCpRequestArg_extensionArg *val)
  3474. {
  3475. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_CpRequestArg_extensionArg_ElmFn, sizeof(**val));
  3476. }
  3477. static int ASN1CALL ASN1Dec_CpRequestArg_extensionArg_ElmFn(ASN1decoding_t dec, PCpRequestArg_extensionArg val)
  3478. {
  3479. if (!ASN1Dec_MixedExtension(dec, &val->value))
  3480. return 0;
  3481. return 1;
  3482. }
  3483. static void ASN1CALL ASN1Free_CpRequestArg_extensionArg(PCpRequestArg_extensionArg *val)
  3484. {
  3485. if (val) {
  3486. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_CpRequestArg_extensionArg_ElmFn);
  3487. }
  3488. }
  3489. static void ASN1CALL ASN1Free_CpRequestArg_extensionArg_ElmFn(PCpRequestArg_extensionArg val)
  3490. {
  3491. if (val) {
  3492. ASN1Free_MixedExtension(&val->value);
  3493. }
  3494. }
  3495. static int ASN1CALL ASN1Enc_ServiceApdus_rosApdus(ASN1encoding_t enc, PServiceApdus_rosApdus *val)
  3496. {
  3497. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_ServiceApdus_rosApdus_ElmFn);
  3498. }
  3499. static int ASN1CALL ASN1Enc_ServiceApdus_rosApdus_ElmFn(ASN1encoding_t enc, PServiceApdus_rosApdus val)
  3500. {
  3501. if (!ASN1Enc_H4503ROS(enc, &val->value))
  3502. return 0;
  3503. return 1;
  3504. }
  3505. static int ASN1CALL ASN1Dec_ServiceApdus_rosApdus(ASN1decoding_t dec, PServiceApdus_rosApdus *val)
  3506. {
  3507. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_ServiceApdus_rosApdus_ElmFn, sizeof(**val));
  3508. }
  3509. static int ASN1CALL ASN1Dec_ServiceApdus_rosApdus_ElmFn(ASN1decoding_t dec, PServiceApdus_rosApdus val)
  3510. {
  3511. if (!ASN1Dec_H4503ROS(dec, &val->value))
  3512. return 0;
  3513. return 1;
  3514. }
  3515. static void ASN1CALL ASN1Free_ServiceApdus_rosApdus(PServiceApdus_rosApdus *val)
  3516. {
  3517. if (val) {
  3518. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_ServiceApdus_rosApdus_ElmFn);
  3519. }
  3520. }
  3521. static void ASN1CALL ASN1Free_ServiceApdus_rosApdus_ElmFn(PServiceApdus_rosApdus val)
  3522. {
  3523. if (val) {
  3524. ASN1Free_H4503ROS(&val->value);
  3525. }
  3526. }
  3527. static ASN1stringtableentry_t AliasAddress_e164_StringTableEntries[] = {
  3528. { 35, 35, 0 }, { 42, 42, 1 }, { 44, 44, 2 },
  3529. { 48, 57, 3 },
  3530. };
  3531. static ASN1stringtable_t AliasAddress_e164_StringTable = {
  3532. 4, AliasAddress_e164_StringTableEntries
  3533. };
  3534. static int ASN1CALL ASN1Enc_AliasAddress(ASN1encoding_t enc, AliasAddress *val)
  3535. {
  3536. ASN1uint32_t t;
  3537. ASN1encoding_t ee;
  3538. if (!ASN1PEREncComplexChoice(enc, (val)->choice, 1, 2))
  3539. return 0;
  3540. switch ((val)->choice) {
  3541. case 1:
  3542. t = lstrlenA((val)->u.e164);
  3543. if (!ASN1PEREncBitVal(enc, 7, t - 1))
  3544. return 0;
  3545. ASN1PEREncAlignment(enc);
  3546. if (!ASN1PEREncTableCharString(enc, t, (val)->u.e164, 4, &AliasAddress_e164_StringTable))
  3547. return 0;
  3548. break;
  3549. case 2:
  3550. ASN1PEREncAlignment(enc);
  3551. if (!ASN1PEREncBitVal(enc, 8, ((val)->u.h323_ID).length - 1))
  3552. return 0;
  3553. if (!ASN1PEREncChar16String(enc, ((val)->u.h323_ID).length, ((val)->u.h323_ID).value, 16))
  3554. return 0;
  3555. break;
  3556. case 3:
  3557. if (ASN1_CreateEncoder(enc->module, &ee, NULL, 0, enc) < 0)
  3558. return 0;
  3559. t = lstrlenA((val)->u.url_ID);
  3560. ASN1PEREncAlignment(ee);
  3561. if (!ASN1PEREncBitVal(ee, 16, t - 1))
  3562. return 0;
  3563. if (!ASN1PEREncCharString(ee, t, (val)->u.url_ID, 8))
  3564. return 0;
  3565. if (!ASN1PEREncFlushFragmentedToParent(ee))
  3566. return 0;
  3567. ASN1_CloseEncoder2(ee);
  3568. break;
  3569. case 4:
  3570. if (ASN1_CreateEncoder(enc->module, &ee, NULL, 0, enc) < 0)
  3571. return 0;
  3572. if (!ASN1Enc_TransportAddress(ee, &(val)->u.transportID))
  3573. return 0;
  3574. if (!ASN1PEREncFlushFragmentedToParent(ee))
  3575. return 0;
  3576. ASN1_CloseEncoder2(ee);
  3577. break;
  3578. case 5:
  3579. if (ASN1_CreateEncoder(enc->module, &ee, NULL, 0, enc) < 0)
  3580. return 0;
  3581. t = lstrlenA((val)->u.email_ID);
  3582. ASN1PEREncAlignment(ee);
  3583. if (!ASN1PEREncBitVal(ee, 16, t - 1))
  3584. return 0;
  3585. if (!ASN1PEREncCharString(ee, t, (val)->u.email_ID, 8))
  3586. return 0;
  3587. if (!ASN1PEREncFlushFragmentedToParent(ee))
  3588. return 0;
  3589. ASN1_CloseEncoder2(ee);
  3590. break;
  3591. case 6:
  3592. if (ASN1_CreateEncoder(enc->module, &ee, NULL, 0, enc) < 0)
  3593. return 0;
  3594. if (!ASN1Enc_PartyNumber(ee, &(val)->u.partyNumber))
  3595. return 0;
  3596. if (!ASN1PEREncFlushFragmentedToParent(ee))
  3597. return 0;
  3598. ASN1_CloseEncoder2(ee);
  3599. break;
  3600. default:
  3601. /* impossible */
  3602. ASN1EncSetError(enc, ASN1_ERR_CHOICE);
  3603. return 0;
  3604. }
  3605. return 1;
  3606. }
  3607. static int ASN1CALL ASN1Dec_AliasAddress(ASN1decoding_t dec, AliasAddress *val)
  3608. {
  3609. ASN1uint32_t l;
  3610. ASN1decoding_t dd;
  3611. ASN1octet_t *db;
  3612. ASN1uint32_t ds;
  3613. if (!ASN1PERDecComplexChoice(dec, &(val)->choice, 1, 2))
  3614. return 0;
  3615. switch ((val)->choice) {
  3616. case 1:
  3617. if (!ASN1PERDecU32Val(dec, 7, &l))
  3618. return 0;
  3619. l += 1;
  3620. ASN1PERDecAlignment(dec);
  3621. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->u.e164, 4, &AliasAddress_e164_StringTable))
  3622. return 0;
  3623. break;
  3624. case 2:
  3625. ASN1PERDecAlignment(dec);
  3626. if (!ASN1PERDecU32Val(dec, 8, &((val)->u.h323_ID).length))
  3627. return 0;
  3628. ((val)->u.h323_ID).length += 1;
  3629. if (!ASN1PERDecChar16String(dec, ((val)->u.h323_ID).length, &((val)->u.h323_ID).value, 16))
  3630. return 0;
  3631. break;
  3632. case 3:
  3633. if (!ASN1PERDecFragmented(dec, &ds, &db, 8))
  3634. return 0;
  3635. if (ASN1_CreateDecoderEx(dec->module, &dd, db, ds, dec, ASN1DECODE_AUTOFREEBUFFER) < 0)
  3636. return 0;
  3637. ASN1PERDecAlignment(dd);
  3638. if (!ASN1PERDecU32Val(dd, 16, &l))
  3639. return 0;
  3640. l += 1;
  3641. if (!ASN1PERDecZeroCharStringNoAlloc(dd, l, (val)->u.url_ID, 8))
  3642. return 0;
  3643. ASN1_CloseDecoder(dd);
  3644. break;
  3645. case 4:
  3646. if (!ASN1PERDecFragmented(dec, &ds, &db, 8))
  3647. return 0;
  3648. if (ASN1_CreateDecoderEx(dec->module, &dd, db, ds, dec, ASN1DECODE_AUTOFREEBUFFER) < 0)
  3649. return 0;
  3650. if (!ASN1Dec_TransportAddress(dd, &(val)->u.transportID))
  3651. return 0;
  3652. ASN1_CloseDecoder(dd);
  3653. break;
  3654. case 5:
  3655. if (!ASN1PERDecFragmented(dec, &ds, &db, 8))
  3656. return 0;
  3657. if (ASN1_CreateDecoderEx(dec->module, &dd, db, ds, dec, ASN1DECODE_AUTOFREEBUFFER) < 0)
  3658. return 0;
  3659. ASN1PERDecAlignment(dd);
  3660. if (!ASN1PERDecU32Val(dd, 16, &l))
  3661. return 0;
  3662. l += 1;
  3663. if (!ASN1PERDecZeroCharStringNoAlloc(dd, l, (val)->u.email_ID, 8))
  3664. return 0;
  3665. ASN1_CloseDecoder(dd);
  3666. break;
  3667. case 6:
  3668. if (!ASN1PERDecFragmented(dec, &ds, &db, 8))
  3669. return 0;
  3670. if (ASN1_CreateDecoderEx(dec->module, &dd, db, ds, dec, ASN1DECODE_AUTOFREEBUFFER) < 0)
  3671. return 0;
  3672. if (!ASN1Dec_PartyNumber(dd, &(val)->u.partyNumber))
  3673. return 0;
  3674. ASN1_CloseDecoder(dd);
  3675. break;
  3676. case 0:
  3677. /* extension case */
  3678. if (!ASN1PERDecSkipFragmented(dec, 8))
  3679. return 0;
  3680. break;
  3681. default:
  3682. /* impossible */
  3683. ASN1DecSetError(dec, ASN1_ERR_CHOICE);
  3684. return 0;
  3685. }
  3686. return 1;
  3687. }
  3688. static void ASN1CALL ASN1Free_AliasAddress(AliasAddress *val)
  3689. {
  3690. if (val) {
  3691. switch ((val)->choice) {
  3692. case 1:
  3693. break;
  3694. case 2:
  3695. ASN1char16string_free(&(val)->u.h323_ID);
  3696. break;
  3697. case 3:
  3698. break;
  3699. case 4:
  3700. ASN1Free_TransportAddress(&(val)->u.transportID);
  3701. break;
  3702. case 5:
  3703. break;
  3704. case 6:
  3705. ASN1Free_PartyNumber(&(val)->u.partyNumber);
  3706. break;
  3707. }
  3708. }
  3709. }
  3710. static int ASN1CALL ASN1Enc_EndpointAddress_destinationAddress(ASN1encoding_t enc, PEndpointAddress_destinationAddress *val)
  3711. {
  3712. return ASN1PEREncSeqOf_NoSize(enc, (ASN1iterator_t **) val, (ASN1iterator_encfn) ASN1Enc_EndpointAddress_destinationAddress_ElmFn);
  3713. }
  3714. static int ASN1CALL ASN1Enc_EndpointAddress_destinationAddress_ElmFn(ASN1encoding_t enc, PEndpointAddress_destinationAddress val)
  3715. {
  3716. if (!ASN1Enc_AliasAddress(enc, &val->value))
  3717. return 0;
  3718. return 1;
  3719. }
  3720. static int ASN1CALL ASN1Dec_EndpointAddress_destinationAddress(ASN1decoding_t dec, PEndpointAddress_destinationAddress *val)
  3721. {
  3722. return ASN1PERDecSeqOf_NoSize(dec, (ASN1iterator_t **) val, (ASN1iterator_decfn) ASN1Dec_EndpointAddress_destinationAddress_ElmFn, sizeof(**val));
  3723. }
  3724. static int ASN1CALL ASN1Dec_EndpointAddress_destinationAddress_ElmFn(ASN1decoding_t dec, PEndpointAddress_destinationAddress val)
  3725. {
  3726. if (!ASN1Dec_AliasAddress(dec, &val->value))
  3727. return 0;
  3728. return 1;
  3729. }
  3730. static void ASN1CALL ASN1Free_EndpointAddress_destinationAddress(PEndpointAddress_destinationAddress *val)
  3731. {
  3732. if (val) {
  3733. ASN1PERFreeSeqOf((ASN1iterator_t **) val, (ASN1iterator_freefn) ASN1Free_EndpointAddress_destinationAddress_ElmFn);
  3734. }
  3735. }
  3736. static void ASN1CALL ASN1Free_EndpointAddress_destinationAddress_ElmFn(PEndpointAddress_destinationAddress val)
  3737. {
  3738. if (val) {
  3739. ASN1Free_AliasAddress(&val->value);
  3740. }
  3741. }
  3742. static int ASN1CALL ASN1Enc_AddressInformation(ASN1encoding_t enc, AddressInformation *val)
  3743. {
  3744. if (!ASN1Enc_AliasAddress(enc, val))
  3745. return 0;
  3746. return 1;
  3747. }
  3748. static int ASN1CALL ASN1Dec_AddressInformation(ASN1decoding_t dec, AddressInformation *val)
  3749. {
  3750. if (!ASN1Dec_AliasAddress(dec, val))
  3751. return 0;
  3752. return 1;
  3753. }
  3754. static void ASN1CALL ASN1Free_AddressInformation(AddressInformation *val)
  3755. {
  3756. if (val) {
  3757. ASN1Free_AliasAddress(val);
  3758. }
  3759. }
  3760. static int ASN1CALL ASN1Enc_EndpointAddress(ASN1encoding_t enc, EndpointAddress *val)
  3761. {
  3762. if (!ASN1PEREncExtensionBitClear(enc))
  3763. return 0;
  3764. if (!ASN1PEREncBits(enc, 1, (val)->o))
  3765. return 0;
  3766. if (!ASN1Enc_EndpointAddress_destinationAddress(enc, &(val)->destinationAddress))
  3767. return 0;
  3768. if ((val)->o[0] & 0x80) {
  3769. if (!ASN1Enc_AliasAddress(enc, &(val)->remoteExtensionAddress))
  3770. return 0;
  3771. }
  3772. return 1;
  3773. }
  3774. static int ASN1CALL ASN1Dec_EndpointAddress(ASN1decoding_t dec, EndpointAddress *val)
  3775. {
  3776. ASN1uint32_t y;
  3777. if (!ASN1PERDecExtensionBit(dec, &y))
  3778. return 0;
  3779. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  3780. return 0;
  3781. if (!ASN1Dec_EndpointAddress_destinationAddress(dec, &(val)->destinationAddress))
  3782. return 0;
  3783. if ((val)->o[0] & 0x80) {
  3784. if (!ASN1Dec_AliasAddress(dec, &(val)->remoteExtensionAddress))
  3785. return 0;
  3786. }
  3787. if (y) {
  3788. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  3789. return 0;
  3790. }
  3791. return 1;
  3792. }
  3793. static void ASN1CALL ASN1Free_EndpointAddress(EndpointAddress *val)
  3794. {
  3795. if (val) {
  3796. ASN1Free_EndpointAddress_destinationAddress(&(val)->destinationAddress);
  3797. if ((val)->o[0] & 0x80) {
  3798. ASN1Free_AliasAddress(&(val)->remoteExtensionAddress);
  3799. }
  3800. }
  3801. }
  3802. static int ASN1CALL ASN1Enc_NetworkFacilityExtension(ASN1encoding_t enc, NetworkFacilityExtension *val)
  3803. {
  3804. if (!ASN1PEREncExtensionBitClear(enc))
  3805. return 0;
  3806. if (!ASN1PEREncBits(enc, 2, (val)->o))
  3807. return 0;
  3808. if (!ASN1Enc_EntityType(enc, &(val)->sourceEntity))
  3809. return 0;
  3810. if ((val)->o[0] & 0x80) {
  3811. if (!ASN1Enc_AddressInformation(enc, &(val)->sourceEntityAddress))
  3812. return 0;
  3813. }
  3814. if (!ASN1Enc_EntityType(enc, &(val)->destinationEntity))
  3815. return 0;
  3816. if ((val)->o[0] & 0x40) {
  3817. if (!ASN1Enc_AddressInformation(enc, &(val)->destinationEntityAddress))
  3818. return 0;
  3819. }
  3820. return 1;
  3821. }
  3822. static int ASN1CALL ASN1Dec_NetworkFacilityExtension(ASN1decoding_t dec, NetworkFacilityExtension *val)
  3823. {
  3824. ASN1uint32_t y;
  3825. if (!ASN1PERDecExtensionBit(dec, &y))
  3826. return 0;
  3827. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  3828. return 0;
  3829. if (!ASN1Dec_EntityType(dec, &(val)->sourceEntity))
  3830. return 0;
  3831. if ((val)->o[0] & 0x80) {
  3832. if (!ASN1Dec_AddressInformation(dec, &(val)->sourceEntityAddress))
  3833. return 0;
  3834. }
  3835. if (!ASN1Dec_EntityType(dec, &(val)->destinationEntity))
  3836. return 0;
  3837. if ((val)->o[0] & 0x40) {
  3838. if (!ASN1Dec_AddressInformation(dec, &(val)->destinationEntityAddress))
  3839. return 0;
  3840. }
  3841. if (y) {
  3842. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  3843. return 0;
  3844. }
  3845. return 1;
  3846. }
  3847. static void ASN1CALL ASN1Free_NetworkFacilityExtension(NetworkFacilityExtension *val)
  3848. {
  3849. if (val) {
  3850. if ((val)->o[0] & 0x80) {
  3851. ASN1Free_AddressInformation(&(val)->sourceEntityAddress);
  3852. }
  3853. if ((val)->o[0] & 0x40) {
  3854. ASN1Free_AddressInformation(&(val)->destinationEntityAddress);
  3855. }
  3856. }
  3857. }
  3858. static int ASN1CALL ASN1Enc_ActivateDiversionQArgument(ASN1encoding_t enc, ActivateDiversionQArgument *val)
  3859. {
  3860. ASN1uint32_t u;
  3861. if (!ASN1PEREncExtensionBitClear(enc))
  3862. return 0;
  3863. if (!ASN1PEREncBits(enc, 1, (val)->o))
  3864. return 0;
  3865. if (!ASN1PEREncExtensionBitClear(enc))
  3866. return 0;
  3867. if (!ASN1PEREncBitVal(enc, 2, (val)->procedure))
  3868. return 0;
  3869. switch ((val)->basicService) {
  3870. case 0:
  3871. u = 0;
  3872. break;
  3873. case 1:
  3874. u = 1;
  3875. break;
  3876. case 2:
  3877. u = 2;
  3878. break;
  3879. case 3:
  3880. u = 3;
  3881. break;
  3882. case 32:
  3883. u = 4;
  3884. break;
  3885. case 33:
  3886. u = 5;
  3887. break;
  3888. case 34:
  3889. u = 6;
  3890. break;
  3891. case 35:
  3892. u = 7;
  3893. break;
  3894. case 36:
  3895. u = 8;
  3896. break;
  3897. }
  3898. if (!ASN1PEREncExtensionBitClear(enc))
  3899. return 0;
  3900. if (!ASN1PEREncBitVal(enc, 4, u))
  3901. return 0;
  3902. if (!ASN1Enc_EndpointAddress(enc, &(val)->divertedToAddress))
  3903. return 0;
  3904. if (!ASN1Enc_EndpointAddress(enc, &(val)->servedUserNr))
  3905. return 0;
  3906. if (!ASN1Enc_EndpointAddress(enc, &(val)->activatingUserNr))
  3907. return 0;
  3908. if ((val)->o[0] & 0x80) {
  3909. if (!ASN1Enc_ActivateDiversionQArgument_extension(enc, &(val)->extension))
  3910. return 0;
  3911. }
  3912. return 1;
  3913. }
  3914. static int ASN1CALL ASN1Dec_ActivateDiversionQArgument(ASN1decoding_t dec, ActivateDiversionQArgument *val)
  3915. {
  3916. ASN1uint32_t y;
  3917. ASN1uint32_t x;
  3918. ASN1uint32_t u;
  3919. if (!ASN1PERDecExtensionBit(dec, &y))
  3920. return 0;
  3921. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  3922. return 0;
  3923. if (!ASN1PERDecExtensionBit(dec, &x))
  3924. return 0;
  3925. if (!x) {
  3926. if (!ASN1PERDecU32Val(dec, 2, &(val)->procedure))
  3927. return 0;
  3928. } else {
  3929. if (!ASN1PERDecSkipNormallySmall(dec))
  3930. return 0;
  3931. }
  3932. if (!ASN1PERDecExtensionBit(dec, &x))
  3933. return 0;
  3934. if (!x) {
  3935. if (!ASN1PERDecU32Val(dec, 4, &u))
  3936. return 0;
  3937. switch (u) {
  3938. case 0:
  3939. (val)->basicService = 0;
  3940. break;
  3941. case 1:
  3942. (val)->basicService = 1;
  3943. break;
  3944. case 2:
  3945. (val)->basicService = 2;
  3946. break;
  3947. case 3:
  3948. (val)->basicService = 3;
  3949. break;
  3950. case 4:
  3951. (val)->basicService = 32;
  3952. break;
  3953. case 5:
  3954. (val)->basicService = 33;
  3955. break;
  3956. case 6:
  3957. (val)->basicService = 34;
  3958. break;
  3959. case 7:
  3960. (val)->basicService = 35;
  3961. break;
  3962. case 8:
  3963. (val)->basicService = 36;
  3964. break;
  3965. }
  3966. } else {
  3967. if (!ASN1PERDecSkipNormallySmall(dec))
  3968. return 0;
  3969. }
  3970. if (!ASN1Dec_EndpointAddress(dec, &(val)->divertedToAddress))
  3971. return 0;
  3972. if (!ASN1Dec_EndpointAddress(dec, &(val)->servedUserNr))
  3973. return 0;
  3974. if (!ASN1Dec_EndpointAddress(dec, &(val)->activatingUserNr))
  3975. return 0;
  3976. if ((val)->o[0] & 0x80) {
  3977. if (!ASN1Dec_ActivateDiversionQArgument_extension(dec, &(val)->extension))
  3978. return 0;
  3979. }
  3980. if (y) {
  3981. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  3982. return 0;
  3983. }
  3984. return 1;
  3985. }
  3986. static void ASN1CALL ASN1Free_ActivateDiversionQArgument(ActivateDiversionQArgument *val)
  3987. {
  3988. if (val) {
  3989. ASN1Free_EndpointAddress(&(val)->divertedToAddress);
  3990. ASN1Free_EndpointAddress(&(val)->servedUserNr);
  3991. ASN1Free_EndpointAddress(&(val)->activatingUserNr);
  3992. if ((val)->o[0] & 0x80) {
  3993. ASN1Free_ActivateDiversionQArgument_extension(&(val)->extension);
  3994. }
  3995. }
  3996. }
  3997. static int ASN1CALL ASN1Enc_DeactivateDiversionQArgument(ASN1encoding_t enc, DeactivateDiversionQArgument *val)
  3998. {
  3999. ASN1uint32_t u;
  4000. if (!ASN1PEREncExtensionBitClear(enc))
  4001. return 0;
  4002. if (!ASN1PEREncBits(enc, 1, (val)->o))
  4003. return 0;
  4004. if (!ASN1PEREncExtensionBitClear(enc))
  4005. return 0;
  4006. if (!ASN1PEREncBitVal(enc, 2, (val)->procedure))
  4007. return 0;
  4008. switch ((val)->basicService) {
  4009. case 0:
  4010. u = 0;
  4011. break;
  4012. case 1:
  4013. u = 1;
  4014. break;
  4015. case 2:
  4016. u = 2;
  4017. break;
  4018. case 3:
  4019. u = 3;
  4020. break;
  4021. case 32:
  4022. u = 4;
  4023. break;
  4024. case 33:
  4025. u = 5;
  4026. break;
  4027. case 34:
  4028. u = 6;
  4029. break;
  4030. case 35:
  4031. u = 7;
  4032. break;
  4033. case 36:
  4034. u = 8;
  4035. break;
  4036. }
  4037. if (!ASN1PEREncExtensionBitClear(enc))
  4038. return 0;
  4039. if (!ASN1PEREncBitVal(enc, 4, u))
  4040. return 0;
  4041. if (!ASN1Enc_EndpointAddress(enc, &(val)->servedUserNr))
  4042. return 0;
  4043. if (!ASN1Enc_EndpointAddress(enc, &(val)->deactivatingUserNr))
  4044. return 0;
  4045. if ((val)->o[0] & 0x80) {
  4046. if (!ASN1Enc_DeactivateDiversionQArgument_extension(enc, &(val)->extension))
  4047. return 0;
  4048. }
  4049. return 1;
  4050. }
  4051. static int ASN1CALL ASN1Dec_DeactivateDiversionQArgument(ASN1decoding_t dec, DeactivateDiversionQArgument *val)
  4052. {
  4053. ASN1uint32_t y;
  4054. ASN1uint32_t x;
  4055. ASN1uint32_t u;
  4056. if (!ASN1PERDecExtensionBit(dec, &y))
  4057. return 0;
  4058. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  4059. return 0;
  4060. if (!ASN1PERDecExtensionBit(dec, &x))
  4061. return 0;
  4062. if (!x) {
  4063. if (!ASN1PERDecU32Val(dec, 2, &(val)->procedure))
  4064. return 0;
  4065. } else {
  4066. if (!ASN1PERDecSkipNormallySmall(dec))
  4067. return 0;
  4068. }
  4069. if (!ASN1PERDecExtensionBit(dec, &x))
  4070. return 0;
  4071. if (!x) {
  4072. if (!ASN1PERDecU32Val(dec, 4, &u))
  4073. return 0;
  4074. switch (u) {
  4075. case 0:
  4076. (val)->basicService = 0;
  4077. break;
  4078. case 1:
  4079. (val)->basicService = 1;
  4080. break;
  4081. case 2:
  4082. (val)->basicService = 2;
  4083. break;
  4084. case 3:
  4085. (val)->basicService = 3;
  4086. break;
  4087. case 4:
  4088. (val)->basicService = 32;
  4089. break;
  4090. case 5:
  4091. (val)->basicService = 33;
  4092. break;
  4093. case 6:
  4094. (val)->basicService = 34;
  4095. break;
  4096. case 7:
  4097. (val)->basicService = 35;
  4098. break;
  4099. case 8:
  4100. (val)->basicService = 36;
  4101. break;
  4102. }
  4103. } else {
  4104. if (!ASN1PERDecSkipNormallySmall(dec))
  4105. return 0;
  4106. }
  4107. if (!ASN1Dec_EndpointAddress(dec, &(val)->servedUserNr))
  4108. return 0;
  4109. if (!ASN1Dec_EndpointAddress(dec, &(val)->deactivatingUserNr))
  4110. return 0;
  4111. if ((val)->o[0] & 0x80) {
  4112. if (!ASN1Dec_DeactivateDiversionQArgument_extension(dec, &(val)->extension))
  4113. return 0;
  4114. }
  4115. if (y) {
  4116. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4117. return 0;
  4118. }
  4119. return 1;
  4120. }
  4121. static void ASN1CALL ASN1Free_DeactivateDiversionQArgument(DeactivateDiversionQArgument *val)
  4122. {
  4123. if (val) {
  4124. ASN1Free_EndpointAddress(&(val)->servedUserNr);
  4125. ASN1Free_EndpointAddress(&(val)->deactivatingUserNr);
  4126. if ((val)->o[0] & 0x80) {
  4127. ASN1Free_DeactivateDiversionQArgument_extension(&(val)->extension);
  4128. }
  4129. }
  4130. }
  4131. static int ASN1CALL ASN1Enc_InterrogateDiversionQArgument(ASN1encoding_t enc, InterrogateDiversionQArgument *val)
  4132. {
  4133. ASN1octet_t o[1];
  4134. ASN1uint32_t u;
  4135. CopyMemory(o, (val)->o, 1);
  4136. if ((val)->basicService == 0)
  4137. o[0] &= ~0x80;
  4138. if (!ASN1PEREncExtensionBitClear(enc))
  4139. return 0;
  4140. if (!ASN1PEREncBits(enc, 2, o))
  4141. return 0;
  4142. if (!ASN1PEREncExtensionBitClear(enc))
  4143. return 0;
  4144. if (!ASN1PEREncBitVal(enc, 2, (val)->procedure))
  4145. return 0;
  4146. if (o[0] & 0x80) {
  4147. switch ((val)->basicService) {
  4148. case 0:
  4149. u = 0;
  4150. break;
  4151. case 1:
  4152. u = 1;
  4153. break;
  4154. case 2:
  4155. u = 2;
  4156. break;
  4157. case 3:
  4158. u = 3;
  4159. break;
  4160. case 32:
  4161. u = 4;
  4162. break;
  4163. case 33:
  4164. u = 5;
  4165. break;
  4166. case 34:
  4167. u = 6;
  4168. break;
  4169. case 35:
  4170. u = 7;
  4171. break;
  4172. case 36:
  4173. u = 8;
  4174. break;
  4175. }
  4176. if (!ASN1PEREncExtensionBitClear(enc))
  4177. return 0;
  4178. if (!ASN1PEREncBitVal(enc, 4, u))
  4179. return 0;
  4180. }
  4181. if (!ASN1Enc_EndpointAddress(enc, &(val)->servedUserNr))
  4182. return 0;
  4183. if (!ASN1Enc_EndpointAddress(enc, &(val)->interrogatingUserNr))
  4184. return 0;
  4185. if (o[0] & 0x40) {
  4186. if (!ASN1Enc_InterrogateDiversionQArgument_extension(enc, &(val)->extension))
  4187. return 0;
  4188. }
  4189. return 1;
  4190. }
  4191. static int ASN1CALL ASN1Dec_InterrogateDiversionQArgument(ASN1decoding_t dec, InterrogateDiversionQArgument *val)
  4192. {
  4193. ASN1uint32_t y;
  4194. ASN1uint32_t x;
  4195. ASN1uint32_t u;
  4196. if (!ASN1PERDecExtensionBit(dec, &y))
  4197. return 0;
  4198. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  4199. return 0;
  4200. if (!ASN1PERDecExtensionBit(dec, &x))
  4201. return 0;
  4202. if (!x) {
  4203. if (!ASN1PERDecU32Val(dec, 2, &(val)->procedure))
  4204. return 0;
  4205. } else {
  4206. if (!ASN1PERDecSkipNormallySmall(dec))
  4207. return 0;
  4208. }
  4209. if ((val)->o[0] & 0x80) {
  4210. if (!ASN1PERDecExtensionBit(dec, &x))
  4211. return 0;
  4212. if (!x) {
  4213. if (!ASN1PERDecU32Val(dec, 4, &u))
  4214. return 0;
  4215. switch (u) {
  4216. case 0:
  4217. (val)->basicService = 0;
  4218. break;
  4219. case 1:
  4220. (val)->basicService = 1;
  4221. break;
  4222. case 2:
  4223. (val)->basicService = 2;
  4224. break;
  4225. case 3:
  4226. (val)->basicService = 3;
  4227. break;
  4228. case 4:
  4229. (val)->basicService = 32;
  4230. break;
  4231. case 5:
  4232. (val)->basicService = 33;
  4233. break;
  4234. case 6:
  4235. (val)->basicService = 34;
  4236. break;
  4237. case 7:
  4238. (val)->basicService = 35;
  4239. break;
  4240. case 8:
  4241. (val)->basicService = 36;
  4242. break;
  4243. }
  4244. } else {
  4245. if (!ASN1PERDecSkipNormallySmall(dec))
  4246. return 0;
  4247. }
  4248. }
  4249. if (!ASN1Dec_EndpointAddress(dec, &(val)->servedUserNr))
  4250. return 0;
  4251. if (!ASN1Dec_EndpointAddress(dec, &(val)->interrogatingUserNr))
  4252. return 0;
  4253. if ((val)->o[0] & 0x40) {
  4254. if (!ASN1Dec_InterrogateDiversionQArgument_extension(dec, &(val)->extension))
  4255. return 0;
  4256. }
  4257. if (y) {
  4258. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4259. return 0;
  4260. }
  4261. if (!((val)->o[0] & 0x80))
  4262. (val)->basicService = 0;
  4263. return 1;
  4264. }
  4265. static void ASN1CALL ASN1Free_InterrogateDiversionQArgument(InterrogateDiversionQArgument *val)
  4266. {
  4267. if (val) {
  4268. ASN1Free_EndpointAddress(&(val)->servedUserNr);
  4269. ASN1Free_EndpointAddress(&(val)->interrogatingUserNr);
  4270. if ((val)->o[0] & 0x40) {
  4271. ASN1Free_InterrogateDiversionQArgument_extension(&(val)->extension);
  4272. }
  4273. }
  4274. }
  4275. static int ASN1CALL ASN1Enc_CheckRestrictionArgument(ASN1encoding_t enc, CheckRestrictionArgument *val)
  4276. {
  4277. ASN1uint32_t u;
  4278. if (!ASN1PEREncExtensionBitClear(enc))
  4279. return 0;
  4280. if (!ASN1PEREncBits(enc, 1, (val)->o))
  4281. return 0;
  4282. if (!ASN1Enc_EndpointAddress(enc, &(val)->servedUserNr))
  4283. return 0;
  4284. switch ((val)->basicService) {
  4285. case 0:
  4286. u = 0;
  4287. break;
  4288. case 1:
  4289. u = 1;
  4290. break;
  4291. case 2:
  4292. u = 2;
  4293. break;
  4294. case 3:
  4295. u = 3;
  4296. break;
  4297. case 32:
  4298. u = 4;
  4299. break;
  4300. case 33:
  4301. u = 5;
  4302. break;
  4303. case 34:
  4304. u = 6;
  4305. break;
  4306. case 35:
  4307. u = 7;
  4308. break;
  4309. case 36:
  4310. u = 8;
  4311. break;
  4312. }
  4313. if (!ASN1PEREncExtensionBitClear(enc))
  4314. return 0;
  4315. if (!ASN1PEREncBitVal(enc, 4, u))
  4316. return 0;
  4317. if (!ASN1Enc_EndpointAddress(enc, &(val)->divertedToNr))
  4318. return 0;
  4319. if ((val)->o[0] & 0x80) {
  4320. if (!ASN1Enc_CheckRestrictionArgument_extension(enc, &(val)->extension))
  4321. return 0;
  4322. }
  4323. return 1;
  4324. }
  4325. static int ASN1CALL ASN1Dec_CheckRestrictionArgument(ASN1decoding_t dec, CheckRestrictionArgument *val)
  4326. {
  4327. ASN1uint32_t y;
  4328. ASN1uint32_t x;
  4329. ASN1uint32_t u;
  4330. if (!ASN1PERDecExtensionBit(dec, &y))
  4331. return 0;
  4332. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  4333. return 0;
  4334. if (!ASN1Dec_EndpointAddress(dec, &(val)->servedUserNr))
  4335. return 0;
  4336. if (!ASN1PERDecExtensionBit(dec, &x))
  4337. return 0;
  4338. if (!x) {
  4339. if (!ASN1PERDecU32Val(dec, 4, &u))
  4340. return 0;
  4341. switch (u) {
  4342. case 0:
  4343. (val)->basicService = 0;
  4344. break;
  4345. case 1:
  4346. (val)->basicService = 1;
  4347. break;
  4348. case 2:
  4349. (val)->basicService = 2;
  4350. break;
  4351. case 3:
  4352. (val)->basicService = 3;
  4353. break;
  4354. case 4:
  4355. (val)->basicService = 32;
  4356. break;
  4357. case 5:
  4358. (val)->basicService = 33;
  4359. break;
  4360. case 6:
  4361. (val)->basicService = 34;
  4362. break;
  4363. case 7:
  4364. (val)->basicService = 35;
  4365. break;
  4366. case 8:
  4367. (val)->basicService = 36;
  4368. break;
  4369. }
  4370. } else {
  4371. if (!ASN1PERDecSkipNormallySmall(dec))
  4372. return 0;
  4373. }
  4374. if (!ASN1Dec_EndpointAddress(dec, &(val)->divertedToNr))
  4375. return 0;
  4376. if ((val)->o[0] & 0x80) {
  4377. if (!ASN1Dec_CheckRestrictionArgument_extension(dec, &(val)->extension))
  4378. return 0;
  4379. }
  4380. if (y) {
  4381. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4382. return 0;
  4383. }
  4384. return 1;
  4385. }
  4386. static void ASN1CALL ASN1Free_CheckRestrictionArgument(CheckRestrictionArgument *val)
  4387. {
  4388. if (val) {
  4389. ASN1Free_EndpointAddress(&(val)->servedUserNr);
  4390. ASN1Free_EndpointAddress(&(val)->divertedToNr);
  4391. if ((val)->o[0] & 0x80) {
  4392. ASN1Free_CheckRestrictionArgument_extension(&(val)->extension);
  4393. }
  4394. }
  4395. }
  4396. static int ASN1CALL ASN1Enc_CallReroutingArgument(ASN1encoding_t enc, CallReroutingArgument *val)
  4397. {
  4398. if (!ASN1PEREncExtensionBitClear(enc))
  4399. return 0;
  4400. if (!ASN1PEREncBits(enc, 7, (val)->o))
  4401. return 0;
  4402. if (!ASN1PEREncExtensionBitClear(enc))
  4403. return 0;
  4404. if (!ASN1PEREncBitVal(enc, 2, (val)->reroutingReason))
  4405. return 0;
  4406. if ((val)->o[0] & 0x80) {
  4407. if (!ASN1PEREncExtensionBitClear(enc))
  4408. return 0;
  4409. if (!ASN1PEREncBitVal(enc, 2, (val)->originalReroutingReason))
  4410. return 0;
  4411. }
  4412. if (!ASN1Enc_EndpointAddress(enc, &(val)->calledAddress))
  4413. return 0;
  4414. if (!ASN1PEREncBitVal(enc, 4, (val)->diversionCounter - 1))
  4415. return 0;
  4416. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->h225InfoElement))
  4417. return 0;
  4418. if (!ASN1Enc_EndpointAddress(enc, &(val)->lastReroutingNr))
  4419. return 0;
  4420. if (!ASN1PEREncExtensionBitClear(enc))
  4421. return 0;
  4422. if (!ASN1PEREncBitVal(enc, 2, (val)->subscriptionOption))
  4423. return 0;
  4424. if ((val)->o[0] & 0x40) {
  4425. if (!ASN1Enc_PartySubaddress(enc, &(val)->callingPartySubaddress))
  4426. return 0;
  4427. }
  4428. if (!ASN1Enc_EndpointAddress(enc, &(val)->callingNumber))
  4429. return 0;
  4430. if ((val)->o[0] & 0x20) {
  4431. if (!ASN1PEREncBitVal(enc, 7, ((val)->callingInfo).length - 1))
  4432. return 0;
  4433. ASN1PEREncAlignment(enc);
  4434. if (!ASN1PEREncChar16String(enc, ((val)->callingInfo).length, ((val)->callingInfo).value, 16))
  4435. return 0;
  4436. }
  4437. if ((val)->o[0] & 0x10) {
  4438. if (!ASN1Enc_EndpointAddress(enc, &(val)->originalCalledNr))
  4439. return 0;
  4440. }
  4441. if ((val)->o[0] & 0x8) {
  4442. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectingInfo).length - 1))
  4443. return 0;
  4444. ASN1PEREncAlignment(enc);
  4445. if (!ASN1PEREncChar16String(enc, ((val)->redirectingInfo).length, ((val)->redirectingInfo).value, 16))
  4446. return 0;
  4447. }
  4448. if ((val)->o[0] & 0x4) {
  4449. if (!ASN1PEREncBitVal(enc, 7, ((val)->originalCalledInfo).length - 1))
  4450. return 0;
  4451. ASN1PEREncAlignment(enc);
  4452. if (!ASN1PEREncChar16String(enc, ((val)->originalCalledInfo).length, ((val)->originalCalledInfo).value, 16))
  4453. return 0;
  4454. }
  4455. if ((val)->o[0] & 0x2) {
  4456. if (!ASN1Enc_CallReroutingArgument_extension(enc, &(val)->extension))
  4457. return 0;
  4458. }
  4459. return 1;
  4460. }
  4461. static int ASN1CALL ASN1Dec_CallReroutingArgument(ASN1decoding_t dec, CallReroutingArgument *val)
  4462. {
  4463. ASN1uint32_t y;
  4464. ASN1uint32_t x;
  4465. if (!ASN1PERDecExtensionBit(dec, &y))
  4466. return 0;
  4467. if (!ASN1PERDecExtension(dec, 7, (val)->o))
  4468. return 0;
  4469. if (!ASN1PERDecExtensionBit(dec, &x))
  4470. return 0;
  4471. if (!x) {
  4472. if (!ASN1PERDecU32Val(dec, 2, &(val)->reroutingReason))
  4473. return 0;
  4474. } else {
  4475. if (!ASN1PERDecSkipNormallySmall(dec))
  4476. return 0;
  4477. }
  4478. if ((val)->o[0] & 0x80) {
  4479. if (!ASN1PERDecExtensionBit(dec, &x))
  4480. return 0;
  4481. if (!x) {
  4482. if (!ASN1PERDecU32Val(dec, 2, &(val)->originalReroutingReason))
  4483. return 0;
  4484. } else {
  4485. if (!ASN1PERDecSkipNormallySmall(dec))
  4486. return 0;
  4487. }
  4488. }
  4489. if (!ASN1Dec_EndpointAddress(dec, &(val)->calledAddress))
  4490. return 0;
  4491. if (!ASN1PERDecU16Val(dec, 4, &(val)->diversionCounter))
  4492. return 0;
  4493. (val)->diversionCounter += 1;
  4494. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->h225InfoElement))
  4495. return 0;
  4496. if (!ASN1Dec_EndpointAddress(dec, &(val)->lastReroutingNr))
  4497. return 0;
  4498. if (!ASN1PERDecExtensionBit(dec, &x))
  4499. return 0;
  4500. if (!x) {
  4501. if (!ASN1PERDecU32Val(dec, 2, &(val)->subscriptionOption))
  4502. return 0;
  4503. } else {
  4504. if (!ASN1PERDecSkipNormallySmall(dec))
  4505. return 0;
  4506. }
  4507. if ((val)->o[0] & 0x40) {
  4508. if (!ASN1Dec_PartySubaddress(dec, &(val)->callingPartySubaddress))
  4509. return 0;
  4510. }
  4511. if (!ASN1Dec_EndpointAddress(dec, &(val)->callingNumber))
  4512. return 0;
  4513. if ((val)->o[0] & 0x20) {
  4514. if (!ASN1PERDecU32Val(dec, 7, &((val)->callingInfo).length))
  4515. return 0;
  4516. ((val)->callingInfo).length += 1;
  4517. ASN1PERDecAlignment(dec);
  4518. if (!ASN1PERDecChar16String(dec, ((val)->callingInfo).length, &((val)->callingInfo).value, 16))
  4519. return 0;
  4520. }
  4521. if ((val)->o[0] & 0x10) {
  4522. if (!ASN1Dec_EndpointAddress(dec, &(val)->originalCalledNr))
  4523. return 0;
  4524. }
  4525. if ((val)->o[0] & 0x8) {
  4526. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectingInfo).length))
  4527. return 0;
  4528. ((val)->redirectingInfo).length += 1;
  4529. ASN1PERDecAlignment(dec);
  4530. if (!ASN1PERDecChar16String(dec, ((val)->redirectingInfo).length, &((val)->redirectingInfo).value, 16))
  4531. return 0;
  4532. }
  4533. if ((val)->o[0] & 0x4) {
  4534. if (!ASN1PERDecU32Val(dec, 7, &((val)->originalCalledInfo).length))
  4535. return 0;
  4536. ((val)->originalCalledInfo).length += 1;
  4537. ASN1PERDecAlignment(dec);
  4538. if (!ASN1PERDecChar16String(dec, ((val)->originalCalledInfo).length, &((val)->originalCalledInfo).value, 16))
  4539. return 0;
  4540. }
  4541. if ((val)->o[0] & 0x2) {
  4542. if (!ASN1Dec_CallReroutingArgument_extension(dec, &(val)->extension))
  4543. return 0;
  4544. }
  4545. if (y) {
  4546. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4547. return 0;
  4548. }
  4549. return 1;
  4550. }
  4551. static void ASN1CALL ASN1Free_CallReroutingArgument(CallReroutingArgument *val)
  4552. {
  4553. if (val) {
  4554. ASN1Free_EndpointAddress(&(val)->calledAddress);
  4555. ASN1octetstring_free(&(val)->h225InfoElement);
  4556. ASN1Free_EndpointAddress(&(val)->lastReroutingNr);
  4557. if ((val)->o[0] & 0x40) {
  4558. ASN1Free_PartySubaddress(&(val)->callingPartySubaddress);
  4559. }
  4560. ASN1Free_EndpointAddress(&(val)->callingNumber);
  4561. if ((val)->o[0] & 0x20) {
  4562. ASN1char16string_free(&(val)->callingInfo);
  4563. }
  4564. if ((val)->o[0] & 0x10) {
  4565. ASN1Free_EndpointAddress(&(val)->originalCalledNr);
  4566. }
  4567. if ((val)->o[0] & 0x8) {
  4568. ASN1char16string_free(&(val)->redirectingInfo);
  4569. }
  4570. if ((val)->o[0] & 0x4) {
  4571. ASN1char16string_free(&(val)->originalCalledInfo);
  4572. }
  4573. if ((val)->o[0] & 0x2) {
  4574. ASN1Free_CallReroutingArgument_extension(&(val)->extension);
  4575. }
  4576. }
  4577. }
  4578. static int ASN1CALL ASN1Enc_DivertingLegInformation1Argument(ASN1encoding_t enc, DivertingLegInformation1Argument *val)
  4579. {
  4580. if (!ASN1PEREncExtensionBitClear(enc))
  4581. return 0;
  4582. if (!ASN1PEREncBits(enc, 4, (val)->o))
  4583. return 0;
  4584. if (!ASN1PEREncExtensionBitClear(enc))
  4585. return 0;
  4586. if (!ASN1PEREncBitVal(enc, 2, (val)->diversionReason))
  4587. return 0;
  4588. if (!ASN1PEREncExtensionBitClear(enc))
  4589. return 0;
  4590. if (!ASN1PEREncBitVal(enc, 2, (val)->subscriptionOption))
  4591. return 0;
  4592. if (!ASN1Enc_EndpointAddress(enc, &(val)->nominatedNr))
  4593. return 0;
  4594. if ((val)->o[0] & 0x80) {
  4595. if (!ASN1PEREncBitVal(enc, 7, ((val)->nominatedInfo).length - 1))
  4596. return 0;
  4597. ASN1PEREncAlignment(enc);
  4598. if (!ASN1PEREncChar16String(enc, ((val)->nominatedInfo).length, ((val)->nominatedInfo).value, 16))
  4599. return 0;
  4600. }
  4601. if ((val)->o[0] & 0x40) {
  4602. if (!ASN1Enc_EndpointAddress(enc, &(val)->redirectingNr))
  4603. return 0;
  4604. }
  4605. if ((val)->o[0] & 0x20) {
  4606. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectingInfo).length - 1))
  4607. return 0;
  4608. ASN1PEREncAlignment(enc);
  4609. if (!ASN1PEREncChar16String(enc, ((val)->redirectingInfo).length, ((val)->redirectingInfo).value, 16))
  4610. return 0;
  4611. }
  4612. if ((val)->o[0] & 0x10) {
  4613. if (!ASN1Enc_DivertingLegInformation1Argument_extension(enc, &(val)->extension))
  4614. return 0;
  4615. }
  4616. return 1;
  4617. }
  4618. static int ASN1CALL ASN1Dec_DivertingLegInformation1Argument(ASN1decoding_t dec, DivertingLegInformation1Argument *val)
  4619. {
  4620. ASN1uint32_t y;
  4621. ASN1uint32_t x;
  4622. if (!ASN1PERDecExtensionBit(dec, &y))
  4623. return 0;
  4624. if (!ASN1PERDecExtension(dec, 4, (val)->o))
  4625. return 0;
  4626. if (!ASN1PERDecExtensionBit(dec, &x))
  4627. return 0;
  4628. if (!x) {
  4629. if (!ASN1PERDecU32Val(dec, 2, &(val)->diversionReason))
  4630. return 0;
  4631. } else {
  4632. if (!ASN1PERDecSkipNormallySmall(dec))
  4633. return 0;
  4634. }
  4635. if (!ASN1PERDecExtensionBit(dec, &x))
  4636. return 0;
  4637. if (!x) {
  4638. if (!ASN1PERDecU32Val(dec, 2, &(val)->subscriptionOption))
  4639. return 0;
  4640. } else {
  4641. if (!ASN1PERDecSkipNormallySmall(dec))
  4642. return 0;
  4643. }
  4644. if (!ASN1Dec_EndpointAddress(dec, &(val)->nominatedNr))
  4645. return 0;
  4646. if ((val)->o[0] & 0x80) {
  4647. if (!ASN1PERDecU32Val(dec, 7, &((val)->nominatedInfo).length))
  4648. return 0;
  4649. ((val)->nominatedInfo).length += 1;
  4650. ASN1PERDecAlignment(dec);
  4651. if (!ASN1PERDecChar16String(dec, ((val)->nominatedInfo).length, &((val)->nominatedInfo).value, 16))
  4652. return 0;
  4653. }
  4654. if ((val)->o[0] & 0x40) {
  4655. if (!ASN1Dec_EndpointAddress(dec, &(val)->redirectingNr))
  4656. return 0;
  4657. }
  4658. if ((val)->o[0] & 0x20) {
  4659. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectingInfo).length))
  4660. return 0;
  4661. ((val)->redirectingInfo).length += 1;
  4662. ASN1PERDecAlignment(dec);
  4663. if (!ASN1PERDecChar16String(dec, ((val)->redirectingInfo).length, &((val)->redirectingInfo).value, 16))
  4664. return 0;
  4665. }
  4666. if ((val)->o[0] & 0x10) {
  4667. if (!ASN1Dec_DivertingLegInformation1Argument_extension(dec, &(val)->extension))
  4668. return 0;
  4669. }
  4670. if (y) {
  4671. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4672. return 0;
  4673. }
  4674. return 1;
  4675. }
  4676. static void ASN1CALL ASN1Free_DivertingLegInformation1Argument(DivertingLegInformation1Argument *val)
  4677. {
  4678. if (val) {
  4679. ASN1Free_EndpointAddress(&(val)->nominatedNr);
  4680. if ((val)->o[0] & 0x80) {
  4681. ASN1char16string_free(&(val)->nominatedInfo);
  4682. }
  4683. if ((val)->o[0] & 0x40) {
  4684. ASN1Free_EndpointAddress(&(val)->redirectingNr);
  4685. }
  4686. if ((val)->o[0] & 0x20) {
  4687. ASN1char16string_free(&(val)->redirectingInfo);
  4688. }
  4689. if ((val)->o[0] & 0x10) {
  4690. ASN1Free_DivertingLegInformation1Argument_extension(&(val)->extension);
  4691. }
  4692. }
  4693. }
  4694. static int ASN1CALL ASN1Enc_DivertingLegInformation2Argument(ASN1encoding_t enc, DivertingLegInformation2Argument *val)
  4695. {
  4696. if (!ASN1PEREncExtensionBitClear(enc))
  4697. return 0;
  4698. if (!ASN1PEREncBits(enc, 6, (val)->o))
  4699. return 0;
  4700. if (!ASN1PEREncBitVal(enc, 4, (val)->diversionCounter - 1))
  4701. return 0;
  4702. if (!ASN1PEREncExtensionBitClear(enc))
  4703. return 0;
  4704. if (!ASN1PEREncBitVal(enc, 2, (val)->diversionReason))
  4705. return 0;
  4706. if ((val)->o[0] & 0x80) {
  4707. if (!ASN1PEREncExtensionBitClear(enc))
  4708. return 0;
  4709. if (!ASN1PEREncBitVal(enc, 2, (val)->originalDiversionReason))
  4710. return 0;
  4711. }
  4712. if ((val)->o[0] & 0x40) {
  4713. if (!ASN1Enc_EndpointAddress(enc, &(val)->divertingNr))
  4714. return 0;
  4715. }
  4716. if ((val)->o[0] & 0x20) {
  4717. if (!ASN1Enc_EndpointAddress(enc, &(val)->originalCalledNr))
  4718. return 0;
  4719. }
  4720. if ((val)->o[0] & 0x10) {
  4721. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectingInfo).length - 1))
  4722. return 0;
  4723. ASN1PEREncAlignment(enc);
  4724. if (!ASN1PEREncChar16String(enc, ((val)->redirectingInfo).length, ((val)->redirectingInfo).value, 16))
  4725. return 0;
  4726. }
  4727. if ((val)->o[0] & 0x8) {
  4728. if (!ASN1PEREncBitVal(enc, 7, ((val)->originalCalledInfo).length - 1))
  4729. return 0;
  4730. ASN1PEREncAlignment(enc);
  4731. if (!ASN1PEREncChar16String(enc, ((val)->originalCalledInfo).length, ((val)->originalCalledInfo).value, 16))
  4732. return 0;
  4733. }
  4734. if ((val)->o[0] & 0x4) {
  4735. if (!ASN1Enc_DivertingLegInformation2Argument_extension(enc, &(val)->extension))
  4736. return 0;
  4737. }
  4738. return 1;
  4739. }
  4740. static int ASN1CALL ASN1Dec_DivertingLegInformation2Argument(ASN1decoding_t dec, DivertingLegInformation2Argument *val)
  4741. {
  4742. ASN1uint32_t y;
  4743. ASN1uint32_t x;
  4744. if (!ASN1PERDecExtensionBit(dec, &y))
  4745. return 0;
  4746. if (!ASN1PERDecExtension(dec, 6, (val)->o))
  4747. return 0;
  4748. if (!ASN1PERDecU16Val(dec, 4, &(val)->diversionCounter))
  4749. return 0;
  4750. (val)->diversionCounter += 1;
  4751. if (!ASN1PERDecExtensionBit(dec, &x))
  4752. return 0;
  4753. if (!x) {
  4754. if (!ASN1PERDecU32Val(dec, 2, &(val)->diversionReason))
  4755. return 0;
  4756. } else {
  4757. if (!ASN1PERDecSkipNormallySmall(dec))
  4758. return 0;
  4759. }
  4760. if ((val)->o[0] & 0x80) {
  4761. if (!ASN1PERDecExtensionBit(dec, &x))
  4762. return 0;
  4763. if (!x) {
  4764. if (!ASN1PERDecU32Val(dec, 2, &(val)->originalDiversionReason))
  4765. return 0;
  4766. } else {
  4767. if (!ASN1PERDecSkipNormallySmall(dec))
  4768. return 0;
  4769. }
  4770. }
  4771. if ((val)->o[0] & 0x40) {
  4772. if (!ASN1Dec_EndpointAddress(dec, &(val)->divertingNr))
  4773. return 0;
  4774. }
  4775. if ((val)->o[0] & 0x20) {
  4776. if (!ASN1Dec_EndpointAddress(dec, &(val)->originalCalledNr))
  4777. return 0;
  4778. }
  4779. if ((val)->o[0] & 0x10) {
  4780. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectingInfo).length))
  4781. return 0;
  4782. ((val)->redirectingInfo).length += 1;
  4783. ASN1PERDecAlignment(dec);
  4784. if (!ASN1PERDecChar16String(dec, ((val)->redirectingInfo).length, &((val)->redirectingInfo).value, 16))
  4785. return 0;
  4786. }
  4787. if ((val)->o[0] & 0x8) {
  4788. if (!ASN1PERDecU32Val(dec, 7, &((val)->originalCalledInfo).length))
  4789. return 0;
  4790. ((val)->originalCalledInfo).length += 1;
  4791. ASN1PERDecAlignment(dec);
  4792. if (!ASN1PERDecChar16String(dec, ((val)->originalCalledInfo).length, &((val)->originalCalledInfo).value, 16))
  4793. return 0;
  4794. }
  4795. if ((val)->o[0] & 0x4) {
  4796. if (!ASN1Dec_DivertingLegInformation2Argument_extension(dec, &(val)->extension))
  4797. return 0;
  4798. }
  4799. if (y) {
  4800. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4801. return 0;
  4802. }
  4803. return 1;
  4804. }
  4805. static void ASN1CALL ASN1Free_DivertingLegInformation2Argument(DivertingLegInformation2Argument *val)
  4806. {
  4807. if (val) {
  4808. if ((val)->o[0] & 0x40) {
  4809. ASN1Free_EndpointAddress(&(val)->divertingNr);
  4810. }
  4811. if ((val)->o[0] & 0x20) {
  4812. ASN1Free_EndpointAddress(&(val)->originalCalledNr);
  4813. }
  4814. if ((val)->o[0] & 0x10) {
  4815. ASN1char16string_free(&(val)->redirectingInfo);
  4816. }
  4817. if ((val)->o[0] & 0x8) {
  4818. ASN1char16string_free(&(val)->originalCalledInfo);
  4819. }
  4820. if ((val)->o[0] & 0x4) {
  4821. ASN1Free_DivertingLegInformation2Argument_extension(&(val)->extension);
  4822. }
  4823. }
  4824. }
  4825. static int ASN1CALL ASN1Enc_DivertingLegInformation3Argument(ASN1encoding_t enc, DivertingLegInformation3Argument *val)
  4826. {
  4827. if (!ASN1PEREncExtensionBitClear(enc))
  4828. return 0;
  4829. if (!ASN1PEREncBits(enc, 3, (val)->o))
  4830. return 0;
  4831. if (!ASN1PEREncBoolean(enc, (val)->presentationAllowedIndicator))
  4832. return 0;
  4833. if ((val)->o[0] & 0x80) {
  4834. if (!ASN1Enc_EndpointAddress(enc, &(val)->redirectionNr))
  4835. return 0;
  4836. }
  4837. if ((val)->o[0] & 0x40) {
  4838. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectionInfo).length - 1))
  4839. return 0;
  4840. ASN1PEREncAlignment(enc);
  4841. if (!ASN1PEREncChar16String(enc, ((val)->redirectionInfo).length, ((val)->redirectionInfo).value, 16))
  4842. return 0;
  4843. }
  4844. if ((val)->o[0] & 0x20) {
  4845. if (!ASN1Enc_DivertingLegInformation3Argument_extension(enc, &(val)->extension))
  4846. return 0;
  4847. }
  4848. return 1;
  4849. }
  4850. static int ASN1CALL ASN1Dec_DivertingLegInformation3Argument(ASN1decoding_t dec, DivertingLegInformation3Argument *val)
  4851. {
  4852. ASN1uint32_t y;
  4853. if (!ASN1PERDecExtensionBit(dec, &y))
  4854. return 0;
  4855. if (!ASN1PERDecExtension(dec, 3, (val)->o))
  4856. return 0;
  4857. if (!ASN1PERDecBoolean(dec, &(val)->presentationAllowedIndicator))
  4858. return 0;
  4859. if ((val)->o[0] & 0x80) {
  4860. if (!ASN1Dec_EndpointAddress(dec, &(val)->redirectionNr))
  4861. return 0;
  4862. }
  4863. if ((val)->o[0] & 0x40) {
  4864. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectionInfo).length))
  4865. return 0;
  4866. ((val)->redirectionInfo).length += 1;
  4867. ASN1PERDecAlignment(dec);
  4868. if (!ASN1PERDecChar16String(dec, ((val)->redirectionInfo).length, &((val)->redirectionInfo).value, 16))
  4869. return 0;
  4870. }
  4871. if ((val)->o[0] & 0x20) {
  4872. if (!ASN1Dec_DivertingLegInformation3Argument_extension(dec, &(val)->extension))
  4873. return 0;
  4874. }
  4875. if (y) {
  4876. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4877. return 0;
  4878. }
  4879. return 1;
  4880. }
  4881. static void ASN1CALL ASN1Free_DivertingLegInformation3Argument(DivertingLegInformation3Argument *val)
  4882. {
  4883. if (val) {
  4884. if ((val)->o[0] & 0x80) {
  4885. ASN1Free_EndpointAddress(&(val)->redirectionNr);
  4886. }
  4887. if ((val)->o[0] & 0x40) {
  4888. ASN1char16string_free(&(val)->redirectionInfo);
  4889. }
  4890. if ((val)->o[0] & 0x20) {
  4891. ASN1Free_DivertingLegInformation3Argument_extension(&(val)->extension);
  4892. }
  4893. }
  4894. }
  4895. static int ASN1CALL ASN1Enc_DivertingLegInformation4Argument(ASN1encoding_t enc, DivertingLegInformation4Argument *val)
  4896. {
  4897. if (!ASN1PEREncExtensionBitClear(enc))
  4898. return 0;
  4899. if (!ASN1PEREncBits(enc, 3, (val)->o))
  4900. return 0;
  4901. if (!ASN1PEREncExtensionBitClear(enc))
  4902. return 0;
  4903. if (!ASN1PEREncBitVal(enc, 2, (val)->diversionReason))
  4904. return 0;
  4905. if (!ASN1PEREncExtensionBitClear(enc))
  4906. return 0;
  4907. if (!ASN1PEREncBitVal(enc, 2, (val)->subscriptionOption))
  4908. return 0;
  4909. if (!ASN1Enc_EndpointAddress(enc, &(val)->callingNr))
  4910. return 0;
  4911. if ((val)->o[0] & 0x80) {
  4912. if (!ASN1PEREncBitVal(enc, 7, ((val)->callingInfo).length - 1))
  4913. return 0;
  4914. ASN1PEREncAlignment(enc);
  4915. if (!ASN1PEREncChar16String(enc, ((val)->callingInfo).length, ((val)->callingInfo).value, 16))
  4916. return 0;
  4917. }
  4918. if (!ASN1Enc_EndpointAddress(enc, &(val)->nominatedNr))
  4919. return 0;
  4920. if ((val)->o[0] & 0x40) {
  4921. if (!ASN1PEREncBitVal(enc, 7, ((val)->nominatedInfo).length - 1))
  4922. return 0;
  4923. ASN1PEREncAlignment(enc);
  4924. if (!ASN1PEREncChar16String(enc, ((val)->nominatedInfo).length, ((val)->nominatedInfo).value, 16))
  4925. return 0;
  4926. }
  4927. if ((val)->o[0] & 0x20) {
  4928. if (!ASN1Enc_DivertingLegInformation4Argument_extension(enc, &(val)->extension))
  4929. return 0;
  4930. }
  4931. return 1;
  4932. }
  4933. static int ASN1CALL ASN1Dec_DivertingLegInformation4Argument(ASN1decoding_t dec, DivertingLegInformation4Argument *val)
  4934. {
  4935. ASN1uint32_t y;
  4936. ASN1uint32_t x;
  4937. if (!ASN1PERDecExtensionBit(dec, &y))
  4938. return 0;
  4939. if (!ASN1PERDecExtension(dec, 3, (val)->o))
  4940. return 0;
  4941. if (!ASN1PERDecExtensionBit(dec, &x))
  4942. return 0;
  4943. if (!x) {
  4944. if (!ASN1PERDecU32Val(dec, 2, &(val)->diversionReason))
  4945. return 0;
  4946. } else {
  4947. if (!ASN1PERDecSkipNormallySmall(dec))
  4948. return 0;
  4949. }
  4950. if (!ASN1PERDecExtensionBit(dec, &x))
  4951. return 0;
  4952. if (!x) {
  4953. if (!ASN1PERDecU32Val(dec, 2, &(val)->subscriptionOption))
  4954. return 0;
  4955. } else {
  4956. if (!ASN1PERDecSkipNormallySmall(dec))
  4957. return 0;
  4958. }
  4959. if (!ASN1Dec_EndpointAddress(dec, &(val)->callingNr))
  4960. return 0;
  4961. if ((val)->o[0] & 0x80) {
  4962. if (!ASN1PERDecU32Val(dec, 7, &((val)->callingInfo).length))
  4963. return 0;
  4964. ((val)->callingInfo).length += 1;
  4965. ASN1PERDecAlignment(dec);
  4966. if (!ASN1PERDecChar16String(dec, ((val)->callingInfo).length, &((val)->callingInfo).value, 16))
  4967. return 0;
  4968. }
  4969. if (!ASN1Dec_EndpointAddress(dec, &(val)->nominatedNr))
  4970. return 0;
  4971. if ((val)->o[0] & 0x40) {
  4972. if (!ASN1PERDecU32Val(dec, 7, &((val)->nominatedInfo).length))
  4973. return 0;
  4974. ((val)->nominatedInfo).length += 1;
  4975. ASN1PERDecAlignment(dec);
  4976. if (!ASN1PERDecChar16String(dec, ((val)->nominatedInfo).length, &((val)->nominatedInfo).value, 16))
  4977. return 0;
  4978. }
  4979. if ((val)->o[0] & 0x20) {
  4980. if (!ASN1Dec_DivertingLegInformation4Argument_extension(dec, &(val)->extension))
  4981. return 0;
  4982. }
  4983. if (y) {
  4984. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  4985. return 0;
  4986. }
  4987. return 1;
  4988. }
  4989. static void ASN1CALL ASN1Free_DivertingLegInformation4Argument(DivertingLegInformation4Argument *val)
  4990. {
  4991. if (val) {
  4992. ASN1Free_EndpointAddress(&(val)->callingNr);
  4993. if ((val)->o[0] & 0x80) {
  4994. ASN1char16string_free(&(val)->callingInfo);
  4995. }
  4996. ASN1Free_EndpointAddress(&(val)->nominatedNr);
  4997. if ((val)->o[0] & 0x40) {
  4998. ASN1char16string_free(&(val)->nominatedInfo);
  4999. }
  5000. if ((val)->o[0] & 0x20) {
  5001. ASN1Free_DivertingLegInformation4Argument_extension(&(val)->extension);
  5002. }
  5003. }
  5004. }
  5005. static int ASN1CALL ASN1Enc_IntResult(ASN1encoding_t enc, IntResult *val)
  5006. {
  5007. ASN1octet_t o[1];
  5008. ASN1uint32_t u;
  5009. CopyMemory(o, (val)->o, 1);
  5010. if (!(val)->remoteEnabled)
  5011. o[0] &= ~0x80;
  5012. if (!ASN1PEREncExtensionBitClear(enc))
  5013. return 0;
  5014. if (!ASN1PEREncBits(enc, 2, o))
  5015. return 0;
  5016. if (!ASN1Enc_EndpointAddress(enc, &(val)->servedUserNr))
  5017. return 0;
  5018. switch ((val)->basicService) {
  5019. case 0:
  5020. u = 0;
  5021. break;
  5022. case 1:
  5023. u = 1;
  5024. break;
  5025. case 2:
  5026. u = 2;
  5027. break;
  5028. case 3:
  5029. u = 3;
  5030. break;
  5031. case 32:
  5032. u = 4;
  5033. break;
  5034. case 33:
  5035. u = 5;
  5036. break;
  5037. case 34:
  5038. u = 6;
  5039. break;
  5040. case 35:
  5041. u = 7;
  5042. break;
  5043. case 36:
  5044. u = 8;
  5045. break;
  5046. }
  5047. if (!ASN1PEREncExtensionBitClear(enc))
  5048. return 0;
  5049. if (!ASN1PEREncBitVal(enc, 4, u))
  5050. return 0;
  5051. if (!ASN1PEREncExtensionBitClear(enc))
  5052. return 0;
  5053. if (!ASN1PEREncBitVal(enc, 2, (val)->procedure))
  5054. return 0;
  5055. if (!ASN1Enc_EndpointAddress(enc, &(val)->divertedToAddress))
  5056. return 0;
  5057. if (o[0] & 0x80) {
  5058. if (!ASN1PEREncBoolean(enc, (val)->remoteEnabled))
  5059. return 0;
  5060. }
  5061. if (o[0] & 0x40) {
  5062. if (!ASN1Enc_IntResult_extension(enc, &(val)->extension))
  5063. return 0;
  5064. }
  5065. return 1;
  5066. }
  5067. static int ASN1CALL ASN1Dec_IntResult(ASN1decoding_t dec, IntResult *val)
  5068. {
  5069. ASN1uint32_t y;
  5070. ASN1uint32_t x;
  5071. ASN1uint32_t u;
  5072. if (!ASN1PERDecExtensionBit(dec, &y))
  5073. return 0;
  5074. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5075. return 0;
  5076. if (!ASN1Dec_EndpointAddress(dec, &(val)->servedUserNr))
  5077. return 0;
  5078. if (!ASN1PERDecExtensionBit(dec, &x))
  5079. return 0;
  5080. if (!x) {
  5081. if (!ASN1PERDecU32Val(dec, 4, &u))
  5082. return 0;
  5083. switch (u) {
  5084. case 0:
  5085. (val)->basicService = 0;
  5086. break;
  5087. case 1:
  5088. (val)->basicService = 1;
  5089. break;
  5090. case 2:
  5091. (val)->basicService = 2;
  5092. break;
  5093. case 3:
  5094. (val)->basicService = 3;
  5095. break;
  5096. case 4:
  5097. (val)->basicService = 32;
  5098. break;
  5099. case 5:
  5100. (val)->basicService = 33;
  5101. break;
  5102. case 6:
  5103. (val)->basicService = 34;
  5104. break;
  5105. case 7:
  5106. (val)->basicService = 35;
  5107. break;
  5108. case 8:
  5109. (val)->basicService = 36;
  5110. break;
  5111. }
  5112. } else {
  5113. if (!ASN1PERDecSkipNormallySmall(dec))
  5114. return 0;
  5115. }
  5116. if (!ASN1PERDecExtensionBit(dec, &x))
  5117. return 0;
  5118. if (!x) {
  5119. if (!ASN1PERDecU32Val(dec, 2, &(val)->procedure))
  5120. return 0;
  5121. } else {
  5122. if (!ASN1PERDecSkipNormallySmall(dec))
  5123. return 0;
  5124. }
  5125. if (!ASN1Dec_EndpointAddress(dec, &(val)->divertedToAddress))
  5126. return 0;
  5127. if ((val)->o[0] & 0x80) {
  5128. if (!ASN1PERDecBoolean(dec, &(val)->remoteEnabled))
  5129. return 0;
  5130. }
  5131. if ((val)->o[0] & 0x40) {
  5132. if (!ASN1Dec_IntResult_extension(dec, &(val)->extension))
  5133. return 0;
  5134. }
  5135. if (y) {
  5136. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5137. return 0;
  5138. }
  5139. if (!((val)->o[0] & 0x80))
  5140. (val)->remoteEnabled = 0;
  5141. return 1;
  5142. }
  5143. static void ASN1CALL ASN1Free_IntResult(IntResult *val)
  5144. {
  5145. if (val) {
  5146. ASN1Free_EndpointAddress(&(val)->servedUserNr);
  5147. ASN1Free_EndpointAddress(&(val)->divertedToAddress);
  5148. if ((val)->o[0] & 0x40) {
  5149. ASN1Free_IntResult_extension(&(val)->extension);
  5150. }
  5151. }
  5152. }
  5153. static ASN1stringtableentry_t CTInitiateArg_callIdentity_StringTableEntries[] = {
  5154. { 32, 32, 0 }, { 48, 57, 1 },
  5155. };
  5156. static ASN1stringtable_t CTInitiateArg_callIdentity_StringTable = {
  5157. 2, CTInitiateArg_callIdentity_StringTableEntries
  5158. };
  5159. static int ASN1CALL ASN1Enc_CTInitiateArg(ASN1encoding_t enc, CTInitiateArg *val)
  5160. {
  5161. ASN1uint32_t t;
  5162. if (!ASN1PEREncExtensionBitClear(enc))
  5163. return 0;
  5164. if (!ASN1PEREncBits(enc, 1, (val)->o))
  5165. return 0;
  5166. t = lstrlenA((val)->callIdentity);
  5167. if (!ASN1PEREncBitVal(enc, 3, t))
  5168. return 0;
  5169. //nik
  5170. if (t!=0) ASN1PEREncAlignment(enc);
  5171. if (!ASN1PEREncTableCharString(enc, t, (val)->callIdentity, 4, &CTInitiateArg_callIdentity_StringTable))
  5172. return 0;
  5173. if (!ASN1Enc_EndpointAddress(enc, &(val)->reroutingNumber))
  5174. return 0;
  5175. if ((val)->o[0] & 0x80) {
  5176. if (!ASN1Enc_CTInitiateArg_argumentExtension(enc, &(val)->argumentExtension))
  5177. return 0;
  5178. }
  5179. return 1;
  5180. }
  5181. static int ASN1CALL ASN1Dec_CTInitiateArg(ASN1decoding_t dec, CTInitiateArg *val)
  5182. {
  5183. ASN1uint32_t y;
  5184. ASN1uint32_t l;
  5185. if (!ASN1PERDecExtensionBit(dec, &y))
  5186. return 0;
  5187. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  5188. return 0;
  5189. if (!ASN1PERDecU32Val(dec, 3, &l))
  5190. return 0;
  5191. //nik
  5192. if (l!=0) ASN1PERDecAlignment(dec);
  5193. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->callIdentity, 4, &CTInitiateArg_callIdentity_StringTable))
  5194. return 0;
  5195. if (!ASN1Dec_EndpointAddress(dec, &(val)->reroutingNumber))
  5196. return 0;
  5197. if ((val)->o[0] & 0x80) {
  5198. if (!ASN1Dec_CTInitiateArg_argumentExtension(dec, &(val)->argumentExtension))
  5199. return 0;
  5200. }
  5201. if (y) {
  5202. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5203. return 0;
  5204. }
  5205. return 1;
  5206. }
  5207. static void ASN1CALL ASN1Free_CTInitiateArg(CTInitiateArg *val)
  5208. {
  5209. if (val) {
  5210. ASN1Free_EndpointAddress(&(val)->reroutingNumber);
  5211. if ((val)->o[0] & 0x80) {
  5212. ASN1Free_CTInitiateArg_argumentExtension(&(val)->argumentExtension);
  5213. }
  5214. }
  5215. }
  5216. static ASN1stringtableentry_t CTSetupArg_callIdentity_StringTableEntries[] = {
  5217. { 32, 32, 0 }, { 48, 57, 1 },
  5218. };
  5219. static ASN1stringtable_t CTSetupArg_callIdentity_StringTable = {
  5220. 2, CTSetupArg_callIdentity_StringTableEntries
  5221. };
  5222. static int ASN1CALL ASN1Enc_CTSetupArg(ASN1encoding_t enc, CTSetupArg *val)
  5223. {
  5224. ASN1uint32_t t;
  5225. if (!ASN1PEREncExtensionBitClear(enc))
  5226. return 0;
  5227. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5228. return 0;
  5229. t = lstrlenA((val)->callIdentity);
  5230. if (!ASN1PEREncBitVal(enc, 3, t))
  5231. return 0;
  5232. //nik
  5233. if (t!=0) ASN1PEREncAlignment(enc);
  5234. if (!ASN1PEREncTableCharString(enc, t, (val)->callIdentity, 4, &CTSetupArg_callIdentity_StringTable))
  5235. return 0;
  5236. if ((val)->o[0] & 0x80) {
  5237. if (!ASN1Enc_EndpointAddress(enc, &(val)->transferringNumber))
  5238. return 0;
  5239. }
  5240. if ((val)->o[0] & 0x40) {
  5241. if (!ASN1Enc_CTSetupArg_argumentExtension(enc, &(val)->argumentExtension))
  5242. return 0;
  5243. }
  5244. return 1;
  5245. }
  5246. static int ASN1CALL ASN1Dec_CTSetupArg(ASN1decoding_t dec, CTSetupArg *val)
  5247. {
  5248. ASN1uint32_t y;
  5249. ASN1uint32_t l;
  5250. if (!ASN1PERDecExtensionBit(dec, &y))
  5251. return 0;
  5252. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5253. return 0;
  5254. if (!ASN1PERDecU32Val(dec, 3, &l))
  5255. return 0;
  5256. //nik
  5257. if (l!=0) ASN1PERDecAlignment(dec);
  5258. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->callIdentity, 4, &CTSetupArg_callIdentity_StringTable))
  5259. return 0;
  5260. if ((val)->o[0] & 0x80) {
  5261. if (!ASN1Dec_EndpointAddress(dec, &(val)->transferringNumber))
  5262. return 0;
  5263. }
  5264. if ((val)->o[0] & 0x40) {
  5265. if (!ASN1Dec_CTSetupArg_argumentExtension(dec, &(val)->argumentExtension))
  5266. return 0;
  5267. }
  5268. if (y) {
  5269. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5270. return 0;
  5271. }
  5272. return 1;
  5273. }
  5274. static void ASN1CALL ASN1Free_CTSetupArg(CTSetupArg *val)
  5275. {
  5276. if (val) {
  5277. if ((val)->o[0] & 0x80) {
  5278. ASN1Free_EndpointAddress(&(val)->transferringNumber);
  5279. }
  5280. if ((val)->o[0] & 0x40) {
  5281. ASN1Free_CTSetupArg_argumentExtension(&(val)->argumentExtension);
  5282. }
  5283. }
  5284. }
  5285. static ASN1stringtableentry_t CTIdentifyRes_callIdentity_StringTableEntries[] = {
  5286. { 32, 32, 0 }, { 48, 57, 1 },
  5287. };
  5288. static ASN1stringtable_t CTIdentifyRes_callIdentity_StringTable = {
  5289. 2, CTIdentifyRes_callIdentity_StringTableEntries
  5290. };
  5291. static int ASN1CALL ASN1Enc_CTIdentifyRes(ASN1encoding_t enc, CTIdentifyRes *val)
  5292. {
  5293. ASN1uint32_t t;
  5294. if (!ASN1PEREncExtensionBitClear(enc))
  5295. return 0;
  5296. if (!ASN1PEREncBits(enc, 1, (val)->o))
  5297. return 0;
  5298. t = lstrlenA((val)->callIdentity);
  5299. if (!ASN1PEREncBitVal(enc, 3, t))
  5300. return 0;
  5301. //nik
  5302. if (t!=0) ASN1PEREncAlignment(enc);
  5303. if (!ASN1PEREncTableCharString(enc, t, (val)->callIdentity, 4, &CTIdentifyRes_callIdentity_StringTable))
  5304. return 0;
  5305. if (!ASN1Enc_EndpointAddress(enc, &(val)->reroutingNumber))
  5306. return 0;
  5307. if ((val)->o[0] & 0x80) {
  5308. if (!ASN1Enc_CTIdentifyRes_resultExtension(enc, &(val)->resultExtension))
  5309. return 0;
  5310. }
  5311. return 1;
  5312. }
  5313. static int ASN1CALL ASN1Dec_CTIdentifyRes(ASN1decoding_t dec, CTIdentifyRes *val)
  5314. {
  5315. ASN1uint32_t y;
  5316. ASN1uint32_t l;
  5317. if (!ASN1PERDecExtensionBit(dec, &y))
  5318. return 0;
  5319. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  5320. return 0;
  5321. if (!ASN1PERDecU32Val(dec, 3, &l))
  5322. return 0;
  5323. //nik
  5324. if (l!=0) ASN1PERDecAlignment(dec);
  5325. if (!ASN1PERDecZeroTableCharStringNoAlloc(dec, l, (val)->callIdentity, 4, &CTIdentifyRes_callIdentity_StringTable))
  5326. return 0;
  5327. if (!ASN1Dec_EndpointAddress(dec, &(val)->reroutingNumber))
  5328. return 0;
  5329. if ((val)->o[0] & 0x80) {
  5330. if (!ASN1Dec_CTIdentifyRes_resultExtension(dec, &(val)->resultExtension))
  5331. return 0;
  5332. }
  5333. if (y) {
  5334. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5335. return 0;
  5336. }
  5337. return 1;
  5338. }
  5339. static void ASN1CALL ASN1Free_CTIdentifyRes(CTIdentifyRes *val)
  5340. {
  5341. if (val) {
  5342. ASN1Free_EndpointAddress(&(val)->reroutingNumber);
  5343. if ((val)->o[0] & 0x80) {
  5344. ASN1Free_CTIdentifyRes_resultExtension(&(val)->resultExtension);
  5345. }
  5346. }
  5347. }
  5348. static int ASN1CALL ASN1Enc_CTUpdateArg(ASN1encoding_t enc, CTUpdateArg *val)
  5349. {
  5350. if (!ASN1PEREncExtensionBitClear(enc))
  5351. return 0;
  5352. if (!ASN1PEREncBits(enc, 3, (val)->o))
  5353. return 0;
  5354. if (!ASN1Enc_EndpointAddress(enc, &(val)->redirectionNumber))
  5355. return 0;
  5356. if ((val)->o[0] & 0x80) {
  5357. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectionInfo).length - 1))
  5358. return 0;
  5359. ASN1PEREncAlignment(enc);
  5360. if (!ASN1PEREncChar16String(enc, ((val)->redirectionInfo).length, ((val)->redirectionInfo).value, 16))
  5361. return 0;
  5362. }
  5363. if ((val)->o[0] & 0x40) {
  5364. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->basicCallInfoElements))
  5365. return 0;
  5366. }
  5367. if ((val)->o[0] & 0x20) {
  5368. if (!ASN1Enc_CTUpdateArg_argumentExtension(enc, &(val)->argumentExtension))
  5369. return 0;
  5370. }
  5371. return 1;
  5372. }
  5373. static int ASN1CALL ASN1Dec_CTUpdateArg(ASN1decoding_t dec, CTUpdateArg *val)
  5374. {
  5375. ASN1uint32_t y;
  5376. if (!ASN1PERDecExtensionBit(dec, &y))
  5377. return 0;
  5378. if (!ASN1PERDecExtension(dec, 3, (val)->o))
  5379. return 0;
  5380. if (!ASN1Dec_EndpointAddress(dec, &(val)->redirectionNumber))
  5381. return 0;
  5382. if ((val)->o[0] & 0x80) {
  5383. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectionInfo).length))
  5384. return 0;
  5385. ((val)->redirectionInfo).length += 1;
  5386. ASN1PERDecAlignment(dec);
  5387. if (!ASN1PERDecChar16String(dec, ((val)->redirectionInfo).length, &((val)->redirectionInfo).value, 16))
  5388. return 0;
  5389. }
  5390. if ((val)->o[0] & 0x40) {
  5391. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->basicCallInfoElements))
  5392. return 0;
  5393. }
  5394. if ((val)->o[0] & 0x20) {
  5395. if (!ASN1Dec_CTUpdateArg_argumentExtension(dec, &(val)->argumentExtension))
  5396. return 0;
  5397. }
  5398. if (y) {
  5399. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5400. return 0;
  5401. }
  5402. return 1;
  5403. }
  5404. static void ASN1CALL ASN1Free_CTUpdateArg(CTUpdateArg *val)
  5405. {
  5406. if (val) {
  5407. ASN1Free_EndpointAddress(&(val)->redirectionNumber);
  5408. if ((val)->o[0] & 0x80) {
  5409. ASN1char16string_free(&(val)->redirectionInfo);
  5410. }
  5411. if ((val)->o[0] & 0x40) {
  5412. ASN1octetstring_free(&(val)->basicCallInfoElements);
  5413. }
  5414. if ((val)->o[0] & 0x20) {
  5415. ASN1Free_CTUpdateArg_argumentExtension(&(val)->argumentExtension);
  5416. }
  5417. }
  5418. }
  5419. static int ASN1CALL ASN1Enc_CTCompleteArg(ASN1encoding_t enc, CTCompleteArg *val)
  5420. {
  5421. ASN1octet_t o[1];
  5422. CopyMemory(o, (val)->o, 1);
  5423. if ((val)->callStatus == 0)
  5424. o[0] &= ~0x20;
  5425. if (!ASN1PEREncExtensionBitClear(enc))
  5426. return 0;
  5427. if (!ASN1PEREncBits(enc, 4, o))
  5428. return 0;
  5429. if (!ASN1PEREncExtensionBitClear(enc))
  5430. return 0;
  5431. if (!ASN1PEREncBitVal(enc, 1, (val)->endDesignation))
  5432. return 0;
  5433. if (!ASN1Enc_EndpointAddress(enc, &(val)->redirectionNumber))
  5434. return 0;
  5435. if (o[0] & 0x80) {
  5436. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->basicCallInfoElements))
  5437. return 0;
  5438. }
  5439. if (o[0] & 0x40) {
  5440. if (!ASN1PEREncBitVal(enc, 7, ((val)->redirectionInfo).length - 1))
  5441. return 0;
  5442. ASN1PEREncAlignment(enc);
  5443. if (!ASN1PEREncChar16String(enc, ((val)->redirectionInfo).length, ((val)->redirectionInfo).value, 16))
  5444. return 0;
  5445. }
  5446. if (o[0] & 0x20) {
  5447. if (!ASN1PEREncExtensionBitClear(enc))
  5448. return 0;
  5449. if (!ASN1PEREncBitVal(enc, 1, (val)->callStatus))
  5450. return 0;
  5451. }
  5452. if (o[0] & 0x10) {
  5453. if (!ASN1Enc_CTCompleteArg_argumentExtension(enc, &(val)->argumentExtension))
  5454. return 0;
  5455. }
  5456. return 1;
  5457. }
  5458. static int ASN1CALL ASN1Dec_CTCompleteArg(ASN1decoding_t dec, CTCompleteArg *val)
  5459. {
  5460. ASN1uint32_t y;
  5461. ASN1uint32_t x;
  5462. if (!ASN1PERDecExtensionBit(dec, &y))
  5463. return 0;
  5464. if (!ASN1PERDecExtension(dec, 4, (val)->o))
  5465. return 0;
  5466. if (!ASN1PERDecExtensionBit(dec, &x))
  5467. return 0;
  5468. if (!x) {
  5469. if (!ASN1PERDecU32Val(dec, 1, &(val)->endDesignation))
  5470. return 0;
  5471. } else {
  5472. if (!ASN1PERDecSkipNormallySmall(dec))
  5473. return 0;
  5474. }
  5475. if (!ASN1Dec_EndpointAddress(dec, &(val)->redirectionNumber))
  5476. return 0;
  5477. if ((val)->o[0] & 0x80) {
  5478. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->basicCallInfoElements))
  5479. return 0;
  5480. }
  5481. if ((val)->o[0] & 0x40) {
  5482. if (!ASN1PERDecU32Val(dec, 7, &((val)->redirectionInfo).length))
  5483. return 0;
  5484. ((val)->redirectionInfo).length += 1;
  5485. ASN1PERDecAlignment(dec);
  5486. if (!ASN1PERDecChar16String(dec, ((val)->redirectionInfo).length, &((val)->redirectionInfo).value, 16))
  5487. return 0;
  5488. }
  5489. if ((val)->o[0] & 0x20) {
  5490. if (!ASN1PERDecExtensionBit(dec, &x))
  5491. return 0;
  5492. if (!x) {
  5493. if (!ASN1PERDecU32Val(dec, 1, &(val)->callStatus))
  5494. return 0;
  5495. } else {
  5496. if (!ASN1PERDecSkipNormallySmall(dec))
  5497. return 0;
  5498. }
  5499. }
  5500. if ((val)->o[0] & 0x10) {
  5501. if (!ASN1Dec_CTCompleteArg_argumentExtension(dec, &(val)->argumentExtension))
  5502. return 0;
  5503. }
  5504. if (y) {
  5505. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5506. return 0;
  5507. }
  5508. if (!((val)->o[0] & 0x20))
  5509. (val)->callStatus = 0;
  5510. return 1;
  5511. }
  5512. static void ASN1CALL ASN1Free_CTCompleteArg(CTCompleteArg *val)
  5513. {
  5514. if (val) {
  5515. ASN1Free_EndpointAddress(&(val)->redirectionNumber);
  5516. if ((val)->o[0] & 0x80) {
  5517. ASN1octetstring_free(&(val)->basicCallInfoElements);
  5518. }
  5519. if ((val)->o[0] & 0x40) {
  5520. ASN1char16string_free(&(val)->redirectionInfo);
  5521. }
  5522. if ((val)->o[0] & 0x10) {
  5523. ASN1Free_CTCompleteArg_argumentExtension(&(val)->argumentExtension);
  5524. }
  5525. }
  5526. }
  5527. static int ASN1CALL ASN1Enc_CTActiveArg(ASN1encoding_t enc, CTActiveArg *val)
  5528. {
  5529. if (!ASN1PEREncExtensionBitClear(enc))
  5530. return 0;
  5531. if (!ASN1PEREncBits(enc, 3, (val)->o))
  5532. return 0;
  5533. if (!ASN1Enc_EndpointAddress(enc, &(val)->connectedAddress))
  5534. return 0;
  5535. if ((val)->o[0] & 0x80) {
  5536. if (!ASN1PEREncOctetString_NoSize(enc, &(val)->basicCallInfoElements))
  5537. return 0;
  5538. }
  5539. if ((val)->o[0] & 0x40) {
  5540. if (!ASN1PEREncBitVal(enc, 7, ((val)->connectedInfo).length - 1))
  5541. return 0;
  5542. ASN1PEREncAlignment(enc);
  5543. if (!ASN1PEREncChar16String(enc, ((val)->connectedInfo).length, ((val)->connectedInfo).value, 16))
  5544. return 0;
  5545. }
  5546. if ((val)->o[0] & 0x20) {
  5547. if (!ASN1Enc_CTActiveArg_argumentExtension(enc, &(val)->argumentExtension))
  5548. return 0;
  5549. }
  5550. return 1;
  5551. }
  5552. static int ASN1CALL ASN1Dec_CTActiveArg(ASN1decoding_t dec, CTActiveArg *val)
  5553. {
  5554. ASN1uint32_t y;
  5555. if (!ASN1PERDecExtensionBit(dec, &y))
  5556. return 0;
  5557. if (!ASN1PERDecExtension(dec, 3, (val)->o))
  5558. return 0;
  5559. if (!ASN1Dec_EndpointAddress(dec, &(val)->connectedAddress))
  5560. return 0;
  5561. if ((val)->o[0] & 0x80) {
  5562. if (!ASN1PERDecOctetString_NoSize(dec, &(val)->basicCallInfoElements))
  5563. return 0;
  5564. }
  5565. if ((val)->o[0] & 0x40) {
  5566. if (!ASN1PERDecU32Val(dec, 7, &((val)->connectedInfo).length))
  5567. return 0;
  5568. ((val)->connectedInfo).length += 1;
  5569. ASN1PERDecAlignment(dec);
  5570. if (!ASN1PERDecChar16String(dec, ((val)->connectedInfo).length, &((val)->connectedInfo).value, 16))
  5571. return 0;
  5572. }
  5573. if ((val)->o[0] & 0x20) {
  5574. if (!ASN1Dec_CTActiveArg_argumentExtension(dec, &(val)->argumentExtension))
  5575. return 0;
  5576. }
  5577. if (y) {
  5578. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5579. return 0;
  5580. }
  5581. return 1;
  5582. }
  5583. static void ASN1CALL ASN1Free_CTActiveArg(CTActiveArg *val)
  5584. {
  5585. if (val) {
  5586. ASN1Free_EndpointAddress(&(val)->connectedAddress);
  5587. if ((val)->o[0] & 0x80) {
  5588. ASN1octetstring_free(&(val)->basicCallInfoElements);
  5589. }
  5590. if ((val)->o[0] & 0x40) {
  5591. ASN1char16string_free(&(val)->connectedInfo);
  5592. }
  5593. if ((val)->o[0] & 0x20) {
  5594. ASN1Free_CTActiveArg_argumentExtension(&(val)->argumentExtension);
  5595. }
  5596. }
  5597. }
  5598. static int ASN1CALL ASN1Enc_CpRequestArg(ASN1encoding_t enc, CpRequestArg *val)
  5599. {
  5600. if (!ASN1PEREncExtensionBitClear(enc))
  5601. return 0;
  5602. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5603. return 0;
  5604. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkingNumber))
  5605. return 0;
  5606. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedNumber))
  5607. return 0;
  5608. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedToNumber))
  5609. return 0;
  5610. if ((val)->o[0] & 0x80) {
  5611. if (!ASN1PEREncUnsignedShort(enc, (val)->parkedToPosition))
  5612. return 0;
  5613. }
  5614. if ((val)->o[0] & 0x40) {
  5615. if (!ASN1Enc_CpRequestArg_extensionArg(enc, &(val)->extensionArg))
  5616. return 0;
  5617. }
  5618. return 1;
  5619. }
  5620. static int ASN1CALL ASN1Dec_CpRequestArg(ASN1decoding_t dec, CpRequestArg *val)
  5621. {
  5622. ASN1uint32_t y;
  5623. if (!ASN1PERDecExtensionBit(dec, &y))
  5624. return 0;
  5625. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5626. return 0;
  5627. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkingNumber))
  5628. return 0;
  5629. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedNumber))
  5630. return 0;
  5631. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedToNumber))
  5632. return 0;
  5633. if ((val)->o[0] & 0x80) {
  5634. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkedToPosition))
  5635. return 0;
  5636. }
  5637. if ((val)->o[0] & 0x40) {
  5638. if (!ASN1Dec_CpRequestArg_extensionArg(dec, &(val)->extensionArg))
  5639. return 0;
  5640. }
  5641. if (y) {
  5642. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5643. return 0;
  5644. }
  5645. return 1;
  5646. }
  5647. static void ASN1CALL ASN1Free_CpRequestArg(CpRequestArg *val)
  5648. {
  5649. if (val) {
  5650. ASN1Free_EndpointAddress(&(val)->parkingNumber);
  5651. ASN1Free_EndpointAddress(&(val)->parkedNumber);
  5652. ASN1Free_EndpointAddress(&(val)->parkedToNumber);
  5653. if ((val)->o[0] & 0x40) {
  5654. ASN1Free_CpRequestArg_extensionArg(&(val)->extensionArg);
  5655. }
  5656. }
  5657. }
  5658. static int ASN1CALL ASN1Enc_CpRequestRes(ASN1encoding_t enc, CpRequestRes *val)
  5659. {
  5660. if (!ASN1PEREncExtensionBitClear(enc))
  5661. return 0;
  5662. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5663. return 0;
  5664. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedToNumber))
  5665. return 0;
  5666. if ((val)->o[0] & 0x80) {
  5667. if (!ASN1PEREncUnsignedShort(enc, (val)->parkedToPosition))
  5668. return 0;
  5669. }
  5670. if (!ASN1PEREncExtensionBitClear(enc))
  5671. return 0;
  5672. if (!ASN1PEREncBitVal(enc, 2, (val)->parkCondition))
  5673. return 0;
  5674. if ((val)->o[0] & 0x40) {
  5675. if (!ASN1Enc_CpRequestRes_extensionRes(enc, &(val)->extensionRes))
  5676. return 0;
  5677. }
  5678. return 1;
  5679. }
  5680. static int ASN1CALL ASN1Dec_CpRequestRes(ASN1decoding_t dec, CpRequestRes *val)
  5681. {
  5682. ASN1uint32_t y;
  5683. ASN1uint32_t x;
  5684. if (!ASN1PERDecExtensionBit(dec, &y))
  5685. return 0;
  5686. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5687. return 0;
  5688. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedToNumber))
  5689. return 0;
  5690. if ((val)->o[0] & 0x80) {
  5691. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkedToPosition))
  5692. return 0;
  5693. }
  5694. if (!ASN1PERDecExtensionBit(dec, &x))
  5695. return 0;
  5696. if (!x) {
  5697. if (!ASN1PERDecU32Val(dec, 2, &(val)->parkCondition))
  5698. return 0;
  5699. } else {
  5700. if (!ASN1PERDecSkipNormallySmall(dec))
  5701. return 0;
  5702. }
  5703. if ((val)->o[0] & 0x40) {
  5704. if (!ASN1Dec_CpRequestRes_extensionRes(dec, &(val)->extensionRes))
  5705. return 0;
  5706. }
  5707. if (y) {
  5708. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5709. return 0;
  5710. }
  5711. return 1;
  5712. }
  5713. static void ASN1CALL ASN1Free_CpRequestRes(CpRequestRes *val)
  5714. {
  5715. if (val) {
  5716. ASN1Free_EndpointAddress(&(val)->parkedToNumber);
  5717. if ((val)->o[0] & 0x40) {
  5718. ASN1Free_CpRequestRes_extensionRes(&(val)->extensionRes);
  5719. }
  5720. }
  5721. }
  5722. static int ASN1CALL ASN1Enc_CpSetupArg(ASN1encoding_t enc, CpSetupArg *val)
  5723. {
  5724. if (!ASN1PEREncExtensionBitClear(enc))
  5725. return 0;
  5726. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5727. return 0;
  5728. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkingNumber))
  5729. return 0;
  5730. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedNumber))
  5731. return 0;
  5732. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedToNumber))
  5733. return 0;
  5734. if ((val)->o[0] & 0x80) {
  5735. if (!ASN1PEREncUnsignedShort(enc, (val)->parkedToPosition))
  5736. return 0;
  5737. }
  5738. if ((val)->o[0] & 0x40) {
  5739. if (!ASN1Enc_CpSetupArg_extensionArg(enc, &(val)->extensionArg))
  5740. return 0;
  5741. }
  5742. return 1;
  5743. }
  5744. static int ASN1CALL ASN1Dec_CpSetupArg(ASN1decoding_t dec, CpSetupArg *val)
  5745. {
  5746. ASN1uint32_t y;
  5747. if (!ASN1PERDecExtensionBit(dec, &y))
  5748. return 0;
  5749. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5750. return 0;
  5751. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkingNumber))
  5752. return 0;
  5753. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedNumber))
  5754. return 0;
  5755. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedToNumber))
  5756. return 0;
  5757. if ((val)->o[0] & 0x80) {
  5758. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkedToPosition))
  5759. return 0;
  5760. }
  5761. if ((val)->o[0] & 0x40) {
  5762. if (!ASN1Dec_CpSetupArg_extensionArg(dec, &(val)->extensionArg))
  5763. return 0;
  5764. }
  5765. if (y) {
  5766. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5767. return 0;
  5768. }
  5769. return 1;
  5770. }
  5771. static void ASN1CALL ASN1Free_CpSetupArg(CpSetupArg *val)
  5772. {
  5773. if (val) {
  5774. ASN1Free_EndpointAddress(&(val)->parkingNumber);
  5775. ASN1Free_EndpointAddress(&(val)->parkedNumber);
  5776. ASN1Free_EndpointAddress(&(val)->parkedToNumber);
  5777. if ((val)->o[0] & 0x40) {
  5778. ASN1Free_CpSetupArg_extensionArg(&(val)->extensionArg);
  5779. }
  5780. }
  5781. }
  5782. static int ASN1CALL ASN1Enc_CpSetupRes(ASN1encoding_t enc, CpSetupRes *val)
  5783. {
  5784. if (!ASN1PEREncExtensionBitClear(enc))
  5785. return 0;
  5786. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5787. return 0;
  5788. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkedToNumber))
  5789. return 0;
  5790. if ((val)->o[0] & 0x80) {
  5791. if (!ASN1PEREncUnsignedShort(enc, (val)->parkedToPosition))
  5792. return 0;
  5793. }
  5794. if (!ASN1PEREncExtensionBitClear(enc))
  5795. return 0;
  5796. if (!ASN1PEREncBitVal(enc, 2, (val)->parkCondition))
  5797. return 0;
  5798. if ((val)->o[0] & 0x40) {
  5799. if (!ASN1Enc_CpSetupRes_extensionRes(enc, &(val)->extensionRes))
  5800. return 0;
  5801. }
  5802. return 1;
  5803. }
  5804. static int ASN1CALL ASN1Dec_CpSetupRes(ASN1decoding_t dec, CpSetupRes *val)
  5805. {
  5806. ASN1uint32_t y;
  5807. ASN1uint32_t x;
  5808. if (!ASN1PERDecExtensionBit(dec, &y))
  5809. return 0;
  5810. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5811. return 0;
  5812. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkedToNumber))
  5813. return 0;
  5814. if ((val)->o[0] & 0x80) {
  5815. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkedToPosition))
  5816. return 0;
  5817. }
  5818. if (!ASN1PERDecExtensionBit(dec, &x))
  5819. return 0;
  5820. if (!x) {
  5821. if (!ASN1PERDecU32Val(dec, 2, &(val)->parkCondition))
  5822. return 0;
  5823. } else {
  5824. if (!ASN1PERDecSkipNormallySmall(dec))
  5825. return 0;
  5826. }
  5827. if ((val)->o[0] & 0x40) {
  5828. if (!ASN1Dec_CpSetupRes_extensionRes(dec, &(val)->extensionRes))
  5829. return 0;
  5830. }
  5831. if (y) {
  5832. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5833. return 0;
  5834. }
  5835. return 1;
  5836. }
  5837. static void ASN1CALL ASN1Free_CpSetupRes(CpSetupRes *val)
  5838. {
  5839. if (val) {
  5840. ASN1Free_EndpointAddress(&(val)->parkedToNumber);
  5841. if ((val)->o[0] & 0x40) {
  5842. ASN1Free_CpSetupRes_extensionRes(&(val)->extensionRes);
  5843. }
  5844. }
  5845. }
  5846. static int ASN1CALL ASN1Enc_GroupIndicationOnArg(ASN1encoding_t enc, GroupIndicationOnArg *val)
  5847. {
  5848. if (!ASN1PEREncExtensionBitClear(enc))
  5849. return 0;
  5850. if (!ASN1PEREncBits(enc, 2, (val)->o))
  5851. return 0;
  5852. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  5853. return 0;
  5854. if (!ASN1Enc_EndpointAddress(enc, &(val)->groupMemberUserNr))
  5855. return 0;
  5856. if (!ASN1PEREncExtensionBitClear(enc))
  5857. return 0;
  5858. if (!ASN1PEREncBitVal(enc, 1, (val)->retrieveCallType))
  5859. return 0;
  5860. if (!ASN1Enc_EndpointAddress(enc, &(val)->partyToRetrieve))
  5861. return 0;
  5862. if (!ASN1Enc_EndpointAddress(enc, &(val)->retrieveAddress))
  5863. return 0;
  5864. if ((val)->o[0] & 0x80) {
  5865. if (!ASN1PEREncUnsignedShort(enc, (val)->parkPosition))
  5866. return 0;
  5867. }
  5868. if ((val)->o[0] & 0x40) {
  5869. if (!ASN1Enc_GroupIndicationOnArg_extensionArg(enc, &(val)->extensionArg))
  5870. return 0;
  5871. }
  5872. return 1;
  5873. }
  5874. static int ASN1CALL ASN1Dec_GroupIndicationOnArg(ASN1decoding_t dec, GroupIndicationOnArg *val)
  5875. {
  5876. ASN1uint32_t y;
  5877. ASN1uint32_t x;
  5878. if (!ASN1PERDecExtensionBit(dec, &y))
  5879. return 0;
  5880. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  5881. return 0;
  5882. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  5883. return 0;
  5884. if (!ASN1Dec_EndpointAddress(dec, &(val)->groupMemberUserNr))
  5885. return 0;
  5886. if (!ASN1PERDecExtensionBit(dec, &x))
  5887. return 0;
  5888. if (!x) {
  5889. if (!ASN1PERDecU32Val(dec, 1, &(val)->retrieveCallType))
  5890. return 0;
  5891. } else {
  5892. if (!ASN1PERDecSkipNormallySmall(dec))
  5893. return 0;
  5894. }
  5895. if (!ASN1Dec_EndpointAddress(dec, &(val)->partyToRetrieve))
  5896. return 0;
  5897. if (!ASN1Dec_EndpointAddress(dec, &(val)->retrieveAddress))
  5898. return 0;
  5899. if ((val)->o[0] & 0x80) {
  5900. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkPosition))
  5901. return 0;
  5902. }
  5903. if ((val)->o[0] & 0x40) {
  5904. if (!ASN1Dec_GroupIndicationOnArg_extensionArg(dec, &(val)->extensionArg))
  5905. return 0;
  5906. }
  5907. if (y) {
  5908. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5909. return 0;
  5910. }
  5911. return 1;
  5912. }
  5913. static void ASN1CALL ASN1Free_GroupIndicationOnArg(GroupIndicationOnArg *val)
  5914. {
  5915. if (val) {
  5916. ASN1Free_CallIdentifier(&(val)->callPickupId);
  5917. ASN1Free_EndpointAddress(&(val)->groupMemberUserNr);
  5918. ASN1Free_EndpointAddress(&(val)->partyToRetrieve);
  5919. ASN1Free_EndpointAddress(&(val)->retrieveAddress);
  5920. if ((val)->o[0] & 0x40) {
  5921. ASN1Free_GroupIndicationOnArg_extensionArg(&(val)->extensionArg);
  5922. }
  5923. }
  5924. }
  5925. static int ASN1CALL ASN1Enc_GroupIndicationOffArg(ASN1encoding_t enc, GroupIndicationOffArg *val)
  5926. {
  5927. if (!ASN1PEREncExtensionBitClear(enc))
  5928. return 0;
  5929. if (!ASN1PEREncBits(enc, 1, (val)->o))
  5930. return 0;
  5931. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  5932. return 0;
  5933. if (!ASN1Enc_EndpointAddress(enc, &(val)->groupMemberUserNr))
  5934. return 0;
  5935. if ((val)->o[0] & 0x80) {
  5936. if (!ASN1Enc_GroupIndicationOffArg_extensionArg(enc, &(val)->extensionArg))
  5937. return 0;
  5938. }
  5939. return 1;
  5940. }
  5941. static int ASN1CALL ASN1Dec_GroupIndicationOffArg(ASN1decoding_t dec, GroupIndicationOffArg *val)
  5942. {
  5943. ASN1uint32_t y;
  5944. if (!ASN1PERDecExtensionBit(dec, &y))
  5945. return 0;
  5946. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  5947. return 0;
  5948. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  5949. return 0;
  5950. if (!ASN1Dec_EndpointAddress(dec, &(val)->groupMemberUserNr))
  5951. return 0;
  5952. if ((val)->o[0] & 0x80) {
  5953. if (!ASN1Dec_GroupIndicationOffArg_extensionArg(dec, &(val)->extensionArg))
  5954. return 0;
  5955. }
  5956. if (y) {
  5957. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  5958. return 0;
  5959. }
  5960. return 1;
  5961. }
  5962. static void ASN1CALL ASN1Free_GroupIndicationOffArg(GroupIndicationOffArg *val)
  5963. {
  5964. if (val) {
  5965. ASN1Free_CallIdentifier(&(val)->callPickupId);
  5966. ASN1Free_EndpointAddress(&(val)->groupMemberUserNr);
  5967. if ((val)->o[0] & 0x80) {
  5968. ASN1Free_GroupIndicationOffArg_extensionArg(&(val)->extensionArg);
  5969. }
  5970. }
  5971. }
  5972. static int ASN1CALL ASN1Enc_PickrequArg(ASN1encoding_t enc, PickrequArg *val)
  5973. {
  5974. if (!ASN1PEREncExtensionBitClear(enc))
  5975. return 0;
  5976. if (!ASN1PEREncBits(enc, 4, (val)->o))
  5977. return 0;
  5978. if (!ASN1Enc_EndpointAddress(enc, &(val)->picking_upNumber))
  5979. return 0;
  5980. if ((val)->o[0] & 0x80) {
  5981. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  5982. return 0;
  5983. }
  5984. if ((val)->o[0] & 0x40) {
  5985. if (!ASN1Enc_EndpointAddress(enc, &(val)->partyToRetrieve))
  5986. return 0;
  5987. }
  5988. if (!ASN1Enc_EndpointAddress(enc, &(val)->retrieveAddress))
  5989. return 0;
  5990. if ((val)->o[0] & 0x20) {
  5991. if (!ASN1PEREncUnsignedShort(enc, (val)->parkPosition))
  5992. return 0;
  5993. }
  5994. if ((val)->o[0] & 0x10) {
  5995. if (!ASN1Enc_PickrequArg_extensionArg(enc, &(val)->extensionArg))
  5996. return 0;
  5997. }
  5998. return 1;
  5999. }
  6000. static int ASN1CALL ASN1Dec_PickrequArg(ASN1decoding_t dec, PickrequArg *val)
  6001. {
  6002. ASN1uint32_t y;
  6003. if (!ASN1PERDecExtensionBit(dec, &y))
  6004. return 0;
  6005. if (!ASN1PERDecExtension(dec, 4, (val)->o))
  6006. return 0;
  6007. if (!ASN1Dec_EndpointAddress(dec, &(val)->picking_upNumber))
  6008. return 0;
  6009. if ((val)->o[0] & 0x80) {
  6010. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  6011. return 0;
  6012. }
  6013. if ((val)->o[0] & 0x40) {
  6014. if (!ASN1Dec_EndpointAddress(dec, &(val)->partyToRetrieve))
  6015. return 0;
  6016. }
  6017. if (!ASN1Dec_EndpointAddress(dec, &(val)->retrieveAddress))
  6018. return 0;
  6019. if ((val)->o[0] & 0x20) {
  6020. if (!ASN1PERDecUnsignedShort(dec, &(val)->parkPosition))
  6021. return 0;
  6022. }
  6023. if ((val)->o[0] & 0x10) {
  6024. if (!ASN1Dec_PickrequArg_extensionArg(dec, &(val)->extensionArg))
  6025. return 0;
  6026. }
  6027. if (y) {
  6028. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6029. return 0;
  6030. }
  6031. return 1;
  6032. }
  6033. static void ASN1CALL ASN1Free_PickrequArg(PickrequArg *val)
  6034. {
  6035. if (val) {
  6036. ASN1Free_EndpointAddress(&(val)->picking_upNumber);
  6037. if ((val)->o[0] & 0x80) {
  6038. ASN1Free_CallIdentifier(&(val)->callPickupId);
  6039. }
  6040. if ((val)->o[0] & 0x40) {
  6041. ASN1Free_EndpointAddress(&(val)->partyToRetrieve);
  6042. }
  6043. ASN1Free_EndpointAddress(&(val)->retrieveAddress);
  6044. if ((val)->o[0] & 0x10) {
  6045. ASN1Free_PickrequArg_extensionArg(&(val)->extensionArg);
  6046. }
  6047. }
  6048. }
  6049. static int ASN1CALL ASN1Enc_PickupArg(ASN1encoding_t enc, PickupArg *val)
  6050. {
  6051. if (!ASN1PEREncExtensionBitClear(enc))
  6052. return 0;
  6053. if (!ASN1PEREncBits(enc, 1, (val)->o))
  6054. return 0;
  6055. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  6056. return 0;
  6057. if (!ASN1Enc_EndpointAddress(enc, &(val)->picking_upNumber))
  6058. return 0;
  6059. if ((val)->o[0] & 0x80) {
  6060. if (!ASN1Enc_PickupArg_extensionArg(enc, &(val)->extensionArg))
  6061. return 0;
  6062. }
  6063. return 1;
  6064. }
  6065. static int ASN1CALL ASN1Dec_PickupArg(ASN1decoding_t dec, PickupArg *val)
  6066. {
  6067. ASN1uint32_t y;
  6068. if (!ASN1PERDecExtensionBit(dec, &y))
  6069. return 0;
  6070. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  6071. return 0;
  6072. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  6073. return 0;
  6074. if (!ASN1Dec_EndpointAddress(dec, &(val)->picking_upNumber))
  6075. return 0;
  6076. if ((val)->o[0] & 0x80) {
  6077. if (!ASN1Dec_PickupArg_extensionArg(dec, &(val)->extensionArg))
  6078. return 0;
  6079. }
  6080. if (y) {
  6081. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6082. return 0;
  6083. }
  6084. return 1;
  6085. }
  6086. static void ASN1CALL ASN1Free_PickupArg(PickupArg *val)
  6087. {
  6088. if (val) {
  6089. ASN1Free_CallIdentifier(&(val)->callPickupId);
  6090. ASN1Free_EndpointAddress(&(val)->picking_upNumber);
  6091. if ((val)->o[0] & 0x80) {
  6092. ASN1Free_PickupArg_extensionArg(&(val)->extensionArg);
  6093. }
  6094. }
  6095. }
  6096. static int ASN1CALL ASN1Enc_PickExeArg(ASN1encoding_t enc, PickExeArg *val)
  6097. {
  6098. if (!ASN1PEREncExtensionBitClear(enc))
  6099. return 0;
  6100. if (!ASN1PEREncBits(enc, 1, (val)->o))
  6101. return 0;
  6102. if (!ASN1Enc_CallIdentifier(enc, &(val)->callPickupId))
  6103. return 0;
  6104. if (!ASN1Enc_EndpointAddress(enc, &(val)->picking_upNumber))
  6105. return 0;
  6106. if (!ASN1Enc_EndpointAddress(enc, &(val)->partyToRetrieve))
  6107. return 0;
  6108. if ((val)->o[0] & 0x80) {
  6109. if (!ASN1Enc_PickExeArg_extensionArg(enc, &(val)->extensionArg))
  6110. return 0;
  6111. }
  6112. return 1;
  6113. }
  6114. static int ASN1CALL ASN1Dec_PickExeArg(ASN1decoding_t dec, PickExeArg *val)
  6115. {
  6116. ASN1uint32_t y;
  6117. if (!ASN1PERDecExtensionBit(dec, &y))
  6118. return 0;
  6119. if (!ASN1PERDecExtension(dec, 1, (val)->o))
  6120. return 0;
  6121. if (!ASN1Dec_CallIdentifier(dec, &(val)->callPickupId))
  6122. return 0;
  6123. if (!ASN1Dec_EndpointAddress(dec, &(val)->picking_upNumber))
  6124. return 0;
  6125. if (!ASN1Dec_EndpointAddress(dec, &(val)->partyToRetrieve))
  6126. return 0;
  6127. if ((val)->o[0] & 0x80) {
  6128. if (!ASN1Dec_PickExeArg_extensionArg(dec, &(val)->extensionArg))
  6129. return 0;
  6130. }
  6131. if (y) {
  6132. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6133. return 0;
  6134. }
  6135. return 1;
  6136. }
  6137. static void ASN1CALL ASN1Free_PickExeArg(PickExeArg *val)
  6138. {
  6139. if (val) {
  6140. ASN1Free_CallIdentifier(&(val)->callPickupId);
  6141. ASN1Free_EndpointAddress(&(val)->picking_upNumber);
  6142. ASN1Free_EndpointAddress(&(val)->partyToRetrieve);
  6143. if ((val)->o[0] & 0x80) {
  6144. ASN1Free_PickExeArg_extensionArg(&(val)->extensionArg);
  6145. }
  6146. }
  6147. }
  6148. static int ASN1CALL ASN1Enc_CpNotifyArg(ASN1encoding_t enc, CpNotifyArg *val)
  6149. {
  6150. if (!ASN1PEREncExtensionBitClear(enc))
  6151. return 0;
  6152. if (!ASN1PEREncBits(enc, 2, (val)->o))
  6153. return 0;
  6154. if ((val)->o[0] & 0x80) {
  6155. if (!ASN1Enc_EndpointAddress(enc, &(val)->parkingNumber))
  6156. return 0;
  6157. }
  6158. if ((val)->o[0] & 0x40) {
  6159. if (!ASN1Enc_CpNotifyArg_extensionArg(enc, &(val)->extensionArg))
  6160. return 0;
  6161. }
  6162. return 1;
  6163. }
  6164. static int ASN1CALL ASN1Dec_CpNotifyArg(ASN1decoding_t dec, CpNotifyArg *val)
  6165. {
  6166. ASN1uint32_t y;
  6167. if (!ASN1PERDecExtensionBit(dec, &y))
  6168. return 0;
  6169. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  6170. return 0;
  6171. if ((val)->o[0] & 0x80) {
  6172. if (!ASN1Dec_EndpointAddress(dec, &(val)->parkingNumber))
  6173. return 0;
  6174. }
  6175. if ((val)->o[0] & 0x40) {
  6176. if (!ASN1Dec_CpNotifyArg_extensionArg(dec, &(val)->extensionArg))
  6177. return 0;
  6178. }
  6179. if (y) {
  6180. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6181. return 0;
  6182. }
  6183. return 1;
  6184. }
  6185. static void ASN1CALL ASN1Free_CpNotifyArg(CpNotifyArg *val)
  6186. {
  6187. if (val) {
  6188. if ((val)->o[0] & 0x80) {
  6189. ASN1Free_EndpointAddress(&(val)->parkingNumber);
  6190. }
  6191. if ((val)->o[0] & 0x40) {
  6192. ASN1Free_CpNotifyArg_extensionArg(&(val)->extensionArg);
  6193. }
  6194. }
  6195. }
  6196. static int ASN1CALL ASN1Enc_CpickupNotifyArg(ASN1encoding_t enc, CpickupNotifyArg *val)
  6197. {
  6198. if (!ASN1PEREncExtensionBitClear(enc))
  6199. return 0;
  6200. if (!ASN1PEREncBits(enc, 2, (val)->o))
  6201. return 0;
  6202. if ((val)->o[0] & 0x80) {
  6203. if (!ASN1Enc_EndpointAddress(enc, &(val)->picking_upNumber))
  6204. return 0;
  6205. }
  6206. if ((val)->o[0] & 0x40) {
  6207. if (!ASN1Enc_CpickupNotifyArg_extensionArg(enc, &(val)->extensionArg))
  6208. return 0;
  6209. }
  6210. return 1;
  6211. }
  6212. static int ASN1CALL ASN1Dec_CpickupNotifyArg(ASN1decoding_t dec, CpickupNotifyArg *val)
  6213. {
  6214. ASN1uint32_t y;
  6215. if (!ASN1PERDecExtensionBit(dec, &y))
  6216. return 0;
  6217. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  6218. return 0;
  6219. if ((val)->o[0] & 0x80) {
  6220. if (!ASN1Dec_EndpointAddress(dec, &(val)->picking_upNumber))
  6221. return 0;
  6222. }
  6223. if ((val)->o[0] & 0x40) {
  6224. if (!ASN1Dec_CpickupNotifyArg_extensionArg(dec, &(val)->extensionArg))
  6225. return 0;
  6226. }
  6227. if (y) {
  6228. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6229. return 0;
  6230. }
  6231. return 1;
  6232. }
  6233. static void ASN1CALL ASN1Free_CpickupNotifyArg(CpickupNotifyArg *val)
  6234. {
  6235. if (val) {
  6236. if ((val)->o[0] & 0x80) {
  6237. ASN1Free_EndpointAddress(&(val)->picking_upNumber);
  6238. }
  6239. if ((val)->o[0] & 0x40) {
  6240. ASN1Free_CpickupNotifyArg_extensionArg(&(val)->extensionArg);
  6241. }
  6242. }
  6243. }
  6244. static int ASN1CALL ASN1Enc_H4501SupplementaryService(ASN1encoding_t enc, H4501SupplementaryService *val)
  6245. {
  6246. if (!ASN1PEREncExtensionBitClear(enc))
  6247. return 0;
  6248. if (!ASN1PEREncBits(enc, 2, (val)->o))
  6249. return 0;
  6250. if ((val)->o[0] & 0x80) {
  6251. if (!ASN1Enc_NetworkFacilityExtension(enc, &(val)->networkFacilityExtension))
  6252. return 0;
  6253. }
  6254. if ((val)->o[0] & 0x40) {
  6255. if (!ASN1Enc_InterpretationApdu(enc, &(val)->interpretationApdu))
  6256. return 0;
  6257. }
  6258. if (!ASN1Enc_ServiceApdus(enc, &(val)->serviceApdu))
  6259. return 0;
  6260. return 1;
  6261. }
  6262. static int ASN1CALL ASN1Dec_H4501SupplementaryService(ASN1decoding_t dec, H4501SupplementaryService *val)
  6263. {
  6264. ASN1uint32_t y;
  6265. if (!ASN1PERDecExtensionBit(dec, &y))
  6266. return 0;
  6267. if (!ASN1PERDecExtension(dec, 2, (val)->o))
  6268. return 0;
  6269. if ((val)->o[0] & 0x80) {
  6270. if (!ASN1Dec_NetworkFacilityExtension(dec, &(val)->networkFacilityExtension))
  6271. return 0;
  6272. }
  6273. if ((val)->o[0] & 0x40) {
  6274. if (!ASN1Dec_InterpretationApdu(dec, &(val)->interpretationApdu))
  6275. return 0;
  6276. }
  6277. if (!ASN1Dec_ServiceApdus(dec, &(val)->serviceApdu))
  6278. return 0;
  6279. if (y) {
  6280. if (!ASN1PERDecSkipNormallySmallExtensionFragmented(dec))
  6281. return 0;
  6282. }
  6283. return 1;
  6284. }
  6285. static void ASN1CALL ASN1Free_H4501SupplementaryService(H4501SupplementaryService *val)
  6286. {
  6287. if (val) {
  6288. if ((val)->o[0] & 0x80) {
  6289. ASN1Free_NetworkFacilityExtension(&(val)->networkFacilityExtension);
  6290. }
  6291. ASN1Free_ServiceApdus(&(val)->serviceApdu);
  6292. }
  6293. }
  6294. static int ASN1CALL ASN1Enc_IntResultList(ASN1encoding_t enc, IntResultList *val)
  6295. {
  6296. ASN1uint32_t i;
  6297. if (!ASN1PEREncBitVal(enc, 5, (val)->count))
  6298. return 0;
  6299. for (i = 0; i < (val)->count; i++) {
  6300. if (!ASN1Enc_IntResult(enc, &((val)->value)[i]))
  6301. return 0;
  6302. }
  6303. return 1;
  6304. }
  6305. static int ASN1CALL ASN1Dec_IntResultList(ASN1decoding_t dec, IntResultList *val)
  6306. {
  6307. ASN1uint32_t i;
  6308. if (!ASN1PERDecU32Val(dec, 5, &(val)->count))
  6309. return 0;
  6310. for (i = 0; i < (val)->count; i++) {
  6311. if (!ASN1Dec_IntResult(dec, &((val)->value)[i]))
  6312. return 0;
  6313. }
  6314. return 1;
  6315. }
  6316. static void ASN1CALL ASN1Free_IntResultList(IntResultList *val)
  6317. {
  6318. ASN1uint32_t i;
  6319. if (val) {
  6320. for (i = 0; i < (val)->count; i++) {
  6321. ASN1Free_IntResult(&(val)->value[i]);
  6322. }
  6323. }
  6324. }