# HG changeset patch # User Sergey Kandaurov # Date 1522422503 -10800 # Node ID b6d941ff65f489666ebb374b481f03400eb5c81d # Parent cc2f17cd9677a9146abf7f0e3a03040b255c7859 Tests: added stream ssl preread test for message fragmentation. diff --git a/stream_ssl_preread.t b/stream_ssl_preread.t --- a/stream_ssl_preread.t +++ b/stream_ssl_preread.t @@ -122,7 +122,7 @@ eval { }; plan(skip_all => 'Net::SSLeay with OpenSSL SNI support required') if $@; -$t->plan(12); +$t->plan(13); $t->write_file('openssl.conf', <stop(); is($t->read_file('status.log'), "400\n", 'preread buffer full - log'); ############################################################################### +sub get_frag { + my $r = pack("N*", 0x16030100, 0x3b010000, 0x380303ac, + 0x8c8678a0, 0xaa1e7eed, 0x3644eed6, 0xc3bd2c69, + 0x7bc7deda, 0x249db0e3, 0x0c339eba, 0xa80b7600, + 0x00020000, 0x0100000d, 0x00000009, 0x00070000, + 0x04666f6f, 0x16030100); + $r .= pack("n", 0x0166); + + http($r); +} + sub get_short { my $r = pack("N*", 0x16030100, 0x38010000, 0x330303eb); $r .= pack("N*", 0x6357cdba, 0xa6b8d853, 0xf1f6ac0f);