aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/asn1/wlancertextn
diff options
context:
space:
mode:
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>2016-03-09 03:17:51 +0000
committerJoão Valverde <j@v6e.pt>2016-03-13 21:30:24 +0000
commit54a520d4a1151c68d0b4e5f09a8d82466fa499f3 (patch)
tree7aacae160382098ce651ac862a5dfd5de4beff94 /epan/dissectors/asn1/wlancertextn
parentc1f3c935bdd33090c87f0d2f84842ce9729b747a (diff)
Move /asn1 to /epan/dissectors
Change-Id: I1208fe3c2ba428995526f561e8f792b8d871e9a9 Reviewed-on: https://code.wireshark.org/review/14388 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: João Valverde <j@v6e.pt>
Diffstat (limited to 'epan/dissectors/asn1/wlancertextn')
-rw-r--r--epan/dissectors/asn1/wlancertextn/CMakeLists.txt48
-rw-r--r--epan/dissectors/asn1/wlancertextn/Makefile.am23
-rw-r--r--epan/dissectors/asn1/wlancertextn/Makefile.common43
-rw-r--r--epan/dissectors/asn1/wlancertextn/Makefile.nmake26
-rw-r--r--epan/dissectors/asn1/wlancertextn/WLANCERTEXTN.asn93
-rw-r--r--epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.c82
-rw-r--r--epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.h30
-rw-r--r--epan/dissectors/asn1/wlancertextn/wlancertextn.cnf21
8 files changed, 366 insertions, 0 deletions
diff --git a/epan/dissectors/asn1/wlancertextn/CMakeLists.txt b/epan/dissectors/asn1/wlancertextn/CMakeLists.txt
new file mode 100644
index 0000000000..45e773fafc
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/CMakeLists.txt
@@ -0,0 +1,48 @@
+# CMakeLists.txt
+#
+# Wireshark - Network traffic analyzer
+# By Gerald Combs <gerald@wireshark.org>
+# Copyright 1998 Gerald Combs
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+#
+
+set( PROTOCOL_NAME wlancertextn )
+
+set( PROTO_OPT )
+
+set( EXT_ASN_FILE_LIST
+)
+
+set( ASN_FILE_LIST
+ WLANCERTEXTN.asn
+)
+
+set( EXTRA_DIST
+ ${ASN_FILE_LIST}
+ packet-${PROTOCOL_NAME}-template.c
+ packet-${PROTOCOL_NAME}-template.h
+ ${PROTOCOL_NAME}.cnf
+)
+
+set( SRC_FILES
+ ${EXTRA_DIST}
+ ${EXT_ASN_FILE_LIST}
+)
+
+set( A2W_FLAGS -b )
+
+ASN2WRS()
+
diff --git a/epan/dissectors/asn1/wlancertextn/Makefile.am b/epan/dissectors/asn1/wlancertextn/Makefile.am
new file mode 100644
index 0000000000..72d28e600b
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/Makefile.am
@@ -0,0 +1,23 @@
+# Wireshark - Network traffic analyzer
+# By Gerald Combs <gerald@wireshark.org>
+# Copyright 1998 Gerald Combs
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+
+include ../Makefile.preinc
+include Makefile.common
+include ../Makefile.inc
+
diff --git a/epan/dissectors/asn1/wlancertextn/Makefile.common b/epan/dissectors/asn1/wlancertextn/Makefile.common
new file mode 100644
index 0000000000..2940a92e49
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/Makefile.common
@@ -0,0 +1,43 @@
+# Wireshark - Network traffic analyzer
+# By Gerald Combs <gerald@wireshark.org>
+# Copyright 1998 Gerald Combs
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+
+PROTOCOL_NAME=wlancertextn
+
+EXT_ASN_FILE_LIST =
+
+ASN_FILE_LIST = \
+ WLANCERTEXTN.asn
+
+# The packet-$(PROTOCOL_NAME)-template.h and $(PROTOCOL_NAME).asn
+# files do not exist for all protocols: Please add/remove as required.
+EXTRA_DIST = \
+ $(EXTRA_DIST_COMMON) \
+ $(ASN_FILE_LIST) \
+ packet-$(PROTOCOL_NAME)-template.c \
+ packet-$(PROTOCOL_NAME)-template.h \
+ $(PROTOCOL_NAME).cnf
+
+SRC_FILES = \
+ $(EXTRA_DIST) \
+ $(EXT_ASN_FILE_LIST)
+
+A2W_FLAGS= -b
+
+EXTRA_CNF=
+
diff --git a/epan/dissectors/asn1/wlancertextn/Makefile.nmake b/epan/dissectors/asn1/wlancertextn/Makefile.nmake
new file mode 100644
index 0000000000..d296638ddd
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/Makefile.nmake
@@ -0,0 +1,26 @@
+## Use: $(MAKE) /$(MAKEFLAGS) -f makefile.nmake
+#
+# Wireshark - Network traffic analyzer
+# By Gerald Combs <gerald@wireshark.org>
+# Copyright 1998 Gerald Combs
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+
+include ../../../../config.nmake
+include ../Makefile.preinc.nmake
+include Makefile.common
+include ../Makefile.inc.nmake
+
diff --git a/epan/dissectors/asn1/wlancertextn/WLANCERTEXTN.asn b/epan/dissectors/asn1/wlancertextn/WLANCERTEXTN.asn
new file mode 100644
index 0000000000..52bda2c963
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/WLANCERTEXTN.asn
@@ -0,0 +1,93 @@
+-- ASN definitions taken from RFC3770
+-- Copyright notice from RFC3770 follows below
+--
+-- RFC 3770 PPP and WLAN May 2004
+--
+-- 10. Full Copyright Statement
+--
+-- Copyright (C) The Internet Society (2004). This document is subject
+-- to the rights, licenses and restrictions contained in BCP 78, and
+-- except as set forth therein, the authors retain all their rights.
+--
+-- This document and the information contained herein are provided on an
+-- "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
+-- OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET
+-- ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,
+-- INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE
+-- INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
+-- WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
+--
+-- Intellectual Property
+--
+-- The IETF takes no position regarding the validity or scope of any
+-- Intellectual Property Rights or other rights that might be claimed to
+-- pertain to the implementation or use of the technology described in
+-- this document or the extent to which any license under such rights
+-- might or might not be available; nor does it represent that it has
+-- made any independent effort to identify any such rights. Information
+-- on the procedures with respect to rights in RFC documents can be
+-- found in BCP 78 and BCP 79.
+--
+-- Copies of IPR disclosures made to the IETF Secretariat and any
+-- assurances of licenses to be made available, or the result of an
+-- attempt made to obtain a general license or permission for the use of
+-- such proprietary rights by implementers or users of this
+-- specification can be obtained from the IETF on-line IPR repository at
+-- http://www.ietf.org/ipr.
+--
+-- The IETF invites any interested party to bring to its attention any
+-- copyrights, patents or patent applications, or other proprietary
+-- rights that may cover technology that may be required to implement
+-- this standard. Please address the information to the IETF at ietf-
+-- ipr@ietf.org.
+--
+-- Acknowledgement
+--
+-- Funding for the RFC Editor function is currently provided by the
+-- Internet Society.
+--
+
+
+ WLANCertExtn
+ { iso(1) identified-organization(3) dod(6) internet(1)
+ security(5) mechanisms(5) pkix(7) id-mod(0)
+ id-mod-wlan-extns(24) }
+
+ DEFINITIONS IMPLICIT TAGS ::=
+ BEGIN
+
+ -- OID Arcs
+
+ id-pe OBJECT IDENTIFIER ::=
+ { iso(1) identified-organization(3) dod(6) internet(1)
+ security(5) mechanisms(5) pkix(7) 1 }
+
+ id-kp OBJECT IDENTIFIER ::=
+ { iso(1) identified-organization(3) dod(6) internet(1)
+ security(5) mechanisms(5) pkix(7) 3 }
+
+ id-aca OBJECT IDENTIFIER ::=
+ { iso(1) identified-organization(3) dod(6) internet(1)
+ security(5) mechanisms(5) pkix(7) 10 }
+
+ -- Extended Key Usage Values
+
+ id-kp-eapOverPPP OBJECT IDENTIFIER ::= { id-kp 13 }
+
+ id-kp-eapOverLAN OBJECT IDENTIFIER ::= { id-kp 14 }
+
+
+ -- Wireless LAN SSID Extension
+
+ id-pe-wlanSSID OBJECT IDENTIFIER ::= { id-pe 13 }
+
+ SSIDList ::= SEQUENCE SIZE (1..MAX) OF SSID
+
+ SSID ::= OCTET STRING (SIZE (1..32))
+
+ -- Wireless LAN SSID Attribute Certificate Attribute
+ -- Uses same syntax as the certificate extension: SSIDList
+
+ id-aca-wlanSSID OBJECT IDENTIFIER ::= { id-aca 6 }
+
+ END
diff --git a/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.c b/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.c
new file mode 100644
index 0000000000..9fbb68614c
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.c
@@ -0,0 +1,82 @@
+/* packet-wlancertextn.c
+ * Routines for Wireless Certificate Extension (RFC3770)
+ * Ronnie Sahlberg 2005
+ *
+ * Wireshark - Network traffic analyzer
+ * By Gerald Combs <gerald@wireshark.org>
+ * Copyright 1998 Gerald Combs
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#include "config.h"
+
+#include <epan/packet.h>
+#include <epan/oids.h>
+#include <epan/asn1.h>
+
+#include "packet-ber.h"
+#include "packet-wlancertextn.h"
+#include "packet-x509af.h"
+#include "packet-x509ce.h"
+#include "packet-x509sat.h"
+
+#define PNAME "Wlan Certificate Extension"
+#define PSNAME "WLANCERTEXTN"
+#define PFNAME "wlancertextn"
+
+void proto_register_wlancertextn(void);
+void proto_reg_handoff_wlancertextn(void);
+
+/* Initialize the protocol and registered fields */
+static int proto_wlancertextn = -1;
+#include "packet-wlancertextn-hf.c"
+
+/* Initialize the subtree pointers */
+#include "packet-wlancertextn-ett.c"
+
+#include "packet-wlancertextn-fn.c"
+
+
+/*--- proto_register_wlancertextn ----------------------------------------------*/
+void proto_register_wlancertextn(void) {
+
+ /* List of fields */
+ static hf_register_info hf[] = {
+#include "packet-wlancertextn-hfarr.c"
+ };
+
+ /* List of subtrees */
+ static gint *ett[] = {
+#include "packet-wlancertextn-ettarr.c"
+ };
+
+ /* Register protocol */
+ proto_wlancertextn = proto_register_protocol(PNAME, PSNAME, PFNAME);
+
+ /* Register fields and subtrees */
+ proto_register_field_array(proto_wlancertextn, hf, array_length(hf));
+ proto_register_subtree_array(ett, array_length(ett));
+
+}
+
+
+/*--- proto_reg_handoff_wlancertextn -------------------------------------------*/
+void proto_reg_handoff_wlancertextn(void) {
+#include "packet-wlancertextn-dis-tab.c"
+ oid_add_from_string("id-kp-eapOverPPP","1.3.6.1.5.5.7.3.13");
+ oid_add_from_string("id-kp-eapOverLAN","1.3.6.1.5.5.7.3.14");
+}
+
diff --git a/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.h b/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.h
new file mode 100644
index 0000000000..bc09a71e10
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/packet-wlancertextn-template.h
@@ -0,0 +1,30 @@
+/* packet-wlancertextn.h
+ * Routines for Wireless Certificate Extensions (RFC3770) packet dissection
+ * Ronnie Sahlberg 2005
+ *
+ * Wireshark - Network traffic analyzer
+ * By Gerald Combs <gerald@wireshark.org>
+ * Copyright 1998 Gerald Combs
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#ifndef PACKET_WLANCERTEXTN_H
+#define PACKET_WLANCERTEXTN_H
+
+/*#include "packet-wlancertextn-exp.h"*/
+
+#endif /* PACKET_WLANCERTEXTN_H */
+
diff --git a/epan/dissectors/asn1/wlancertextn/wlancertextn.cnf b/epan/dissectors/asn1/wlancertextn/wlancertextn.cnf
new file mode 100644
index 0000000000..2a86702974
--- /dev/null
+++ b/epan/dissectors/asn1/wlancertextn/wlancertextn.cnf
@@ -0,0 +1,21 @@
+# WlanCertExtn.cnf
+# WlanCertExtn conformation file
+
+#.MODULE_IMPORT
+
+#.EXPORTS
+
+#.REGISTER
+
+SSIDList B "1.3.6.1.5.5.7.1.13" "id-pe-wlanSSID"
+SSIDList B "1.3.6.1.5.5.7.10.6" "id-aca-wlanSSID"
+
+#.NO_EMIT
+
+#.TYPE_RENAME
+
+#.FIELD_RENAME
+
+#.END
+
+