Skip to content

Commit b0d8b0a

Browse files
committed
Clean up incoming file handling
1 parent cfd06ab commit b0d8b0a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/auxiliary/scanner/misc/cisco_smart_install.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,13 +98,13 @@ def process_incoming(info)
9898
name = info[:file][:name]
9999
data = info[:file][:data]
100100
from = info[:from]
101-
return if not (name and data)
101+
return if not (name && data && from)
102102

103103
# Trim off IPv6 mapped IPv4 if necessary
104104
from = from[0].dup
105105
from.gsub!('::ffff:', '')
106106

107-
print_status("Incoming file from #{from} - #{name} #{data.length} bytes")
107+
print_status("Incoming file from #{from} - #{name} (#{data.length} bytes)")
108108
cisco_ios_config_eater(from, 4786, data)
109109
end
110110

0 commit comments

Comments
 (0)