diff options
author | Bill Meier <wmeier@newsguy.com> | 2008-11-12 23:55:52 +0000 |
---|---|---|
committer | Bill Meier <wmeier@newsguy.com> | 2008-11-12 23:55:52 +0000 |
commit | 422bca98883c11c76da95e66a97311b2b4fc7e02 (patch) | |
tree | 793df6b06faf46e880c152a5f59abb15660d3acd /epan/dissectors/packet-ldap.c | |
parent | c3bef047d68c5dd352ebd39e67472aabff8b8863 (diff) |
Small changes related to proto_reg_handoff;
Use find_dissector;
Initialize saved tcp_port pref properly; This should
fix a possble bug wherein LDAP over SSL would not
be dissected properly. (I don't have a test capture
to verify this fix).
svn path=/trunk/; revision=26764
Diffstat (limited to 'epan/dissectors/packet-ldap.c')
-rw-r--r-- | epan/dissectors/packet-ldap.c | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/epan/dissectors/packet-ldap.c b/epan/dissectors/packet-ldap.c index 4b3a9f4249..ea96928656 100644 --- a/epan/dissectors/packet-ldap.c +++ b/epan/dissectors/packet-ldap.c @@ -393,12 +393,12 @@ static guint global_ldaps_tcp_port = TCP_PORT_LDAPS; static guint tcp_port = 0; static guint ssl_port = 0; -static dissector_handle_t gssapi_handle = NULL; -static dissector_handle_t gssapi_wrap_handle = NULL; -static dissector_handle_t ntlmssp_handle = NULL; -static dissector_handle_t spnego_handle = NULL; -static dissector_handle_t ssl_handle = NULL; -static dissector_handle_t ldap_handle = NULL; +static dissector_handle_t gssapi_handle; +static dissector_handle_t gssapi_wrap_handle; +static dissector_handle_t ntlmssp_handle; +static dissector_handle_t spnego_handle; +static dissector_handle_t ssl_handle; +static dissector_handle_t ldap_handle ; void prefs_register_ldap(void); /* forward declaration for use in preferences registration */ @@ -5226,13 +5226,10 @@ void proto_reg_handoff_ldap(void) { dissector_handle_t cldap_handle; - ldap_handle = create_dissector_handle(dissect_ldap_tcp, proto_ldap); + ldap_handle = find_dissector("ldap"); - dissector_add("tcp.port", global_ldap_tcp_port, ldap_handle); dissector_add("tcp.port", TCP_PORT_GLOBALCAT_LDAP, ldap_handle); - ssl_dissector_add(global_ldaps_tcp_port, "ldap", TRUE); - cldap_handle = create_dissector_handle(dissect_mscldap, proto_cldap); dissector_add("udp.port", UDP_PORT_CLDAP, cldap_handle); @@ -5244,6 +5241,8 @@ proto_reg_handoff_ldap(void) ssl_handle = find_dissector("ssl"); + prefs_register_ldap(); + /* http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dsml/dsml/ldap_controls_and_session_support.asp */ oid_add_from_string("LDAP_PAGED_RESULT_OID_STRING","1.2.840.113556.1.4.319"); oid_add_from_string("LDAP_SERVER_SHOW_DELETED_OID","1.2.840.113556.1.4.417"); @@ -5301,7 +5300,7 @@ proto_reg_handoff_ldap(void) /*--- End of included file: packet-ldap-dis-tab.c ---*/ -#line 2212 "packet-ldap-template.c" +#line 2211 "packet-ldap-template.c" } |