diff options
Diffstat (limited to 'epan/dissectors/asn1/p772')
-rw-r--r-- | epan/dissectors/asn1/p772/CMakeLists.txt | 47 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSAbstractService.asn | 182 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSExtendedBodyPartTypes.asn | 115 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSHeadingExtensions.asn | 250 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSInformationObjects.asn | 62 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSObjectIdentifiers.asn | 262 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSOtherNotificationTypeExtensions.asn | 56 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSPerRecipientSpecifierExtensions.asn | 34 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/MMSUpperBounds.asn | 25 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/p772.cnf | 117 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/packet-p772-template.c | 106 | ||||
-rw-r--r-- | epan/dissectors/asn1/p772/packet-p772-template.h | 17 |
12 files changed, 1273 insertions, 0 deletions
diff --git a/epan/dissectors/asn1/p772/CMakeLists.txt b/epan/dissectors/asn1/p772/CMakeLists.txt new file mode 100644 index 00000000..d3b1842d --- /dev/null +++ b/epan/dissectors/asn1/p772/CMakeLists.txt @@ -0,0 +1,47 @@ +# CMakeLists.txt +# +# Wireshark - Network traffic analyzer +# By Gerald Combs <gerald@wireshark.org> +# Copyright 1998 Gerald Combs +# +# SPDX-License-Identifier: GPL-2.0-or-later +# + +set( PROTOCOL_NAME p772 ) + +set( PROTO_OPT ) + +set( EXT_ASN_FILE_LIST +) + +set( ASN_FILE_LIST + MMSAbstractService.asn + MMSInformationObjects.asn + MMSOtherNotificationTypeExtensions.asn + MMSObjectIdentifiers.asn + MMSHeadingExtensions.asn + MMSUpperBounds.asn + MMSExtendedBodyPartTypes.asn + MMSPerRecipientSpecifierExtensions.asn +) + +set( EXTRA_DIST + ${ASN_FILE_LIST} + packet-${PROTOCOL_NAME}-template.c + packet-${PROTOCOL_NAME}-template.h + ${PROTOCOL_NAME}.cnf +) + +set( SRC_FILES + ${EXTRA_DIST} + ${EXT_ASN_FILE_LIST} +) + +set( A2W_FLAGS -b -C ) + +set( EXTRA_CNF + "${CMAKE_CURRENT_BINARY_DIR}/../p1/p1-exp.cnf" + "${CMAKE_CURRENT_BINARY_DIR}/../p22/p22-exp.cnf" +) + +ASN2WRS() diff --git a/epan/dissectors/asn1/p772/MMSAbstractService.asn b/epan/dissectors/asn1/p772/MMSAbstractService.asn new file mode 100644 index 00000000..d5b19980 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSAbstractService.asn @@ -0,0 +1,182 @@ +MMSAbstractService {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) abstract-service(3)} DEFINITIONS +IMPLICIT TAGS ::= +BEGIN + +--Prologue +-- Exports Everything +IMPORTS + -- IPMS information objects + AutoForwardComment, Heading + -- + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MMS information objects + MM, MN, MNRN, MRN, MON, InformationObject + -- + FROM MMSInformationObjects {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0) module(0) mms(1)} + -- MMS object identifiers + id-mpt-management, id-mpt-origination, id-mpt-reception + -- + FROM MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0)} + -- MTS abstract service + MessageDeliveryEnvelope, MessageSubmissionEnvelope, + MessageSubmissionIdentifier, MessageSubmissionTime, ORName, + ProbeSubmissionEnvelope, ProbeSubmissionIdentifier, ProbeSubmissionTime, + RecipientImproperlySpecified, ReportDeliveryEnvelope, + SupplementaryInformation + -- + FROM MTSAbstractService {joint-iso-ccitt mhs-motis(6) mts(3) modules(0) + mts-abstract-service(1)} + -- Abstract service definition conventions + ABSTRACT-ERROR, ABSTRACT-OPERATION, PORT + -- + FROM AbstractServiceNotation {joint-iso-ccitt mhs-motis(6) asdc(2) + modules(0) notation(1)}; + +-- Ports +-- origination PORT ::= { +-- CONSUMER INVOKES +-- {OriginateProbe | +-- + -- Although, national implementation may + -- support probes within their own domain, probes are not + -- permitted across national boundaries +-- OriginateMM | OriginateMRN} +-- ID id-pt-origination} +-- +--reception PORT ::= { +-- CONSUMER INVOKES +-- {ReceiveReport | ReceiveMM | ReceiveMRN | ReceiveMNRN | ReceiveMON} +-- ID id-pt-reception} +-- +--management PORT ::= { +-- CONSUMER INVOKES +-- {ChangeAutoDiscard | ChangeAutoAcknowledgment | ChangeAutoForwarding} +-- ID id-pt-management} + +-- Origination abstract operations +-- Probes are prohibited across national boundaries. +--originate-probe ABSTRACT-OPERATION ::= { +-- ARGUMENT OriginateProbeArgument +-- RESULT OriginateProbeResult +-- ERROR {SubcriptionError | RecipientImproperlySpecified}} + +OriginateProbeArgument ::= SET { + envelope [0] ProbeSubmissionEnvelope, + content [1] MM} + +OriginateProbeResult ::= SET { + submission-identifier [0] ProbeSubmissionIdentifier, + submission-time [1] ProbeSubmissionTime} + +--originate-mm ABSTRACT-OPERATION ::= { +-- ARGUMENT OriginateMMArgument +-- RESULT OriginateMMResult +-- ERROR {SubcriptionError | RecipientImproperlySpecified}} + +OriginateMMArgument ::= SET { + envelope [0] MessageSubmissionEnvelope, + content [1] MM} + +OriginateMMResult ::= SET { + submission-identifier [0] MessageSubmissionIdentifier, + submission-time [1] MessageSubmissionTime} + +--originate-mrn ABSTRACT-OPERATION ::= { +-- ARGUMENT OriginateMRNArgument +-- RESULT OriginateMRNResult +-- ERROR {SubcriptionError | RecipientImproperlySpecified}} + +OriginateMRNArgument ::= SET { + envelope [0] MessageSubmissionEnvelope, + content [1] MRN} + +OriginateMRNResult ::= SET { + submission-identifier [0] MessageSubmissionIdentifier, + submission-time [1] MessageSubmissionTime} + +-- Reception abstract operations +--receive-report ABSTRACT-OPERATION ::= { +-- ARGUMENT ReceiveReportArgument +-- RESULT ERROR {}} + +ReceiveReportArgument ::= SET { + envelope [0] ReportDeliveryEnvelope, + undelivered-object [1] InformationObject OPTIONAL} + +--receive-mm ABSTRACT-OPERATION ::= { +-- ARGUMENT ReceiveMMArgument +-- RESULT ERROR {}} + +ReceiveMMArgument ::= SET { + envelope [0] MessageDeliveryEnvelope, + content [1] MM} + +--receive-mrn ABSTRACT-OPERATION ::= { +-- ARGUMENT ReceiveMRNArgument +-- RESULT ERROR {}} + +ReceiveMRNArgument ::= SET { + envelope [0] MessageDeliveryEnvelope, + content [1] MRN} + +--receive-mnrn ABSTRACT-OPERATION ::= { +-- ARGUMENT ReceiveMNRNArgument +-- RESULT ERROR {}} + +ReceiveMNRNArgument ::= SET { + envelope [0] MessageDeliveryEnvelope, + content [1] MNRN} + +--receive-mon ABSTRACT-OPERATION ::= { +-- ARGUMENT ReceiveMONArgument +-- RESULT ERROR {}} + +ReceiveMONArgument ::= SET { + envelope [0] MessageDeliveryEnvelope, + content [1] MON} + +-- Management abstract operations +-- It should be noted that in cases where an implementation has dual +-- IPM and MM functionality, the management abstract operations may be used +-- for support of both types of messaging. +--change-auto-discard ABSTRACT-OPERATION ::= { +-- ARGUMENT ChangeAutoDiscardArgument +-- RESULT ERRORS {}} + +ChangeAutoDiscardArgument ::= SET { + auto-discard-expired-MMs [0] BOOLEAN, + auto-discard-obsolete-MMs [1] BOOLEAN} + +--change-auto-acknowledgement ABSTRACT-OPERATION ::= { +-- ARGUMENT ChangeAutoAcknowledgementArgument +-- RESULT ERRORS {SubscriptionError}} + +ChangeAutoAcknowledgementArgument ::= SET { + auto-acknowledge-MMs [0] BOOLEAN, + auto-acknowledge-suppl-receipt-info [1] SupplementaryInformation} + +--change-auto-forwarding ABSTRACT-OPERATION ::= { +-- ARGUMENT ChangeAutoForwardingArgument +-- RESULT ERRORS {SubscriptionError, +-- RecipientImproperlySpecified}} + +ChangeAutoForwardingArgument ::= SET { + autoforward-MMs [0] BOOLEAN, + auto-forward-recipients [1] SEQUENCE OF ORName OPTIONAL, + auto-forward-heading [2] Heading OPTIONAL, + auto-forward-comment [3] AutoForwardComment OPTIONAL} + +-- Abstract errors +--subscription-error ABSTRACT-ERROR ::= {PARAMETER SubscriptionErrorParameter +--} + +SubscriptionErrorParameter ::= SET {problem [0] SubscriptionProblem} + +SubscriptionProblem ::= ENUMERATED { + mms-eos-not-subcribed(0), mts-eos-not-subcribed(1)} + +END --of MMSAbstractService diff --git a/epan/dissectors/asn1/p772/MMSExtendedBodyPartTypes.asn b/epan/dissectors/asn1/p772/MMSExtendedBodyPartTypes.asn new file mode 100644 index 00000000..312e60f2 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSExtendedBodyPartTypes.asn @@ -0,0 +1,115 @@ +MMSExtendedBodyPartTypes {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0) module(0) + extended-body-part-types(7)} DEFINITIONS IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS + -- IPMS information objects + EXTENDED-BODY-PART-TYPE + --= + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MMS information objects + MM + --= + FROM MMSInformationObjects {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0) module(0) mms(1)} + -- MMS upper lower bounds + ub-data-size + --= + FROM MMSUpperBounds {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) upper-bounds(0)} + -- MTS Abstract Service + MessageDeliveryTime, OtherMessageDeliveryFields + --= + FROM MTSAbstractService {joint-iso-ccitt mhs-motis(6) mts(3) modules(0) + mts-abstract-service(1)} + -- MMS object identifiers + --= + id-nato-mmhs-et-adatp3, id-nato-mmhs-et-adatp3-parameters, + id-nato-mmhs-et-acp127data, id-nato-mmhs-et-acp127data-parameters, + id-nato-mmhs-et-corrections, id-nato-mmhs-et-corrections-parameters, + id-nato-mmhs-et-forwarded-encrypted, + id-nato-mmhs-et-forwarded-encrypted-parameters, id-nato-mmhs-et-mm-message, + id-nato-mmhs-et-mm-message-parameters + --= + FROM MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0)}; + +-- extended adatp3 bodypart +--adatp3-body-part EXTENDED-BODY-PART-TYPE ::= { +-- PARAMETERS {ADatP3Parameters +-- IDENTIFIED BY id-nato-mmhs-et-adatp3-parameters}, +-- DATA {ADatP3Data +-- IDENTIFIED BY id-nato-mmhs-et-adatp3}} + +ADatP3Parameters ::= INTEGER -- DEFAULT (0) + +ADatP3Data ::= CHOICE { + lineOriented [0] IMPLICIT IA5String, + setOriented [1] IMPLICIT SEQUENCE OF IA5String} + +-- extended corrections body part +--corrections-body-part EXTENDED-BODY-PART-TYPE ::= { +-- PARAMETERS {CorrectionsParameters +-- IDENTIFIED BY id-nato-mmhs-et-corrections-parameters}, +-- DATA {CorrectionsData +-- IDENTIFIED BY id-nato-mmhs-et-corrections}} + +CorrectionsParameters ::= INTEGER + +CorrectionsData ::= IA5String + +-- extended forwarded encrypted body part +--forwarded-encrypted-body-part EXTENDED-BODY-PART-TYPE ::= { +-- PARAMETERS +-- {ForwardedEncryptedParameters +-- IDENTIFIED BY id-nato-mmhs-et-forwarded-encrypted-parameters}, +-- DATA +-- {ForwardedEncryptedData +-- IDENTIFIED BY id-nato-mmhs-et-forwarded-encrypted}} + +-- A forwarded-encrypted-body must contain the delivery information, +-- containing the content type which will indicate whether the forwarded +-- encrypted message is an MM or IPM. All security related information +-- (i.e., token) of the original message must be forwarded. +ForwardedEncryptedParameters ::= SET { + delivery-time [0] MessageDeliveryTime OPTIONAL, + delivery-envelope [1] OtherMessageDeliveryFields} + +-- 2/X.411, part 9 of 26. +ForwardedEncryptedData ::= BIT STRING + +-- extended MM message body part +--mm-message-body-part EXTENDED-BODY-PART-TYPE ::= { +-- PARAMETERS +-- {MMMessageParameters +-- IDENTIFIED BY id-nato-mmhs-et-mm-message-parameters}, +-- DATA {MMMessageData +-- IDENTIFIED BY id-nato-mmhs-et-mm-message}} + +-- An mm-message-body-part can either carry a forwarded M1M or a forwarded +-- IPM. In the case of a message-body-part, as defined in X.420, +-- it can only carry an IPM. +MMMessageParameters ::= SET { + delivery-time [0] MessageDeliveryTime OPTIONAL, + delivery-envelope [1] OtherMessageDeliveryFields} + +MMMessageData ::= IPM + +-- extended acp127data body part +--acp127data-body-part EXTENDED-BODY-PART-TYPE ::= { +-- PARAMETERS +-- {ACP127DataParameters +-- IDENTIFIED BY id-nato-mmhs-et-acp127data-parameters}, +-- DATA {ACP127DataData +-- IDENTIFIED BY id-nato-mmhs-et-acp127data}} + +ACP127DataParameters ::= INTEGER + +ACP127DataData ::= IA5String(SIZE (1..ub-data-size)) + +END -- of MMS ExtendedBodyPartTypes + diff --git a/epan/dissectors/asn1/p772/MMSHeadingExtensions.asn b/epan/dissectors/asn1/p772/MMSHeadingExtensions.asn new file mode 100644 index 00000000..d20c1425 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSHeadingExtensions.asn @@ -0,0 +1,250 @@ +MMSHeadingExtensions {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) heading-extensions(6)} DEFINITIONS +IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS + -- IPMS information objects + IPMS-EXTENSION, ORDescriptor + --= + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MMS upper bounds + lb-military-sic, ub-military-number-of-sics, ub-military-sic + --= + FROM MMSUpperBounds {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) upper-bounds(0)} + -- MMS object identifiers + id-nato-mmhs-mm-acp127-message-identifier, + id-nato-mmhs-mm-address-list-indicator, id-nato-mmhs-mm-codress-message, + id-nato-mmhs-mm-copy-precedence, id-nato-mmhs-mm-distribution-codes, + id-nato-mmhs-mm-exempted-address, + id-nato-mmhs-mm-extended-authorisation-info, + id-nato-mmhs-mm-handling-instructions, id-nato-mmhs-mm-information-labels, + id-nato-mmhs-mm-message-instructions, id-nato-mmhs-mm-message-type, + id-nato-mmhs-mm-originator-reference, id-nato-mmhs-mm-originator-plad, + id-nato-mmhs-mm-other-recipients-indicator, + id-nato-mmhs-mm-pilot-forwarding-info, id-nato-mmhs-mm-primary-precedence + --= + FROM MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0)} + -- MTS abstract service + --Message--SecurityLabel + --= + FROM MTSAbstractService {joint-iso-ccitt mhs-motis(6) mts(3) modules(0) + mts-abstract-service(1)}; + +-- exempted address +--exempted-address IPMS-EXTENSION ::= { +-- VALUE SEQUENCE OF ExemptedAddress +-- IDENTIFIED BY id-nato-mmhs-mm-exempted-address} + +ExemptedAddressSeq ::= SEQUENCE OF ExemptedAddress + +ExemptedAddress ::= ORDescriptor + +-- extended authorisation information +--extended-authorisation-info IPMS-EXTENSION ::= { +-- VALUE ExtendedAuthorisationInfo +-- IDENTIFIED BY id-nato-mmhs-mm-extended-authorisation-info} + +ExtendedAuthorisationInfo ::= UTCTime + +-- UTCTime as defined in 8.5.4 of ITU-T X.411 +-- Distribution codes +-- will carry subject indicator codes and leave room for expansion. +--distribution-codes IPMS-EXTENSION ::= { +-- VALUE DistributionCodes +-- IDENTIFIED BY id-nato-mmhs-mm-distribution-codes} + +DistributionCodes ::= SET { + sics + [0] SEQUENCE SIZE (1..ub-military-number-of-sics) OF Sic OPTIONAL, + dist-Extensions [1] SEQUENCE OF DistributionExtensionField OPTIONAL} + +Sic ::= PrintableString(SIZE (lb-military-sic..ub-military-sic)) + +--DistributionExtensionField ::= INSTANCE OF TYPE-IDENTIFIER +DistributionExtensionField ::= SEQUENCE { + dist-type OBJECT IDENTIFIER, + dist-value ANY --DEFINED BY dist-type-- } + +-- Handling instructions +--handling-instructions IPMS-EXTENSION ::= { +-- VALUE HandlingInstructions +-- IDENTIFIED BY id-nato-mmhs-mm-handling-instructions} + +HandlingInstructions ::= SEQUENCE OF MilitaryString + +MilitaryString ::= PrintableString(SIZE (1..ub-military-string)) + +-- Message instructions +-- will carry operating signals +--message-instructions IPMS-EXTENSION ::= { +-- VALUE MessageInstructions +-- IDENTIFIED BY id-nato-mmhs-mm-message-instructions} + +MessageInstructions ::= SEQUENCE OF MilitaryString + +-- Codress message +-- Needed for transition or as long as codress messages need to be carried. +--codress-message IPMS-EXTENSION ::= { +-- VALUE CodressMessage +-- IDENTIFIED BY id-nato-mmhs-mm-codress-message} + +CodressMessage ::= INTEGER + +-- Originator reference +-- only used if a user designated identifier string becomes important. +--originator-reference IPMS-EXTENSION ::= { +-- VALUE OriginatorReference +-- IDENTIFIED BY id-nato-mmhs-mm-originator-reference} + +OriginatorReference ::= MilitaryString + +-- we have expanded MMHSPrecedence to PrimaryPrecedence and CopyPrecedence to +-- all rules to be written to highlight high priority messages. +MMHSPrecedence ::= INTEGER { + deferred(0), routine(1), priority(2), immediate(3), flash(4), override(5) + -- these are used by some National systems XXX need to verify + , ecp(16), critic(17), override(18) +} + +-- Primary reference +--primary-precedence IPMS-EXTENSION ::= { +-- VALUE MMHSPrecedence +-- IDENTIFIED BY id-nato-mmhs-mm-primary-precedence} + +PrimaryPrecedence ::= INTEGER { + deferred(0), routine(1), priority(2), immediate(3), flash(4), override(5) + -- these are used by some National systems XXX need to verify + , ecp(16), critic(17), override(18) +} + +-- Note: Values 0 to 15 are reserved for NATO defined precedence levels. +-- Values 16 to 31 are reserved for national user. +-- Copy precedence +--copy-precedence IPMS-EXTENSION ::= { +-- VALUE MMHSPrecedence +-- IDENTIFIED BY id-nato-mmhs-mm-copy-precedence} + +CopyPrecedence ::= INTEGER { + deferred(0), routine(1), priority(2), immediate(3), flash(4), override(5) + -- these are used by some National systems XXX need to verify + , ecp(16), critic(17), override(18) +} + +-- Message type +--message-type IPMS-EXTENSION ::= { +-- VALUE MessageType +-- IDENTIFIED BY id-nato-mmhs-mm-message-type} + +MessageType ::= SET { + type [0] TypeMessage, + identifier [1] MessageIdentifier OPTIONAL} + +TypeMessage ::= INTEGER {exercise(0), operation(1), project(2), drill(3)} + +-- Note: Values 0 to 127 are reserved for NATO defined Message Type +-- identifiers. Values above 128 to 255 are not defined by NATO and may +-- be used nationally or bilaterally. +MessageIdentifier ::= + MilitaryString + +-- Address list indicator +--address-list-indicator IPMS-EXTENSION ::= { +-- VALUE SEQUENCE OF AddressListDesignator +-- IDENTIFIED BY id-nato-mmhs-mm-address-list-indicator} + +AddressListDesignatorSeq ::= SEQUENCE OF AddressListDesignator + +AddressListDesignator ::= SET { + type [0] INTEGER {primaryAddressList(0), copyAddressList(1)}, + listName [1] ORDescriptor, + notificationRequest [2] AddressListRequest OPTIONAL, + replyRequest [3] AddressListRequest OPTIONAL} + +AddressListRequest ::= INTEGER {action(0), info(1), both(2)} + +-- Other recipients indicator +--other-recipients-indicator IPMS-EXTENSION ::= { +-- VALUE SEQUENCE OF OtherRecipientDesignator +-- IDENTIFIED BY id-nato-mmhs-mm-other-recipients-indicator} + +OtherRecipientDesignatorSeq ::= SEQUENCE OF OtherRecipientDesignator + +OtherRecipientDesignator ::= SET { + type [0] INTEGER {primary(0), copy(1)}, + designator [1] MilitaryString} + +-- pilot forwarding information +--pilot-forwarding-info IPMS-EXTENSION ::= { +-- VALUE SEQUENCE OF PilotInformation +-- IDENTIFIED BY id-nato-mmhs-mm-pilot-forwarding-info} + +PilotInformationSeq ::= SEQUENCE OF PilotInformation + +PilotInformation ::= SEQUENCE { + pilotPrecedence [0] MMHSPrecedence OPTIONAL, + -- Note: Values 0 to 15 are reserved for NATO defined precedence levels. + -- Values 16 to 31 are reserved for national use. + pilotRecipient [1] SEQUENCE OF ORDescriptor OPTIONAL, + pilotSecurity [2] --Message--SecurityLabel OPTIONAL, + pilotHandling [3] SEQUENCE OF MilitaryString OPTIONAL} + +-- Acp127 message identifier +-- a string to store routing indicator, station serial number and julian file +-- time seperated by spaces. +--acp127-message-identifier IPMS-EXTENSION ::= { +-- VALUE Acp127MessageIdentifier +-- IDENTIFIED BY id-nato-mmhs-mm-acp127-message-identifier} + +Acp127MessageIdentifier ::= MilitaryString + +-- Originator PLAD +--originator-plad IPMS-EXTENSION ::= { +-- VALUE OriginatorPlad +-- IDENTIFIED BY id-nato-mmhs-mm-originator-plad} + +OriginatorPlad ::= MilitaryString + +-- Information label +--security-information-labels IPMS-EXTENSION ::= { +-- VALUE SecurityInformationLabels +-- IDENTIFIED BY id-nato-mmhs-mm-information-labels} + +SecurityInformationLabels ::= SEQUENCE { + content-security-label [0] SecurityLabel, + -- SecurityLabel as defined in 8.5.9 of ITU-T X.411 + heading-security-label [1] SecurityLabel OPTIONAL, + body-part-security-labels [2] SEQUENCE OF BodyPartSecurityLabel OPTIONAL} + +BodyPartSecurityLabel ::= SET { + body-part-security-label [0] SecurityLabel, + body-part-sequence-number [1] BodyPartSequenceNumber OPTIONAL} + +BodyPartSequenceNumber ::= INTEGER + +-- Note: If all body parts of the message are labelled, each +-- element in the body sequence above shall correspond to the +-- same numbered element of the Body sequence, and the body +-- part sequence number may be absent. (i.e. the first element +-- of this field shall correspond to the first body part, etc. +-- Otherwise the body part sequence number shall be present +-- and shall correspond to the sequence of the body part +-- to which the security label relates. (i.e. the value of the +-- body part sequence number shall correspond to sequence in which +-- the originator encoded the body parts of the message). +-- NOTE: The security-information-labels heading extension is now +-- deprecated. Its use is, therefore, discouraged. See STANAG 4406 +-- Annex B for instruction on the use of its replacement, the +-- ESSSecurityLabel. + +PriorityLevelQualifier ::= ENUMERATED { + low(0), + high(1) } + +END -- of Military heading extensions used in MMS + diff --git a/epan/dissectors/asn1/p772/MMSInformationObjects.asn b/epan/dissectors/asn1/p772/MMSInformationObjects.asn new file mode 100644 index 00000000..510b551f --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSInformationObjects.asn @@ -0,0 +1,62 @@ +MMSInformationObjects {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) mms(1)} DEFINITIONS IMPLICIT TAGS +::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS + -- IPM Information Object + Body, CommonFields, Heading, NonReceiptFields, OtherNotificationTypeFields, + ReceiptFields, IPM, IPN + --= + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MTS abstract service + ORName + --= + FROM MTSAbstractService {joint-iso-ccitt mhs-motis(6) mts(3) modules(0) + mts-abstract-service(1)}; + +-- Information Object +--InformationObject ::= CHOICE {mm [0] MM, +-- mn [1] MN} + +-- We use IPM and IPN here because asn2wrs is unable to fetch +-- COMPONENTS OF CommonFields from IPMSInformationObjects.asn (x420). +InformationObject ::= CHOICE {mm [0] IPM, + mn [1] IPN} + +-- MM (Military Message) +MM ::= SEQUENCE {mmheading Heading, + mmbody Body} + +-- The mandatory support on the IPMIdentifier components is more important +-- in MMS than in IPMS. The user component, ORName of the originating UA is +-- mandatory. Local IPMIdentifier is made up of 2 concatenated string +-- separated by a space both generated by the originating UA, a serial +-- number and the filing time (the time the message generation is finished) +-- in UTC time format. The minimum length of 15 is because both a date/time +-- stamp in UTC format including seconds and a serial number, plus the space +-- delimiter are mandatory. The smallest acceptable UTC date/time stamp +-- is 13 (ddmmyyhhmmssZ). +-- MN (Military Notification receipt/non receipt / other notification types) +MN ::= SET { + COMPONENTS OF CommonFields, + choice + [0] CHOICE {mn-non-receipt-fields [0] NonReceiptFields, + mn-receipt-fields [1] ReceiptFields, + mn-other-notification-type-fields + [2] OtherNotificationTypeFields}} + +MRN ::= MN -- with MN-receipt-fields chosen + +MNRN ::= MN -- with MN-non-receipt-fields chosen + +MON ::= MN -- with MN-other-notification-type-fields chosen + +-- All military specific body parts are defined as extended body parts. +-- The military specific body parts are defined in Annex A +-- of this part of the MBS. +END -- of MMS InformationObjects + diff --git a/epan/dissectors/asn1/p772/MMSObjectIdentifiers.asn b/epan/dissectors/asn1/p772/MMSObjectIdentifiers.asn new file mode 100644 index 00000000..c801d701 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSObjectIdentifiers.asn @@ -0,0 +1,262 @@ +MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0)} DEFINITIONS IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Export everything +IMPORTS --nothing-- ; + +ID ::= OBJECT IDENTIFIER + +-- Military Messaging +id-mmhs ID ::= + {iso(1) identified-organization(3) nato(26) stanags(0) mmhs(4406) + object-identifiers(0)} + +-- Categories of object identifiers +id-mod ID ::= {id-mmhs 0} -- mm module + +id-mm ID ::= {id-mmhs 2} -- heading extension + +id-hat ID ::= {id-mmhs 3} -- heading attributes for MS + +id-mcont ID ::= {id-mmhs 4} -- content types + +id-policy ID ::= {id-mmhs 5} -- NATO policy identifier + +id-cat ID ::= {id-mmhs 6} -- special category identifiers + +id-et ID ::= {id-mmhs 7} -- military defined extended body part types + +id-mmts ID ::= {id-mmhs 8} -- mts object identifiers + +id-nat ID ::= {id-mmhs 9} -- military defined notification attributes + +id-mot ID ::= {id-mmhs 10} -- military object types + +id-mpt ID ::= {id-mmhs 11} -- military port types + +id-ref ID ::= {id-mmhs 12} -- refinements + +id-informationlabel ID ::= {id-mmhs 13} + +-- Modules +-- MMS information objects +id-mod-upper-bounds ID ::= {id-mod 0} + +id-mod-mms ID ::= {id-mod 1} + +id-mod-functional-objects ID ::= {id-mod 2} + +id-mod-abstract-service ID ::= {id-mod 3} + +id-mod-heading-extension ID ::= {id-mod 6} + +id-mod-extended-body-part-types ID ::= {id-mod 7} + +id-mod-message-store-attributes ID ::= {id-mod 8} + +id-mod-per-recipient-specifier-extensions ID ::= {id-mod 11} + +id-mod-other-notification-type-extensions ID ::= {id-mod 12} + +-- Object types +id-mot-mmme ID ::= {id-mot 0} + +id-mot-mms-user ID ::= {id-mot 1} + +id-mot-mms ID ::= {id-mot 2} + +id-mot-mms-ua ID ::= {id-mot 3} + +id-mot-mms-ms ID ::= {id-mot 4} + +id-mot-acp127au ID ::= {id-mot 5} + +id-mot-pdau ID ::= {id-mot 6} + +-- port types +id-mpt-origination ID ::= {id-mpt 0} + +id-mpt-reception ID ::= {id-mpt 1} + +id-mpt-management ID ::= {id-mpt 2} + +-- Refinements +id-ref-primary ID ::= {id-ref 0} + +id-ref-secondary ID ::= {id-ref 1} + +-- Military Defined body parts +id-nato-mmhs-et-adatp3 ID ::= {id-et 0} + +id-nato-mmhs-et-corrections ID ::= {id-et 1} + +id-nato-mmhs-et-adatp3-parameters ID ::= {id-et 2} + +id-nato-mmhs-et-corrections-parameters ID ::= {id-et 3} + +id-nato-mmhs-et-forwarded-encrypted ID ::= {id-et 6} + +id-nato-mmhs-et-forwarded-encrypted-parameters ID ::= {id-et 7} + +id-nato-mmhs-et-mm-message ID ::= {id-et 9} + +id-nato-mmhs-et-mm-message-parameters ID ::= {id-et 10} + +id-nato-mmhs-et-mm-acp127data ID ::= {id-et 12} + +id-nato-mmhs-et-mm-acp127data-parameters ID ::= {id-et 13} + +-- Military Defined Heading Fields +id-nato-mmhs-mm-primary-precedence ID ::= + {id-mm 0} + +id-nato-mmhs-mm-copy-precedence ID ::= {id-mm 1} + +id-nato-mmhs-mm-message-type ID ::= {id-mm 2} + +id-nato-mmhs-mm-address-list-indicator ID ::= {id-mm 3} + +id-nato-mmhs-mm-exempted-address ID ::= {id-mm 4} + +id-nato-mmhs-mm-extended-authorisation-info ID ::= {id-mm 5} + +id-nato-mmhs-mm-distribution-codes ID ::= {id-mm 6} + +id-nato-mmhs-mm-handling-instructions ID ::= {id-mm 7} + +id-nato-mmhs-mm-message-instructions ID ::= {id-mm 8} + +id-nato-mmhs-mm-codress-message ID ::= {id-mm 9} + +id-nato-mmhs-mm-originator-reference ID ::= {id-mm 10} + +id-nato-mmhs-mm-other-recipients-indicator ID ::= {id-mm 11} + +id-nato-mmhs-mm-pilot-forwarding-info ID ::= {id-mm 12} + +id-nato-mmhs-mm-acp127-message-identifier ID ::= {id-mm 13} + +id-nato-mmhs-mm-originator-plad ID ::= {id-mm 14} + +id-nato-mmhs-mm-information-labels ID ::= {id-mm 17} + +-- This value is deprecated. +-- the following are per-recipient +id-nato-mmhs-mm-acp127-notification-request ID ::= + {id-mm 15} + +-- the following are per other-notification-type +id-nato-mmhs-mm-acp127-notification-response ID ::= + {id-mm 16} + +-- Military Defined Heading Attributes for MS +id-nato-mmhs-hat-primary-precedence ID ::= + {id-hat 0} + +id-nato-mmhs-hat-copy-precedence ID ::= {id-hat 1} + +id-nato-mmhs-hat-message-type ID ::= {id-hat 2} + +id-nato-mmhs-hat-address-list-indicator ID ::= {id-hat 3} + +id-nato-mmhs-hat-exempted-address ID ::= {id-hat 4} + +id-nato-mmhs-hat-extended-authorisation-info ID ::= {id-hat 5} + +id-nato-mmhs-hat-distribution-codes ID ::= {id-hat 6} + +id-nato-mmhs-hat-handling-instructions ID ::= {id-hat 7} + +id-nato-mmhs-hat-message-instructions ID ::= {id-hat 8} + +id-nato-mmhs-hat-codress-message ID ::= {id-hat 9} + +id-nato-mmhs-hat-originator-reference ID ::= {id-hat 10} + +id-nato-mmhs-hat-other-recipients-indicator ID ::= {id-hat 11} + +id-nato-mmhs-hat-pilot-forwarding-info ID ::= {id-hat 12} + +id-nato-mmhs-hat-acp127-message-identifier ID ::= {id-hat 13} + +id-nato-mmhs-hat-originator-plad ID ::= {id-hat 14} + +-- the following are per-recipient +id-nato-mmhs-hat-acp127-notification-request ID ::= + {id-hat 15} + +id-nato-mmhs-hat-sic-codes ID ::= {id-hat 16} + +id-nato-mmhs-hat-distribution-extensions ID ::= {id-hat 17} + +id-nato-mmhs-hat-body-part-information-label ID ::= {id-hat 18} + +-- This value is deprecated. +id-nato-mmhs-hat-security-information-labels ID ::= + {id-hat 19} + +-- This value is deprecated. +-- Military Defined special category identifiers +id-nato-mmhs-cat ID ::= + {id-cat 0} + +-- This value is deprecated. +id-nato-mmhs-cat-atomal ID ::= {id-cat 1} + +-- This value is deprecated. +id-nato-mmhs-cat-cryptosecurity ID ::= {id-cat 2} + +-- This value is deprecated. +id-nato-mmhs-cat-specialhandlingintel ID ::= + {id-cat 3} + +-- This value is deprecated. +id-nato-mmhs-cat-ussiopesi ID ::= {id-cat 4} + +-- This value is deprecated. +id-nato-mmhs-cat-eyesonly ID ::= {id-cat 5} + +-- This value is deprecated. +id-nato-mmhs-cat-exclusive ID ::= {id-cat 6} + +-- This value is deprecated. +id-nato-mmhs-cat-information-label ID ::= + {id-cat 7} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-atomal ID ::= + {id-informationlabel 1} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-cryptosecurity ID ::= + {id-informationlabel 2} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-specialhandlingintel ID ::= + {id-informationlabel 3} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-ussiopesi ID ::= + {id-informationlabel 4} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-eyesonly ID ::= + {id-informationlabel 5} + +-- This value is deprecated. +id-nato-mmhs-informationlabel-exclusive ID ::= + {id-informationlabel 6} + +-- This value is deprecated. +-- Military Defined Notification Extension +id-nato-mmhs-nat-acp127-notification-response ID ::= + {id-nat 0} + +-- Military Message content types (for use by MS only) +id-mct-p772 ID ::= + {id-mcont 1} + +END -- of MMHSObjectIdentifiers + diff --git a/epan/dissectors/asn1/p772/MMSOtherNotificationTypeExtensions.asn b/epan/dissectors/asn1/p772/MMSOtherNotificationTypeExtensions.asn new file mode 100644 index 00000000..4aa53b18 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSOtherNotificationTypeExtensions.asn @@ -0,0 +1,56 @@ +MMSOtherNotificationTypeExtensions {iso(1) identified-organization(3) + nato(26) stanags(0) mmhs(4406) object-identifiers(0) module(0) + other-notification-type-extensions(12)} DEFINITIONS IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS + -- IPMS information objects + IPMS-EXTENSION, ReceiptTimeField + --= + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MMS upper bounds + ub-military-bigstring + --= + FROM MMSUpperBounds {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) upper-bounds(0)} + -- MMS object identifiers + id-nato-mmhs-mm-acp127-notification-response + --= + FROM MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0)} + -- MMS heading extensions + AddressListDesignator + --= + FROM MMSHeadingExtensions {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0) module(0) + heading-extensions(6)} + -- MMS per recipient specifier extensions + Acp127NotificationType + --= + FROM MMSPerRecipientSpecifierExtensions {iso(1) identified-organization(3) + nato(26) stanags(0) mmhs(4406) object-identifiers(0) module(0) + per-recipient-specifier-extensions(11)}; + +--ACP127 notification response +--acp127-notification-response IPMS-EXTENSION ::= { +-- VALUE Acp127NotificationResponse +-- IDENTIFIED BY id-nato-mmhs-mm-acp127-notification-response} + +Acp127NotificationResponse ::= SET { + acp127-notification-type [0] Acp127NotificationType, + receipt-time [1] ReceiptTimeField, + addressListIndicator [2] AddressListIndicator OPTIONAL, + acp127-recipient [3] Acp127Recipient OPTIONAL, + acp127-supp-info [4] Acp127SuppInfo OPTIONAL} + +AddressListIndicator ::= SEQUENCE OF AddressListDesignator + +Acp127Recipient ::= PrintableString(SIZE (1..ub-military-bigstring)) + +Acp127SuppInfo ::= PrintableString(SIZE (1..ub-military-bigstring)) + +END -- of MMS OtherNotificationType extensions + diff --git a/epan/dissectors/asn1/p772/MMSPerRecipientSpecifierExtensions.asn b/epan/dissectors/asn1/p772/MMSPerRecipientSpecifierExtensions.asn new file mode 100644 index 00000000..b7d001a8 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSPerRecipientSpecifierExtensions.asn @@ -0,0 +1,34 @@ +MMSPerRecipientSpecifierExtensions {iso(1) identified-organization(3) + nato(26) stanags(0) mmhs(4406) object-identifiers(0) module(0) + per-recipient-specifier-extensions(11)} DEFINITIONS IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS + -- IPMS information objects + IPMS-EXTENSION + --= + FROM IPMSInformationObjects {joint-iso-ccitt mhs-motis(6) ipms(1) + modules(0) information-objects(2)} + -- MMS object identifiers + id-nato-mmhs-mm-acp127-notification-request + --= + FROM MMSObjectIdentifiers {iso(1) identified-organization(3) nato(26) + stanags(0) mmhs(4406) object-identifiers(0)}; + +-- ACP127 notification request +-- The following definitions are made in order to support +-- informing the originator of a message that the subject message +-- has reached a gateway to an ACP 127 domain. +--acp127-notification-request IPMS-EXTENSION ::= { +-- VALUE Acp127NotificationType +-- IDENTIFIED BY id-nato-mmhs-mm-acp127-notification-request} + +Acp127NotificationType ::= BIT STRING { + acp127-nn(0), -- negative notification + acp127-pn(1), -- positive notification + acp127-tn(2)} -- transfer notification + +END -- of MMS per recipient pecifier extensions + diff --git a/epan/dissectors/asn1/p772/MMSUpperBounds.asn b/epan/dissectors/asn1/p772/MMSUpperBounds.asn new file mode 100644 index 00000000..6095f926 --- /dev/null +++ b/epan/dissectors/asn1/p772/MMSUpperBounds.asn @@ -0,0 +1,25 @@ +MMSUpperBounds {iso(1) identified-organization(3) nato(26) stanags(0) + mmhs(4406) object-identifiers(0) module(0) upper-bounds(0)} DEFINITIONS +IMPLICIT TAGS ::= +BEGIN + +-- Prologue +-- Exports Everything +IMPORTS -- nothing -- ; + +-- Upper Bounds +ub-military-string INTEGER ::= 69 + +ub-military-number-of-sics INTEGER ::= 8 + +lb-military-sic INTEGER ::= 3 + +ub-military-sic INTEGER ::= 8 + +ub-military-bigstring INTEGER ::= 128 + +ub-data-size INTEGER ::= 65535 + +-- size of ACP127DATADATA +END -- of MMSUpperBounds + diff --git a/epan/dissectors/asn1/p772/p772.cnf b/epan/dissectors/asn1/p772/p772.cnf new file mode 100644 index 00000000..d2da78e3 --- /dev/null +++ b/epan/dissectors/asn1/p772/p772.cnf @@ -0,0 +1,117 @@ +# p772.cnf +# p772 conformation file + +#.IMPORT ../p1/p1-exp.cnf +#.IMPORT ../p22/p22-exp.cnf + +#.OMIT_ASSIGNMENT +ID +MM +MN +MRN +MNRN +MON +OriginateProbeArgument +OriginateProbeResult +OriginateMMArgument +OriginateMMResult +OriginateMRNArgument +OriginateMRNResult +ReceiveReportArgument +ReceiveMMArgument +ReceiveMRNArgument +ReceiveMNRNArgument +ReceiveMONArgument +ChangeAutoDiscardArgument +ChangeAutoAcknowledgementArgument +ChangeAutoForwardingArgument +SubscriptionErrorParameter +SubscriptionProblem + +#.NO_EMIT ONLY_VALS +InformationObject + +#.TYPE_RENAME +AddressListDesignator/type AddressListType +OtherRecipientDesignator/type OtherRecipientType + +#.FIELD_RENAME +AddressListDesignator/type address_list_type +MessageType/type message_type_type +OtherRecipientDesignator/type other_recipient_type + +#.PDU +PrimaryPrecedence +CopyPrecedence +MessageType +#AddressListDesignator +#ExemptedAddress +ExtendedAuthorisationInfo +DistributionCodes +HandlingInstructions +MessageInstructions +CodressMessage +OriginatorReference +#OtherRecipientDesignator +#PilotInformation +Acp127MessageIdentifier +OriginatorPlad +Acp127NotificationType +SecurityInformationLabels + +#.REGISTER +PrimaryPrecedence B "1.3.26.0.4406.0.2.0" "primary-precedence" +CopyPrecedence B "1.3.26.0.4406.0.2.1" "copy-precedence" +MessageType B "1.3.26.0.4406.0.2.2" "message-type" +AddressListDesignatorSeq B "1.3.26.0.4406.0.2.3" "address-list-indicator" +ExemptedAddressSeq B "1.3.26.0.4406.0.2.4" "exempted-address" +ExtendedAuthorisationInfo B "1.3.26.0.4406.0.2.5" "extended-authorisation-info" +DistributionCodes B "1.3.26.0.4406.0.2.6" "distribution-codes" +HandlingInstructions B "1.3.26.0.4406.0.2.7" "handling-instructions" +MessageInstructions B "1.3.26.0.4406.0.2.8" "message-instructions" +CodressMessage B "1.3.26.0.4406.0.2.9" "codress-message" +OriginatorReference B "1.3.26.0.4406.0.2.10" "originator-reference" +OtherRecipientDesignatorSeq B "1.3.26.0.4406.0.2.11" "other-recipients-indicator" +PilotInformationSeq B "1.3.26.0.4406.0.2.12" "pilot-forwarding-info" +Acp127MessageIdentifier B "1.3.26.0.4406.0.2.13" "acp127-message-identifier" +OriginatorPlad B "1.3.26.0.4406.0.2.14" "originator-plad" +Acp127NotificationType B "1.3.26.0.4406.0.2.15" "acp127-notification-request" +Acp127NotificationResponse B "1.3.26.0.4406.0.2.16" "acp127-notification-response" +SecurityInformationLabels B "1.3.26.0.4406.0.2.17" "information-labels" + +PriorityLevelQualifier B "1.3.26.0.4406.0.8.0" "priority-level-qualifier" + + +ADatP3Data B id_nato_mmhs_et_adatp3 "adatp3" +ADatP3Parameters B id_nato_mmhs_et_adatp3_parameters "adatp3-parameters" +CorrectionsData B id_nato_mmhs_et_corrections "corrections" +CorrectionsParameters B id_nato_mmhs_et_corrections_parameters "corrections-parameters" +ForwardedEncryptedData B id_nato_mmhs_et_forwarded_encrypted "forwarded-encrypted" +ForwardedEncryptedParameters B id_nato_mmhs_et_forwarded_encrypted_parameters "forwarded-encrypted-parameters" +MMMessageData B id_nato_mmhs_et_mm_message "mm-message" +MMMessageParameters B id_nato_mmhs_et_mm_message_parameters "mm-message-parameters" +ACP127DataData B id_nato_mmhs_et_mm_acp127data "acp127-data" +ACP127DataParameters B id_nato_mmhs_et_mm_acp127data_parameters "acp127-data-parameters" + +InformationObject B "2.6.1.4.17.1.3.26.0.4406.0.4.1" "id-et-content-p772" + + +#.FN_BODY DistributionExtensionField/dist-value +/* XXX: not implemented */ + offset = dissect_unknown_ber(actx->pinfo, tvb, offset, tree); + +#.FN_PARS PrimaryPrecedence + VAL_PTR=&precedence +#.FN_BODY PrimaryPrecedence + int precedence = -1; + %(DEFAULT_BODY)s + if(precedence != -1) + col_append_fstr(actx->pinfo->cinfo, COL_INFO, " (primary=%%s)", val_to_str(precedence, p772_PrimaryPrecedence_vals, "precedence(%%d)")); + +#.FN_PARS CopyPrecedence + VAL_PTR=&precedence +#.FN_BODY CopyPrecedence + int precedence = -1; + %(DEFAULT_BODY)s + if(precedence != -1) + col_append_fstr(actx->pinfo->cinfo, COL_INFO, " (copy=%%s)", val_to_str(precedence, p772_CopyPrecedence_vals, "precedence(%%d)")); diff --git a/epan/dissectors/asn1/p772/packet-p772-template.c b/epan/dissectors/asn1/p772/packet-p772-template.c new file mode 100644 index 00000000..4b20d84e --- /dev/null +++ b/epan/dissectors/asn1/p772/packet-p772-template.c @@ -0,0 +1,106 @@ +/* packet-p772.c + * Routines for STANAG 4406 (X.400 Military Message Extensions) packet dissection + * Graeme Lunt 2005 + * + * Wireshark - Network traffic analyzer + * By Gerald Combs <gerald@wireshark.org> + * Copyright 1998 Gerald Combs + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ + +#include "config.h" + +#include <epan/packet.h> +#include <epan/asn1.h> + +#include "packet-ber.h" + +#include "packet-x509if.h" + +#include "packet-p772.h" +#include "packet-p1.h" +#include "packet-p22.h" + +#define PNAME "STANAG 4406 Message" +#define PSNAME "P772" +#define PFNAME "p772" + +void proto_register_p772(void); +void proto_reg_handoff_p772(void); + + +/* Initialize the protocol and registered fields */ +static int proto_p772 = -1; + +#include "packet-p772-val.h" + +#include "packet-p772-hf.c" + +/* Initialize the subtree pointers */ +static gint ett_p772 = -1; +#include "packet-p772-ett.c" + +#include "packet-p772-fn.c" + + +/* +* Dissect STANAG 4406 PDUs inside a PPDU. +*/ +static int +dissect_p772(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* data _U_) +{ + int offset = 0; + proto_item *item=NULL; + proto_tree *tree=NULL; + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + + if (parent_tree) { + item = proto_tree_add_item(parent_tree, proto_p772, tvb, 0, -1, ENC_NA); + tree = proto_item_add_subtree(item, ett_p772); + } + + col_set_str(pinfo->cinfo, COL_PROTOCOL, "P772"); + col_set_str(pinfo->cinfo, COL_INFO, "Military"); + + dissect_p772_InformationObject(TRUE, tvb, offset, &asn1_ctx , tree, -1); + return tvb_captured_length(tvb); +} + + + +/*--- proto_register_p772 -------------------------------------------*/ +void proto_register_p772(void) { + + /* List of fields */ + static hf_register_info hf[] = + { +#include "packet-p772-hfarr.c" + }; + + /* List of subtrees */ + static gint *ett[] = { + &ett_p772, +#include "packet-p772-ettarr.c" + }; + + /* Register protocol */ + proto_p772 = proto_register_protocol(PNAME, PSNAME, PFNAME); + register_dissector("p772", dissect_p772, proto_p772); + + /* Register fields and subtrees */ + proto_register_field_array(proto_p772, hf, array_length(hf)); + proto_register_subtree_array(ett, array_length(ett)); + + register_ber_syntax_dissector("STANAG 4406", proto_p772, dissect_p772); + register_ber_oid_syntax(".p772", NULL, "STANAG 4406"); +} + + +/*--- proto_reg_handoff_p772 --- */ +void proto_reg_handoff_p772(void) { +#include "packet-p772-dis-tab.c" + + register_ber_oid_dissector("1.3.26.0.4406.0.4.1", dissect_p772, proto_p772, "STANAG 4406"); +} diff --git a/epan/dissectors/asn1/p772/packet-p772-template.h b/epan/dissectors/asn1/p772/packet-p772-template.h new file mode 100644 index 00000000..b9c09047 --- /dev/null +++ b/epan/dissectors/asn1/p772/packet-p772-template.h @@ -0,0 +1,17 @@ +/* packet-p772.h + * Routines for STANAG 4406 (X.400 Military Message Extensions) packet dissection + * Graeme Lunt 2005 + * + * Wireshark - Network traffic analyzer + * By Gerald Combs <gerald@wireshark.org> + * Copyright 1998 Gerald Combs + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ + +#ifndef PACKET_P772_H +#define PACKET_P772_H + +/* #include "packet-p772-exp.h" */ + +#endif /* PACKET_P772_H */ |