Skip to content

Commit

Permalink
v1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jhunt committed Oct 1, 2017
1 parent 58b532a commit 44b10a2
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion tcptrace
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/perl
# tcptrace Copyright (c) 2016 James Hunt <james@niftylogic.com>
# tcptrace Copyright (c) 2017 James Hunt <james@niftylogic.com>

use strict;
use warnings;
Expand All @@ -18,6 +18,13 @@ my $P2 = "\e[1;38;5;226m";
my $F_OK = "\e[1;38;5;46m";
my $F_END = "\e[1;38;5;196m";

if ($ARGV[0] && $ARGV[0] eq '-v') {
print "tcptrace v1.0\n";
print "Copyright (c) 2017 James Hunt\n";
print "https://jameshunt.us/code/tcptrace\n";
exit 0;
}

my $fh;
{ no warnings; open $fh, "-|", "tcpdump -Xnv ".join(' ', map { "'$_'" } @ARGV)
or die "Failed to exec tcpdump: $!\n... is tcpdump installed, executable and in your \$PATH?\n"; }
Expand Down

0 comments on commit 44b10a2

Please sign in to comment.