Безопасность в Internet- Intranet

       

Пример проверки, осуществляемой системой WebTrends Security Analyzer


<TestAuthor> WebTrends Corporation </TestAuthor>

<TestCopyright> Copyright 1998, WebTrends Corporation, All Rights Reserved. </TestCopyright>

<TestVersion> 2.0 </TestVersion>

====================================================================

<TestDependency>estabvc</TestDependency>

<TestCategory>inventory</TestCategory>

====================================================================

<TestTitle>Query OS Type via Netbios</TestTitle>

<TestVulnerabilityDescription>

This test attempts to determine the operating system type and version running on

the specified hosts.

</TestVulnerabilityDescription>

====================================================================



<Test>

# osdetectnt.pl

# attempt to detect OS using a netbios over tcp/ip call

require "crowbar.pl";

$theTargetNetbiosName = GetStringParam($crowbar::WTDB_NetbiosName);

crowbar::WTDebugOutput("OSDetect -- the target netbios name is $theTargetNetbiosName");

if($theTargetNetbiosName){

$a = crowbar::WTGetNTOSInfo($theTargetNetbiosName);

if($a){

$a =~ /^OSTYPE (.*):VERSION (.*)/;

$type = $1;

$version = $2;

crowbar::WTDebugOutput("Type is $type, version is $version\n");

if($version =~ m/OSVersion_Unknown/){

crowbar::WTAddRecord( $crowbar::WTDB_OSVersion, length("Unknown") + 1, "Unknown", -1);

}

elsif($version =~ m/OSVersion_WindowsNT_3_5_0/){

crowbar::WTAddRecord( $crowbar::WTDB_OSVersion, length("Version 3.5") + 1, "Version 3.5", -1);

}

elsif($version =~ m/OSVersion_WindowsNT_3_5_1/){

crowbar::WTAddRecord( $crowbar::WTDB_OSVersion, length("Version 3.51") + 1, "Version 3.51", -1);

}

elsif($version =~ m/OSVersion_WindowsNT_4_0/){

crowbar::WTAddRecord( $crowbar::WTDB_OSVersion, length("Version 4.0") + 1, "Version 4.0", -1);

}

elsif($version =~ m/OSVersion_WindowsNT_5_0/){


crowbar::WTAddRecord( $crowbar::WTDB_OSVersion, length("Version 5.0") + 1, "Version 5.0", -1);

}

if($type =~ m/OSType_Unknown/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Unknown") + 1, "Unknown", -1);

}

elsif($type =~ m/OSType_Unix/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Unix Server") + 1, "Unix Server", -1);

}

elsif($type =~ m/OSType_WindowsNTServer/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows NT Server") + 1, "Windows NT Server", -1);

}

elsif($type =~ m/OSType_WindowsNTPDC/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length(" Windows NT Primary Domain Controller") + 1, "Windows NT Primary Domain Controller", -1);

}

elsif($type =~ m/OSType_WindowsNTBDC/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows NT Backup Domain Controller") + 1, "Windows NT Backup Domain Controller", -1);

}

elsif($type =~ m/OSType_WindowsNTWorkstation/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows NT Workstation") + 1, "Windows NT Workstation", -1);

}

elsif($type =~ m/OSType_WindowsNT/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows NT") + 1, "Windows NT", -1);

}

elsif($type =~ m/OSType_Windows95/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows 95/98") + 1, "Windows 95/98", -1);

}

elsif($type =~ m/OSType_Windows98/){

crowbar::WTAddRecord( $crowbar::WTDB_OSType, length("Windows 98") + 1, "Windows 98", -1);

}

}

}

</Test>


Содержание раздела