summaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2018-04-16 14:10:39 +0200
committerAndy Polyakov <appro@openssl.org>2018-04-18 19:56:12 +0200
commit3f473b936a292262a020353e99f896cabfedc947 (patch)
tree07895e1bd645efebf4468ef5da48e5cd1a7fc691 /util
parentpoly1305/asm/poly1305-armv4.pl: remove unintentional relocation. (diff)
downloadopenssl-3f473b936a292262a020353e99f896cabfedc947.tar.xz
openssl-3f473b936a292262a020353e99f896cabfedc947.zip
TLSProxy/Message.pm: refine end-of-conversation detection logic.
Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5975)
Diffstat (limited to 'util')
-rw-r--r--util/perl/TLSProxy/Message.pm7
1 files changed, 5 insertions, 2 deletions
diff --git a/util/perl/TLSProxy/Message.pm b/util/perl/TLSProxy/Message.pm
index 68179d914d..4a60ba0157 100644
--- a/util/perl/TLSProxy/Message.pm
+++ b/util/perl/TLSProxy/Message.pm
@@ -267,14 +267,17 @@ sub get_messages
}
} elsif ($record->content_type == TLSProxy::Record::RT_ALERT) {
my ($alertlev, $alertdesc) = unpack('CC', $record->decrypt_data);
+ print " [$alertlev, $alertdesc]\n";
#A CloseNotify from the client indicates we have finished successfully
#(we assume)
if (!$end && !$server && $alertlev == AL_LEVEL_WARN
&& $alertdesc == AL_DESC_CLOSE_NOTIFY) {
$success = 1;
}
- #All alerts end the test
- $end = 1;
+ #Fatal or close notify alerts end the test
+ if ($alertlev == AL_LEVEL_FATAL || $alertdesc == AL_DESC_CLOSE_NOTIFY) {
+ $end = 1;
+ }
}
return @messages;