(!$ENV{HARNESS_ACTIVE} || $ENV{HARNESS_VERBOSE})
);
-plan tests => 3;
-
# Test 1: Sending a zero length extension block should pass
-$proxy->start();
+$proxy->start() or plan skip_all => "Unable to start up Proxy for tests";
+plan tests => 3;
ok(TLSProxy::Message->success, "Zero extension length test");
sub extension_filter
{
my $proxy = shift;
+ if ($proxy->flight == 1) {
+ # Change the ServerRandom so that the downgrade sentinel doesn't cause
+ # the connection to fail
+ my $message = ${$proxy->message_list}[1];
+ $message->random("\0"x32);
+ $message->repack();
+ return;
+ }
+
# We're only interested in the initial ClientHello
if ($proxy->flight != 0) {
return;
$proxy->filter(\&inject_duplicate_extension_serverhello);
$proxy->start();
ok(TLSProxy::Message->fail(), "Duplicate ServerHello extension");
-