Skip to content

Commit ce7d4cf

Browse files
Removed "shell" from SessionTypes
Remove the need to check for the session type manually. It will be automatically validated at the time of module run.
1 parent f37e736 commit ce7d4cf

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

modules/post/windows/gather/credentials/mdaemon_cred_collector.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def initialize(info = {})
2424
'Author' => ['Manuel Nader #AgoraSecurity'],
2525
'Platform' => ['win'],
2626
'Arch' => ['x64','x86'],
27-
'SessionTypes' => ['meterpreter', 'shell']
27+
'SessionTypes' => ['meterpreter']
2828
))
2929

3030
register_options(
@@ -33,10 +33,6 @@ def initialize(info = {})
3333
end
3434

3535
def run
36-
if session.type != 'meterpreter'
37-
print_error ('Only meterpreter sessions are supported by this post module')
38-
return
39-
end
4036
progfiles_env = session.sys.config.getenvs('SYSTEMDRIVE', 'HOMEDRIVE', 'ProgramFiles', 'ProgramFiles(x86)', 'ProgramW6432')
4137
locations = []
4238
progfiles_env.each do |_k, v|

0 commit comments

Comments
 (0)