land #11617 ssh library unifi cleanup
commit
759dbc86b1
|
@ -122,16 +122,16 @@ module Metasploit
|
|||
proof = ssh_socket.exec!("cli show version\n").split("\n")[2..4].join(", ").to_s
|
||||
elsif (proof =~ /Linux USG /)
|
||||
# Ubiquiti Unifi USG
|
||||
proof << ssh_socket.exec!("cat /etc/version\n").to_s
|
||||
proof << ssh_socket.exec!("cat /etc/version\n").to_s.rstrip
|
||||
end
|
||||
temp_proof << ssh_socket.exec!("grep unifi.version /tmp/system.cfg\n").to_s
|
||||
if (temp_proof =~ /unifi.version/)
|
||||
temp_proof = ssh_socket.exec!("grep unifi.version /tmp/system.cfg\n").to_s.rstrip
|
||||
if (temp_proof =~ /unifi\.version/)
|
||||
proof << temp_proof
|
||||
# Ubiquiti Unifi device (non-USG), possibly a switch. Tested on US-24
|
||||
# Ubiquiti Unifi device (non-USG), possibly a switch. Tested on US-24, UAP-nanoHD
|
||||
# The /tmp/*.cfg files don't give us device info, however the info command does
|
||||
# we dont call it originally since it doesnt say unifi/ubiquiti in it and info
|
||||
# is a linux command as well
|
||||
proof << ssh_socket.exec!("grep board.name /etc/board.info\n").to_s
|
||||
proof << ssh_socket.exec!("grep board.name /etc/board.info\n").to_s.rstrip
|
||||
end
|
||||
else
|
||||
# Cisco IOS
|
||||
|
|
Loading…
Reference in New Issue