[Netpass-devel] NetPass/www/components/Client ShowResults,1.7,1.8
Brought to you by:
jeffmurphy
From: jeff m. <jef...@us...> - 2005-08-16 14:04:48
|
Update of /cvsroot/netpass/NetPass/www/components/Client In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25260/www/components/Client Modified Files: ShowResults Log Message: bug fixes Index: ShowResults =================================================================== RCS file: /cvsroot/netpass/NetPass/www/components/Client/ShowResults,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- ShowResults 18 May 2005 15:23:43 -0000 1.7 +++ ShowResults 16 Aug 2005 14:04:33 -0000 1.8 @@ -111,15 +111,21 @@ # if no custom message is configured, we'll print the default that # is supplied by nessus or snort. - if($info =~ /^(nessus:|snort:)$/) { - $description =~ s/\\n/\n/g; - print $q->pre($description); + if($info =~ /^(nessus:|snort:)/) { + my $msg = $np->db->getPage(-name => $info, -nohtml => 1, -npcfg => $np->cfg, + -ip => $ip); + if (!defined($msg)) { + $description =~ s/\\n/\n/g; + print $q->pre($description); + } else { + print $msg; + } } elsif($info =~ /^msg:/) { print $np->db->getPage(-name => $info, -nohtml => 1, -npcfg => $np->cfg, -ip => $ip); } - print qq{</td></tr>}; + print qq{</ul></td></tr>}; } else { my $autoexpand = ($nres <= ($np->cfg->policy(-key => 'RESULTS_EXPAND', -network =>$ip)-1)); @@ -171,15 +177,21 @@ # if no custom message is configured, we'll print the default that # is supplied by nessus or snort. - if($info =~ /^(nessus:|snort:)$/) { - $description =~ s/\\n/\n/g; - print $q->pre($description); + if($info =~ /^(nessus:|snort:)/) { + my $msg = $np->db->getPage(-name => $info, -nohtml => 1, -npcfg => $np->cfg, + -ip => $ip); + if (!defined($msg)) { + $description =~ s/\\n/\n/g; + print $q->pre($description); + } else { + print $msg; + } } elsif($info =~ /^msg:/) { print $np->db->getPage(-name => $info, -nohtml => 1, -npcfg => $np->cfg, -ip => $ip); } - print qq{</td></tr>}; + print qq{</ul></td></tr>}; } } } else { |