Skip to content

Commit e306019

Browse files
committed
Fix formatting in ubiquiti_airos_file_upload
Also add :config and :use_agent options.
1 parent 5acc17a commit e306019

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

modules/exploits/linux/ssh/ubiquiti_airos_file_upload.rb

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def initialize(info = {})
4747
],
4848
'DefaultTarget' => 0,
4949
'DefaultOptions' => {
50-
'SSL' => true
50+
'SSL' => true
5151
}
5252
))
5353

@@ -119,12 +119,15 @@ def upload_authorized_keys
119119

120120
def ssh_login
121121
factory = ssh_socket_factory
122+
122123
ssh_opts = {
123-
port: datastore['SSH_PORT'],
124-
auth_methods: %w{publickey password},
125-
key_data: [private_key],
126-
proxy: factory,
127-
non_interactive: true
124+
port: datastore['SSH_PORT'],
125+
auth_methods: %w{publickey password},
126+
key_data: [private_key],
127+
non_interactive: true,
128+
config: false,
129+
use_agent: false,
130+
proxy: factory
128131
}
129132

130133
ssh_opts.merge!(verbose: :debug) if datastore['SSH_DEBUG']

0 commit comments

Comments
 (0)