/usr/share/doc/cfingerd/examples/ping is in cfingerd 1.4.3-3.1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #! /usr/bin/perl
#
# Nice little script to do a ping to someone else's site...
# Version 1.0 by Martin Schulze (joey@infodrom.org)
# based on trace 1.0.1 by Ken Hollis (khollis@bitgate.com)
$ENV{'PATH'} = '/bin:/usr/bin';
$path = $ENV{'PATH'};
# Turn non-buffered input/output on
$| = 1;
# Get our site that we want a traceroute to be performed for
$pingsite = $ARGV[0];
$pingsite =~ tr/,/./;
# Set maximum packets to send
$max_packets = "-k 5";
# And check to make sure they entered a site
if ($pingsite) {
print "Performing a ping to $pingsite... \n\n";
system("ping $max_packets $pingsite");
print "\nDone.\n";
} else {
print <<"EOT";
Ping script 1.0
by Ken Hollis and Martin Schulze
Please finger \"site.whatever\" with your \".\" marks converted to \",\"
marks instead. This is because the finger daemon separates all options
by a \".\".
EOT
}
|