Skip to content

Commit 9688845

Browse files
author
jvazquez-r7
committed
Add new signature for CF9
1 parent a6a46f8 commit 9688845

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

modules/auxiliary/scanner/http/cold_fusion_version.rb

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def fingerprint(response)
3535
if(response.headers['Server'] =~ /IIS/ or response.headers['Server'] =~ /\(Windows/)
3636
os = "Windows (#{response.headers['Server']})"
3737
elsif(response.headers['Server'] =~ /Apache\//)
38-
os = "Unix (#{response.headers['Server']})"
38+
os = "Unix (#{response.headers['Server']})"
3939
else
4040
os = response.headers['Server']
4141
end
@@ -48,10 +48,10 @@ def fingerprint(response)
4848
title = $1
4949
title.gsub!(/\s/, '')
5050
end
51-
return nil if( title == 'Not Found' or not title =~ /ColdFusionAdministrator/)
5251

53-
out = nil
52+
return nil if( title == 'Not Found' or not title =~ /ColdFusionAdministrator/)
5453

54+
out = nil
5555

5656
if(response.body =~ />\s*Version:\s*(.*)<\/strong\><br\s\//)
5757
v = $1
@@ -64,7 +64,8 @@ def fingerprint(response)
6464
response.body =~ /1997\-2012 Adobe Systems Incorporated and its licensors/)
6565
out = "Adobe ColdFusion 10"
6666
elsif(response.body =~ /<meta name=\"Author\" content=\"Copyright \(c\) 1995\-2010 Adobe/ or
67-
response.body =~ /<meta name=\"Author\" content=\"Copyright \(c\) 1995\-2009 Adobe Systems\, Inc\. All rights reserved/)
67+
response.body =~ /<meta name=\"Author\" content=\"Copyright \(c\) 1995\-2009 Adobe Systems\, Inc\. All rights reserved/ or
68+
response.body =~ /<meta name=\"Author\" content=\"Copyright \(c\) 1997\-2012 Adobe Systems\, Inc\. All rights reserved/)
6869
out = "Adobe ColdFusion 9"
6970
elsif(response.body =~ /<meta name=\"Keywords\" content=\"(.*)\">\s+<meta name/)
7071
out = $1.split(/,/)[0]
@@ -85,8 +86,8 @@ def run_host(ip)
8586
url = '/CFIDE/administrator/index.cfm'
8687

8788
res = send_request_cgi({
88-
'uri' => url,
89-
'method' => 'GET',
89+
'uri' => url,
90+
'method' => 'GET',
9091
})
9192

9293
return if not res or not res.body or not res.code

0 commit comments

Comments
 (0)