From Samuel Qu, Michael Lum, and Jeff Morriss: TCAP support, and
"asn_id_decode1()" variant of "asn_id_decode()". svn path=/trunk/; revision=8586
This commit is contained in:
parent
18496f5d55
commit
860376a9ab
5
AUTHORS
5
AUTHORS
|
@ -1787,6 +1787,7 @@ Oleg Terletsky <oleg.terletsky [AT] comverse.com> {
|
|||
|
||||
Michael Lum <mlum [AT] telostech.com> {
|
||||
Support for saving list of disabled protocols
|
||||
ANSI TCAP support
|
||||
}
|
||||
|
||||
Shiang-Ming Huang <smhuang [AT] pcs.csie.nctu.edu.tw> {
|
||||
|
@ -1859,6 +1860,10 @@ Lars Ruoff <lars.ruoff [AT] sxb.bsf.alcatel.fr> {
|
|||
Rewritten RTP analysis tap
|
||||
}
|
||||
|
||||
Samuel Qu <samuel.qu [AT] utstar.com> {
|
||||
ITU TCAP support
|
||||
}
|
||||
|
||||
And assorted fixes and enhancements by the people listed above and by:
|
||||
|
||||
Pavel Roskin <proski [AT] gnu.org>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Makefile.am
|
||||
# Automake file for Ethereal
|
||||
#
|
||||
# $Id: Makefile.am,v 1.632 2003/10/01 15:09:32 jmayer Exp $
|
||||
# $Id: Makefile.am,v 1.633 2003/10/02 06:13:27 guy Exp $
|
||||
#
|
||||
# Ethereal - Network traffic analyzer
|
||||
# By Gerald Combs <gerald@ethereal.com>
|
||||
|
@ -405,6 +405,7 @@ DISSECTOR_SRC = \
|
|||
packet-syslog.c \
|
||||
packet-t38.c \
|
||||
packet-tacacs.c \
|
||||
packet-tcap.c \
|
||||
packet-tcp.c \
|
||||
packet-tds.c \
|
||||
packet-telnet.c\
|
||||
|
@ -687,6 +688,7 @@ noinst_HEADERS = \
|
|||
packet-stat-notify.h \
|
||||
packet-stat.h \
|
||||
packet-tacacs.h \
|
||||
packet-tcap.h \
|
||||
packet-tcp.h \
|
||||
packet-tns.h \
|
||||
packet-tpkt.h \
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
## Makefile for building ethereal.exe with Microsoft C and nmake
|
||||
## Use: $(MAKE) /$(MAKEFLAGS) -f makefile.nmake
|
||||
#
|
||||
# $Id: Makefile.nmake,v 1.340 2003/09/26 22:20:06 guy Exp $
|
||||
# $Id: Makefile.nmake,v 1.341 2003/10/02 06:13:27 guy Exp $
|
||||
|
||||
include config.nmake
|
||||
include <win32.mak>
|
||||
|
@ -345,6 +345,7 @@ DISSECTOR_SRC = \
|
|||
packet-syslog.c \
|
||||
packet-t38.c \
|
||||
packet-tacacs.c \
|
||||
packet-tcap.c \
|
||||
packet-tcp.c \
|
||||
packet-tds.c \
|
||||
packet-telnet.c\
|
||||
|
|
64
asn1.c
64
asn1.c
|
@ -1,7 +1,7 @@
|
|||
/* asn1.c
|
||||
* Routines for ASN.1 BER dissection
|
||||
*
|
||||
* $Id: asn1.c,v 1.21 2003/08/29 19:13:28 guy Exp $
|
||||
* $Id: asn1.c,v 1.22 2003/10/02 06:13:27 guy Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@ethereal.com>
|
||||
|
@ -138,22 +138,21 @@ asn1_octet_decode(ASN1_SCK *asn1, guchar *ch)
|
|||
}
|
||||
|
||||
/*
|
||||
* NAME: asn1_tag_decode
|
||||
* SYNOPSIS: int asn1_tag_decode
|
||||
* NAME: asn1_tag_get
|
||||
* SYNOPSIS: int asn1_tag_get
|
||||
* (
|
||||
* ASN1_SCK *asn1,
|
||||
* guint *tag
|
||||
* )
|
||||
* DESCRIPTION: Decodes a tag.
|
||||
* DESCRIPTION: Decodes a tag number, combining it with existing tag bits.
|
||||
* RETURNS: ASN1_ERR value (ASN1_ERR_NOERROR on success)
|
||||
*/
|
||||
int
|
||||
asn1_tag_decode(ASN1_SCK *asn1, guint *tag)
|
||||
static int
|
||||
asn1_tag_get(ASN1_SCK *asn1, guint *tag)
|
||||
{
|
||||
int ret;
|
||||
guchar ch;
|
||||
|
||||
*tag = 0;
|
||||
do {
|
||||
ret = asn1_octet_decode (asn1, &ch);
|
||||
if (ret != ASN1_ERR_NOERROR)
|
||||
|
@ -164,6 +163,23 @@ asn1_tag_decode(ASN1_SCK *asn1, guint *tag)
|
|||
return ASN1_ERR_NOERROR;
|
||||
}
|
||||
|
||||
/*
|
||||
* NAME: asn1_tag_decode
|
||||
* SYNOPSIS: int asn1_tag_decode
|
||||
* (
|
||||
* ASN1_SCK *asn1,
|
||||
* guint *tag
|
||||
* )
|
||||
* DESCRIPTION: Decodes a tag number.
|
||||
* RETURNS: ASN1_ERR value (ASN1_ERR_NOERROR on success)
|
||||
*/
|
||||
int
|
||||
asn1_tag_decode(ASN1_SCK *asn1, guint *tag)
|
||||
{
|
||||
*tag = 0;
|
||||
return asn1_tag_get(asn1, tag);
|
||||
}
|
||||
|
||||
/*
|
||||
* NAME: asn1_id_decode
|
||||
* SYNOPSIS: int asn1_id_decode
|
||||
|
@ -182,6 +198,7 @@ asn1_id_decode(ASN1_SCK *asn1, guint *cls, guint *con, guint *tag)
|
|||
int ret;
|
||||
guchar ch;
|
||||
|
||||
*tag = 0;
|
||||
ret = asn1_octet_decode (asn1, &ch);
|
||||
if (ret != ASN1_ERR_NOERROR)
|
||||
return ret;
|
||||
|
@ -196,6 +213,39 @@ asn1_id_decode(ASN1_SCK *asn1, guint *cls, guint *con, guint *tag)
|
|||
return ASN1_ERR_NOERROR;
|
||||
}
|
||||
|
||||
/*
|
||||
* NAME: asn1_id_decode1
|
||||
* SYNOPSIS: int asn1_id_decode1
|
||||
* (
|
||||
* ASN1_SCK *asn1,
|
||||
* guint *tag
|
||||
* )
|
||||
* DESCRIPTION: Decodes an identifier.
|
||||
* Like asn1_id_decode() except that the Class and Constructor
|
||||
* bits are returned in the tag.
|
||||
* RETURNS: ASN1_ERR value (ASN1_ERR_NOERROR on success)
|
||||
*/
|
||||
int
|
||||
asn1_id_decode1(ASN1_SCK *asn1, guint *tag)
|
||||
{
|
||||
int ret;
|
||||
guchar ch;
|
||||
|
||||
*tag = 0;
|
||||
ret = asn1_octet_decode (asn1, &ch);
|
||||
if (ret != ASN1_ERR_NOERROR)
|
||||
return ret;
|
||||
|
||||
*tag = ch;
|
||||
if ((*tag & 0x1F) == 0x1F) { /* high-tag-number format */
|
||||
*tag = ch >> 5; /* leave just the Class and Constructor bits */
|
||||
ret = asn1_tag_get (asn1, tag);
|
||||
if (ret != ASN1_ERR_NOERROR)
|
||||
return ret;
|
||||
}
|
||||
return ASN1_ERR_NOERROR;
|
||||
}
|
||||
|
||||
/*
|
||||
* NAME: asn1_length_decode
|
||||
* SYNOPSIS: int asn1_length_decode
|
||||
|
|
3
asn1.h
3
asn1.h
|
@ -1,7 +1,7 @@
|
|||
/* asn1.h
|
||||
* Definitions for ASN.1 BER dissection
|
||||
*
|
||||
* $Id: asn1.h,v 1.13 2003/04/28 00:31:26 guy Exp $
|
||||
* $Id: asn1.h,v 1.14 2003/10/02 06:13:28 guy Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@ethereal.com>
|
||||
|
@ -116,6 +116,7 @@ extern void asn1_close (ASN1_SCK *asn1, int *offset);
|
|||
extern int asn1_octet_decode (ASN1_SCK *asn1, guchar *ch);
|
||||
extern int asn1_tag_decode (ASN1_SCK *asn1, guint *tag);
|
||||
extern int asn1_id_decode (ASN1_SCK *asn1, guint *cls, guint *con, guint *tag);
|
||||
extern int asn1_id_decode1 (ASN1_SCK *asn1, guint *tag);
|
||||
extern int asn1_length_decode (ASN1_SCK *asn1, gboolean *def, guint *len);
|
||||
extern int asn1_header_decode(ASN1_SCK *asn1, guint *cls, guint *con,
|
||||
guint *tag, gboolean *defp, guint *lenp);
|
||||
|
|
|
@ -2100,6 +2100,7 @@ B<http://www.ethereal.com>.
|
|||
Emanuele Caratti <wiz [AT] libero.it>
|
||||
Graeme Reid <graeme.reid [AT] norwoodsystems.com>
|
||||
Lars Ruoff <lars.ruoff [AT] sxb.bsf.alcatel.fr>
|
||||
Samuel Qu <samuel.qu [AT] utstar.com>
|
||||
Pavel Roskin <proski [AT] gnu.org>
|
||||
Georgi Guninski <guninski [AT] guninski.com>
|
||||
Jason Copenhaver <jcopenha [AT] typedef.org>
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,34 @@
|
|||
/* packet-tcap.h
|
||||
*
|
||||
* $Id: packet-tcap.h,v 1.1 2003/10/02 06:13:28 guy Exp $
|
||||
*
|
||||
* Copyright 2003, Michael Lum <mlum [AT] telostech.com>,
|
||||
* In association with Telos Technology Inc.
|
||||
*
|
||||
* Taken from packet-mtp3.h
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@ethereal.com>
|
||||
* 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
typedef enum {
|
||||
ITU_TCAP_STANDARD = 1,
|
||||
ANSI_TCAP_STANDARD = 2,
|
||||
} Tcap_Standard_Type;
|
||||
|
||||
extern Tcap_Standard_Type tcap_standard;
|
Loading…
Reference in New Issue