Skip to content

Commit 6aa7c74

Browse files
David MaloneyDavid Maloney
authored andcommitted
make anemone also rspect domain
1 parent 78b2a0a commit 6aa7c74

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

lib/anemone/rex_http.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,8 @@ def connection(url)
195195

196196
conn.set_config(
197197
'vhost' => virtual_host(url),
198-
'agent' => user_agent
198+
'agent' => user_agent,
199+
'domain' => @opts[:domain]
199200
)
200201

201202
conn

lib/msf/core/auxiliary/crawler.rb

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@ def initialize(info = {})
2424
OptInt.new('MAX_MINUTES', [ true, 'The maximum number of minutes to spend on each URL', 5]),
2525
OptInt.new('MAX_THREADS', [ true, 'The maximum number of concurrent requests', 4]),
2626
OptString.new('USERNAME', [false, 'The HTTP username to specify for authentication']),
27-
OptString.new('PASSWORD', [false, 'The HTTP password to specify for authentication'])
27+
OptString.new('PASSWORD', [false, 'The HTTP password to specify for authentication']),
28+
OptString.new('DOMAIN', [ true, 'The domain to use for windows authentication', 'WORKSTATION'])
29+
2830
], self.class
2931
)
3032

@@ -123,6 +125,7 @@ def run
123125
if datastore['USERNAME'] and datastore['USERNAME'] != ''
124126
t[:username] = datastore['USERNAME'].to_s
125127
t[:password] = datastore['PASSWORD'].to_s
128+
t[:domain] = datastore['DOMAIN'].to_s
126129
end
127130

128131
if datastore['HTTPCookie']
@@ -282,7 +285,8 @@ def crawler_options(t)
282285
end
283286

284287
opts[:username] = t[:username] || ''
285-
opts[:password] =t[:password] || ''
288+
opts[:password] = t[:password] || ''
289+
opts[:domain] = t[:domain] || 'WORKSTATION'
286290

287291
opts
288292
end

0 commit comments

Comments
 (0)