summaryrefslogtreecommitdiff
path: root/epan/dissectors/packet-imap.c
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2015-02-06 11:43:54 +0100
committerPeter Wu <peter@lekensteyn.nl>2015-02-06 22:51:57 +0100
commite47000012eb7226feab476c64941e311896f8ff3 (patch)
tree9f4ff660c98f21182d8a02910ace8337d0411446 /epan/dissectors/packet-imap.c
parentbd8d509d5e3ff877034be4eb7cd3bda8bdad30f9 (diff)
downloadwireshark-e47000012eb7226feab476c64941e311896f8ff3.tar.gz
ldap: simplify Start TLS handling
RFC 2830 describes the Start TLS operation as follows: 1. ExtendedRequest is sent by client with the requestName OID set to "1.3.6.1.4.1.1466.20037". 2. Server responds with an ExtendedResponse having a resultCode and optionally a responseName (OID). The text mentions that the field *must* be set but the definition allows it to be optional. The previous code then made assumption that once (1) was seen, then any ExtendedResponse signals an acknowledgement. That is not entirely correct, a server could reject the request. This patch corrects that by checking the ExtendedResponse_resultCode for success, and then uses the new ssl_starttls_ack() helper to kick off SSL. This simplifies the code a bit. Tested against ldap-ssl.pcapng (which has no responseName) from http://wiki.wireshark.org/SampleCaptures#SSL_with_decryption_keys The result is the same as before, except that "Protocols in frame" changed from "...:ldap:ssl:ldap" to "...:ssl:ldap". Change-Id: Id7e40c5a50a217c4d3d46f08241d704f19d195dd
Diffstat (limited to 'epan/dissectors/packet-imap.c')
0 files changed, 0 insertions, 0 deletions