aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/ftam/packet-ftam-template.c
diff options
context:
space:
mode:
Diffstat (limited to 'asn1/ftam/packet-ftam-template.c')
-rw-r--r--asn1/ftam/packet-ftam-template.c30
1 files changed, 28 insertions, 2 deletions
diff --git a/asn1/ftam/packet-ftam-template.c b/asn1/ftam/packet-ftam-template.c
index fe44af82dd..7d8317cd98 100644
--- a/asn1/ftam/packet-ftam-template.c
+++ b/asn1/ftam/packet-ftam-template.c
@@ -56,6 +56,8 @@ static const char *object_identifier_id;
/* Declare the function to avoid a compiler warning */
static int dissect_ftam_OR_Set(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx, proto_tree *tree, int hf_index _U_);
+static int hf_ftam_unstructured_text = -1; /* ISO FTAM unstructured text */
+static int hf_ftam_unstructured_binary = -1; /* ISO FTAM unstructured binary */
#include "packet-ftam-hf.c"
/* Initialize the subtree pointers */
@@ -65,6 +67,24 @@ static gint ett_ftam = -1;
#include "packet-ftam-fn.c"
/*
+* Dissect FTAM unstructured text
+*/
+static void
+dissect_ftam_unstructured_text(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *parent_tree)
+{
+ proto_tree_add_item (parent_tree, hf_ftam_unstructured_text, tvb, 0, tvb_length_remaining(tvb, 0), FALSE);
+}
+
+/*
+* Dissect FTAM unstructured binary
+*/
+static void
+dissect_ftam_unstructured_binary(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *parent_tree)
+{
+ proto_tree_add_item (parent_tree, hf_ftam_unstructured_binary, tvb, 0, tvb_length_remaining(tvb, 0), FALSE);
+}
+
+/*
* Dissect FTAM PDUs inside a PPDU.
*/
static void
@@ -105,6 +125,12 @@ void proto_register_ftam(void) {
/* List of fields */
static hf_register_info hf[] =
{
+ { &hf_ftam_unstructured_text,
+ { "ISO FTAM unstructured text", "ftam.unstructured_text", FT_STRING,
+ BASE_DEC, NULL, 0x0, "ISO FTAM unstructured text", HFILL } },
+ { &hf_ftam_unstructured_binary,
+ { "ISO FTAM unstructured binary", "ftam.unstructured_binary", FT_BYTES,
+ BASE_DEC, NULL, 0x0, "ISO FTAM unstructured binary", HFILL } },
#include "packet-ftam-hfarr.c"
};
@@ -131,7 +157,7 @@ void proto_reg_handoff_ftam(void) {
register_ber_oid_dissector("1.3.14.5.2.2", dissect_ftam, proto_ftam,"NIST file directory entry abstract syntax");
/* Unstructured text file document type FTAM-1 */
- add_oid_str_name("1.0.8571.5.1","ISO FTAM unstructured text");
+ register_ber_oid_dissector("1.0.8571.5.1", dissect_ftam_unstructured_text, proto_ftam,"ISO FTAM unstructured text");
add_oid_str_name("1.0.8571.5.2","ISO FTAM sequential text");
add_oid_str_name("1.0.8571.2.3","FTAM unstructured text abstract syntax");
add_oid_str_name("1.0.8571.2.4","FTAM sequential text abstract syntax");
@@ -140,7 +166,7 @@ void proto_reg_handoff_ftam(void) {
add_oid_str_name("1.0.8571.4.1","FTAM unstructured constraint set");
/* Unstructured text file document type FTAM-3 */
- add_oid_str_name("1.0.8571.5.3","ISO FTAM unstructured binary");
+ register_ber_oid_dissector("1.0.8571.5.3", dissect_ftam_unstructured_binary, proto_ftam,"ISO FTAM unstructured binary");
add_oid_str_name("1.0.8571.2.4","FTAM unstructured binary abstract syntax");
/* Filedirectory file document type NBS-9 */