greenbone / openvas-smb

SMB module for OpenVAS Scanner
GNU General Public License v2.0
47 stars 47 forks source link

Change: Revert #83 #84

Closed jjnicola closed 11 months ago

jjnicola commented 11 months ago

What

Revert #83, which added connection options in a hardcoded way. Jira: SC-960

Why

With greenbone/openvas-scanner#1355 this options can be added when calling wmic or wmi via the library, and currently defaults to [sign]. This hardcoded options collide with the default or provided one.

For testing with wmic:

wmic -d 7 -U domain/user%pass //192.168.0.1[sign,seal] "SELECT name FROM Win32_ComputerSystem"

or using openvas-nasl

host = get_host_ip();
usrname = get_kb_item( "SMB/login" );
passwd  = get_kb_item( "SMB/password" );
opts = "[sign,seal]";

handle = wmi_connect( host:host, username:usrname, password:passwd, options:opts);

References

Jira: SC-960

Checklist