Skip to content

Commit

Permalink
Merge pull request appneta#373 from appneta/Bug_#364_l7fuzzing_test_f…
Browse files Browse the repository at this point in the history
…ails

Bug appneta#364 appneta#371 appneta#372 Updates to fuzz
  • Loading branch information
fklassen authored May 2, 2017
2 parents af4f61e + a4c1889 commit 4b1ced6
Show file tree
Hide file tree
Showing 16 changed files with 272 additions and 216 deletions.
5 changes: 4 additions & 1 deletion docs/CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
05/01/2017 Version 4.2.5-beta1
05/02/2017 Version 4.2.5-beta1
- Fuzz should not be overwritting Layer 3 (#372)
- Add --fuzz-factor option to specify fuzz ratio (#371)
- Warnings when building on old distributions (#368)
- Fix more Lintian detected spelling errors (#365)
- Fuzz test failure on ARM and MIPS (#365)

04/26/2017 Version 4.2.4
- Fix Lintian detected spelling errors (#362)
Expand Down
2 changes: 2 additions & 0 deletions src/defines.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,8 @@ typedef struct tcpr_speed_s {
#define BPF_OPTIMIZE 1 /* default is to optimize bpf program */
#define PCAP_TIMEOUT 100 /* 100ms pcap_open_live timeout */

#define DEFAULT_FUZZ_FACTOR 8

/* HP-UX already defines TRUE/FALSE */
#ifndef TRUE
typedef enum bool_e {
Expand Down
2 changes: 1 addition & 1 deletion src/send_packets.c
Original file line number Diff line number Diff line change
Expand Up @@ -1195,7 +1195,7 @@ static bool calc_sleep_time(tcpreplay_t *ctx, struct timeval *pkt_time_delta,
*/
now_us = TIMSTAMP_TO_MICROSEC(sent_timestamp);
if (now_us) {
COUNTER pph = ctx->options->speed.speed * (ctx->options->speed.pps_multi > 0 ? ctx->options->speed.pps_multi : (60 * 60));;
COUNTER pph = ctx->options->speed.speed * (ctx->options->speed.pps_multi > 0 ? ctx->options->speed.pps_multi : (60 * 60));
COUNTER pkts_sent = ctx->stats.pkts_sent;
/*
* packets * 1000000 divided by pps = microseconds
Expand Down
2 changes: 1 addition & 1 deletion src/tcpedit/edit_packet.c
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ static void ipv6_addr_csum_replace(ipv6_hdr_t *ip6_hdr,
uint8_t *l4 = NULL, protocol;
assert(ip6_hdr);

protocol = get_ipv6_l4proto(ip6_hdr, 65536);;
protocol = get_ipv6_l4proto(ip6_hdr, 65536);
if (protocol == IPPROTO_TCP || protocol == IPPROTO_UDP ||
protocol == IPPROTO_ICMP || protocol == IPPROTO_ICMP6)
l4 = get_layer4_v6(ip6_hdr, 65536);
Expand Down
Loading

0 comments on commit 4b1ced6

Please sign in to comment.