#
# This script was written by Mathieu Perrin <mathieu@tpfh.org>
# modded by John Jackson <jjackson@attrition.org> to pull hostname
#
# changes by rd : more verbose report on hostname
#
# changes by Tenable Network Security: new detection code
#
# See the Nessus Scripts License for details
#

if(description)
{
 script_id(10006);
 script_version ("$Revision: 7190 $");
 script_tag(name:"risk_factor", value:"None");
 name = "pcAnywhere";
 script_name(name);

 
 desc = "
pcAnywhere is running on this port.

Solution : Disable this service if you do not use it.
Risk factor : None";
 
 script_description(desc);
 
 summary = "Checks for the presence pcAnywhere";
 script_summary(summary);


 script_category(ACT_GATHER_INFO);

 script_copyright("This script is Copyright (C) 1999 Mathieu Perrin");

 family = "Windows";
 script_family(family);
 script_dependencie("find_service.nes");


exit(0);
}


#
# The script code starts here
#

port = 5632;
if (!get_port_state(port))
  exit (0);

soc = open_sock_udp(port);
if (!soc) exit(0);

send (socket:soc, data:"ST");
buf = recv(socket:soc, length:2);
if ("ST" >< buf)
  security_note (port);
