#  This software was derived from SATAN 1.1.1 by Dan Farmer and Wietse Venema
#  (http://www.porcupine.org/satan).
#
#
#  This code update is provided by the Advanced Research Corporation (r) to
#  further the utility of the SARA Report Writer.  We request that the
#  developers do not modify or reverse engineer this code for
#  their own gain.
#
#  Developed and distributed by the Advanced Research Corporation.
#
# List all hosts in a subnet
#
($_subnet, $_sort_order) = split(/,/, $html_script_args);
print CLIENT <<EOF;
<HTML>
<HEAD>
<title> Host Table - Subnet $_subnet</title>
<LINK REV="made" HREF="mailto:satan\@fish.com">
<LINK REV="made" HREF="mailto:sara\@arc.com">
</HEAD>
<BODY>
<CENTER><H1>Reporting - Subnet $_subnet</h1></Center>
<hr>

<h3> 
$subnet_severities{$_subnet} Vulnerable/$subnet_count{$_subnet} total.
Vulnerability counts in parentheses.
</h3>
EOF
@_hosts = split(/\s/, $all_subnets{$_subnet});
do "$html_root/reporting/reportwriter/report_host_summary.pl";
print CLIENT <<EOF;
</TABLE></CENTER>
EOF
@_hosts = split(/\s/, $all_subnets{$_subnet});
do "$html_root/reporting/reportwriter/report_hosts.pl";
#print CLIENT $@ if $@;

print CLIENT <<EOF;
<hr> <a href=$HTML_SERVER> Back to the SARA start page </a> |
<a href=$HTML_SERVER/reporting/analysis.pl> Back to SARA Reporting and Analysis </a>
</UL></UL>
</BODY>
</HTML>
EOF
1;
