From: Russ Combs (rucombs) Date: Wed, 24 Nov 2021 16:26:05 +0000 (+0000) Subject: Pull request #3184: stream_tcp: delete unused unit test cruft X-Git-Tag: 3.1.18.0~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=db01197e7354b19e93635d7111ba943a3b5b03b5;p=thirdparty%2Fsnort3.git Pull request #3184: stream_tcp: delete unused unit test cruft Merge in SNORT/snort3 from ~RUCOMBS/snort3:dead_code_2 to master Squashed commit of the following: commit c62e9004b421bb8e9d9745441be754fa2a0df722 Author: russ Date: Wed Nov 24 08:22:15 2021 -0500 stream_tcp: delete unused unit test cruft --- diff --git a/src/stream/tcp/test/stream_tcp_test_utils.cc b/src/stream/tcp/test/stream_tcp_test_utils.cc index 3e2891a78..f6d8bdbd5 100644 --- a/src/stream/tcp/test/stream_tcp_test_utils.cc +++ b/src/stream/tcp/test/stream_tcp_test_utils.cc @@ -45,30 +45,6 @@ static const uint8_t cooked_syn[] = static const uint8_t cooked_syn_ack[] = "\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x08\x00\x45\x00\x00\x28\x00\x01\x00\x00\x40\x06\x88\x96\x48\xa7\xe8\x90\xc0\xa8\x00\x59\x00\x50\x23\x34\x00\x00\x23\x41\x00\x00\x23\x5b\x50\x12\x20\x00\x33\x79\x00\x00"; -// ACK PACKET -// IP 192.168.0.89.9012 > p3nlh044.shr.prod.phx3.secureserver.net.http: Flags [.], ack 1, win 8192, -// length 0 -static const uint8_t cooked_ack[] = - "\x00\x21\x91\x01\xb2\x48\xaa\x00\x04\x00\x0a\x04\x08\x00\x45\x00\x00\x28\x00\x01\x00\x00\x40\x06\x88\x96\xc0\xa8\x00\x59\x48\xa7\xe8\x90\x23\x34\x00\x50\x00\x00\x23\x5b\x00\x00\x23\x42\x50\x10\x20\x00\x33\x7a\x00\x00"; - -// FIXIT-M this is not a FIN PACKET yet... -// IP 192.168.0.89.9012 > p3nlh044.shr.prod.phx3.secureserver.net.http: Flags [.], ack 1, win 8192, -// length 0 -static const uint8_t cooked_fin[] = - "\x00\x21\x91\x01\xb2\x48\xaa\x00\x04\x00\x0a\x04\x08\x00\x45\x00\x00\x28\x00\x01\x00\x00\x40\x06\x88\x96\xc0\xa8\x00\x59\x48\xa7\xe8\x90\x23\x34\x00\x50\x00\x00\x23\x5b\x00\x00\x23\x42\x50\x10\x20\x00\x33\x7a\x00\x00"; - -// FIXIT-M this is not a RST PACKET yet... -// IP 192.168.0.89.9012 > p3nlh044.shr.prod.phx3.secureserver.net.http: Flags [.], ack 1, win 8192, -// length 0 -static const uint8_t cooked_rst[] = - "\x00\x21\x91\x01\xb2\x48\xaa\x00\x04\x00\x0a\x04\x08\x00\x45\x00\x00\x28\x00\x01\x00\x00\x40\x06\x88\x96\xc0\xa8\x00\x59\x48\xa7\xe8\x90\x23\x34\x00\x50\x00\x00\x23\x5b\x00\x00\x23\x42\x50\x10\x20\x00\x33\x7a\x00\x00"; - -// DATA PACKET -// IP 192.168.0.89.9012 > p3nlh044.shr.prod.phx3.secureserver.net.http: Flags [P.], seq 1:43, ack -// 1, win 8192, length 42 -static const uint8_t cooked_data[] = - "\x00\x21\x91\x01\xb2\x48\xaa\x00\x04\x00\x0a\x04\x08\x00\x45\x00\x00\x52\x00\x01\x00\x00\x40\x06\x88\x6c\xc0\xa8\x00\x59\x48\xa7\xe8\x90\x23\x34\x00\x50\x00\x00\x23\x5b\x00\x00\x23\x42\x50\x18\x20\x00\x14\x83\x00\x00\x47\x45\x54\x20\x2f\x20\x48\x54\x54\x50\x2f\x31\x2e\x31\x0d\x0a\x48\x6f\x73\x74\x3a\x20\x77\x77\x77\x2e\x6d\x61\x6c\x66\x6f\x72\x67\x65\x2e\x63\x6f\x6d\x0d\x0a\x0d\x0a"; - DAQ_PktHdr_t daqHdr; static DAQ_PktHdr_t* initDaqHdr( ) diff --git a/src/stream/tcp/test/stream_tcp_test_utils.h b/src/stream/tcp/test/stream_tcp_test_utils.h index cce4a3bbe..90528f925 100644 --- a/src/stream/tcp/test/stream_tcp_test_utils.h +++ b/src/stream/tcp/test/stream_tcp_test_utils.h @@ -30,10 +30,6 @@ struct Packet; snort::Packet* get_syn_packet(snort::Flow*); snort::Packet* get_syn_ack_packet(snort::Flow*); -snort::Packet* get_ack_packet(snort::Flow*); -snort::Packet* get_fin_packet(snort::Flow*); -snort::Packet* get_rst_packet(snort::Flow*); -snort::Packet* get_data_packet(snort::Flow*); void release_packet(snort::Packet*);