diff options
-rw-r--r-- | epan/dissectors/packet-gssapi.c | 35 | ||||
-rw-r--r-- | epan/dissectors/packet-gssapi.h | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-kerberos.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-ntlmssp.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-spnego.c | 32 |
5 files changed, 33 insertions, 38 deletions
diff --git a/epan/dissectors/packet-gssapi.c b/epan/dissectors/packet-gssapi.c index 01c6f26b86..1e5f244ef4 100644 --- a/epan/dissectors/packet-gssapi.c +++ b/epan/dissectors/packet-gssapi.c @@ -38,8 +38,6 @@ #include <glib.h> #include <epan/packet.h> -#include <epan/asn1.h> /* for subid_t */ -#include "format-oid.h" #include <epan/dissectors/packet-dcerpc.h> #include <epan/dissectors/packet-gssapi.h> #include <epan/dissectors/packet-frame.h> @@ -98,37 +96,6 @@ gssapi_init_oid(char *oid, int proto, int ett, dissector_handle_t handle, } /* - * This takes an OID in binary form, not an OID as a text string, as - * an argument. - */ -gssapi_oid_value * -gssapi_lookup_oid(subid_t *oid, guint oid_len) -{ - gchar *oid_key; - gchar *p; - unsigned int i; - int len; - gssapi_oid_value *value; - - /* - * Convert the OID to a string, as text strings are used as - * keys in the OID hash table. - */ - oid_key = g_malloc(oid_len * 22 + 1); - p = oid_key; - len = sprintf(p, "%lu", (unsigned long)oid[0]); - p += len; - for (i = 1; i < oid_len;i++) { - len = sprintf(p, ".%lu", (unsigned long)oid[i]); - p += len; - } - - value = g_hash_table_lookup(gssapi_oids, oid_key); - g_free(oid_key); - return value; -} - -/* * This takes an OID in text string form as * an argument. */ @@ -385,7 +352,7 @@ proto_register_gssapi(void) }; proto_gssapi = proto_register_protocol( - "Generic Security Service Application Program Interface", + "GSS-API Generic Security Service Application Program Interface", "GSS-API", "gss-api"); proto_register_field_array(proto_gssapi, hf, array_length(hf)); diff --git a/epan/dissectors/packet-gssapi.h b/epan/dissectors/packet-gssapi.h index 8f8f619f5f..b745dd3135 100644 --- a/epan/dissectors/packet-gssapi.h +++ b/epan/dissectors/packet-gssapi.h @@ -43,8 +43,6 @@ gssapi_init_oid(char *oid, int proto, int ett, dissector_handle_t handle, dissector_handle_t wrap_handle, gchar *comment); gssapi_oid_value * -gssapi_lookup_oid(subid_t *oid, guint oid_len); -gssapi_oid_value * gssapi_lookup_oid_str(gchar *oid_key); int wrap_dissect_gssapi_verf(tvbuff_t *tvb, int offset, diff --git a/epan/dissectors/packet-kerberos.c b/epan/dissectors/packet-kerberos.c index 7bdd1daa03..7f9d0ff975 100644 --- a/epan/dissectors/packet-kerberos.c +++ b/epan/dissectors/packet-kerberos.c @@ -94,7 +94,6 @@ #include <epan/dissectors/packet-dcerpc-netlogon.h> #include <epan/dissectors/packet-dcerpc.h> -#include <epan/asn1.h> /* for "subid_t" */ #include <epan/dissectors/packet-gssapi.h> #define UDP_PORT_KERBEROS 88 diff --git a/epan/dissectors/packet-ntlmssp.c b/epan/dissectors/packet-ntlmssp.c index 0774db0ac3..2be8619196 100644 --- a/epan/dissectors/packet-ntlmssp.c +++ b/epan/dissectors/packet-ntlmssp.c @@ -36,7 +36,6 @@ #include "packet-windows-common.h" #include "packet-smb-common.h" -#include <epan/asn1.h> /* XXX - needed for subid_t */ #include "packet-frame.h" #include <epan/prefs.h> #include <epan/crypt-rc4.h> diff --git a/epan/dissectors/packet-spnego.c b/epan/dissectors/packet-spnego.c index 51baf7e09a..58211e1f39 100644 --- a/epan/dissectors/packet-spnego.c +++ b/epan/dissectors/packet-spnego.c @@ -146,6 +146,38 @@ static const true_false_string tfs_reqflags_integ = { "Per-message Integrity NOT Requested" }; +/* + * This takes an OID in binary form, not an OID as a text string, as + * an argument. + */ +static gssapi_oid_value * +gssapi_lookup_oid(subid_t *oid, guint oid_len) +{ + gchar *oid_key; + gchar *p; + unsigned int i; + int len; + gssapi_oid_value *value; + + /* + * Convert the OID to a string, as text strings are used as + * keys in the OID hash table. + */ + oid_key = g_malloc(oid_len * 22 + 1); + p = oid_key; + len = sprintf(p, "%lu", (unsigned long)oid[0]); + p += len; + for (i = 1; i < oid_len;i++) { + len = sprintf(p, ".%lu", (unsigned long)oid[i]); + p += len; + } + + value = gssapi_lookup_oid_str(oid_key); + g_free(oid_key); + return value; +} + + /* Display an ASN1 parse error. Taken from packet-snmp.c */ static dissector_handle_t data_handle; |