From robionekenobi: Enhancement of the packet-mq dissector (WMQ 7.1-7.5)
authorBill Meier <wmeier@newsguy.com>
Fri, 1 Nov 2013 20:13:15 +0000 (20:13 -0000)
committerBill Meier <wmeier@newsguy.com>
Fri, 1 Nov 2013 20:13:15 +0000 (20:13 -0000)
Add more detail for SPI Open LPOO Structure
Add more int_to_vals for INQ_Q_MGR reply
Add more display detail for encoding value
Some fix and display correction

See: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9367

svn path=/trunk/; revision=53027

epan/dissectors/packet-mq-base.c
epan/dissectors/packet-mq-pcf.c
epan/dissectors/packet-mq.c
epan/dissectors/packet-mq.h

index 2b797ff70e59189783442bb4f161e21bcc722821..e16fbc06325194b3153343475909a70900b17d4d 100644 (file)
@@ -59,7 +59,7 @@ guint16 tvb_get_guint16_endian(tvbuff_t *a_tvb, gint a_iOffset, gint a_rep)
        return sResult;
 };
 /* This routine truncates the string at the first blank space */
-guint32 strip_trailing_blanks(guint8* a_str, guint32 a_size)
+gint32 strip_trailing_blanks(guint8* a_str, guint32 a_size)
 {
        gint32 i = 0;
        if (a_str != NULL)
@@ -75,6 +75,15 @@ guint32 strip_trailing_blanks(guint8* a_str, guint32 a_size)
        return i;
 }
 
+DEF_VALRB(ccsid)
+       DEF_VALR3(MQCCSI_UNDEFINED   , MQCCSI_UNDEFINED, "UNDEFINED/DEFAULT/Q_MGR"),
+       DEF_VALR1(MQCCSI_EMBEDDED    ),
+       DEF_VALR1(MQCCSI_INHERIT     ),
+       DEF_VALR1(MQCCSI_APPL        ),
+       DEF_VALR1(MQCCSI_AS_PUBLISHED),
+       DEF_VALR3(MQCCSI_1           ,MQCCSI_65535, ""),
+DEF_VALRE;
+
 DEF_VALSB(mqat)
        DEF_VALS1(MQAT_UNKNOWN          ),
        DEF_VALS1(MQAT_NO_CONTEXT       ),
@@ -1713,8 +1722,8 @@ DEF_VALSE;
 
 DEF_VALSB(Monitoring)
        DEF_VALS1(MQMON_NONE  ),
-       DEF_VALS1(MQMON_ON    ),
-       DEF_VALS1(MQMON_OFF   ),
+       DEF_VALS2(MQMON_ON    ,"ON/ENABLED"),
+       DEF_VALS2(MQMON_OFF   ,"OFF/DISABLED"),
        DEF_VALS1(MQMON_LOW   ),
        DEF_VALS1(MQMON_MEDIUM),
        DEF_VALS1(MQMON_HIGH  ),
@@ -4881,10 +4890,6 @@ DEF_VALSB(IGQPutAuthority)
        DEF_VALS1(MQIGQPA_ALTERNATE_OR_IGQ),
 DEF_VALSE;
 
-/*Only on z/OS */
-#define MQSCYC_UPPER                   0
-#define MQSCYC_MIXED                   1
-
 DEF_VALSB(SecurityCase)
        DEF_VALS1(MQSCYC_UPPER),
        DEF_VALS1(MQSCYC_MIXED),
@@ -4892,8 +4897,8 @@ DEF_VALSE;
 
 DEF_VALSB(ChlauthType)
        DEF_VALS1(MQCAUT_BLOCKUSER ),
-       DEF_VALS1(MQCAUT_BLOCKADDR ), 
-       DEF_VALS1(MQCAUT_SSLPEERMAP), 
+       DEF_VALS1(MQCAUT_BLOCKADDR ),
+       DEF_VALS1(MQCAUT_SSLPEERMAP),
        DEF_VALS1(MQCAUT_ADDRESSMAP),
        DEF_VALS1(MQCAUT_USERMAP   ),
        DEF_VALS1(MQCAUT_QMGRMAP   ),
@@ -4910,10 +4915,52 @@ DEF_VALSB(Warning)
        DEF_VALS1(MQWARN_YES),
 DEF_VALSE;
 
+DEF_VALSB(CertValPolicy)
+       DEF_VALS1(MQ_CERT_VAL_POLICY_ANY    ),
+       DEF_VALS1(MQ_CERT_VAL_POLICY_RFC5280),
+DEF_VALSE;
+
+DEF_VALSB(ChanAutoDef)
+       DEF_VALS1(MQCHAD_DISABLED),
+       DEF_VALS1(MQCHAD_ENABLED ),
+DEF_VALSE;
+
+DEF_VALSB(ChlAuthRecords)
+       DEF_VALS1(MQCHLA_DISABLED),
+       DEF_VALS1(MQCHLA_ENABLED ),
+DEF_VALSE;
+
+DEF_VALSB(DefClusXmitTyp)
+       DEF_VALS1(MQCLXQ_SCTQ   ),
+       DEF_VALS1(MQCLXQ_CHANNEL),
+DEF_VALSE;
+
+DEF_VALSB(ServiceControl)
+       DEF_VALS1(MQSVC_CONTROL_Q_MGR      ),
+       DEF_VALS1(MQSVC_CONTROL_Q_MGR_START),
+       DEF_VALS1(MQSVC_CONTROL_MANUAL     ),
+DEF_VALSE;
+
+DEF_VALSB(Capability)
+       DEF_VALS1(MQCAP_NOT_SUPPORTED),
+       DEF_VALS1(MQCAP_SUPPORTED    ),
+       DEF_VALS1(MQCAP_EXPIRED      ),
+DEF_VALSE;
+
+DEF_VALSB(FipsRequired)
+       DEF_VALS1(MQSSL_FIPS_NO ),
+       DEF_VALS1(MQSSL_FIPS_YES),
+DEF_VALSE;
+
+DEF_VALSB(SyncpointAvailability)
+       DEF_VALS1(MQSP_AVAILABLE    ),
+       DEF_VALS1(MQSP_NOT_AVAILABLE),
+DEF_VALSE;
+
 DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIACF_ASYNC_STATE           ,GET_VALSP(AsynchronousStateValues)),
-       DEF_VALS2(MQIACF_CLUSTER_Q_MGR_ATTRS   ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_CHLAUTH_TYPE          ,GET_VALSP(ChlauthType)),
+       DEF_VALS2(MQIACF_CLUSTER_Q_MGR_ATTRS   ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_COMMAND               ,GET_VALSP(Command)),
        DEF_VALS2(MQIACF_CONNECTION_ATTRS      ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_CONN_INFO_TYPE        ,GET_VALSP(ConnInfoType)),
@@ -4925,17 +4972,17 @@ DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIACF_OPEN_INPUT_TYPE       ,GET_VALSP(QueueStatusOpenOptions)),
        DEF_VALS2(MQIACF_OPEN_INQUIRE          ,GET_VALSP(QueueStatusOptionsYesNo)),
        DEF_VALS2(MQIACF_OPEN_OUTPUT           ,GET_VALSP(QueueStatusOptionsYesNo)),
-       DEF_VALS2(MQIACF_OPEN_TYPE             ,GET_VALSP(QueueStatusOpenTypes)),
        DEF_VALS2(MQIACF_OPEN_SET              ,GET_VALSP(QueueStatusOptionsYesNo)),
+       DEF_VALS2(MQIACF_OPEN_TYPE             ,GET_VALSP(QueueStatusOpenTypes)),
        DEF_VALS2(MQIACF_PARAMETER_ID          ,GET_VALSP(PrmId)),
+       DEF_VALS2(MQIACF_QSG_DISPS             ,GET_VALSP(QShrGrpDisp)),
        DEF_VALS2(MQIACF_Q_ATTRS               ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_Q_MGR_ATTRS           ,GET_VALSP(PrmId)),
-       DEF_VALS2(MQIACF_QSG_DISPS             ,GET_VALSP(QShrGrpDisp)),
        DEF_VALS2(MQIACF_Q_STATUS_ATTRS        ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_Q_STATUS_TYPE         ,GET_VALSP(PrmId)),
        DEF_VALS2(MQIACF_Q_TYPES               ,GET_VALSP(QueueType)),
-       DEF_VALS2(MQIACF_UOW_TYPE              ,GET_VALSP(UOWTypes)),
        DEF_VALS2(MQIACF_UOW_STATE             ,GET_VALSP(UOWStates)),
+       DEF_VALS2(MQIACF_UOW_TYPE              ,GET_VALSP(UOWTypes)),
        DEF_VALS2(MQIACH_CHANNEL_DISP          ,GET_VALSP(ChannelDisp)),
        DEF_VALS2(MQIACH_CHANNEL_INSTANCE_TYPE ,GET_VALSP(ObjType)),
        DEF_VALS2(MQIACH_CHANNEL_STATUS        ,GET_VALSP(ChannelStatus)),
@@ -4954,29 +5001,39 @@ DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIACH_USER_SOURCE           ,GET_VALSP(UserSource)),
        DEF_VALS2(MQIACH_WARNING               ,GET_VALSP(Warning)),
        DEF_VALS2(MQIACH_XMIT_PROTOCOL_TYPE    ,GET_VALSP(TransportType)),
+       DEF_VALS2(MQIA_ACCOUNTING_CONN_OVERRIDE,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_ACCOUNTING_MQI          ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_ACCOUNTING_Q            ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_ACTIVITY_RECORDING      ,GET_VALSP(ActivityRecording)),
+       DEF_VALS2(MQIA_ACTIVITY_TRACE          ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_ADOPTNEWMCA_CHECK       ,GET_VALSP(AdoptNewMCACheck)),
        DEF_VALS2(MQIA_ADOPTNEWMCA_TYPE        ,GET_VALSP(AdoptNewMCAType)),
        DEF_VALS2(MQIA_APPL_TYPE               ,GET_VALSP(ApplType)),
-       DEF_VALS2(MQIA_AUTH_INFO_TYPE          ,GET_VALSP(AuthInfoType)),
        DEF_VALS2(MQIA_AUTHORITY_EVENT         ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_AUTH_INFO_TYPE          ,GET_VALSP(AuthInfoType)),
        DEF_VALS2(MQIA_BASE_TYPE               ,GET_VALSP(BaseType)),
        DEF_VALS2(MQIA_BRIDGE_EVENT            ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_CERT_VAL_POLICY         ,GET_VALSP(CertValPolicy)),
+       DEF_VALS2(MQIA_CHANNEL_AUTO_DEF        ,GET_VALSP(ChanAutoDef)),
+       DEF_VALS2(MQIA_CHANNEL_AUTO_DEF_EVENT  ,GET_VALSP(EventRule)),
        DEF_VALS2(MQIA_CHANNEL_EVENT           ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_CHINIT_CONTROL          ,GET_VALSP(ServiceControl)),
        DEF_VALS2(MQIA_CHINIT_TRACE_AUTO_START ,GET_VALSP(ChinitTraceAutoStart)),
+       DEF_VALS2(MQIA_CHLAUTH_RECORDS         ,GET_VALSP(ChlAuthRecords)),
        DEF_VALS2(MQIA_CLWL_USEQ               ,GET_VALSP(CLWLUseQ)),
+       DEF_VALS2(MQIA_CMD_SERVER_CONTROL      ,GET_VALSP(ServiceControl)),
        DEF_VALS2(MQIA_COMMAND_EVENT           ,GET_VALSP(EventRule)),
        DEF_VALS2(MQIA_CONFIGURATION_EVENT     ,GET_VALSP(EventRule)),
        DEF_VALS2(MQIA_DEFINITION_TYPE         ,GET_VALSP(DefinitionType)),
        DEF_VALS2(MQIA_DEF_BIND                ,GET_VALSP(Bindings)),
+       DEF_VALS2(MQIA_DEF_CLUSTER_XMIT_Q_TYPE ,GET_VALSP(DefClusXmitTyp)),
        DEF_VALS2(MQIA_DEF_INPUT_OPEN_OPTION   ,GET_VALSP(InputOpenOption)),
        DEF_VALS2(MQIA_DEF_PERSISTENCE         ,GET_VALSP(Persistence)),
        DEF_VALS2(MQIA_DEF_PUT_RESPONSE_TYPE   ,GET_VALSP(PutResponse)),
        DEF_VALS2(MQIA_DEF_READ_AHEAD          ,GET_VALSP(ReadAheadValues)),
-       DEF_VALS2(MQIA_DURABLE_SUB             ,GET_VALSP(DurableSubscriptions)),
        DEF_VALS2(MQIA_DIST_LISTS              ,GET_VALSP(DistributionLists)),
        DEF_VALS2(MQIA_DNS_WLM                 ,GET_VALSP(DNSWLM)),
+       DEF_VALS2(MQIA_DURABLE_SUB             ,GET_VALSP(DurableSubscriptions)),
        DEF_VALS2(MQIA_GROUP_UR                ,GET_VALSP(GroupUR)),
        DEF_VALS2(MQIA_HARDEN_GET_BACKOUT      ,GET_VALSP(BackOutHardening)),
        DEF_VALS2(MQIA_IGQ_PUT_AUTHORITY       ,GET_VALSP(IGQPutAuthority)),
@@ -4989,23 +5046,26 @@ DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIA_INTRA_GROUP_QUEUING     ,GET_VALSP(IntraGroupQueuing)),
        DEF_VALS2(MQIA_IP_ADDRESS_VERSION      ,GET_VALSP(IPAddressVersion)),
        DEF_VALS2(MQIA_LOCAL_EVENT             ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_LOGGER_EVENT            ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_MONITORING_AUTO_CLUSSDR ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_MONITORING_AUTO_CLUSSDR ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_MONITORING_CHANNEL      ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_MONITORING_Q            ,GET_VALSP(Monitoring)),
        DEF_VALS2(MQIA_MSG_DELIVERY_SEQUENCE   ,GET_VALSP(MsgDelivSeq)),
-       DEF_VALS2(MQIA_PM_DELIVERY             ,GET_VALSP(MsgDelivery)),
-       DEF_VALS2(MQIA_NPM_DELIVERY            ,GET_VALSP(MsgDelivery)),
        DEF_VALS2(MQIA_NPM_CLASS               ,GET_VALSP(NonpersistentMsgCls)),
+       DEF_VALS2(MQIA_NPM_DELIVERY            ,GET_VALSP(MsgDelivery)),
        DEF_VALS2(MQIA_PERFORMANCE_EVENT       ,GET_VALSP(EventRule)),
        DEF_VALS2(MQIA_PLATFORM                ,GET_VALSP(Platform)),
+       DEF_VALS2(MQIA_PM_DELIVERY             ,GET_VALSP(MsgDelivery)),
        DEF_VALS2(MQIA_PROPERTY_CONTROL        ,GET_VALSP(PropertyCtlVal)),
+       DEF_VALS2(MQIA_PROT_POLICY_CAPABILITY  ,GET_VALSP(Capability)),
        DEF_VALS2(MQIA_PROXY_SUB               ,GET_VALSP(ProxySubscriptions)),
-       DEF_VALS2(MQIA_PUB_SCOPE               ,GET_VALSP(PubSubScope)),
        DEF_VALS2(MQIA_PUBSUB_CLUSTER          ,GET_VALSP(PubSubCluster)),
        DEF_VALS2(MQIA_PUBSUB_MODE             ,GET_VALSP(PubSubMode)),
        DEF_VALS2(MQIA_PUBSUB_NP_MSG           ,GET_VALSP(PubSubNP)),
        DEF_VALS2(MQIA_PUBSUB_NP_RESP          ,GET_VALSP(PubSubNP)),
        DEF_VALS2(MQIA_PUBSUB_SYNC_PT          ,GET_VALSP(PubSubSync)),
+       DEF_VALS2(MQIA_PUB_SCOPE               ,GET_VALSP(PubSubScope)),
        DEF_VALS2(MQIA_QMGR_CFCONLOS           ,GET_VALSP(CFConLoss)),
        DEF_VALS2(MQIA_QSG_DISP                ,GET_VALSP(QShrGrpDisp)),
        DEF_VALS2(MQIA_Q_DEPTH_HIGH_EVENT      ,GET_VALSP(EventRule)),
@@ -5020,8 +5080,15 @@ DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIA_SHAREABILITY            ,GET_VALSP(Shareability)),
        DEF_VALS2(MQIA_SHARED_Q_Q_MGR_NAME     ,GET_VALSP(SharedQueueQueueManagerName)),
        DEF_VALS2(MQIA_SSL_EVENT               ,GET_VALSP(EventRule)),
-       DEF_VALS2(MQIA_SUB_SCOPE               ,GET_VALSP(PubSubScope)),
+       DEF_VALS2(MQIA_SSL_FIPS_REQUIRED       ,GET_VALSP(FipsRequired)),
        DEF_VALS2(MQIA_START_STOP_EVENT        ,GET_VALSP(EventRule)),
+       DEF_VALS2(MQIA_STATISTICS_AUTO_CLUSSDR ,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_STATISTICS_CHANNEL      ,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_STATISTICS_INTERVAL     ,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_STATISTICS_MQI          ,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_STATISTICS_Q            ,GET_VALSP(Monitoring)),
+       DEF_VALS2(MQIA_SUB_SCOPE               ,GET_VALSP(PubSubScope)),
+       DEF_VALS2(MQIA_SYNCPOINT               ,GET_VALSP(SyncpointAvailability)),
        DEF_VALS2(MQIA_TCP_KEEP_ALIVE          ,GET_VALSP(TCPKeepAlive)),
        DEF_VALS2(MQIA_TCP_STACK_TYPE          ,GET_VALSP(TCPStackType)),
        DEF_VALS2(MQIA_TOPIC_DEF_PERSISTENCE   ,GET_VALSP(Persistence)),
@@ -5032,6 +5099,7 @@ DEF_VALSB(MQCFINT_Parse)
        DEF_VALS2(MQIA_UR_DISP                 ,GET_VALSP(QShrGrpDisp)),
        DEF_VALS2(MQIA_USAGE                   ,GET_VALSP(Usage)),
        DEF_VALS2(MQIA_WILDCARD_OPERATION      ,GET_VALSP(WildcardOperation)),
+       DEF_VALS2(MQIA_XR_CAPABILITY           ,GET_VALSP(Capability)),
 DEF_VALSE;
 
 /*
index bbec082c0fa98afd27df4c4ba8f3fb0309f00cd2..ecc0484fdb5789098334f3d9a5723373cbdc7960 100644 (file)
@@ -31,9 +31,9 @@
  *
  *   MQ PCF documentation is called "WebSphere MQ Programmable Command Formats and Administration Interface"
 */
+
 #include "config.h"
+
 #include <string.h>
 #include <math.h>
 
@@ -68,6 +68,7 @@ static int hf_mqpcf_cfh_ParmCount = -1;
 static int hf_mq_pcf_prmtyp = -1;
 static int hf_mq_pcf_prmlen = -1;
 static int hf_mq_pcf_prmid = -1;
+static int hf_mq_pcf_prmidnovals = -1;
 static int hf_mq_pcf_filterop = -1;
 static int hf_mq_pcf_prmccsid = -1;
 static int hf_mq_pcf_prmstrlen = -1;
@@ -111,13 +112,15 @@ guint8 *dissect_mqpcf_parm_getintval(guint uPrm,guint uVal)
        return NULL;
 }
 
-void dissect_mqpcf_parm_int(tvbuff_t *tvb, proto_tree *tree, guint offset, guint uPrm, 
-                                                       guint uVal, int hfindex, guint iCnt, guint iMaxCnt, guint iDigit)
+void dissect_mqpcf_parm_int(tvbuff_t *tvb, proto_tree *tree, guint offset, guint uPrm,
+                                                       guint uVal, int hfindex, guint iCnt, guint iMaxCnt, guint iDigit, gboolean bParse)
 {
        header_field_info *hfinfo;
-       guint8 *pVal;
+       guint8 *pVal = NULL;
+
+       if (bParse)
+               pVal=dissect_mqpcf_parm_getintval(uPrm,uVal);
 
-       pVal=dissect_mqpcf_parm_getintval(uPrm,uVal);
        hfinfo=proto_registrar_get_nth(hfindex);
 
        if (iMaxCnt>1)
@@ -148,7 +151,8 @@ void dissect_mqpcf_parm_int(tvbuff_t *tvb, proto_tree *tree, guint offset, guint
        }
 }
 
-static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq_tree, guint offset,guint32 uCount,guint bLittleEndian)
+static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq_tree,
+                                                          guint offset, guint32 uCount, guint bLittleEndian, gboolean bParse)
 {
        guint32 u=0;
        guint32 tOfs=0;
@@ -168,8 +172,21 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
        const char sPrmLn0[] = " MQPrm[%3u] has a zero length. DECODE Failed (MQPrm Count: %u)";
        const char sMaxPrm[] = " Max # of Parm reached. DECODE interrupted   (actual %u of %u)";
 
-       proto_item *ti=NULL;
-       proto_tree *tree=NULL;
+       proto_item *ti = NULL;
+       proto_tree *tree = NULL;
+
+       if (uCount == (guint32)-1)
+       {
+               guint32 xOfs=offset;
+               guint32  uCnt=0;
+               while (tvb_length_remaining(tvb, xOfs) >= 16)
+               {
+                       uLen = tvb_get_guint32_endian(tvb, xOfs + 4, bLittleEndian);
+                       uCnt++;
+                       xOfs+=uLen;
+               }
+               uCount=uCnt;
+       }
 
        uDig=dissect_mqpcf_getDigits(uCount);
 
@@ -188,10 +205,16 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                uPrm=tvb_get_guint32_endian(tvb, offset + 8, bLittleEndian);
                uLenF=12;
 
-               g_snprintf(strPrm,(gulong)sizeof(strPrm)-1," %-s[%*u] {%2d-%-15.15s} %8x/%5d-%-30.30s",
-                       "MQPrm", uDig, u+1,
-                       uTyp,val_to_str_const(uTyp,GET_VALSV(PrmTyp),"      Unknown")+6,
-                       uPrm,uPrm,val_to_str_const(uPrm,GET_VALSV(PrmId),"Unknown"));
+               if (bParse)
+                       g_snprintf(strPrm,(gulong)sizeof(strPrm)-1," %-s[%*u] {%2d-%-15.15s} %8x/%5d-%-30.30s",
+                               "MQPrm", uDig, u+1,
+                               uTyp,val_to_str_const(uTyp,GET_VALSV(PrmTyp),"      Unknown")+6,
+                               uPrm,uPrm,val_to_str_const(uPrm,GET_VALSV(PrmId),"Unknown"));
+               else
+                       g_snprintf(strPrm,(gulong)sizeof(strPrm)-1," %-s[%*u] {%2d-%-15.15s} %8x/%5d",
+                               "XtraD", uDig, u+1,
+                               uTyp, val_to_str_const(uTyp,GET_VALSV(PrmTyp),"      Unknown")+6,
+                               uPrm, uPrm);
 
                switch (uTyp)
                {
@@ -203,9 +226,10 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                        break;
                case MQ_MQCFT_INTEGER:
                        {
-                               guint8 *pVal;
+                               guint8 *pVal = NULL;
                                uVal = tvb_get_guint32_endian(tvb, offset + uLenF, bLittleEndian);
-                               pVal = dissect_mqpcf_parm_getintval(uPrm,uVal);
+                               if (bParse)
+                                       pVal = dissect_mqpcf_parm_getintval(uPrm, uVal);
                                if (pVal)
                                {
                                        ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %d-%s",
@@ -219,9 +243,9 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp, tvb, offset    , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen, tvb, offset + 4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid , tvb, offset + 8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset + 8, 4, bLittleEndian);
 
-                               dissect_mqpcf_parm_int(tvb, tree, offset+uLenF, uPrm, uVal, hf_mq_pcf_int, 0, 0, 0);
+                               dissect_mqpcf_parm_int(tvb, tree, offset+uLenF, uPrm, uVal, hf_mq_pcf_int, 0, 0, 0, bParse);
                        }
                        break;
                case MQ_MQCFT_STRING:
@@ -230,7 +254,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                uCCS = tvb_get_guint32_endian(tvb, offset + uLenF, bLittleEndian);
                                uSLn = tvb_get_guint32_endian(tvb, offset + uLenF + 4, bLittleEndian);
-                               sStr = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + uLenF + 8, 
+                               sStr = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + uLenF + 8,
                                        uSLn, (uCCS!=500)?ENC_ASCII:ENC_EBCDIC);
                                if (*sStr)
                                        strip_trailing_blanks(sStr,uSLn);
@@ -242,7 +266,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmccsid , tvb, offset + 12, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmstrlen, tvb, offset + 16, 4, bLittleEndian);
 
@@ -262,14 +286,14 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp  , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen  , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid   , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmcount, tvb, offset + 12, 4, bLittleEndian);
 
                                offset += uLenF+4;
                                for (u2 = 0; u2 < uCnt && u2 < mq_pcf_maxlst; u2++)
                                {
                                        uVal = tvb_get_guint32_endian(tvb, offset, bLittleEndian);
-                                       dissect_mqpcf_parm_int(tvb, tree, offset, uPrm, uVal, hf_mq_pcf_intlist, u2+1, uCnt, uDigit);
+                                       dissect_mqpcf_parm_int(tvb, tree, offset, uPrm, uVal, hf_mq_pcf_intlist, u2+1, uCnt, uDigit, bParse);
                                        offset += 4;
                                }
                                if (u2 != uCnt)
@@ -297,7 +321,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmccsid , tvb, offset + 12, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmcount , tvb, offset + 16, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmstrlen, tvb, offset + 20, 4, bLittleEndian);
@@ -307,7 +331,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                offset += uLenF+12;
                                for (u2 = 0; u2 < uCnt && u2 < mq_pcf_maxlst; u2++)
                                {
-                                       sStr = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, 
+                                       sStr = tvb_get_string_enc(wmem_packet_scope(), tvb, offset,
                                                uSLn, (uCCS!=500)?ENC_ASCII:ENC_EBCDIC);
                                        if (*sStr)
                                                strip_trailing_blanks(sStr,uSLn);
@@ -328,6 +352,16 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                case MQ_MQCFT_EVENT:
                        break;
                case MQ_MQCFT_USER:
+                       {
+                               uSLn = tvb_get_guint32_endian(tvb, offset + uLenF, bLittleEndian);
+                               ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s", strPrm);
+                               tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
+
+                               proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
+                               proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
+
+                               proto_tree_add_item(tree, hf_mq_pcf_bytestring, tvb, offset + 8, uLen - 8, bLittleEndian);
+                       }
                        break;
                case MQ_MQCFT_BYTE_STRING:
                        {
@@ -353,7 +387,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmstrlen, tvb, offset + 12, 4, bLittleEndian);
 
                                proto_tree_add_item(tree, hf_mq_pcf_bytestring, tvb, offset + uLenF + 4 , uSLn, bLittleEndian);
@@ -370,13 +404,13 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                uOpe = tvb_get_guint32_endian(tvb, offset + uLenF    , bLittleEndian);
                                uVal = tvb_get_guint32_endian(tvb, offset + uLenF + 4, bLittleEndian);
 
-                               ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s %d", 
+                               ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s %d",
                                        strPrm, val_to_str(uOpe, GET_VALSV(FilterOP),"       Unknown (0x%02x)")+7, uVal);
                                tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_filterop , tvb, offset + 12, 4, bLittleEndian);
 
                                proto_tree_add_item(tree, hf_mq_pcf_int, tvb, offset + uLenF + 4, 4, bLittleEndian);
@@ -393,13 +427,13 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                sStr = format_text_chr(tvb_get_string_enc(wmem_packet_scope(), tvb, offset + uLenF + 12, uSLn, (uCCS!=500)?ENC_ASCII:ENC_EBCDIC), uSLn, '.');
                                strip_trailing_blanks(sStr,uSLn);
 
-                               ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s %s", 
+                               ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s %s",
                                        strPrm, val_to_str(uOpe, GET_VALSV(FilterOP),"       Unknown (0x%02x)")+7, sStr);
                                tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_filterop , tvb, offset + 12, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmccsid , tvb, offset + 16, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmstrlen, tvb, offset + 20, 4, bLittleEndian);
@@ -416,19 +450,19 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
                                {
                                        guint8 *sStrA = format_text_chr(tvb_get_string_enc(wmem_packet_scope(), tvb, offset + uLenF + 8,uSLn,ENC_ASCII) , uSLn, '.');
                                        guint8 *sStrE = format_text_chr(tvb_get_string_enc(wmem_packet_scope(), tvb, offset + uLenF + 8,uSLn,ENC_EBCDIC), uSLn, '.');
-                                       ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s A(%s) E(%s)", 
+                                       ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s A(%s) E(%s)",
                                                strPrm, val_to_str(uOpe, GET_VALSV(FilterOP),"       Unknown (0x%02x)")+7, sStrA, sStrE);
                                }
                                else
                                {
-                                       ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s <MISSING>", 
+                                       ti = proto_tree_add_text(mq_tree, tvb, offset, uLen, "%s %s <MISSING>",
                                                strPrm, val_to_str(uOpe, GET_VALSV(FilterOP),"       Unknown (0x%02x)")+7);
                                }
                                tree = proto_item_add_subtree(ti, ett_mqpcf_prm);
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_filterop , tvb, offset + 12, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmstrlen, tvb, offset + 16, 4, bLittleEndian);
 
@@ -458,7 +492,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp   , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen   , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid    , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmunused, tvb, offset + 12, 4, bLittleEndian);
 
                                proto_tree_add_item(tree, hf_mq_pcf_int64, tvb, offset + uLenF + 4, 8, bLittleEndian);
@@ -479,7 +513,7 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
 
                                proto_tree_add_item(tree, hf_mq_pcf_prmtyp  , tvb, offset     , 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmlen  , tvb, offset +  4, 4, bLittleEndian);
-                               proto_tree_add_item(tree, hf_mq_pcf_prmid   , tvb, offset +  8, 4, bLittleEndian);
+                               proto_tree_add_item(tree, (bParse)?hf_mq_pcf_prmid:hf_mq_pcf_prmidnovals, tvb, offset +  8, 4, bLittleEndian);
                                proto_tree_add_item(tree, hf_mq_pcf_prmcount, tvb, offset + 12, 4, bLittleEndian);
 
                                offset += uLenF + 4;
@@ -507,12 +541,12 @@ static void dissect_mqpcf_parm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mq
        }
 }
 
-static void dissect_mqpcf(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, struct mqinfo* mqinfo)
+static void dissect_mqpcf(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, mq_parm_t* p_mq_parm)
 {
        gint offset = 0;
        gboolean bLittleEndian;
 
-       bLittleEndian = ((mqinfo->encoding & MQ_MQENC_INTEGER_MASK)==MQ_MQENC_INTEGER_REVERSED)?ENC_LITTLE_ENDIAN:ENC_BIG_ENDIAN;
+       bLittleEndian = ((p_mq_parm->mq_cur_ccsid.encod & MQ_MQENC_INTEGER_MASK)==MQ_MQENC_INTEGER_REVERSED)?ENC_LITTLE_ENDIAN:ENC_BIG_ENDIAN;
 
        if (tvb_length(tvb) >= 36)
        {
@@ -573,7 +607,7 @@ static void dissect_mqpcf(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, s
                        proto_tree_add_item(mq_tree, hf_mqpcf_cfh_compcode , tvb, offset + 24, 4, bLittleEndian);
                        proto_tree_add_item(mq_tree, hf_mqpcf_cfh_reason   , tvb, offset + 28, 4, bLittleEndian);
                        proto_tree_add_item(mq_tree, hf_mqpcf_cfh_ParmCount, tvb, offset + 32, 4, bLittleEndian);
-                       dissect_mqpcf_parm(tvb, pinfo, mqroot_tree, offset + iSizeMQCFH, uCnt, bLittleEndian);
+                       dissect_mqpcf_parm(tvb, pinfo, mqroot_tree, offset + iSizeMQCFH, uCnt, bLittleEndian, TRUE);
                }
        }
 }
@@ -582,13 +616,20 @@ static gboolean dissect_mqpcf_heur(tvbuff_t *tvb, packet_info *pinfo, proto_tree
 {
        if (tvb_length(tvb) >= 36)
        {
-               struct mqinfo* mqinfo = (struct mqinfo *)data;
-               if (strncmp((const char*)mqinfo->format, MQ_MQFMT_ADMIN, 8) == 0
-                       || strncmp((const char*)mqinfo->format, MQ_MQFMT_EVENT, 8) == 0
-                       || strncmp((const char*)mqinfo->format, MQ_MQFMT_PCF, 8) == 0)
+               mq_parm_t* p_mq_parm = (mq_parm_t *)data;
+               if (strncmp((const char*)p_mq_parm->mq_format, MQ_MQFMT_ADMIN, 8) == 0
+                       || strncmp((const char*)p_mq_parm->mq_format, MQ_MQFMT_EVENT, 8) == 0
+                       || strncmp((const char*)p_mq_parm->mq_format, MQ_MQFMT_PCF, 8) == 0)
                {
                        /* Dissect the packet */
-                       dissect_mqpcf(tvb, pinfo, tree, mqinfo);
+                       dissect_mqpcf(tvb, pinfo, tree, p_mq_parm);
+                       return TRUE;
+               }
+               if (strncmp((const char *)p_mq_parm->mq_format, "LPOO", 4) == 0)
+               {
+                       gboolean bLittleEndian;
+                       bLittleEndian = ((p_mq_parm->mq_cur_ccsid.encod & MQ_MQENC_INTEGER_MASK)==MQ_MQENC_INTEGER_REVERSED)?ENC_LITTLE_ENDIAN:ENC_BIG_ENDIAN;
+                       dissect_mqpcf_parm(tvb, pinfo, tree, 0, (guint32)-1, bLittleEndian, FALSE);
                        return TRUE;
                }
        }
@@ -599,7 +640,7 @@ void proto_register_mqpcf(void)
 {
        expert_module_t* expert_mqpcf;
 
-       static hf_register_info hf[] = 
+       static hf_register_info hf[] =
        {
                { &hf_mqpcf_cfh_type     , { "Type.....", "mqpcf.cfh.type", FT_UINT32, BASE_DEC, VALS(&GET_VALSV(mqcft)), 0x0, "CFH type", HFILL }},
                { &hf_mqpcf_cfh_length   , { "Length...", "mqpcf.cfh.length", FT_UINT32, BASE_DEC, NULL, 0x0, "CFH length", HFILL }},
@@ -614,8 +655,9 @@ void proto_register_mqpcf(void)
                { &hf_mq_pcf_prmtyp      , { "ParmTyp..", "mqpcf.parm.type", FT_UINT32, BASE_DEC, VALS(&GET_VALSV(PrmTyp)), 0x0, "MQPCF parameter type", HFILL }},
                { &hf_mq_pcf_prmlen      , { "ParmLen..", "mqpcf.parm.len", FT_UINT32, BASE_DEC, NULL, 0x0, "MQPCF parameter length", HFILL }},
                { &hf_mq_pcf_prmid       , { "ParmID...", "mqpcf.parm.id", FT_UINT32, BASE_DEC, VALS(&GET_VALSV(PrmId)), 0x0, "MQPCF parameter id", HFILL }},
+               { &hf_mq_pcf_prmidnovals , { "ParmID...", "mqpcf.parm.idNoVals", FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MQPCF parameter id No Vals", HFILL }},
                { &hf_mq_pcf_filterop    , { "FilterOP.", "mqpcf.filter.op", FT_UINT32, BASE_DEC, VALS(&GET_VALSV(FilterOP)), 0x0, "MQPCF Filter operator", HFILL }},
-               { &hf_mq_pcf_prmccsid    , { "ParmCCSID", "mqpcf.parm.ccsid", FT_UINT32, BASE_DEC, NULL, 0x0, "MQPCF parameter ccsid", HFILL }},
+               { &hf_mq_pcf_prmccsid    , { "ParmCCSID", "mqpcf.parm.ccsid", FT_UINT32, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "MQPCF parameter ccsid", HFILL }},
                { &hf_mq_pcf_prmstrlen   , { "ParmStrLn", "mqpcf.parm.strlen", FT_UINT32, BASE_DEC, NULL, 0x0, "MQPCF parameter strlen", HFILL }},
                { &hf_mq_pcf_prmcount    , { "ParmCount", "mqpcf.parm.count", FT_UINT32, BASE_DEC, NULL, 0x0, "MQPCF parameter count", HFILL }},
                { &hf_mq_pcf_prmunused   , { "ParmUnuse", "mqpcf.parm.unused", FT_UINT32, BASE_DEC, NULL, 0x0, "MQPCF parameter unused", HFILL }},
@@ -627,13 +669,13 @@ void proto_register_mqpcf(void)
                { &hf_mq_pcf_int64       , { "Int64....", "mqpcf.parm.int64", FT_INT64, BASE_DEC, NULL, 0x0, "MQPCF parameter int64", HFILL }},
                { &hf_mq_pcf_int64list   , { "Int64List", "mqpcf.parm.int64list", FT_INT64, BASE_DEC, NULL, 0x0, "MQPCF parameter int64 list", HFILL }},
        };
-       static gint *ett[] = 
+       static gint *ett[] =
        {
                &ett_mqpcf,
                &ett_mqpcf_prm,
                &ett_mqpcf_cfh,
        };
-       static ei_register_info ei[] = 
+       static ei_register_info ei[] =
        {
                { &ei_mq_pcf_prmln0, { "mqpcf.parm.len0", PI_MALFORMED, PI_ERROR, "MQPCF Parameter length is 0", EXPFILL }},
                { &ei_mq_pcf_MaxInt, { "mqpcf.parm.IntList", PI_UNDECODED, PI_WARN, "MQPCF Parameter Integer list exhausted", EXPFILL }},
index 550e2fa67fd9e8bbaf43e2608483ab88a64edab7..17df77020e5355bd940a7ef04478c786b71050d9 100644 (file)
@@ -99,6 +99,7 @@ static int hf_mq_tsh_ctlflgs1 = -1;
 static int hf_mq_tsh_ctlflgs2 = -1;
 static int hf_mq_tsh_luwid = -1;
 static int hf_mq_tsh_encoding = -1;
+
 static int hf_mq_tsh_ccsid = -1;
 static int hf_mq_tsh_reserved = -1;
 
@@ -111,7 +112,7 @@ static int hf_mq_tsh_tcf_first = -1;
 static int hf_mq_tsh_tcf_last = -1;
 static int hf_mq_tsh_tcf_reqacc = -1;
 static int hf_mq_tsh_tcf_dlq = -1;
-static const int *pf_flds_tcf[] = 
+static const int *pf_flds_tcf[] =
 {
        &hf_mq_tsh_tcf_dlq       ,
        &hf_mq_tsh_tcf_reqacc    ,
@@ -605,14 +606,27 @@ static const int *pf_flds_mtchopt[] =
 
 static int hf_mq_lpoo_StructID = -1;
 static int hf_mq_lpoo_version = -1;
-static int hf_mq_lpoo_unknown1 = -1;
-static int hf_mq_lpoo_unknown2 = -1;
-static int hf_mq_lpoo_unknown3 = -1;
-static int hf_mq_lpoo_unknown4 = -1;
-static int hf_mq_lpoo_unknown5 = -1;
+static int hf_mq_lpoo_options = -1;
+static int hf_mq_lpoo_lpiopts = -1;
+static int hf_mq_lpoo_defpersist = -1;
+static int hf_mq_lpoo_defputresptype = -1;
+static int hf_mq_lpoo_defreadahead = -1;
 static int hf_mq_lpoo_qprotect = -1;
 static int hf_mq_lpoo_unknown6 = -1;
-static int hf_mq_lpoo_unknown7 = -1;
+/*static int hf_mq_lpoo_unknown7 = -1;*/
+static int hf_mq_lpoo_xtradata = -1;
+
+static int hf_mq_lpoo_lpiopts_SAVE_IDENTITY_CTXT = -1;
+static int hf_mq_lpoo_lpiopts_SAVE_ORIGIN_CTXT   = -1 ;
+static int hf_mq_lpoo_lpiopts_SAVE_USER_CTXT     = -1;
+static const int *pf_flds_lpooopt[] = 
+{
+       &hf_mq_lpoo_lpiopts_SAVE_IDENTITY_CTXT,
+       &hf_mq_lpoo_lpiopts_SAVE_ORIGIN_CTXT,
+       &hf_mq_lpoo_lpiopts_SAVE_USER_CTXT,
+       NULL
+};
+
 
 static int hf_mq_charv_vsptr     = -1;
 static int hf_mq_charv_vsoffset  = -1;
@@ -818,7 +832,8 @@ static gint ett_mq_pmo = -1;
 static gint ett_mq_pmo_option = -1;
 
 static gint ett_mq_lpoo = -1;
-static gint ett_mq_lpoo_option = -1;
+static gint ett_mq_lpoo_options = -1;
+static gint ett_mq_lpoo_lpiopts = -1;
 
 static gint ett_mq_head = -1; /* Factorisation of common Header structure items (DH, MDE, CIH, IIH, RFH, RMH, WIH */
 static gint ett_mq_xa = -1;
@@ -1195,9 +1210,10 @@ static reassembly_table mq_reassembly_table;
 #define MQ_TEXT_NOTIFICATION "NOTIFICATION"
 #define MQ_TEXT_BIND_READAHEAD_AS_Q_DEF "Bind/Read Ahead As Q Def"
 #define MQ_TEXT_IMMEDIATE_NONE "Close Immediate/No option"
-#define MQ_TEXT_MQPMO_NONE "Resp as Q Def/Resp as Topic Def/None"
-#define MQ_TEXT_MQGMO_NONE "No Wait/Prop as Q Def/None"
-#define MQ_TEXT_MQMO_NONE  "None"
+#define MQ_TEXT_MQPMO_NONE     "Resp as Q Def/Resp as Topic Def/None"
+#define MQ_TEXT_MQGMO_NONE     "No Wait/Prop as Q Def/None"
+#define MQ_TEXT_MQMO_NONE      "None"
+#define MQ_TEXT_LPOOOPT_NONE   "None"
 
 #define MQ_TEXT_PING  "PING"
 #define MQ_TEXT_RESET "RESET"
@@ -1246,11 +1262,6 @@ static reassembly_table mq_reassembly_table;
 #define MQ_TEXT_PMR  "Put Message Record"
 #define MQ_TEXT_RR   "Response Record"
 
-/* Notification Code */
-#define MQ_NOTIF_COMPLETED   12 /* 0x0c */
-#define MQ_NOTIF_FAILED      14 /* 0x0e */
-#define MQ_NOTIF_NODATA      11 /* 0x0b */
-
 #define MQ_NC_GET_INHIBITED          1
 #define MQ_NC_GET_ALLOWED            2
 #define MQ_NC_CONN_STATE             3
@@ -1529,14 +1540,93 @@ DEF_VALSB(sidtype)
        DEF_VALS1(MQSIDT_WAS_SECURITY_ID),
 DEF_VALSE;
 
-struct mq_msg_properties
+static gint dissect_mq_encoding(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding)
 {
-       gint iOffsetEncoding;     /* Message encoding */
-       gint iOffsetCcsid;        /* Message character set */
-       gint iOffsetFormat;       /* Message format */
-};
+       gchar  sEnc[128] = "";
+       gchar *pEnc;
+       guint  uEnc;
+
+       if (length == 2)
+       {
+               uEnc=(gint)tvb_get_guint16_endian(tvb, start, encoding);
+       }
+       else
+       {
+               uEnc=tvb_get_guint32_endian(tvb, start, encoding);
+       }
+       pEnc=sEnc;
 
-static gint dissect_mq_MQMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gint ett_subtree, mq_parm_t *p_mq_parm)
+#define CHECK_ENC(M, T) ((uEnc & M) == T)
+#define DOPRT(A) pEnc += g_snprintf(pEnc, (gulong)(sizeof(sEnc)-1-(pEnc-sEnc)), A);
+       if (CHECK_ENC(MQ_MQENC_FLOAT_MASK,MQ_MQENC_FLOAT_UNDEFINED))
+       {
+               DOPRT("FLT_UNDEFINED");
+       }
+       else if (CHECK_ENC(MQ_MQENC_FLOAT_MASK,MQ_MQENC_FLOAT_IEEE_NORMAL))
+       {
+               DOPRT("FLT_IEEE_NORMAL");
+       }
+       else if (CHECK_ENC(MQ_MQENC_FLOAT_MASK,MQ_MQENC_FLOAT_IEEE_REVERSED))
+       {
+               DOPRT("FLT_IEEE_REVERSED");
+       }
+       else if (CHECK_ENC(MQ_MQENC_FLOAT_MASK,MQ_MQENC_FLOAT_S390))
+       {
+               DOPRT("FLT_S390");
+       }
+       else if (CHECK_ENC(MQ_MQENC_FLOAT_MASK,MQ_MQENC_FLOAT_TNS))
+       {
+               DOPRT("FLT_TNS");
+       }else 
+       {
+               DOPRT("FLT_UNKNOWN");
+       }
+
+       DOPRT("/");
+       if (CHECK_ENC(MQ_MQENC_DECIMAL_MASK,MQ_MQENC_DECIMAL_UNDEFINED))
+       {
+               DOPRT("DEC_UNDEFINED");
+       }
+       else if (CHECK_ENC(MQ_MQENC_DECIMAL_MASK,MQ_MQENC_DECIMAL_NORMAL))
+       {
+               DOPRT("DEC_NORMAL");
+       }
+       else if (CHECK_ENC(MQ_MQENC_DECIMAL_MASK,MQ_MQENC_DECIMAL_REVERSED))
+       {
+               DOPRT("DEC_REVERSED");
+       }
+       else 
+       {
+               DOPRT("DEC_UNKNOWN");
+       }
+
+       DOPRT("/");
+       if (CHECK_ENC(MQ_MQENC_INTEGER_MASK,MQ_MQENC_INTEGER_UNDEFINED))
+       {
+               DOPRT("INT_UNDEFINED");
+       }
+       else if (CHECK_ENC(MQ_MQENC_INTEGER_MASK,MQ_MQENC_INTEGER_NORMAL))
+       {
+               DOPRT("INT_NORMAL");
+       }
+       else if (CHECK_ENC(MQ_MQENC_INTEGER_MASK,MQ_MQENC_INTEGER_REVERSED))
+       {
+               DOPRT("INT_REVERSED");
+       }
+       else 
+       {
+               DOPRT("INT_UNKNOWN");
+       }
+#undef CHECK_ENC
+#undef DOPRT
+       
+       proto_tree_add_uint_format_value(tree, hfindex, tvb, start, length, uEnc, 
+               "%8x-%d (%s)", uEnc, uEnc, sEnc);
+
+       return length;
+}
+
+static gint dissect_mq_MQMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset, gint ett_subtree, mq_parm_t *p_mq_parm)
 {
        guint        uMoOpt;
 
@@ -1556,8 +1646,27 @@ static gint dissect_mq_MQMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gint
        }
        return 4;
 }
+static gint dissect_mq_LPOO_LPIOPTS(tvbuff_t *tvb, proto_tree *mq_tree, gint offset, gint ett_subtree, mq_parm_t *p_mq_parm)
+{
+       guint        uLpiOpts;
+
+       uLpiOpts = tvb_get_guint32_endian(tvb, offset,p_mq_parm->mq_int_enc);
 
-static gint dissect_mq_MQGMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gint ett_subtree, mq_parm_t *p_mq_parm)
+       if (uLpiOpts == 0)
+       {
+               proto_item  *ti;
+               proto_tree  *mq_tree_sub;
+               ti = proto_tree_add_item(mq_tree, hf_mq_lpoo_lpiopts, tvb, offset, 4, p_mq_parm->mq_int_enc);
+               mq_tree_sub = proto_item_add_subtree(ti, ett_subtree);
+               proto_tree_add_text(mq_tree_sub, tvb, offset, 4, MQ_TEXT_LPOOOPT_NONE);
+       }
+       else
+       {
+               proto_tree_add_bitmask(mq_tree, tvb, offset, hf_mq_lpoo_lpiopts, ett_subtree, pf_flds_lpooopt, p_mq_parm->mq_int_enc);
+       }
+       return 4;
+}
+static gint dissect_mq_MQGMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset, gint ett_subtree, mq_parm_t *p_mq_parm)
 {
        guint        uGmoOpt;
 
@@ -1599,7 +1708,7 @@ static gint dissect_mq_MQPMO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gin
        return 4;
 }
 
-static gint dissect_mq_MQOO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gint ett_subtree, mq_parm_t *p_mq_parm)
+static gint dissect_mq_MQOO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset, gint ett_subtree, gint hfindex, mq_parm_t *p_mq_parm)
 {
        guint        uOpenOpt;
 
@@ -1609,13 +1718,13 @@ static gint dissect_mq_MQOO(tvbuff_t *tvb, proto_tree *mq_tree, gint offset,gint
        {
                proto_item  *ti;
                proto_tree  *mq_tree_sub;
-               ti = proto_tree_add_item(mq_tree, hf_mq_open_options, tvb, offset, 4, p_mq_parm->mq_int_enc);
+               ti = proto_tree_add_item(mq_tree, hfindex, tvb, offset, 4, p_mq_parm->mq_int_enc);
                mq_tree_sub = proto_item_add_subtree(ti, ett_subtree);
                proto_tree_add_text(mq_tree_sub, tvb, offset, 4, MQ_TEXT_BIND_READAHEAD_AS_Q_DEF);
        }
        else
        {
-               proto_tree_add_bitmask(mq_tree, tvb, offset, hf_mq_open_options, ett_subtree, pf_flds_opnopt, p_mq_parm->mq_int_enc);
+               proto_tree_add_bitmask(mq_tree, tvb, offset, hfindex, ett_subtree, pf_flds_opnopt, p_mq_parm->mq_int_enc);
        }
        return 4;
 }
@@ -1799,7 +1908,7 @@ static gint dissect_mq_gmo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
                {
                        guint8 *sQueue;
                        sQueue = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 24, 48, p_mq_parm->mq_str_enc);
-                       if (strip_trailing_blanks(sQueue, 48) != 0)
+                       if (strip_trailing_blanks(sQueue, 48) > 0)
                        {
                                col_append_fstr(pinfo->cinfo, COL_INFO, " Q=%s", sQueue);
                        }
@@ -1865,7 +1974,7 @@ static gint dissect_mq_pmo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
                        guint8 * sQueue;
 
                        sQueue = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 32, 48, p_mq_parm->mq_str_enc);
-                       if (strip_trailing_blanks(sQueue, 48) != 0)
+                       if (strip_trailing_blanks(sQueue, 48) > 0)
                        {
                                col_append_fstr(pinfo->cinfo, COL_INFO, " Q=%s", sQueue);
                        }
@@ -1947,15 +2056,18 @@ static gint dissect_mq_od(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, g
                if (iSize != 0 && tvb_length_remaining(tvb, offset) >= iSize)
                {
                        gint iNbrRecords = 0;
-                       guint8 *sQueue;
+                       guint8 *sObj;
+                       guint32 uTyp;
 
                        if (iVersion >= 2)
                                iNbrRecords = tvb_get_guint32_endian(tvb, offset + 168, p_mq_parm->mq_int_enc);
 
-                       sQueue = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 12, 48, p_mq_parm->mq_str_enc);
-                       if (strip_trailing_blanks(sQueue,48) != 0)
+                       uTyp = tvb_get_guint32_endian(tvb, offset + 8, p_mq_parm->mq_int_enc);
+                       sObj = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 12, 48, p_mq_parm->mq_str_enc);
+                       col_append_fstr(pinfo->cinfo, COL_INFO, " Typ=%s", try_val_to_str(uTyp,GET_VALSV(objtype)));
+                       if (strip_trailing_blanks(sObj, 48) > 0)
                        {
-                               col_append_fstr(pinfo->cinfo, COL_INFO, " Obj=%s", sQueue);
+                               col_append_fstr(pinfo->cinfo, COL_INFO, " Obj=%s", sObj);
                        }
 
                        if (tree)
@@ -2097,7 +2209,7 @@ static gint dissect_mq_id(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mqroot_
                guint8 *sChannel;
                sChannel = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 24, 20, p_mq_parm->mq_str_enc);
                col_append_fstr(pinfo->cinfo,COL_INFO, " FAPLvl=%d",iFAPLvl);
-               if (strip_trailing_blanks(sChannel, 20) != 0)
+               if (strip_trailing_blanks(sChannel, 20) > 0)
                {
                        col_append_fstr(pinfo->cinfo, COL_INFO, ", CHL=%s", sChannel);
                }
@@ -2105,10 +2217,11 @@ static gint dissect_mq_id(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mqroot_
                {
                        guint8 *sQMgr;
                        sQMgr = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 48, 48, p_mq_parm->mq_str_enc);
-                       if (strip_trailing_blanks(sQMgr,48) != 0)
+                       if (strip_trailing_blanks(sQMgr,48) > 0)
                        {
                                col_append_fstr(pinfo->cinfo, COL_INFO, ", QM=%s", sQMgr);
                        }
+                       p_mq_parm->mq_id_ccsid.ccsid=(guint32)tvb_get_guint16_endian(tvb, offset +  46,  p_mq_parm->mq_int_enc);
                }
                if (mqroot_tree)
                {
@@ -2170,7 +2283,7 @@ static gint dissect_mq_id(tvbuff_t *tvb, packet_info *pinfo, proto_tree *mqroot_
        }
        return iSize;
 }
-static gint dissect_mq_md(tvbuff_t *tvb, proto_tree *tree, gint offset, struct mq_msg_properties* tMsgProps, mq_parm_t *p_mq_parm, gboolean bDecode)
+static gint dissect_mq_md(tvbuff_t *tvb, proto_tree *tree, gint offset, mq_parm_t *p_mq_parm, gboolean bDecode)
 {
        gint iSize = 0;
 
@@ -2188,9 +2301,12 @@ static gint dissect_mq_md(tvbuff_t *tvb, proto_tree *tree, gint offset, struct m
 
                if (bDecode && iSize != 0 && tvb_length_remaining(tvb, offset) >= iSize)
                {
-                       tMsgProps->iOffsetEncoding = offset + 24;
-                       tMsgProps->iOffsetCcsid    = offset + 28;
-                       tMsgProps->iOffsetFormat   = offset + 32;
+                       p_mq_parm->iOfsEnc = offset + 24;
+                       p_mq_parm->iOfsCcs    = offset + 28;
+                       p_mq_parm->iOfsFmt   = offset + 32;
+                       
+                       p_mq_parm->mq_md_ccsid.encod=tvb_get_guint32_endian(tvb, offset +  24,  p_mq_parm->mq_int_enc);
+                       p_mq_parm->mq_md_ccsid.ccsid=tvb_get_guint32_endian(tvb, offset +  28,  p_mq_parm->mq_int_enc);
                        if (tree)
                        {
                                proto_item *ti = proto_tree_add_text(tree, tvb, offset, iSize, MQ_TEXT_MD);
@@ -2202,7 +2318,7 @@ static gint dissect_mq_md(tvbuff_t *tvb, proto_tree *tree, gint offset, struct m
                                proto_tree_add_item(mq_tree, hf_mq_md_msgtype, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
                                proto_tree_add_item(mq_tree, hf_mq_md_expiry, tvb, offset + 16, 4, p_mq_parm->mq_int_enc);
                                proto_tree_add_item(mq_tree, hf_mq_md_feedback, tvb, offset + 20, 4, p_mq_parm->mq_int_enc);
-                               proto_tree_add_item(mq_tree, hf_mq_md_encoding, tvb, offset + 24, 4, p_mq_parm->mq_int_enc);
+                               dissect_mq_encoding(mq_tree, hf_mq_md_encoding, tvb, offset + 24, 4, p_mq_parm->mq_int_enc);
                                proto_tree_add_item(mq_tree, hf_mq_md_ccsid, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
                                proto_tree_add_item(mq_tree, hf_mq_md_format, tvb, offset + 32, 8, p_mq_parm->mq_str_enc);
                                proto_tree_add_item(mq_tree, hf_mq_md_priority, tvb, offset + 40, 4, p_mq_parm->mq_int_enc);
@@ -2275,7 +2391,6 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
        gboolean bPayload = FALSE;
        gboolean bEBCDIC = FALSE;
        gint iDistributionListSize = 0;
-       struct mq_msg_properties tMsgProps;
        mq_parm_t *p_mq_parm;
 
        p_mq_parm = wmem_new0(wmem_packet_scope(), mq_parm_t);
@@ -2283,17 +2398,12 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
        p_mq_parm->mq_strucID = MQ_STRUCTID_NULL;
        p_mq_parm->mq_int_enc = ENC_BIG_ENDIAN;
        p_mq_parm->mq_str_enc = ENC_UTF_8|ENC_NA;
-       p_mq_parm->mq_encode  = 0;
-       p_mq_parm->mq_ccsid   = 0;
-       p_mq_parm->mq_ctlf1    = 0;
-       p_mq_parm->mq_ctlf2   = 0;
-       p_mq_parm->mq_opcode  = 0;
 
        col_set_str(pinfo->cinfo, COL_PROTOCOL, "MQ");
 
-       tMsgProps.iOffsetEncoding = 0;
-       tMsgProps.iOffsetFormat = 0;
-       tMsgProps.iOffsetCcsid = 0;
+       p_mq_parm->iOfsEnc = 0;
+       p_mq_parm->iOfsFmt = 0;
+       p_mq_parm->iOfsCcs = 0;
        if (tvb_length(tvb) >= 4)
        {
                p_mq_parm->mq_strucID = tvb_get_ntohl(tvb, offset);
@@ -2327,18 +2437,18 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
 
                        if (p_mq_parm->mq_opcode == MQ_TST_REQUEST_MSGS || p_mq_parm->mq_opcode == MQ_TST_ASYNC_MESSAGE)
                        {
-                               tMsgProps.iOffsetEncoding = offset + iSizeMPF + 20;
-                               tMsgProps.iOffsetCcsid    = offset + iSizeMPF + 24;
-                               tMsgProps.iOffsetFormat   = offset ;
+                               p_mq_parm->iOfsEnc = offset + iSizeMPF + 20;
+                               p_mq_parm->iOfsCcs    = offset + iSizeMPF + 24;
+                               p_mq_parm->iOfsFmt   = offset ;
                        }
                        p_mq_parm->mq_int_enc = (tvb_get_guint8(tvb, offset + iSizeMPF + 8) == MQ_LITTLE_ENDIAN ? ENC_LITTLE_ENDIAN : ENC_BIG_ENDIAN);
                        p_mq_parm->mq_ctlf1 = tvb_get_guint8(tvb, offset + iSizeMPF + 10);
                        p_mq_parm->mq_ctlf2 = tvb_get_guint8(tvb, offset + iSizeMPF + 11);
 
-                       p_mq_parm->mq_encode=tvb_get_guint32_endian(tvb, offset + iSizeMPF + 20, p_mq_parm->mq_int_enc);
-                       p_mq_parm->mq_ccsid =tvb_get_guint16_endian(tvb, offset + iSizeMPF + 24, p_mq_parm->mq_int_enc);
+                       p_mq_parm->mq_tsh_ccsid.encod=tvb_get_guint32_endian(tvb, offset + iSizeMPF + 20, p_mq_parm->mq_int_enc);
+                       p_mq_parm->mq_tsh_ccsid.ccsid=tvb_get_guint16_endian(tvb, offset + iSizeMPF + 24, p_mq_parm->mq_int_enc);
 
-                       if (p_mq_parm->mq_ccsid==500 && !bEBCDIC)
+                       if (p_mq_parm->mq_tsh_ccsid.ccsid==500 && !bEBCDIC)
                        {
                                bEBCDIC = TRUE;
                                p_mq_parm->mq_str_enc = ENC_EBCDIC|ENC_NA;
@@ -2384,9 +2494,9 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                proto_tree_add_bitmask(mq_tree, tvb, offset + iSizeMPF + 11, hf_mq_tsh_ctlflgs2, ett_mq_tsh_tcf2, pf_flds_tcf2, ENC_BIG_ENDIAN);
 
                                proto_tree_add_item(mq_tree, hf_mq_tsh_luwid, tvb, offset + iSizeMPF + 12, 8, ENC_NA);
-                               proto_tree_add_item(mq_tree, hf_mq_tsh_encoding, tvb, offset + iSizeMPF + 20, 4, p_mq_parm->mq_int_enc);
-                               proto_tree_add_item(mq_tree, hf_mq_tsh_ccsid, tvb, offset + iSizeMPF + 24, 2, p_mq_parm->mq_int_enc);
-                               proto_tree_add_item(mq_tree, hf_mq_tsh_reserved, tvb, offset + iSizeMPF + 26, 2, ENC_BIG_ENDIAN);
+                               dissect_mq_encoding(mq_tree, hf_mq_tsh_encoding, tvb, offset + iSizeMPF + 20, 4,  p_mq_parm->mq_int_enc);
+                               proto_tree_add_item(mq_tree, hf_mq_tsh_ccsid, tvb, offset + iSizeMPF + 24, 2,  p_mq_parm->mq_int_enc);
+                               proto_tree_add_item(mq_tree, hf_mq_tsh_reserved, tvb, offset + iSizeMPF + 26, 2,  p_mq_parm->mq_int_enc);
                        }
                        offset += iSizeTSH;
 
@@ -2549,7 +2659,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                        mq_tree = proto_item_add_subtree(ti, ett_mq_open);
                                                        if (p_mq_parm->mq_opcode == MQ_TST_MQOPEN || p_mq_parm->mq_opcode == MQ_TST_MQOPEN_REPLY)
                                                        {
-                                                               dissect_mq_MQOO(tvb, mq_tree, offset, ett_mq_open_option, p_mq_parm);
+                                                               dissect_mq_MQOO(tvb, mq_tree, offset, ett_mq_open_option, hf_mq_open_options, p_mq_parm);
                                                        }
                                                        if (p_mq_parm->mq_opcode == MQ_TST_MQCLOSE || p_mq_parm->mq_opcode == MQ_TST_MQCLOSE_REPLY)
                                                        {
@@ -2578,12 +2688,12 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                        guint8 *sApplicationName;
                                                        guint8 *sQMgr;
                                                        sApplicationName = format_text_chr(tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 48, 28, p_mq_parm->mq_str_enc), 28, '.');
-                                                       if (strip_trailing_blanks(sApplicationName, 28) != 0)
+                                                       if (strip_trailing_blanks(sApplicationName, 28) > 0)
                                                        {
                                                                col_append_fstr(pinfo->cinfo, COL_INFO, " App=%s", sApplicationName);
                                                        }
                                                        sQMgr = format_text_chr(tvb_get_string_enc(wmem_packet_scope(), tvb, offset, 48, p_mq_parm->mq_str_enc), 28, '.');
-                                                       if (strip_trailing_blanks(sQMgr, 48) != 0)
+                                                       if (strip_trailing_blanks(sQMgr, 48) > 0)
                                                        {
                                                                col_append_fstr(pinfo->cinfo, COL_INFO, " QM=%s", sQMgr);
                                                        }
@@ -2629,17 +2739,18 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                        }
                                                                }
                                                        }
+#undef do_proto_add_item
                                                        offset += iSizeCONN;
                                                }
                                        }
                                        else if ((p_mq_parm->mq_opcode == MQ_TST_MQINQ || p_mq_parm->mq_opcode == MQ_TST_MQINQ_REPLY || p_mq_parm->mq_opcode == MQ_TST_MQSET) && tvb_length_remaining(tvb, offset) >= 12)
                                        {
                                                /* The MQINQ/MQSET structure is special because it does not start with a structid */
-                                               gint iNbSelectors = 0;
-                                               gint iNbIntegers = 0;
-                                               gint iCharLen = 0;
-                                               gint iOffsetINQ = 0;
-                                               gint iSelector = 0;
+                                               gint iNbSelectors;
+                                               gint iNbIntegers;
+                                               gint iCharLen;
+                                               gint iOffsetINQ;
+                                               gint iSelector;
 
                                                iNbSelectors = tvb_get_guint32_endian(tvb, offset, p_mq_parm->mq_int_enc);
                                                iNbIntegers = tvb_get_guint32_endian(tvb, offset + 4, p_mq_parm->mq_int_enc);
@@ -2667,11 +2778,11 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                        iOffsetINQ += iNbSelectors * 4;
                                                        if (p_mq_parm->mq_opcode == MQ_TST_MQINQ_REPLY || p_mq_parm->mq_opcode == MQ_TST_MQSET)
                                                        {
-                                                               gint iSizeINQValues = 0;
+                                                               gint iSizeINQValues;
                                                                iSizeINQValues = iNbIntegers * 4 + iCharLen;
                                                                if (tvb_length_remaining(tvb, offset + iOffsetINQ) >= iSizeINQValues)
                                                                {
-                                                                       gint iInteger = 0;
+                                                                       gint iInteger;
                                                                        if (tree)
                                                                        {
                                                                                for (iInteger = 0; iInteger < iNbIntegers; iInteger++)
@@ -2694,7 +2805,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                        }
                                        else if (p_mq_parm->mq_opcode == MQ_TST_NOTIFICATION)
                                        {
-                                               gint iHdl = 0;
+                                               gint iHdl;
 
                                                iHdl = tvb_get_guint32_endian(tvb, offset+4, p_mq_parm->mq_int_enc);
 
@@ -2722,13 +2833,17 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                gint xOfs;
                                                gint iOpt;
 
-                                               xOfs=0;
+                                               xOfs       = 0;
                                                iHdl       = tvb_get_guint32_endian(tvb, offset+  4, p_mq_parm->mq_int_enc);
                                                iMaxMsgLen = tvb_get_guint32_endian(tvb, offset+ 16, p_mq_parm->mq_int_enc);
                                                iFlags     = tvb_get_guint32_endian(tvb, offset+ 32, p_mq_parm->mq_int_enc);
                                                iGlbMsgIdx = tvb_get_guint32_endian(tvb, offset+ 36, p_mq_parm->mq_int_enc);
-
-                                               col_append_fstr(pinfo->cinfo, COL_INFO, " Hdl=0x%08x, GlbMsgIdx=%d, MaxLen=%d",
+                                               if (iFlags & 0x00000010)
+                                               {
+                                                       p_mq_parm->mq_msgreq_ccsid.encod=tvb_get_guint32_endian(tvb, offset + 44, p_mq_parm->mq_int_enc);
+                                                       p_mq_parm->mq_msgreq_ccsid.ccsid=tvb_get_guint32_endian(tvb, offset + 48, p_mq_parm->mq_int_enc);
+                                               }
+                                               col_append_fstr(pinfo->cinfo, COL_INFO, " Hdl=0x%08x GlbMsgIdx=%d, MaxLen=%d",
                                                        iHdl, iGlbMsgIdx, iMaxMsgLen);
 
                                                if (tree)
@@ -2753,7 +2868,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                proto_tree_add_item(mq_tree, hf_mq_msgreq_SelectIdx , tvb, offset + 40,  2, p_mq_parm->mq_int_enc);
                                                                proto_tree_add_item(mq_tree, hf_mq_msgreq_MQMDVers , tvb, offset + 42,  2, p_mq_parm->mq_int_enc);
                                                                proto_tree_add_item(mq_tree, hf_mq_msgreq_ccsid   , tvb, offset + 44,  4, p_mq_parm->mq_int_enc);
-                                                               proto_tree_add_item(mq_tree, hf_mq_msgreq_encoding, tvb, offset + 48,  4, p_mq_parm->mq_int_enc);
+                                                               dissect_mq_encoding(mq_tree, hf_mq_msgreq_encoding, tvb, offset + 48,  4, p_mq_parm->mq_int_enc);
                                                                proto_tree_add_item(mq_tree, hf_mq_msgreq_MsgSeqNum, tvb, offset + 52,  4, p_mq_parm->mq_int_enc);
                                                                proto_tree_add_item(mq_tree, hf_mq_msgreq_offset, tvb, offset + 56,  4, p_mq_parm->mq_int_enc);
                                                                dissect_mq_MQMO(tvb, mq_tree, offset + 60, ett_mq_gmo_matchoption, p_mq_parm);
@@ -2815,7 +2930,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
 
                                                if (!mq_in_reassembly)
                                                {
-                                                       col_append_fstr(pinfo->cinfo, COL_INFO, " Hdl=0x%08x, GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
+                                                       col_append_fstr(pinfo->cinfo, COL_INFO, " Hdl=0x%08x GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
                                                                iHdl, iGlbMsgIdx, iSegmIndex, iSegLength);
                                                }
 
@@ -2855,9 +2970,9 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                gint iOffsetSPI = 0;
                                                guint32 iSpiVerb = 0;
 
-                                               tMsgProps.iOffsetEncoding = offset + 12;
-                                               tMsgProps.iOffsetCcsid    = offset + 16;
-                                               tMsgProps.iOffsetFormat   = offset + 20;
+                                               p_mq_parm->iOfsEnc = offset + 12;
+                                               p_mq_parm->iOfsCcs    = offset + 16;
+                                               p_mq_parm->iOfsFmt   = offset + 20;
 
                                                iSpiVerb = tvb_get_guint32_endian(tvb, offset, p_mq_parm->mq_int_enc);
                                                col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)", val_to_str(iSpiVerb, mq_spi_verbs_vals, "Unknown (0x%08x)"));
@@ -2893,7 +3008,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                        offset += 12;
                                                        p_mq_parm->mq_strucID = (tvb_length_remaining(tvb, offset) >= 4) ? tvb_get_ntohl(tvb, offset) : MQ_STRUCTID_NULL;
 
-                                                       if ((iSizeSPIMD = dissect_mq_md(tvb, mqroot_tree, offset, &tMsgProps, p_mq_parm, TRUE)) != 0)
+                                                       if ((iSizeSPIMD = dissect_mq_md(tvb, mqroot_tree, offset, p_mq_parm, TRUE)) != 0)
                                                        {
                                                                offset += iSizeSPIMD;
                                                                offset += dissect_mq_gmo(tvb, pinfo, mqroot_tree, offset, p_mq_parm);
@@ -3061,37 +3176,51 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                        }
                                        if ((p_mq_parm->mq_strucID == MQ_STRUCTID_LPOO || p_mq_parm->mq_strucID == MQ_STRUCTID_LPOO_EBCDIC) && tvb_length_remaining(tvb, offset) >= 32)
                                        {
-                                               guint iVersionID = 0;
-                                               gint iSizeID = 32;
-                                               iVersionID = tvb_get_guint32_endian(tvb, offset+4, p_mq_parm->mq_int_enc);
-                                               /* iSizeID = tvb_get_guint32_endian(tvb, offset+8, p_mq_parm->mq_int_enc); */
+                                               guint iVersion;
+                                               guint iXtraData = 0;
+                                               gint  iSize = 32;
+                                               iVersion = tvb_get_guint32_endian(tvb, offset+4, p_mq_parm->mq_int_enc);
+                                               if (iVersion >= 3)
+                                               {
+                                                       iSize+=56;
+                                                       iXtraData = tvb_get_guint32_endian(tvb, offset + 84, p_mq_parm->mq_int_enc);
+                                               }
 
-                                               if (iSizeID != 0 && tvb_length_remaining(tvb, offset) >= iSizeID)
+                                               if (iSize != 0 && tvb_length_remaining(tvb, offset) >= iSize)
                                                {
                                                        if (tree)
                                                        {
-                                                               ti = proto_tree_add_text(mqroot_tree, tvb, offset, iSizeID, MQ_TEXT_LPOO);
+                                                               ti = proto_tree_add_text(mqroot_tree, tvb, offset, iSize, MQ_TEXT_LPOO);
                                                                mq_tree = proto_item_add_subtree(ti, ett_mq_lpoo);
 
                                                                proto_tree_add_item(mq_tree, hf_mq_lpoo_StructID, tvb, offset, 4, p_mq_parm->mq_str_enc);
                                                                proto_tree_add_item(mq_tree, hf_mq_lpoo_version, tvb, offset + 4, 4, p_mq_parm->mq_int_enc);
 
-                                                               dissect_mq_MQOO(tvb, mq_tree, offset+8, ett_mq_lpoo_option, p_mq_parm);
+                                                               dissect_mq_MQOO(tvb, mq_tree, offset+8, ett_mq_lpoo_options, hf_mq_lpoo_options, p_mq_parm);
 
-                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown1, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
-                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown2, tvb, offset + 16, 4, p_mq_parm->mq_int_enc);
-                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown3, tvb, offset + 20, 4, p_mq_parm->mq_int_enc);
-                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown4, tvb, offset + 24, 4, p_mq_parm->mq_int_enc);
-                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown5, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
-                                                               if (iVersionID>3)
+                                                               dissect_mq_LPOO_LPIOPTS(tvb, mq_tree, offset+16, ett_mq_lpoo_lpiopts, p_mq_parm);
+                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_defpersist, tvb, offset + 20, 4, p_mq_parm->mq_int_enc);
+                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_defputresptype, tvb, offset + 24, 4, p_mq_parm->mq_int_enc);
+                                                               proto_tree_add_item(mq_tree, hf_mq_lpoo_defreadahead, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
+                                                               if (iVersion >= 3)
                                                                {
                                                                        proto_tree_add_item(mq_tree, hf_mq_lpoo_qprotect, tvb, offset + 32, 48, p_mq_parm->mq_int_enc);
                                                                        proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown6, tvb, offset + 80, 4, p_mq_parm->mq_int_enc);
-                                                                       proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown7, tvb, offset + 84, 4, p_mq_parm->mq_int_enc);
+                                                                       /*proto_tree_add_item(mq_tree, hf_mq_lpoo_unknown7, tvb, offset + 84, 2, p_mq_parm->mq_int_enc);*/
+                                                                       proto_tree_add_item(mq_tree, hf_mq_lpoo_xtradata, tvb, offset + 84, 4, p_mq_parm->mq_int_enc);
                                                                }
                                                        }
-                                                       offset += iSizeID;
+                                                       offset += iSize;
                                                        p_mq_parm->mq_strucID = (tvb_length_remaining(tvb, offset) >= 4) ? tvb_get_ntohl(tvb, offset) : MQ_STRUCTID_NULL;
+                                                       if (iXtraData>0)
+                                                       {
+                                                               if (p_mq_parm->mq_opcode == MQ_TST_SPI_REPLY)
+                                                               {
+                                                                       bPayload=TRUE;
+                                                                       iSizePayload=iXtraData;
+                                                                       p_mq_parm->iOfsFmt=(offset-iSize);
+                                                               }
+                                                       }
                                                }
                                        }
                                        if ((p_mq_parm->mq_strucID == MQ_STRUCTID_ID || p_mq_parm->mq_strucID == MQ_STRUCTID_ID_EBCDIC) && tvb_length_remaining(tvb, offset) >= 5)
@@ -3101,7 +3230,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                        }
                                        if ((p_mq_parm->mq_strucID == MQ_STRUCTID_UID || p_mq_parm->mq_strucID == MQ_STRUCTID_UID_EBCDIC) && tvb_length_remaining(tvb, offset) > 0)
                                        {
-                                               gint iSizeUID = 0;
+                                               gint iSizeUID;
                                                /* iSizeUID = (iVersionID < 5 ? 28 : 132);  guess */
                                                /* The iVersionID is available in the previous ID segment, we should keep a state *
                                                * Instead we rely on the segment length announced in the TSH */
@@ -3112,7 +3241,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                {
                                                        guint8 *sUserId;
                                                        sUserId = tvb_get_string_enc(wmem_packet_scope(), tvb, offset + 4, 12, p_mq_parm->mq_str_enc);
-                                                       if (strip_trailing_blanks(sUserId, 12) != 0)
+                                                       if (strip_trailing_blanks(sUserId, 12) > 0)
                                                        {
                                                                col_append_fstr(pinfo->cinfo, COL_INFO, " User=%s", sUserId);
                                                        }
@@ -3142,7 +3271,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
 
                                        offset += dissect_mq_od(tvb, pinfo, mqroot_tree, offset, p_mq_parm, &iDistributionListSize);
 
-                                       if ((iSizeMD = dissect_mq_md(tvb, mqroot_tree, offset, &tMsgProps, p_mq_parm, TRUE)) != 0)
+                                       if ((iSizeMD = dissect_mq_md(tvb, mqroot_tree, offset, p_mq_parm, TRUE)) != 0)
                                        {
                                                gint iSizeGMO = 0;
                                                gint iSizePMO = 0;
@@ -3207,7 +3336,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                        offset += iSizeXQH;
                                                                        iHeadersLength += iSizeXQH;
 
-                                                                       if ((iSizeMD2 = dissect_mq_md(tvb, mqroot_tree, offset, &tMsgProps, p_mq_parm, TRUE)) != 0)
+                                                                       if ((iSizeMD2 = dissect_mq_md(tvb, mqroot_tree, offset, p_mq_parm, TRUE)) != 0)
                                                                        {
                                                                                offset += iSizeMD2;
                                                                                iHeadersLength += iSizeMD2;
@@ -3224,9 +3353,12 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
 
                                                                        iNbrRecords = tvb_get_guint32_endian(tvb, offset + 36, p_mq_parm->mq_int_enc);
                                                                        iRecFlags = tvb_get_guint32_endian(tvb, offset + 32, p_mq_parm->mq_int_enc);
-                                                                       tMsgProps.iOffsetEncoding = offset + 12;
-                                                                       tMsgProps.iOffsetCcsid    = offset + 16;
-                                                                       tMsgProps.iOffsetFormat   = offset + 20;
+                                                                       p_mq_parm->iOfsEnc = offset + 12;
+                                                                       p_mq_parm->iOfsCcs    = offset + 16;
+                                                                       p_mq_parm->iOfsFmt   = offset + 20;
+
+                                                                       p_mq_parm->mq_head_ccsid.encod=tvb_get_guint32_endian(tvb, offset + 12, p_mq_parm->mq_int_enc);
+                                                                       p_mq_parm->mq_head_ccsid.ccsid=tvb_get_guint32_endian(tvb, offset + 16, p_mq_parm->mq_int_enc);
 
                                                                        if (tree)
                                                                        {
@@ -3236,7 +3368,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_StructID, tvb, offset, 4, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_version, tvb, offset + 4, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_length, tvb, offset + 8, 4, p_mq_parm->mq_int_enc);
-                                                                               proto_tree_add_item(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
+                                                                               dissect_mq_encoding(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_ccsid, tvb, offset + 16, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_format, tvb, offset + 20, 8, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_flags, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
@@ -3274,9 +3406,13 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                {
                                                                        /* if MD.format == MQDEAD */
                                                                        gint iSizeDLH = 172;
-                                                                       tMsgProps.iOffsetEncoding = offset + 108;
-                                                                       tMsgProps.iOffsetCcsid    = offset + 112;
-                                                                       tMsgProps.iOffsetFormat   = offset + 116;
+                                                                       p_mq_parm->iOfsEnc = offset + 108;
+                                                                       p_mq_parm->iOfsCcs    = offset + 112;
+                                                                       p_mq_parm->iOfsFmt   = offset + 116;
+
+                                                                       p_mq_parm->mq_dlh_ccsid.encod=tvb_get_guint32_endian(tvb, offset + 108, p_mq_parm->mq_int_enc);
+                                                                       p_mq_parm->mq_dlh_ccsid.ccsid=tvb_get_guint32_endian(tvb, offset + 112, p_mq_parm->mq_int_enc);
+
                                                                        if (tree)
                                                                        {
                                                                                ti = proto_tree_add_text(mqroot_tree, tvb, offset, iSizeDLH, MQ_TEXT_DLH);
@@ -3287,7 +3423,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_reason, tvb, offset + 8, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_destq, tvb, offset + 12, 48, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_destqmgr, tvb, offset + 60, 48, p_mq_parm->mq_str_enc);
-                                                                               proto_tree_add_item(mq_tree, hf_mq_dlh_encoding, tvb, offset + 108, 4, p_mq_parm->mq_int_enc);
+                                                                               dissect_mq_encoding(mq_tree, hf_mq_dlh_encoding, tvb, offset + 108, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_ccsid, tvb, offset + 112, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_format, tvb, offset + 116, 8, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_dlh_putappltype, tvb, offset + 124, 4, p_mq_parm->mq_int_enc);
@@ -3303,9 +3439,9 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                {
                                                                        /* if MD.format == MQHMDE */
                                                                        gint iSizeMDE = 72;
-                                                                       tMsgProps.iOffsetEncoding = offset + 12;
-                                                                       tMsgProps.iOffsetCcsid    = offset + 16;
-                                                                       tMsgProps.iOffsetFormat   = offset + 20;
+                                                                       p_mq_parm->iOfsEnc = offset + 12;
+                                                                       p_mq_parm->iOfsCcs    = offset + 16;
+                                                                       p_mq_parm->iOfsFmt   = offset + 20;
                                                                        if (tree)
                                                                        {
                                                                                ti = proto_tree_add_text(mqroot_tree, tvb, offset, iSizeMDE, MQ_TEXT_MDE);
@@ -3314,7 +3450,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_StructID, tvb, offset, 4, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_version, tvb, offset + 4, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_length, tvb, offset + 8, 4, p_mq_parm->mq_int_enc);
-                                                                               proto_tree_add_item(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
+                                                                               dissect_mq_encoding(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_ccsid, tvb, offset + 16, 4, p_mq_parm->mq_int_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_format, tvb, offset + 20, 8, p_mq_parm->mq_str_enc);
                                                                                proto_tree_add_item(mq_tree, hf_mq_head_flags, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
@@ -3346,9 +3482,9 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
 
                                                                        if (tvb_length_remaining(tvb, offset) >= iSizeHeader)
                                                                        {
-                                                                               tMsgProps.iOffsetEncoding = offset + 12;
-                                                                               tMsgProps.iOffsetCcsid    = offset + 16;
-                                                                               tMsgProps.iOffsetFormat   = offset + 20;
+                                                                               p_mq_parm->iOfsEnc = offset + 12;
+                                                                               p_mq_parm->iOfsCcs    = offset + 16;
+                                                                               p_mq_parm->iOfsFmt   = offset + 20;
                                                                                if (tree)
                                                                                {
                                                                                        ti = proto_tree_add_text(mqroot_tree, tvb, offset, iSizeHeader, "%s", val_to_str(p_mq_parm->mq_strucID, mq_StructID_vals, "Unknown (0x%08x)"));
@@ -3357,7 +3493,7 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_StructID, tvb, offset, 4, p_mq_parm->mq_str_enc);
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_version, tvb, offset + 4, 4, p_mq_parm->mq_int_enc);
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_length, tvb, offset + 8, 4, p_mq_parm->mq_int_enc);
-                                                                                       proto_tree_add_item(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
+                                                                                       dissect_mq_encoding(mq_tree, hf_mq_head_encoding, tvb, offset + 12, 4, p_mq_parm->mq_int_enc);
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_ccsid, tvb, offset + 16, 4, p_mq_parm->mq_int_enc);
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_format, tvb, offset + 20, 8, p_mq_parm->mq_str_enc);
                                                                                        proto_tree_add_item(mq_tree, hf_mq_head_flags, tvb, offset + 28, 4, p_mq_parm->mq_int_enc);
@@ -3377,17 +3513,26 @@ static void dissect_mq_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                        {
                                                                /* Call subdissector for the payload */
                                                                tvbuff_t* next_tvb = NULL;
+                                                               /*
                                                                struct mqinfo *mqinfo;
                                                                mqinfo = wmem_new0(wmem_packet_scope(), struct mqinfo);
+                                                               */
                                                                /* Format, encoding and character set are "data type" information, not subprotocol information */
-                                                               mqinfo->encoding = tvb_get_guint32_endian(tvb, tMsgProps.iOffsetEncoding, p_mq_parm->mq_int_enc);
-                                                               mqinfo->ccsid    = tvb_get_guint32_endian(tvb, tMsgProps.iOffsetCcsid, p_mq_parm->mq_int_enc);
+                                                               /*
+                                                               mqinfo->encoding = tvb_get_guint32_endian(tvb, p_mq_parm->iOfsEnc, p_mq_parm->mq_int_enc);
+                                                               mqinfo->ccsid    = tvb_get_guint32_endian(tvb, p_mq_parm->iOfsCcs, p_mq_parm->mq_int_enc);
                                                                memcpy(mqinfo->format,
-                                                                       tvb_get_string_enc(wmem_packet_scope(), tvb, tMsgProps.iOffsetFormat, sizeof(mqinfo->format), p_mq_parm->mq_str_enc),
+                                                                       tvb_get_string_enc(wmem_packet_scope(), tvb, p_mq_parm->iOfsFmt, sizeof(mqinfo->format), p_mq_parm->mq_str_enc),
                                                                        sizeof(mqinfo->format));
+                                                               */
+                                                               p_mq_parm->mq_cur_ccsid.encod=tvb_get_guint32_endian(tvb, p_mq_parm->iOfsEnc, p_mq_parm->mq_int_enc);
+                                                               p_mq_parm->mq_cur_ccsid.ccsid=tvb_get_guint32_endian(tvb, p_mq_parm->iOfsCcs, p_mq_parm->mq_int_enc);
+                                                               memcpy(p_mq_parm->mq_format,
+                                                                       tvb_get_string_enc(wmem_packet_scope(), tvb, p_mq_parm->iOfsFmt, sizeof(p_mq_parm->mq_format), p_mq_parm->mq_str_enc),
+                                                                       sizeof(p_mq_parm->mq_format));
 
                                                                next_tvb = tvb_new_subset_remaining(tvb, offset);
-                                                               if (!dissector_try_heuristic(mq_heur_subdissector_list, next_tvb, pinfo, mqroot_tree, mqinfo))
+                                                               if (!dissector_try_heuristic(mq_heur_subdissector_list, next_tvb, pinfo, mqroot_tree, p_mq_parm))
                                                                        call_dissector(data_handle, next_tvb, pinfo, mqroot_tree);
                                                        }
                                                        else
@@ -3438,14 +3583,8 @@ static void reassemble_mq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
        {
                mq_parm_t mq_parm;
 
+               memset(&mq_parm,0,sizeof(mq_parm_t));
                mq_parm.mq_strucID = tvb_get_ntohl(tvb, 0);
-               mq_parm.mq_ccsid   = 0;
-               mq_parm.mq_ctlf1   = 0;
-               mq_parm.mq_ctlf2   = 0;
-               mq_parm.mq_encode  = 0;
-               mq_parm.mq_opcode  = 0;
-               mq_parm.mq_int_enc = 0;
-               mq_parm.mq_str_enc = 0;
 
                if ( (mq_parm.mq_strucID & MQ_MASK_TSHx) == MQ_STRUCTID_TSHx || (mq_parm.mq_strucID & MQ_MASK_TSHx) == MQ_STRUCTID_TSHx_EBCDIC )
                {
@@ -3543,7 +3682,7 @@ static void reassemble_mq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                        First segment has a longer header
                                        */
                                        iNxtP = iHdrL + ((bSeg1st)?(54 + 1 + uStrL + uPadL):(24));
-                                       iNxtP += dissect_mq_md(tvb, NULL, iNxtP, NULL, &mq_parm, FALSE);
+                                       iNxtP += dissect_mq_md(tvb, NULL, iNxtP, &mq_parm, FALSE);
 
                                        /*
                                        if it is the 1st Segment, it means we are
@@ -3560,11 +3699,11 @@ static void reassemble_mq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                        {
                                                proto_item* ti = proto_tree_add_item(tree, proto_mq, tvb, 0, -1, ENC_NA);
                                                if (bMore)
-                                                       proto_item_append_text(ti, " [%s of a Reassembled MQ Segment] Hdl=0x%08x, GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
+                                                       proto_item_append_text(ti, " [%s of a Reassembled MQ Segment] Hdl=0x%08x GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
                                                                val_to_str(iOpcd, mq_opcode_vals, "Unknown (0x%02x)"),
                                                                iHdl, iGlbMsgIdx, iSegmIndex, iSegLength);
                                                else
-                                                       proto_item_append_text(ti, " %s Hdl=0x%08x, GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
+                                                       proto_item_append_text(ti, " %s Hdl=0x%08x GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
                                                                val_to_str(iOpcd, mq_opcode_vals, "Unknown (0x%02x)"),
                                                                iHdl, iGlbMsgIdx, iSegmIndex, iSegLength);
                                                mq_tree = proto_item_add_subtree(ti, ett_mq_reaasemb);
@@ -3598,7 +3737,7 @@ static void reassemble_mq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
                                                mq_in_reassembly=TRUE;
                                                /* Reassembly in progress */
                                                col_set_str(pinfo->cinfo, COL_PROTOCOL, "MQ");
-                                               col_add_fstr(pinfo->cinfo, COL_INFO, "[%s of a Reassembled MQ Segment] Hdl=0x%08x, GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
+                                               col_add_fstr(pinfo->cinfo, COL_INFO, "[%s of a Reassembled MQ Segment] Hdl=0x%08x GlbMsgIdx=%d, SegIdx=%d, SegLen=%d",
                                                        val_to_str(iOpcd, mq_opcode_vals, "Unknown (0x%02x)"),
                                                        iHdl, iGlbMsgIdx, iSegmIndex, iSegLength);
                                                dissect_mq_pdu(tvb, pinfo, mq_tree);
@@ -3703,7 +3842,7 @@ void proto_register_mq(void)
                { &hf_mq_tsh_ctlflgs2 ,{"Ctl Flag 2", "mq.tsh.cflags2", FT_UINT8, BASE_HEX, NULL, 0x0, "TSH Control flags 2", HFILL }},
                { &hf_mq_tsh_luwid    ,{"LUW Ident.", "mq.tsh.luwid", FT_BYTES, BASE_NONE, NULL, 0x0, "TSH logical unit of work identifier", HFILL }},
                { &hf_mq_tsh_encoding ,{"Encoding..", "mq.tsh.encoding", FT_UINT32, BASE_DEC, NULL, 0x0, "TSH Encoding", HFILL }},
-               { &hf_mq_tsh_ccsid    ,{"CCSID.....", "mq.tsh.ccsid", FT_UINT16, BASE_DEC, NULL, 0x0, "TSH CCSID", HFILL }},
+               { &hf_mq_tsh_ccsid    ,{"CCSID.....", "mq.tsh.ccsid", FT_INT16, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "TSH CCSID", HFILL }},
                { &hf_mq_tsh_reserved ,{"Reserved..", "mq.tsh.reserved", FT_UINT16, BASE_HEX, NULL, 0x0, "TSH Reserved", HFILL }},
 
                { &hf_mq_tsh_tcf_confirmreq,{"Confirm Req", "mq.tsh.tcf.confirmreq", FT_BOOLEAN, 8, TFS(&tfs_set_notset), MQ_TCF_CONFIRM_REQUEST, "TSH TCF Confirm request", HFILL }},
@@ -3764,7 +3903,7 @@ void proto_register_mq(void)
                { &hf_mq_id_channel    ,{"ChannelNme", "mq.id.channelname", FT_STRINGZ, BASE_NONE, NULL, 0x0, "ID channel name", HFILL }},
                { &hf_mq_id_icf2       ,{"CapFlag2..", "mq.id.idflags2", FT_UINT8, BASE_HEX, NULL, 0x0, "ID Capability flags 2", HFILL }},
                { &hf_mq_id_Eicf2      ,{"ECapFlag2.", "mq.id.ideflags2", FT_UINT8, BASE_HEX, NULL, 0x0, "ID E Capabitlity flags 2", HFILL }},
-               { &hf_mq_id_ccsid      ,{"ccsid.....", "mq.id.ccsid", FT_UINT16, BASE_HEX_DEC, NULL, 0x0, "ID Coded Character Set ID", HFILL }},
+               { &hf_mq_id_ccsid      ,{"ccsid.....", "mq.id.ccsid", FT_INT16, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "ID Coded Character Set ID", HFILL }},
                { &hf_mq_id_qmgrname   ,{"QMgrName..", "mq.id.qm", FT_STRINGZ, BASE_NONE, NULL, 0x0, "ID Queue Manager Name", HFILL }},
                { &hf_mq_id_HBInterval ,{"HBInterval", "mq.id.hbint", FT_UINT32, BASE_DEC, NULL, 0x0, "ID Heartbeat interval", HFILL }},
                { &hf_mq_id_EFLLength  ,{"EFLLength.", "mq.id.efllength", FT_UINT16, BASE_HEX_DEC, NULL, 0x0, "ID EFL Length", HFILL }},
@@ -3911,32 +4050,6 @@ void proto_register_mq(void)
                { &hf_mq_open_options_NO_MULTICAST   ,{"NO_MULTICAST", "mq.open.options.NoMulticast", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_NO_MULTICAST, "OPEN options NO_MULTICAST", HFILL }},
                { &hf_mq_open_options_BIND_ON_GROUP  ,{"BIND_ON_GROUP", "mq.open.options.BindOnGroup", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_BIND_ON_GROUP, "OPEN options BIND_ON_GROUP", HFILL }},
 
-               /*
-               { &hf_mq_open_options_INPUT_AS_Q_DEF ,{"INPUT_AS_Q_DEF..........", "mq.open.options.InputAsQDef", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_INPUT_AS_Q_DEF, "OPEN options INPUT_AS_Q_DEF", HFILL }},
-               { &hf_mq_open_options_INPUT_SHARED   ,{"INPUT_SHARED............", "mq.open.options.InputShared", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_INPUT_SHARED, "OPEN options INPUT_SHARED", HFILL }},
-               { &hf_mq_open_options_INPUT_EXCLUSIVE,{"INPUT_EXCLUSIVE.........", "mq.open.options.InputExclusive", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_INPUT_EXCLUSIVE, "OPEN options INPUT_EXCLUSIVE", HFILL }},
-               { &hf_mq_open_options_BROWSE         ,{"BROWSE..................", "mq.open.options.Browse", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_BROWSE, "OPEN options BROWSE", HFILL }},
-               { &hf_mq_open_options_OUTPUT         ,{"OUTPUT..................", "mq.open.options.Output", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_OUTPUT, "OPEN options OUTPUT", HFILL }},
-               { &hf_mq_open_options_INQUIRE        ,{"INQUIRE.................", "mq.open.options.Inquire", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_INQUIRE, "OPEN options INQUIRE", HFILL }},
-               { &hf_mq_open_options_SET            ,{"SET.....................", "mq.open.options.Set", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_SET, "OPEN options SET", HFILL }},
-               { &hf_mq_open_options_SAVE_ALL_CTX   ,{"SAVE_ALL_CONTEXT........", "mq.open.options.SaveAllContext", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_SAVE_ALL_CONTEXT, "OPEN options SAVE_ALL_CONTEXT", HFILL }},
-               { &hf_mq_open_options_PASS_IDENT_CTX ,{"PASS_IDENTITY_CONTEXT...", "mq.open.options.PassIdentityContext", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_PASS_IDENTITY_CONTEXT, "OPEN options PASS_IDENTITY_CONTEXT", HFILL }},
-               { &hf_mq_open_options_PASS_ALL_CTX   ,{"PASS_ALL_CONTEXT........", "mq.open.options.PassAllContext", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_PASS_ALL_CONTEXT, "OPEN options PASS_ALL_CONTEXT", HFILL }},
-               { &hf_mq_open_options_SET_IDENT_CTX  ,{"SET_IDENTITY_CONTEXT....", "mq.open.options.SetIdentityContext", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_SET_IDENTITY_CONTEXT, "OPEN options SET_IDENTITY_CONTEXT", HFILL }},
-               { &hf_mq_open_options_SET_ALL_CONTEXT,{"SET_ALL_CONTEXT.........", "mq.open.options.SetAllContext", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_SET_ALL_CONTEXT, "OPEN options SET_ALL_CONTEXT", HFILL }},
-               { &hf_mq_open_options_ALT_USER_AUTH  ,{"ALTERNATE_USER_AUTHORITY", "mq.open.options.AlternateUserAuthority", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_ALTERNATE_USER_AUTHORITY, "OPEN options ALTERNATE_USER_AUTHORITY", HFILL }},
-               { &hf_mq_open_options_FAIL_IF_QUIESC ,{"FAIL_IF_QUIESCING.......", "mq.open.options.FailIfQuiescing", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_FAIL_IF_QUIESCING, "OPEN options FAIL_IF_QUIESCING", HFILL }},
-               { &hf_mq_open_options_BIND_ON_OPEN   ,{"BIND_ON_OPEN............", "mq.open.options.BindOnOpen", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_BIND_ON_OPEN, "OPEN options BIND_ON_OPEN", HFILL }},
-               { &hf_mq_open_options_BIND_NOT_FIXED ,{"BIND_NOT_FIXED..........", "mq.open.options.BindNotFixed", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_BIND_NOT_FIXED, "OPEN options BIND_NOT_FIXED", HFILL }},
-               { &hf_mq_open_options_RESOLVE_NAMES  ,{"RESOLVE_NAMES...........", "mq.open.options.ResolveNames", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_RESOLVE_NAMES, "OPEN options RESOLVE_NAMES", HFILL }},
-               { &hf_mq_open_options_CO_OP          ,{"CO_OP...................", "mq.open.options.CoOp", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_CO_OP, "OPEN options CO_OP", HFILL }},
-               { &hf_mq_open_options_RESOLVE_LOCAL_Q,{"RESOLVE_LOCAL_Q.........", "mq.open.options.ResolveLocalQueueOrTopic", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_RESOLVE_LOCAL_Q, "OPEN options RESOLVE_LOCAL_Q", HFILL }},
-               { &hf_mq_open_options_NO_READ_AHEAD  ,{"NO_READ_AHEAD...........", "mq.open.options.NoReadAhead", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_NO_READ_AHEAD, "OPEN options NO_READ_AHEAD", HFILL }},
-               { &hf_mq_open_options_READ_AHEAD     ,{"READ_AHEAD..............", "mq.open.options.ReadAhead", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_READ_AHEAD, "OPEN options READ_AHEAD", HFILL }},
-               { &hf_mq_open_options_NO_MULTICAST   ,{"NO_MULTICAST............", "mq.open.options.NoMulticast", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_NO_MULTICAST, "OPEN options NO_MULTICAST", HFILL }},
-               { &hf_mq_open_options_BIND_ON_GROUP  ,{"BIND_ON_GROUP...........", "mq.open.options.BindOnGroup", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQOO_BIND_ON_GROUP, "OPEN options BIND_ON_GROUP", HFILL }},
-               */
-
                { &hf_mq_fopa_StructID,{"StructId", "mq.fopa.structid", FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL }},
                { &hf_mq_fopa_version ,{"Version.", "mq.fopa.version", FT_UINT32, BASE_DEC, NULL, 0x0, "FOPA Version", HFILL }},
                { &hf_mq_fopa_length  ,{"Length..", "mq.fopa.length", FT_UINT32, BASE_DEC, NULL, 0x0, "FOPA Length", HFILL }},
@@ -3958,7 +4071,7 @@ void proto_register_mq(void)
                { &hf_mq_msgreq_GlbMsgIdx,{"GlbMsgIdx", "mq.msgreq.glbmsgidx", FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MSGREQ Global Message Index", HFILL }},
                { &hf_mq_msgreq_SelectIdx,{"SelectIdx", "mq.msgreq.selectIdx", FT_UINT16, BASE_HEX_DEC, NULL, 0x0, "MSGREQ Selection Index", HFILL }},
                { &hf_mq_msgreq_MQMDVers ,{"MQMDVers.", "mq.msgreq.mqmdvers" , FT_UINT16, BASE_HEX_DEC, NULL, 0x0, "MSGREQ MQMD Version", HFILL }},
-               { &hf_mq_msgreq_ccsid    ,{"CCSID....", "mq.msgreq.ccsid"    , FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MSGREQ ccsid", HFILL }},
+               { &hf_mq_msgreq_ccsid    ,{"CCSID....", "mq.msgreq.ccsid"    , FT_INT32 , BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "MSGREQ ccsid", HFILL }},
                { &hf_mq_msgreq_encoding ,{"Encoding.", "mq.msgreq.encoding" , FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MSGREQ encoding", HFILL }},
                { &hf_mq_msgreq_MsgSeqNum,{"MsgSeqNum", "mq.msgreq.msgseqnum", FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MSGREQ Message Sequence Number", HFILL }},
                { &hf_mq_msgreq_offset   ,{"Offset...", "mq.msgreq.offset"   , FT_UINT32, BASE_HEX_DEC, NULL, 0x0, "MSGREQ Offset", HFILL }},
@@ -4016,7 +4129,7 @@ void proto_register_mq(void)
                { &hf_mq_od_altsecurid  ,{"Alt security id..", "mq.od.altsecid", FT_STRINGZ, BASE_NONE, NULL, 0x0, "OD alternate security id", HFILL }},
                { &hf_mq_od_resolvqname ,{"Resolved Q Name..", "mq.od.resolvq", FT_STRINGZ, BASE_NONE, NULL, 0x0, "OD resolved queue name", HFILL }},
                { &hf_mq_od_resolvqmgrnm,{"Resolved QMgrName", "mq.od.resolvqmgr", FT_STRINGZ, BASE_NONE, NULL, 0x0, "OD resolved queue manager name", HFILL }},
-               { &hf_mq_od_resolvobjtyp,{"Resolv Obj Type..", "mq.od.resolvedobjtype", FT_UINT32, BASE_DEC, NULL, 0x0, "OD resolved object type", HFILL }},
+               { &hf_mq_od_resolvobjtyp,{"Resolv Obj Type..", "mq.od.resolvedobjtype", FT_UINT32, BASE_DEC, VALS(GET_VALSV(objtype)), 0x0, "OD resolved object type", HFILL }},
 
                { &hf_mq_or_objname     ,{"Object name...", "mq.or.objname", FT_STRINGZ, BASE_NONE, NULL, 0x0, "OR object name", HFILL }},
                { &hf_mq_or_objqmgrname ,{"Object QMgr Nm", "mq.or.objqmgrname", FT_STRINGZ, BASE_NONE, NULL, 0x0, "OR object queue manager name", HFILL }},
@@ -4037,7 +4150,7 @@ void proto_register_mq(void)
                { &hf_mq_md_expiry      ,{"Expiry  .", "mq.md.expiry", FT_INT32, BASE_DEC, NULL, 0x0, "MD expiry", HFILL }},
                { &hf_mq_md_feedback    ,{"Feedback.", "mq.md.feedback", FT_UINT32, BASE_DEC, NULL, 0x0, "MD feedback", HFILL }},
                { &hf_mq_md_encoding    ,{"Encoding.", "mq.md.encoding", FT_UINT32, BASE_DEC, NULL, 0x0, "MD encoding", HFILL }},
-               { &hf_mq_md_ccsid       ,{"CCSID....", "mq.md.ccsid", FT_INT32, BASE_DEC, NULL, 0x0, "MD character set", HFILL }},
+               { &hf_mq_md_ccsid       ,{"CCSID....", "mq.md.ccsid", FT_INT32, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "MD character set", HFILL }},
                { &hf_mq_md_format      ,{"Format...", "mq.md.format", FT_STRINGZ, BASE_NONE, NULL, 0x0, "MD format", HFILL }},
                { &hf_mq_md_priority    ,{"Priority.", "mq.md.priority", FT_INT32, BASE_DEC, NULL, 0x0, "MD priority", HFILL }},
                { &hf_mq_md_persistence ,{"Persist..", "mq.md.persistence", FT_UINT32, BASE_DEC, NULL, 0x0, "MD persistence", HFILL }},
@@ -4059,7 +4172,6 @@ void proto_register_mq(void)
                { &hf_mq_md_offset      ,{"Offset...", "mq.md.offset", FT_UINT32, BASE_DEC, NULL, 0x0, "MD Offset", HFILL }},
                { &hf_mq_md_msgflags    ,{"Msg flags", "mq.md.msgflags", FT_UINT32, BASE_HEX, NULL, 0x0, "MD Message flags", HFILL }},
                { &hf_mq_md_origlen     ,{"Orig len.", "mq.md.origlength", FT_INT32, BASE_DEC, NULL, 0x0, "MD Original length", HFILL }},
-               /*{ &hf_mq_md_lastformat  ,{"Last format", "mq.md.lastformat", FT_STRINGZ, BASE_NONE, NULL, 0x0, "MD Last format", HFILL }},*/
 
                { &hf_mq_dlh_StructID   ,{"StructID.", "mq.dlh.structid", FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL }},
                { &hf_mq_dlh_version    ,{"Version..", "mq.dlh.version", FT_UINT32, BASE_DEC, NULL, 0x0, "DLH version", HFILL }},
@@ -4067,7 +4179,7 @@ void proto_register_mq(void)
                { &hf_mq_dlh_destq      ,{"Dest Q...", "mq.dlh.destq", FT_STRINGZ, BASE_NONE, NULL, 0x0, "DLH destination queue", HFILL }},
                { &hf_mq_dlh_destqmgr   ,{"DestQMgr.", "mq.dlh.destqmgr", FT_STRINGZ, BASE_NONE, NULL, 0x0, "DLH destination queue manager", HFILL }},
                { &hf_mq_dlh_encoding   ,{"Encoding.", "mq.dlh.encoding", FT_UINT32, BASE_DEC, NULL, 0x0, "DLH encoding", HFILL }},
-               { &hf_mq_dlh_ccsid      ,{"CCSID....", "mq.dlh.ccsid", FT_INT32, BASE_DEC, NULL, 0x0, "DLH character set", HFILL }},
+               { &hf_mq_dlh_ccsid      ,{"CCSID....", "mq.dlh.ccsid", FT_INT32, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "DLH character set", HFILL }},
                { &hf_mq_dlh_format     ,{"Format...", "mq.dlh.format", FT_STRINGZ, BASE_NONE, NULL, 0x0, "DLH format", HFILL }},
                { &hf_mq_dlh_putappltype,{"PutAppTyp", "mq.dlh.putappltype", FT_INT32, BASE_DEC, VALS(GET_VALSV(mqat)), 0x0, "DLH put application type", HFILL }},
                { &hf_mq_dlh_putapplname,{"PutAppNme", "mq.dlh.putapplname", FT_STRINGZ, BASE_NONE, NULL, 0x0, "DLH put application name", HFILL }},
@@ -4110,36 +4222,7 @@ void proto_register_mq(void)
                { &hf_mq_gmo_options_NO_SYNCPOINT            ,{"NO_SYNCPOINT", "mq.gmo.options.NO_SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_NO_SYNCPOINT , "GMO options NO_SYNCPOINT", HFILL }},
                { &hf_mq_gmo_options_SYNCPOINT               ,{"SYNCPOINT", "mq.gmo.options.SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_SYNCPOINT , "GMO options SYNCPOINT", HFILL }},
                { &hf_mq_gmo_options_WAIT                    ,{"WAIT", "mq.gmo.options.WAIT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_WAIT , "GMO options WAIT", HFILL }},
-               /*
-               { &hf_mq_gmo_options_PROPERTIES_COMPATIBILITY,{"PROPERTIES_COMPATIBILITY", "mq.gmo.options.PROPERTIES_COMPATIBILITY", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_PROPERTIES_COMPATIBILITY, "GMO options PROPERTIES_COMPATIBILITY", HFILL }},
-               { &hf_mq_gmo_options_PROPERTIES_IN_HANDLE    ,{"PROPERTIES_IN_HANDLE....", "mq.gmo.options.PROPERTIES_IN_HANDLE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_PROPERTIES_IN_HANDLE , "GMO options PROPERTIES_IN_HANDLE", HFILL }},
-               { &hf_mq_gmo_options_NO_PROPERTIES           ,{"NO_PROPERTIES...........", "mq.gmo.options.NO_PROPERTIES", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_NO_PROPERTIES , "GMO options NO_PROPERTIES", HFILL }},
-               { &hf_mq_gmo_options_PROPERTIES_FORCE_MQRFH2 ,{"PROPERTIES_FORCE_MQRFH2.", "mq.gmo.options.PROPERTIES_FORCE_MQRFH2", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_PROPERTIES_FORCE_MQRFH2 , "GMO options PROPERTIES_FORCE_MQRFH2", HFILL }},
-               { &hf_mq_gmo_options_UNMARKED_BROWSE_MSG     ,{"UNMARKED_BROWSE_MSG.....", "mq.gmo.options.UNMARKED_BROWSE_MSG", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_UNMARKED_BROWSE_MSG , "GMO options UNMARKED_BROWSE_MSG", HFILL }},
-               { &hf_mq_gmo_options_UNMARK_BROWSE_HANDLE    ,{"UNMARK_BROWSE_HANDLE....", "mq.gmo.options.UNMARK_BROWSE_HANDLE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_UNMARK_BROWSE_HANDLE , "GMO options UNMARK_BROWSE_HANDLE", HFILL }},
-               { &hf_mq_gmo_options_UNMARK_BROWSE_CO_OP     ,{"UNMARK_BROWSE_CO_OP.....", "mq.gmo.options.UNMARK_BROWSE_CO_OP", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_UNMARK_BROWSE_CO_OP , "GMO options UNMARK_BROWSE_CO_OP", HFILL }},
-               { &hf_mq_gmo_options_MARK_BROWSE_CO_OP       ,{"MARK_BROWSE_CO_OP.......", "mq.gmo.options.MARK_BROWSE_CO_OP", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_MARK_BROWSE_CO_OP , "GMO options MARK_BROWSE_CO_OP", HFILL }},
-               { &hf_mq_gmo_options_MARK_BROWSE_HANDLE      ,{"MARK_BROWSE_HANDLE......", "mq.gmo.options.MARK_BROWSE_HANDLE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_MARK_BROWSE_HANDLE , "GMO options MARK_BROWSE_HANDLE", HFILL }},
-               { &hf_mq_gmo_options_ALL_SEGMENTS_AVAILABLE  ,{"ALL_SEGMENTS_AVAILABLE..", "mq.gmo.options.ALL_SEGMENTS_AVAILABLE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_ALL_SEGMENTS_AVAILABLE , "GMO options ALL_SEGMENTS_AVAILABLE", HFILL }},
-               { &hf_mq_gmo_options_ALL_MSGS_AVAILABLE      ,{"ALL_MSGS_AVAILABLE......", "mq.gmo.options.ALL_MSGS_AVAILABLE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_ALL_MSGS_AVAILABLE , "GMO options ALL_MSGS_AVAILABLE", HFILL }},
-               { &hf_mq_gmo_options_COMPLETE_MSG            ,{"COMPLETE_MSG............", "mq.gmo.options.COMPLETE_MSG", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_COMPLETE_MSG , "GMO options COMPLETE_MSG", HFILL }},
-               { &hf_mq_gmo_options_LOGICAL_ORDER           ,{"LOGICAL_ORDER...........", "mq.gmo.options.LOGICAL_ORDER", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_LOGICAL_ORDER , "GMO options LOGICAL_ORDER", HFILL }},
-               { &hf_mq_gmo_options_CONVERT                 ,{"CONVERT.................", "mq.gmo.options.CONVERT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_CONVERT , "GMO options CONVERT", HFILL }},
-               { &hf_mq_gmo_options_FAIL_IF_QUIESCING       ,{"FAIL_IF_QUIESCING.......", "mq.gmo.options.FAIL_IF_QUIESCING", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_FAIL_IF_QUIESCING , "GMO options FAIL_IF_QUIESCING", HFILL }},
-               { &hf_mq_gmo_options_SYNCPOINT_IF_PERSISTENT ,{"SYNCPOINT_IF_PERSISTENT.", "mq.gmo.options.SYNCPOINT_IF_PERSISTENT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_SYNCPOINT_IF_PERSISTENT , "GMO options SYNCPOINT_IF_PERSISTENT", HFILL }},
-               { &hf_mq_gmo_options_BROWSE_MSG_UNDER_CURSOR ,{"BROWSE_MSG_UNDER_CURSOR.", "mq.gmo.options.BROWSE_MSG_UNDER_CURSOR", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_BROWSE_MSG_UNDER_CURSOR , "GMO options BROWSE_MSG_UNDER_CURSOR", HFILL }},
-               { &hf_mq_gmo_options_UNLOCK                  ,{"UNLOCK..................", "mq.gmo.options.UNLOCK", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_UNLOCK , "GMO options UNLOCK", HFILL }},
-               { &hf_mq_gmo_options_LOCK                    ,{"LOCK....................", "mq.gmo.options.LOCK", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_LOCK , "GMO options LOCK", HFILL }},
-               { &hf_mq_gmo_options_MSG_UNDER_CURSOR        ,{"MSG_UNDER_CURSOR........", "mq.gmo.options.MSG_UNDER_CURSOR", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_MSG_UNDER_CURSOR , "GMO options MSG_UNDER_CURSOR", HFILL }},
-               { &hf_mq_gmo_options_MARK_SKIP_BACKOUT       ,{"MARK_SKIP_BACKOUT.......", "mq.gmo.options.MARK_SKIP_BACKOUT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_MARK_SKIP_BACKOUT , "GMO options MARK_SKIP_BACKOUT", HFILL }},
-               { &hf_mq_gmo_options_ACCEPT_TRUNCATED_MSG    ,{"ACCEPT_TRUNCATED_MSG....", "mq.gmo.options.ACCEPT_TRUNCATED_MSG", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_ACCEPT_TRUNCATED_MSG , "GMO options ACCEPT_TRUNCATED_MSG", HFILL }},
-               { &hf_mq_gmo_options_BROWSE_NEXT             ,{"BROWSE_NEXT.............", "mq.gmo.options.BROWSE_NEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_BROWSE_NEXT , "GMO options BROWSE_NEXT", HFILL }},
-               { &hf_mq_gmo_options_BROWSE_FIRST            ,{"BROWSE_FIRST............", "mq.gmo.options.BROWSE_FIRST", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_BROWSE_FIRST , "GMO options BROWSE_FIRST", HFILL }},
-               { &hf_mq_gmo_options_SET_SIGNAL              ,{"SET_SIGNAL..............", "mq.gmo.options.SET_SIGNAL", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_SET_SIGNAL , "GMO options SET_SIGNAL", HFILL }},
-               { &hf_mq_gmo_options_NO_SYNCPOINT            ,{"NO_SYNCPOINT............", "mq.gmo.options.NO_SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_NO_SYNCPOINT , "GMO options NO_SYNCPOINT", HFILL }},
-               { &hf_mq_gmo_options_SYNCPOINT               ,{"SYNCPOINT...............", "mq.gmo.options.SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_SYNCPOINT , "GMO options SYNCPOINT", HFILL }},
-               { &hf_mq_gmo_options_WAIT                    ,{"WAIT....................", "mq.gmo.options.WAIT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQGMO_WAIT , "GMO options WAIT", HFILL }},
-               */
+
                { &hf_mq_gmo_waitinterval,{"WaitIntv.", "mq.gmo.waitint", FT_INT32, BASE_DEC, NULL, 0x0, "GMO wait interval", HFILL }},
                { &hf_mq_gmo_signal1     ,{"Signal 1.", "mq.gmo.signal1", FT_UINT32, BASE_HEX, NULL, 0x0, "GMO signal 1", HFILL }},
                { &hf_mq_gmo_signal2     ,{"Signal 2.", "mq.gmo.signal2", FT_UINT32, BASE_HEX, NULL, 0x0, "GMO signal 2", HFILL }},
@@ -4152,14 +4235,7 @@ void proto_register_mq(void)
                { &hf_mq_gmo_matchoptions_MATCH_GROUP_ID      ,{"MATCH_GROUP_ID", "mq.gmo.matchoptions.MATCH_GROUP_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_GROUP_ID , "GMO matchoptions MATCH_GROUP_ID", HFILL }},
                { &hf_mq_gmo_matchoptions_MATCH_CORREL_ID     ,{"MATCH_CORREL_ID", "mq.gmo.matchoptions.MATCH_CORREL_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_CORREL_ID , "GMO matchoptions MATCH_CORREL_ID", HFILL }},
                { &hf_mq_gmo_matchoptions_MATCH_MSG_ID        ,{"MATCH_MSG_ID", "mq.gmo.matchoptions.MATCH_MSG_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_MSG_ID , "GMO matchoptions MATCH_MSG_ID", HFILL }},
-               /*
-               { &hf_mq_gmo_matchoptions_MATCH_MSG_TOKEN     ,{"MATCH_MSG_TOKEN.....", "mq.gmo.matchoptions.MATCH_MSG_TOKEN", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_MSG_TOKEN , "GMO matchoptions MATCH_MSG_TOKEN", HFILL }},
-               { &hf_mq_gmo_matchoptions_MATCH_OFFSET        ,{"MATCH_OFFSET........", "mq.gmo.matchoptions.MATCH_OFFSET", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_OFFSET , "GMO matchoptions MATCH_OFFSET", HFILL }},
-               { &hf_mq_gmo_matchoptions_MATCH_MSG_SEQ_NUMBER,{"MATCH_MSG_SEQ_NUMBER", "mq.gmo.matchoptions.MATCH_MSG_SEQ_NUMBER", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_MSG_SEQ_NUMBER, "GMO matchoptions MATCH_MSG_SEQ_NUMBER", HFILL }},
-               { &hf_mq_gmo_matchoptions_MATCH_GROUP_ID      ,{"MATCH_GROUP_ID......", "mq.gmo.matchoptions.MATCH_GROUP_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_GROUP_ID , "GMO matchoptions MATCH_GROUP_ID", HFILL }},
-               { &hf_mq_gmo_matchoptions_MATCH_CORREL_ID     ,{"MATCH_CORREL_ID.....", "mq.gmo.matchoptions.MATCH_CORREL_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_CORREL_ID , "GMO matchoptions MATCH_CORREL_ID", HFILL }},
-               { &hf_mq_gmo_matchoptions_MATCH_MSG_ID        ,{"MATCH_MSG_ID........", "mq.gmo.matchoptions.MATCH_MSG_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQMO_MATCH_MSG_ID , "GMO matchoptions MATCH_MSG_ID", HFILL }},
-               */
+
                { &hf_mq_gmo_groupstatus ,{"GrpStatus", "mq.gmo.grpstat", FT_UINT8, BASE_HEX, NULL, 0x0, "GMO group status", HFILL }},
                { &hf_mq_gmo_segmstatus  ,{"SegStatus", "mq.gmo.sgmtstat", FT_UINT8, BASE_HEX, NULL, 0x0, "GMO segment status", HFILL }},
                { &hf_mq_gmo_segmentation,{"Segmentat", "mq.gmo.segmentation", FT_UINT8, BASE_HEX, NULL, 0x0, "GMO segmentation", HFILL }},
@@ -4167,16 +4243,23 @@ void proto_register_mq(void)
                { &hf_mq_gmo_msgtoken    ,{"MsgToken.", "mq.gmo.msgtoken", FT_BYTES, BASE_NONE, NULL, 0x0, "GMO message token", HFILL }},
                { &hf_mq_gmo_returnedlen ,{"RtnLength", "mq.gmo.retlen", FT_INT32, BASE_DEC, NULL, 0x0, "GMO returned length", HFILL }},
 
-               { &hf_mq_lpoo_StructID   ,{"StructID", "mq.lpoo.structid", FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL }},
-               { &hf_mq_lpoo_version    ,{"Version.", "mq.lpoo.version", FT_UINT32, BASE_DEC, NULL, 0x0, "LPOO version", HFILL }},
-               { &hf_mq_lpoo_unknown1   ,{"Unknown1", "mq.lpoo.unknown1", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown1", HFILL }},
-               { &hf_mq_lpoo_unknown2   ,{"Unknown2", "mq.lpoo.unknown2", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown2", HFILL }},
-               { &hf_mq_lpoo_unknown3   ,{"Unknown3", "mq.lpoo.unknown3", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown3", HFILL }},
-               { &hf_mq_lpoo_unknown4   ,{"Unknown4", "mq.lpoo.unknown4", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown4", HFILL }},
-               { &hf_mq_lpoo_unknown5   ,{"Unknown5", "mq.lpoo.unknown5", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown5", HFILL }},
-               { &hf_mq_lpoo_qprotect   ,{"qprotect", "mq.lpoo.qprotect", FT_STRINGZ, BASE_NONE, NULL, 0x0, "LPOO queue protection", HFILL }},
-               { &hf_mq_lpoo_unknown6   ,{"Unknown6", "mq.lpoo.unknown6", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown6", HFILL }},
-               { &hf_mq_lpoo_unknown7   ,{"Unknown7", "mq.lpoo.unknown7", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown7", HFILL }},
+               { &hf_mq_lpoo_StructID      ,{"StructID......", "mq.lpoo.structid", FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL }},
+               { &hf_mq_lpoo_version       ,{"Version.......", "mq.lpoo.version", FT_UINT32, BASE_DEC, NULL, 0x0, "LPOO version", HFILL }},
+               { &hf_mq_lpoo_options       ,{"Options.......", "mq.lpoo.options", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO options", HFILL }},
+               { &hf_mq_lpoo_lpiopts       ,{"LpiOpts.......", "mq.lpoo.lpioopts", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO Lpi Options", HFILL }},
+
+               { &hf_mq_lpoo_lpiopts_SAVE_USER_CTXT    ,{"SAVE_USER_CTXT", "mq.lpoo.opts.SAVE_USER_CTXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_LPOO_SAVE_USER_CTXT, "LPOO options SAVE_USER_CTXT", HFILL }},
+               { &hf_mq_lpoo_lpiopts_SAVE_ORIGIN_CTXT  ,{"SAVE_ORIGIN_CTXT", "mq.lpoo.opts.SAVE_ORIGIN_CTXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_LPOO_SAVE_ORIGIN_CTXT, "LPOO options SAVE_ORIGIN_CTXT", HFILL }},
+               { &hf_mq_lpoo_lpiopts_SAVE_IDENTITY_CTXT,{"SAVE_IDENTITY_CTXT", "mq.lpoo.opts.SAVE_IDENTITY_CTXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_LPOO_SAVE_IDENTITY_CTXT, "LPOO options SAVE_IDENTITY_CTXT", HFILL }},
+
+               { &hf_mq_lpoo_defpersist    ,{"DefPersitence.", "mq.lpoo.defpersist", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO Default Persitence", HFILL }},
+               { &hf_mq_lpoo_defputresptype,{"DefPutRespType", "mq.lpoo.defputresptype", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO Default Put Response Type", HFILL }},
+               { &hf_mq_lpoo_defreadahead  ,{"DefReadAHead..", "mq.lpoo.defreadahead", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO Default Read AHead", HFILL }},
+
+               { &hf_mq_lpoo_qprotect      ,{"qprotect......", "mq.lpoo.qprotect", FT_STRINGZ, BASE_NONE, NULL, 0x0, "LPOO queue protection", HFILL }},
+               { &hf_mq_lpoo_unknown6      ,{"Unknown6......", "mq.lpoo.unknown6", FT_UINT32, BASE_HEX, NULL, 0x0, "LPOO unknown6", HFILL }},
+               /*{ &hf_mq_lpoo_unknown7      ,{"Unknown7......", "mq.lpoo.unknown7", FT_UINT16, BASE_HEX, NULL, 0x0, "LPOO unknown7", HFILL }},*/
+               { &hf_mq_lpoo_xtradata      ,{"ExtraData.....", "mq.lpoo.extradata", FT_UINT32, BASE_DEC, NULL, 0x0, "LPOO Extra Data", HFILL }},
 
                { &hf_mq_pmo_StructID    ,{"StructID.", "mq.pmo.structid", FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL }},
                { &hf_mq_pmo_version     ,{"Version..", "mq.pmo.version", FT_UINT32, BASE_DEC, NULL, 0x0, "PMO version", HFILL }},
@@ -4203,30 +4286,7 @@ void proto_register_mq(void)
                { &hf_mq_pmo_options_DEFAULT_CONTEXT         ,{"DEFAULT_CONTEXT", "mq.pmo.options.DEFAULT_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_DEFAULT_CONTEXT , "PMO options DEFAULT_CONTEXT", HFILL }},
                { &hf_mq_pmo_options_NO_SYNCPOINT            ,{"NO_SYNCPOINT", "mq.pmo.options.NO_SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NO_SYNCPOINT , "PMO options NO_SYNCPOINT", HFILL }},
                { &hf_mq_pmo_options_SYNCPOINT               ,{"SYNCPOINT", "mq.pmo.options.SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SYNCPOINT , "PMO options SYNCPOINT", HFILL }},
-               /*
-               { &hf_mq_pmo_options_NOT_OWN_SUBS            ,{"NOT_OWN_SUBS............", "mq.pmo.options.NOT_OWN_SUBS", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NOT_OWN_SUBS , "PMO options NOT_OWN_SUBS", HFILL }},
-               { &hf_mq_pmo_options_SUPPRESS_REPLYTO        ,{"SUPPRESS_REPLYTO........", "mq.pmo.options.SUPPRESS_REPLYTO", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SUPPRESS_REPLYTO , "PMO options SUPPRESS_REPLYTO", HFILL }},
-               { &hf_mq_pmo_options_SCOPE_QMGR              ,{"SCOPE_QMGR..............", "mq.pmo.options.SCOPE_QMGR", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SCOPE_QMGR , "PMO options SCOPE_QMGR", HFILL }},
-               { &hf_mq_pmo_options_MD_FOR_OUTPUT_ONLY      ,{"MD_FOR_OUTPUT_ONLY......", "mq.pmo.options.MD_FOR_OUTPUT_ONLY", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_MD_FOR_OUTPUT_ONLY , "PMO options MD_FOR_OUTPUT_ONLY", HFILL }},
-               { &hf_mq_pmo_options_RETAIN                  ,{"RETAIN..................", "mq.pmo.options.RETAIN", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_RETAIN , "PMO options RETAIN", HFILL }},
-               { &hf_mq_pmo_options_WARN_IF_NO_SUBS_MATCHED ,{"WARN_IF_NO_SUBS_MATCHED.", "mq.pmo.options.WARN_IF_NO_SUBS_MATCHED", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_WARN_IF_NO_SUBS_MATCHED , "PMO options WARN_IF_NO_SUBS_MATCHED", HFILL }},
-               { &hf_mq_pmo_options_RESOLVE_LOCAL_Q         ,{"RESOLVE_LOCAL_Q.........", "mq.pmo.options.RESOLVE_LOCAL_Q", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_RESOLVE_LOCAL_Q , "PMO options RESOLVE_LOCAL_Q", HFILL }},
-               { &hf_mq_pmo_options_SYNC_RESPONSE           ,{"SYNC_RESPONSE...........", "mq.pmo.options.SYNC_RESPONSE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SYNC_RESPONSE , "PMO options SYNC_RESPONSE", HFILL }},
-               { &hf_mq_pmo_options_ASYNC_RESPONSE          ,{"ASYNC_RESPONSE..........", "mq.pmo.options.ASYNC_RESPONSE", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_ASYNC_RESPONSE , "PMO options ASYNC_RESPONSE", HFILL }},
-               { &hf_mq_pmo_options_LOGICAL_ORDER           ,{"LOGICAL_ORDER...........", "mq.pmo.options.LOGICAL_ORDER", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_LOGICAL_ORDER , "PMO options LOGICAL_ORDER", HFILL }},
-               { &hf_mq_pmo_options_NO_CONTEXT              ,{"NO_CONTEXT..............", "mq.pmo.options.NO_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NO_CONTEXT , "PMO options NO_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_FAIL_IF_QUIESCING       ,{"FAIL_IF_QUIESCING.......", "mq.pmo.options.FAIL_IF_QUIESCING", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_FAIL_IF_QUIESCING , "PMO options FAIL_IF_QUIESCING", HFILL }},
-               { &hf_mq_pmo_options_ALTERNATE_USER_AUTHORITY,{"ALTERNATE_USER_AUTHORITY", "mq.pmo.options.ALTERNATE_USER_AUTHORITY", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_ALTERNATE_USER_AUTHORITY , "PMO options ALTERNATE_USER_AUTHORITY", HFILL }},
-               { &hf_mq_pmo_options_SET_ALL_CONTEXT         ,{"SET_ALL_CONTEXT.........", "mq.pmo.options.SET_ALL_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SET_ALL_CONTEXT , "PMO options SET_ALL_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_SET_IDENTITY_CONTEXT    ,{"SET_IDENTITY_CONTEXT....", "mq.pmo.options.SET_IDENTITY_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SET_IDENTITY_CONTEXT , "PMO options SET_IDENTITY_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_PASS_ALL_CONTEXT        ,{"PASS_ALL_CONTEXT........", "mq.pmo.options.PASS_ALL_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_PASS_ALL_CONTEXT , "PMO options PASS_ALL_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_PASS_IDENTITY_CONTEXT   ,{"PASS_IDENTITY_CONTEXT...", "mq.pmo.options.PASS_IDENTITY_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_PASS_IDENTITY_CONTEXT , "PMO options PASS_IDENTITY_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_NEW_CORREL_ID           ,{"NEW_CORREL_ID...........", "mq.pmo.options.NEW_CORREL_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NEW_CORREL_ID , "PMO options NEW_CORREL_ID", HFILL }},
-               { &hf_mq_pmo_options_NEW_MSG_ID              ,{"NEW_MSG_ID..............", "mq.pmo.options.NEW_MSG_ID", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NEW_MSG_ID , "PMO options NEW_MSG_ID", HFILL }},
-               { &hf_mq_pmo_options_DEFAULT_CONTEXT         ,{"DEFAULT_CONTEXT.........", "mq.pmo.options.DEFAULT_CONTEXT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_DEFAULT_CONTEXT , "PMO options DEFAULT_CONTEXT", HFILL }},
-               { &hf_mq_pmo_options_NO_SYNCPOINT            ,{"NO_SYNCPOINT............", "mq.pmo.options.NO_SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_NO_SYNCPOINT , "PMO options NO_SYNCPOINT", HFILL }},
-               { &hf_mq_pmo_options_SYNCPOINT               ,{"SYNCPOINT...............", "mq.pmo.options.SYNCPOINT", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_MQPMO_SYNCPOINT , "PMO options SYNCPOINT", HFILL }},
-               */
+
                { &hf_mq_pmo_timeout     ,{"Timeout..", "mq.pmo.timeout", FT_INT32, BASE_DEC, NULL, 0x0, "PMO time out", HFILL }},
                { &hf_mq_pmo_context     ,{"Context..", "mq.pmo.context", FT_UINT32, BASE_HEX, NULL, 0x0, "PMO context", HFILL }},
                { &hf_mq_pmo_knowndstcnt ,{"KnDstCnt.", "mq.pmo.kdstcount", FT_UINT32, BASE_DEC, NULL, 0x0, "PMO known destination count", HFILL }},
@@ -4245,7 +4305,7 @@ void proto_register_mq(void)
                { &hf_mq_head_version    ,{"version.", "mq.head.version", FT_UINT32, BASE_DEC, NULL, 0x0, "Header version", HFILL }},
                { &hf_mq_head_length     ,{"Length..", "mq.head.length", FT_UINT32, BASE_DEC, NULL, 0x0, "Header length", HFILL }},
                { &hf_mq_head_encoding   ,{"Encoding", "mq.head.encoding", FT_UINT32, BASE_DEC, NULL, 0x0, "Header encoding", HFILL }},
-               { &hf_mq_head_ccsid      ,{"CCSID...", "mq.head.ccsid", FT_INT32, BASE_DEC, NULL, 0x0, "Header character set", HFILL }},
+               { &hf_mq_head_ccsid      ,{"CCSID...", "mq.head.ccsid", FT_INT32, BASE_DEC | BASE_RANGE_STRING, RVALS(&GET_VALRV(ccsid)), 0x0, "Header character set", HFILL }},
                { &hf_mq_head_format     ,{"Format..", "mq.head.format", FT_STRINGZ, BASE_NONE, NULL, 0x0, "Header format", HFILL }},
                { &hf_mq_head_flags      ,{"Flags...", "mq.head.flags", FT_UINT32, BASE_DEC, NULL, 0x0, "Header flags", HFILL }},
                { &hf_mq_head_struct     ,{"Struct..", "mq.head.struct", FT_BYTES, BASE_NONE, NULL, 0x0, "Header struct", HFILL }},
@@ -4263,16 +4323,7 @@ void proto_register_mq(void)
                { &hf_mq_xa_tmflags_resume    ,{"RESUME", "mq.xa.tmflags.resume", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMRESUME, "XA TM Flags RESUME", HFILL }},
                { &hf_mq_xa_tmflags_fail      ,{"FAIL", "mq.xa.tmflags.fail", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMFAIL, "XA TM Flags FAIL", HFILL }},
                { &hf_mq_xa_tmflags_onephase  ,{"ONEPHASE", "mq.xa.tmflags.onephase", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMONEPHASE, "XA TM Flags ONEPHASE", HFILL }},
-               /*
-               { &hf_mq_xa_tmflags_join      ,{"JOIN......", "mq.xa.tmflags.join", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMJOIN, "XA TM Flags JOIN", HFILL }},
-               { &hf_mq_xa_tmflags_endrscan  ,{"ENDRSCAN..", "mq.xa.tmflags.endrscan", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMENDRSCAN, "XA TM Flags ENDRSCAN", HFILL }},
-               { &hf_mq_xa_tmflags_startrscan,{"STARTRSCAN", "mq.xa.tmflags.startrscan", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMSTARTRSCAN, "XA TM Flags STARTRSCAN", HFILL }},
-               { &hf_mq_xa_tmflags_suspend   ,{"SUSPEND...", "mq.xa.tmflags.suspend", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMSUSPEND, "XA TM Flags SUSPEND", HFILL }},
-               { &hf_mq_xa_tmflags_success   ,{"SUCCESS...", "mq.xa.tmflags.success", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMSUCCESS, "XA TM Flags SUCCESS", HFILL }},
-               { &hf_mq_xa_tmflags_resume    ,{"RESUME....", "mq.xa.tmflags.resume", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMRESUME, "XA TM Flags RESUME", HFILL }},
-               { &hf_mq_xa_tmflags_fail      ,{"FAIL......", "mq.xa.tmflags.fail", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMFAIL, "XA TM Flags FAIL", HFILL }},
-               { &hf_mq_xa_tmflags_onephase  ,{"ONEPHASE..", "mq.xa.tmflags.onephase", FT_BOOLEAN, 32, TFS(&tfs_set_notset), MQ_XA_TMONEPHASE, "XA TM Flags ONEPHASE", HFILL }},
-               */
+
                { &hf_mq_xa_xid_formatid  ,{"Format ID....", "mq.xa.xid.formatid", FT_INT32, BASE_DEC, NULL, 0x0, "XA Xid Format ID", HFILL }},
                { &hf_mq_xa_xid_glbxid_len,{"GlbTransIDLen", "mq.xa.xid.gxidl", FT_UINT8, BASE_DEC, NULL, 0x0, "XA Xid Global TransactionId Length", HFILL }},
                { &hf_mq_xa_xid_brq_length,{"BranchQualLen", "mq.xa.xid.bql", FT_UINT8, BASE_DEC, NULL, 0x0, "XA Xid Branch Qualifier Length", HFILL }},
@@ -4340,7 +4391,8 @@ void proto_register_mq(void)
                &ett_mq_fcno,
                &ett_mq_fopa,
                &ett_mq_lpoo,
-               &ett_mq_lpoo_option,
+               &ett_mq_lpoo_options,
+               &ett_mq_lpoo_lpiopts,
                &ett_mq_head,
                &ett_mq_xa,
                &ett_mq_xa_tmflags,
index f4601029efe669507f57b5ff5ad9ea2469222de3..e4a43f6795d5ae4231347d54fe32fe039a9fd861 100644 (file)
 #ifndef __PACKET_MQ_H__
 #define __PACKET_MQ_H__
 
-#define DEF_VALSX(A)   extern const value_string mq_##A##_vals[]
-#define GET_VALSV(A)   mq_##A##_vals
-#define GET_VALSP(F)   (gchar *)GET_VALSV(F)
-
-#define DEF_VALSB(A) const value_string mq_##A##_vals[] = \
+#define GET_VALSV(A) mq_##A##_vals
+#define DEF_VALSX(A) extern const value_string GET_VALSV(A)[]
+#define GET_VALSP(F) (gchar *)GET_VALSV(F)
+#define DEF_VALSB(A) const value_string GET_VALSV(A)[] = \
 {
-
 #define DEF_VALS1(A)   { (guint32)MQ_##A, #A }
 #define DEF_VALS2(A,B) { (guint32)MQ_##A, B }
-
 #define DEF_VALSE \
 { 0, NULL } \
 }
+#define DEF_VALSEXT(A)  value_string_ext GET_VALSV(A)_ext = VALUE_STRING_EXT_INIT(GET_VALSV(A))
+#define DEF_VALSEXTX(A) extern value_string_ext GET_VALSV(A)_ext
+
+/* | BASE_RANGE_STRING, GET_VALRV(RVALS(aaa)) */
+#define GET_VALRV(A) mq_##A##_rvals
+#define DEF_VALRX(A) extern const range_string GET_VALRV(A)[]
+#define GET_VALRP(F) (gchar *)GET_VALRV(F)
+#define DEF_VALRB(A) const range_string GET_VALRV(A)[] = \
+{
+#define DEF_VALR1(A)     { (guint32)MQ_##A, (guint32)MQ_##A, #A }
+#define DEF_VALR3(A,B,C) { (guint32)MQ_##A, (guint32)MQ_##B, C }
+#define DEF_VALRE \
+{ 0, 0, NULL } \
+}
+#define DEF_VALREXTX(A) extern value_string_ext GET_VALRV(A)_ext
 
-#define DEF_VALSEXT(A)  value_string_ext mq_##A##_vals_ext = VALUE_STRING_EXT_INIT(mq_##A##_vals)
-#define DEF_VALSEXTX(A) extern value_string_ext mq_##A##_vals_ext
-
-/*
-* Private data passed from the MQ dissector to subdissectors.
-*/
-struct mqinfo 
+typedef struct _mq_ccsid_t
 {
-       guint32 encoding;           /* Message encoding */
-       guint32 ccsid;              /* Message character set */
-       guint8  format[8];          /* Message format */
-};
+       guint32 encod;
+       guint32 ccsid;
+} mq_ccsid_t;
 
 typedef struct _mq_parm_t
 {
        guint32 mq_strucID ;
        guint32 mq_int_enc ;
        guint32 mq_str_enc ;
-       guint32 mq_encode  ;
-       guint16 mq_ccsid   ;
        guint8  mq_ctlf1   ;
        guint8  mq_ctlf2   ;
        guint8  mq_opcode  ;
+       mq_ccsid_t mq_tsh_ccsid;
+       mq_ccsid_t mq_id_ccsid;
+       mq_ccsid_t mq_md_ccsid;
+       mq_ccsid_t mq_dlh_ccsid;
+       mq_ccsid_t mq_head_ccsid;
+       mq_ccsid_t mq_msgreq_ccsid;
+       mq_ccsid_t mq_cur_ccsid;
+       guint8     mq_format[8];
+       gint32     iOfsEnc;     /* Offset to Message encoding */
+       gint32     iOfsCcs;     /* Offset to Message character set */
+       gint32     iOfsFmt;     /* Offset to Message format */
 } mq_parm_t;
 
 #define MQ_MQCA_XR_VERSION2 2120
@@ -336,6 +350,11 @@ typedef struct _mq_parm_t
 #define MQ_MQMO_MATCH_MSG_TOKEN           0x00000020
 #define MQ_MQMO_NONE                      0x00000000
 
+/* LPOO Options */
+#define MQ_LPOO_SAVE_IDENTITY_CTXT  0x00000001
+#define MQ_LPOO_SAVE_ORIGIN_CTXT    0x00000002
+#define MQ_LPOO_SAVE_USER_CTXT      0x00000004
+
 /* Group Status */
 #define MQ_MQGS_NOT_IN_GROUP              ' '
 #define MQ_MQGS_MSG_IN_GROUP              'G'
@@ -531,13 +550,15 @@ typedef struct _mq_parm_t
 #define MQ_MQENC_AS_PUBLISHED             (-1)
 
 /* Coded Character Set Identifiers */
+#define MQ_MQCCSI_AS_PUBLISHED            (-4)
+#define MQ_MQCCSI_APPL                    (-3)
+#define MQ_MQCCSI_INHERIT                 (-2)
+#define MQ_MQCCSI_EMBEDDED                (-1)
 #define MQ_MQCCSI_UNDEFINED               0
 #define MQ_MQCCSI_DEFAULT                 0
 #define MQ_MQCCSI_Q_MGR                   0
-#define MQ_MQCCSI_INHERIT                 (-2)
-#define MQ_MQCCSI_EMBEDDED                (-1)
-#define MQ_MQCCSI_APPL                    (-3)
-#define MQ_MQCCSI_AS_PUBLISHED            (-4)
+#define MQ_MQCCSI_1                       1
+#define MQ_MQCCSI_65535                   65535
 
 /* Formats */
 #define MQ_MQFMT_NONE                     "        "
@@ -1855,7 +1876,6 @@ typedef struct _mq_parm_t
 /* Capability */
 #define MQ_MQCAP_NOT_SUPPORTED            0
 #define MQ_MQCAP_SUPPORTED                1
-
 #define MQ_MQCAP_EXPIRED                  2
 /****************************************************************/
 /* Values Related to Topic Attributes                           */
@@ -4797,12 +4817,16 @@ typedef struct _mq_parm_t
 #define MQ_MQCLCT_STATIC                  0
 #define MQ_MQCLCT_DYNAMIC                 1
 
+ /* Transmission queue types */
+#define MQ_MQCLXQ_SCTQ                    0
+#define MQ_MQCLXQ_CHANNEL                 1
+
 #endif
 
 extern guint32 tvb_get_guint32_endian(tvbuff_t *a_tvb, gint a_iOffset, gint a_rep);
 extern guint16 tvb_get_guint16_endian(tvbuff_t *a_tvb, gint a_iOffset, gint a_rep);
 extern guint64 tvb_get_guint64_endian(tvbuff_t *a_tvb, gint a_iOffset, gint a_rep);
-extern guint32 strip_trailing_blanks(guint8 *a_str, guint32 a_size);
+extern gint32  strip_trailing_blanks(guint8 *a_str, guint32 a_size);
 
 DEF_VALSX(mqcc);
 DEF_VALSX(mqrc);
@@ -4817,6 +4841,8 @@ DEF_VALSX(FilterOP);
 
 DEF_VALSX(MQCFINT_Parse);
 
+DEF_VALRX(ccsid);
+
 /*
  * Editor modelines  -  http://www.wireshark.org/tools/modelines.html
  *