arachni 0.2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/ACKNOWLEDGMENTS.md +14 -0
- data/AUTHORS.md +6 -0
- data/CHANGELOG.md +162 -0
- data/CONTRIBUTORS.md +10 -0
- data/EXPLOITATION.md +429 -0
- data/HACKING.md +101 -0
- data/LICENSE.md +341 -0
- data/README.md +350 -0
- data/Rakefile +86 -0
- data/bin/arachni +22 -0
- data/bin/arachni_web +77 -0
- data/bin/arachni_xmlrpc +21 -0
- data/bin/arachni_xmlrpcd +82 -0
- data/bin/arachni_xmlrpcd_monitor +74 -0
- data/conf/README.webui.yaml.txt +44 -0
- data/conf/webui.yaml +11 -0
- data/external/metasploit/LICENSE +24 -0
- data/external/metasploit/modules/exploits/unix/webapp/arachni_exec.rb +142 -0
- data/external/metasploit/modules/exploits/unix/webapp/arachni_path_traversal.rb +113 -0
- data/external/metasploit/modules/exploits/unix/webapp/arachni_php_eval.rb +150 -0
- data/external/metasploit/modules/exploits/unix/webapp/arachni_php_include.rb +141 -0
- data/external/metasploit/modules/exploits/unix/webapp/arachni_sqlmap.rb +92 -0
- data/external/metasploit/plugins/arachni.rb +536 -0
- data/getoptslong.rb +241 -0
- data/lib/anemone.rb +2 -0
- data/lib/anemone/cookie_store.rb +35 -0
- data/lib/anemone/core.rb +371 -0
- data/lib/anemone/exceptions.rb +5 -0
- data/lib/anemone/http.rb +144 -0
- data/lib/anemone/page.rb +337 -0
- data/lib/anemone/page_store.rb +160 -0
- data/lib/anemone/storage.rb +34 -0
- data/lib/anemone/storage/base.rb +75 -0
- data/lib/anemone/storage/exceptions.rb +15 -0
- data/lib/anemone/storage/mongodb.rb +89 -0
- data/lib/anemone/storage/pstore.rb +50 -0
- data/lib/anemone/storage/redis.rb +90 -0
- data/lib/anemone/storage/tokyo_cabinet.rb +57 -0
- data/lib/anemone/tentacle.rb +40 -0
- data/lib/arachni.rb +16 -0
- data/lib/audit_store.rb +346 -0
- data/lib/component_manager.rb +293 -0
- data/lib/component_options.rb +395 -0
- data/lib/exceptions.rb +76 -0
- data/lib/framework.rb +637 -0
- data/lib/http.rb +809 -0
- data/lib/issue.rb +302 -0
- data/lib/module.rb +4 -0
- data/lib/module/auditor.rb +455 -0
- data/lib/module/base.rb +188 -0
- data/lib/module/element_db.rb +158 -0
- data/lib/module/key_filler.rb +87 -0
- data/lib/module/manager.rb +87 -0
- data/lib/module/output.rb +68 -0
- data/lib/module/trainer.rb +240 -0
- data/lib/module/utilities.rb +110 -0
- data/lib/options.rb +547 -0
- data/lib/parser.rb +2 -0
- data/lib/parser/auditable.rb +522 -0
- data/lib/parser/elements.rb +296 -0
- data/lib/parser/page.rb +149 -0
- data/lib/parser/parser.rb +717 -0
- data/lib/plugin.rb +4 -0
- data/lib/plugin/base.rb +110 -0
- data/lib/plugin/manager.rb +162 -0
- data/lib/report.rb +4 -0
- data/lib/report/base.rb +119 -0
- data/lib/report/manager.rb +92 -0
- data/lib/rpc/xml/client/base.rb +71 -0
- data/lib/rpc/xml/client/dispatcher.rb +49 -0
- data/lib/rpc/xml/client/instance.rb +88 -0
- data/lib/rpc/xml/server/base.rb +90 -0
- data/lib/rpc/xml/server/dispatcher.rb +357 -0
- data/lib/rpc/xml/server/framework.rb +206 -0
- data/lib/rpc/xml/server/instance.rb +191 -0
- data/lib/rpc/xml/server/module/manager.rb +46 -0
- data/lib/rpc/xml/server/options.rb +124 -0
- data/lib/rpc/xml/server/output.rb +299 -0
- data/lib/rpc/xml/server/plugin/manager.rb +58 -0
- data/lib/ruby.rb +5 -0
- data/lib/ruby/object.rb +32 -0
- data/lib/ruby/string.rb +74 -0
- data/lib/ruby/xmlrpc/server.rb +27 -0
- data/lib/spider.rb +200 -0
- data/lib/typhoeus/request.rb +91 -0
- data/lib/typhoeus/response.rb +34 -0
- data/lib/ui/cli/cli.rb +744 -0
- data/lib/ui/cli/output.rb +279 -0
- data/lib/ui/web/log.rb +82 -0
- data/lib/ui/web/output_stream.rb +94 -0
- data/lib/ui/web/report_manager.rb +222 -0
- data/lib/ui/web/server.rb +903 -0
- data/lib/ui/web/server/db/placeholder +0 -0
- data/lib/ui/web/server/public/banner.png +0 -0
- data/lib/ui/web/server/public/bodybg-small.png +0 -0
- data/lib/ui/web/server/public/bodybg.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/pbar-ani.gif +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-icons_222222_256x240.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-icons_2e83ff_256x240.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-icons_454545_256x240.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-icons_888888_256x240.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/lib/ui/web/server/public/css/smoothness/jquery-ui-1.8.9.custom.css +573 -0
- data/lib/ui/web/server/public/favicon.ico +0 -0
- data/lib/ui/web/server/public/footer.jpg +0 -0
- data/lib/ui/web/server/public/icons/error.png +0 -0
- data/lib/ui/web/server/public/icons/info.png +0 -0
- data/lib/ui/web/server/public/icons/ok.png +0 -0
- data/lib/ui/web/server/public/icons/status.png +0 -0
- data/lib/ui/web/server/public/js/jquery-1.4.4.min.js +167 -0
- data/lib/ui/web/server/public/js/jquery-ui-1.8.9.custom.min.js +781 -0
- data/lib/ui/web/server/public/logo.png +0 -0
- data/lib/ui/web/server/public/nav-left.jpg +0 -0
- data/lib/ui/web/server/public/nav-right.jpg +0 -0
- data/lib/ui/web/server/public/nav-selected-left.jpg +0 -0
- data/lib/ui/web/server/public/nav-selected-right.jpg +0 -0
- data/lib/ui/web/server/public/reports/placeholder +1 -0
- data/lib/ui/web/server/public/sidebar-bottom.jpg +0 -0
- data/lib/ui/web/server/public/sidebar-h4.jpg +0 -0
- data/lib/ui/web/server/public/sidebar-top.jpg +0 -0
- data/lib/ui/web/server/public/spider.png +0 -0
- data/lib/ui/web/server/public/style.css +604 -0
- data/lib/ui/web/server/tmp/placeholder +0 -0
- data/lib/ui/web/server/views/dispatcher.erb +85 -0
- data/lib/ui/web/server/views/dispatcher_error.erb +14 -0
- data/lib/ui/web/server/views/error.erb +1 -0
- data/lib/ui/web/server/views/flash.erb +18 -0
- data/lib/ui/web/server/views/home.erb +14 -0
- data/lib/ui/web/server/views/instance.erb +213 -0
- data/lib/ui/web/server/views/layout.erb +95 -0
- data/lib/ui/web/server/views/log.erb +40 -0
- data/lib/ui/web/server/views/modules.erb +71 -0
- data/lib/ui/web/server/views/options.erb +23 -0
- data/lib/ui/web/server/views/output_results.erb +51 -0
- data/lib/ui/web/server/views/plugins.erb +42 -0
- data/lib/ui/web/server/views/report_formats.erb +30 -0
- data/lib/ui/web/server/views/reports.erb +55 -0
- data/lib/ui/web/server/views/settings.erb +120 -0
- data/lib/ui/web/server/views/welcome.erb +38 -0
- data/lib/ui/xmlrpc/dispatcher_monitor.rb +204 -0
- data/lib/ui/xmlrpc/xmlrpc.rb +843 -0
- data/logs/placeholder +0 -0
- data/metamodules/autothrottle.rb +74 -0
- data/metamodules/timeout_notice.rb +118 -0
- data/metamodules/uniformity.rb +98 -0
- data/modules/audit/code_injection.rb +136 -0
- data/modules/audit/code_injection_timing.rb +115 -0
- data/modules/audit/code_injection_timing/payloads.txt +4 -0
- data/modules/audit/csrf.rb +301 -0
- data/modules/audit/ldapi.rb +103 -0
- data/modules/audit/ldapi/errors.txt +26 -0
- data/modules/audit/os_cmd_injection.rb +103 -0
- data/modules/audit/os_cmd_injection/payloads.txt +2 -0
- data/modules/audit/os_cmd_injection_timing.rb +104 -0
- data/modules/audit/os_cmd_injection_timing/payloads.txt +3 -0
- data/modules/audit/path_traversal.rb +141 -0
- data/modules/audit/response_splitting.rb +105 -0
- data/modules/audit/rfi.rb +193 -0
- data/modules/audit/sqli.rb +120 -0
- data/modules/audit/sqli/regexp_ids.txt +90 -0
- data/modules/audit/sqli_blind_rdiff.rb +321 -0
- data/modules/audit/sqli_blind_timing.rb +103 -0
- data/modules/audit/sqli_blind_timing/payloads.txt +51 -0
- data/modules/audit/trainer.rb +89 -0
- data/modules/audit/unvalidated_redirect.rb +90 -0
- data/modules/audit/xpath.rb +104 -0
- data/modules/audit/xpath/errors.txt +26 -0
- data/modules/audit/xss.rb +99 -0
- data/modules/audit/xss_event.rb +134 -0
- data/modules/audit/xss_path.rb +125 -0
- data/modules/audit/xss_script_tag.rb +112 -0
- data/modules/audit/xss_tag.rb +112 -0
- data/modules/audit/xss_uri.rb +125 -0
- data/modules/recon/allowed_methods.rb +104 -0
- data/modules/recon/backdoors.rb +131 -0
- data/modules/recon/backdoors/filenames.txt +16 -0
- data/modules/recon/backup_files.rb +177 -0
- data/modules/recon/backup_files/extensions.txt +28 -0
- data/modules/recon/common_directories.rb +138 -0
- data/modules/recon/common_directories/directories.txt +265 -0
- data/modules/recon/common_files.rb +138 -0
- data/modules/recon/common_files/filenames.txt +17 -0
- data/modules/recon/directory_listing.rb +171 -0
- data/modules/recon/grep/captcha.rb +62 -0
- data/modules/recon/grep/credit_card.rb +85 -0
- data/modules/recon/grep/cvs_svn_users.rb +73 -0
- data/modules/recon/grep/emails.rb +59 -0
- data/modules/recon/grep/html_objects.rb +53 -0
- data/modules/recon/grep/private_ip.rb +54 -0
- data/modules/recon/grep/ssn.rb +53 -0
- data/modules/recon/htaccess_limit.rb +82 -0
- data/modules/recon/http_put.rb +95 -0
- data/modules/recon/interesting_responses.rb +118 -0
- data/modules/recon/unencrypted_password_forms.rb +119 -0
- data/modules/recon/webdav.rb +126 -0
- data/modules/recon/xst.rb +107 -0
- data/path_extractors/anchors.rb +35 -0
- data/path_extractors/forms.rb +35 -0
- data/path_extractors/frames.rb +38 -0
- data/path_extractors/generic.rb +39 -0
- data/path_extractors/links.rb +35 -0
- data/path_extractors/meta_refresh.rb +39 -0
- data/path_extractors/scripts.rb +37 -0
- data/path_extractors/sitemap.rb +31 -0
- data/plugins/autologin.rb +137 -0
- data/plugins/content_types.rb +90 -0
- data/plugins/cookie_collector.rb +99 -0
- data/plugins/form_dicattack.rb +185 -0
- data/plugins/healthmap.rb +94 -0
- data/plugins/http_dicattack.rb +133 -0
- data/plugins/metamodules.rb +118 -0
- data/plugins/proxy.rb +248 -0
- data/plugins/proxy/server.rb +66 -0
- data/plugins/waf_detector.rb +184 -0
- data/profiles/comprehensive.afp +74 -0
- data/profiles/full.afp +75 -0
- data/reports/afr.rb +59 -0
- data/reports/ap.rb +55 -0
- data/reports/html.rb +179 -0
- data/reports/html/default.erb +967 -0
- data/reports/metareport.rb +139 -0
- data/reports/metareport/arachni_metareport.rb +174 -0
- data/reports/plugin_formatters/html/content_types.rb +82 -0
- data/reports/plugin_formatters/html/cookie_collector.rb +66 -0
- data/reports/plugin_formatters/html/form_dicattack.rb +54 -0
- data/reports/plugin_formatters/html/healthmap.rb +76 -0
- data/reports/plugin_formatters/html/http_dicattack.rb +54 -0
- data/reports/plugin_formatters/html/metaformatters/timeout_notice.rb +65 -0
- data/reports/plugin_formatters/html/metaformatters/uniformity.rb +71 -0
- data/reports/plugin_formatters/html/metamodules.rb +93 -0
- data/reports/plugin_formatters/html/waf_detector.rb +54 -0
- data/reports/plugin_formatters/stdout/content_types.rb +73 -0
- data/reports/plugin_formatters/stdout/cookie_collector.rb +61 -0
- data/reports/plugin_formatters/stdout/form_dicattack.rb +52 -0
- data/reports/plugin_formatters/stdout/healthmap.rb +72 -0
- data/reports/plugin_formatters/stdout/http_dicattack.rb +53 -0
- data/reports/plugin_formatters/stdout/metaformatters/timeout_notice.rb +55 -0
- data/reports/plugin_formatters/stdout/metaformatters/uniformity.rb +68 -0
- data/reports/plugin_formatters/stdout/metamodules.rb +89 -0
- data/reports/plugin_formatters/stdout/waf_detector.rb +48 -0
- data/reports/plugin_formatters/xml/content_types.rb +91 -0
- data/reports/plugin_formatters/xml/cookie_collector.rb +70 -0
- data/reports/plugin_formatters/xml/form_dicattack.rb +57 -0
- data/reports/plugin_formatters/xml/healthmap.rb +82 -0
- data/reports/plugin_formatters/xml/http_dicattack.rb +57 -0
- data/reports/plugin_formatters/xml/metaformatters/timeout_notice.rb +67 -0
- data/reports/plugin_formatters/xml/metaformatters/uniformity.rb +82 -0
- data/reports/plugin_formatters/xml/metamodules.rb +91 -0
- data/reports/plugin_formatters/xml/waf_detector.rb +58 -0
- data/reports/stdout.rb +182 -0
- data/reports/txt.rb +77 -0
- data/reports/xml.rb +231 -0
- data/reports/xml/buffer.rb +98 -0
- metadata +516 -0
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
module Modules
|
|
13
|
+
|
|
14
|
+
#
|
|
15
|
+
# CVS/SVN users recon module.
|
|
16
|
+
#
|
|
17
|
+
# Scans every page for CVS/SVN users.
|
|
18
|
+
#
|
|
19
|
+
# @author: morpheuslaw <msidagni@nopsec.com>
|
|
20
|
+
# @version: 0.1
|
|
21
|
+
#
|
|
22
|
+
class CvsSvnUsers < Arachni::Module::Base
|
|
23
|
+
|
|
24
|
+
def initialize( page )
|
|
25
|
+
@page = page
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
def run
|
|
29
|
+
regexps = [
|
|
30
|
+
/\$Author: (.*) \$/,
|
|
31
|
+
/\$Locker: (.*) \$/,
|
|
32
|
+
/\$Header: .* (.*) (Exp )?\$/,
|
|
33
|
+
/\$Id: .* (.*) (Exp )?\$/
|
|
34
|
+
]
|
|
35
|
+
|
|
36
|
+
matches = regexps.map {
|
|
37
|
+
|regexp|
|
|
38
|
+
@page.html.scan( regexp )
|
|
39
|
+
}.flatten.reject{ |match| !match || match =~ /Exp/ }.map{ |match| match.strip }.uniq
|
|
40
|
+
|
|
41
|
+
matches.each {
|
|
42
|
+
|match|
|
|
43
|
+
log(
|
|
44
|
+
:regexp => regexps.to_s,
|
|
45
|
+
:match => match,
|
|
46
|
+
:element => Issue::Element::BODY
|
|
47
|
+
)
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
def self.info
|
|
53
|
+
{
|
|
54
|
+
:name => 'CVS/SVN users',
|
|
55
|
+
:description => %q{Scans every page for CVS/SVN users.},
|
|
56
|
+
:author => 'morpheuslaw <msidagni@nopsec.com>',
|
|
57
|
+
:version => '0.1',
|
|
58
|
+
:targets => { 'Generic' => 'all' },
|
|
59
|
+
:issue => {
|
|
60
|
+
:name => %q{CVS/SVN user disclosure.},
|
|
61
|
+
:description => %q{A CVS or SVN user is disclosed in the body of the HTML page.},
|
|
62
|
+
:cwe => '200',
|
|
63
|
+
:severity => Issue::Severity::LOW,
|
|
64
|
+
:cvssv2 => '0',
|
|
65
|
+
:remedy_guidance => %q{Remove all CVS and SVN users from the body of the HTML page.},
|
|
66
|
+
:remedy_code => '',
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
end
|
|
72
|
+
end
|
|
73
|
+
end
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
module Modules
|
|
13
|
+
|
|
14
|
+
#
|
|
15
|
+
#
|
|
16
|
+
# @author: Tasos "Zapotek" Laskos
|
|
17
|
+
# <tasos.laskos@gmail.com>
|
|
18
|
+
# <zapotek@segfault.gr>
|
|
19
|
+
# @version: 0.1
|
|
20
|
+
#
|
|
21
|
+
class EMails < Arachni::Module::Base
|
|
22
|
+
|
|
23
|
+
def initialize( page )
|
|
24
|
+
@page = page
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def run( )
|
|
28
|
+
@@_logged ||= Set.new
|
|
29
|
+
|
|
30
|
+
regexp = /[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}/i
|
|
31
|
+
match_and_log( regexp ){
|
|
32
|
+
|email|
|
|
33
|
+
return false if @@_logged.include?( email )
|
|
34
|
+
@@_logged << email
|
|
35
|
+
}
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
def self.info
|
|
39
|
+
{
|
|
40
|
+
:name => 'E-mail address',
|
|
41
|
+
:description => %q{Greps pages for disclosed e-mail addresses.},
|
|
42
|
+
:author => 'Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>',
|
|
43
|
+
:version => '0.1',
|
|
44
|
+
:targets => { 'Generic' => 'all' },
|
|
45
|
+
:issue => {
|
|
46
|
+
:name => %q{Disclosed e-mail address.},
|
|
47
|
+
:description => %q{An e-mail address is being disclosed.},
|
|
48
|
+
:cwe => '200',
|
|
49
|
+
:severity => Issue::Severity::INFORMATIONAL,
|
|
50
|
+
:cvssv2 => '0',
|
|
51
|
+
:remedy_guidance => %q{},
|
|
52
|
+
:remedy_code => '',
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
end
|
|
58
|
+
end
|
|
59
|
+
end
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
module Modules
|
|
13
|
+
|
|
14
|
+
#
|
|
15
|
+
#
|
|
16
|
+
# @author: Tasos "Zapotek" Laskos
|
|
17
|
+
# <tasos.laskos@gmail.com>
|
|
18
|
+
# <zapotek@segfault.gr>
|
|
19
|
+
# @version: 0.1
|
|
20
|
+
#
|
|
21
|
+
class HTMLObjects < Arachni::Module::Base
|
|
22
|
+
|
|
23
|
+
def initialize( page )
|
|
24
|
+
@page = page
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def run( )
|
|
28
|
+
regexp = /\<object(.*)\>(.*)\<\/object\>/im
|
|
29
|
+
match_and_log( regexp )
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
def self.info
|
|
33
|
+
{
|
|
34
|
+
:name => 'HTML objects',
|
|
35
|
+
:description => %q{Greps pages for HTML objects.},
|
|
36
|
+
:author => 'Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>',
|
|
37
|
+
:version => '0.1',
|
|
38
|
+
:targets => { 'Generic' => 'all' },
|
|
39
|
+
:issue => {
|
|
40
|
+
:name => %q{Found an HTML object.},
|
|
41
|
+
:description => %q{},
|
|
42
|
+
:cwe => '200',
|
|
43
|
+
:severity => Issue::Severity::INFORMATIONAL,
|
|
44
|
+
:cvssv2 => '0',
|
|
45
|
+
:remedy_guidance => %q{},
|
|
46
|
+
:remedy_code => '',
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
end
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
module Modules
|
|
13
|
+
|
|
14
|
+
#
|
|
15
|
+
# Private IP address recon module.
|
|
16
|
+
#
|
|
17
|
+
# Scans every page for prvate IP addresses.
|
|
18
|
+
#
|
|
19
|
+
# @author: morpheuslaw <msidagni@nopsec.com>
|
|
20
|
+
# @version: 0.1
|
|
21
|
+
#
|
|
22
|
+
class PrivateIP < Arachni::Module::Base
|
|
23
|
+
|
|
24
|
+
def initialize( page )
|
|
25
|
+
@page = page
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
def run( )
|
|
29
|
+
regexp = /(?<!\.)(?<!\d)(?:(?:10|127)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)|192\.168|169\.254|172\.0?(?:1[6-9]|2[0-9]|3[01]))(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){2}(?!\d)(?!\.)/
|
|
30
|
+
match_and_log( regexp )
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def self.info
|
|
34
|
+
{
|
|
35
|
+
:name => 'Private IP address finder',
|
|
36
|
+
:description => %q{Scans pages for private IP addresses.},
|
|
37
|
+
:author => 'morpheuslaw <msidagni@nopsec.com>',
|
|
38
|
+
:version => '0.1',
|
|
39
|
+
:targets => { 'Generic' => 'all' },
|
|
40
|
+
:issue => {
|
|
41
|
+
:name => %q{Private IP address disclosure.},
|
|
42
|
+
:description => %q{A private IP address is disclosured in the body of the HTML page},
|
|
43
|
+
:cwe => '200',
|
|
44
|
+
:severity => Issue::Severity::LOW,
|
|
45
|
+
:cvssv2 => '0',
|
|
46
|
+
:remedy_guidance => %q{Remove private IP addresses from the body of the HTML pages.},
|
|
47
|
+
:remedy_code => '',
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
end
|
|
53
|
+
end
|
|
54
|
+
end
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
module Modules
|
|
13
|
+
|
|
14
|
+
#
|
|
15
|
+
#
|
|
16
|
+
# @author: Tasos "Zapotek" Laskos
|
|
17
|
+
# <tasos.laskos@gmail.com>
|
|
18
|
+
# <zapotek@segfault.gr>
|
|
19
|
+
# @version: 0.1
|
|
20
|
+
#
|
|
21
|
+
class SSN < Arachni::Module::Base
|
|
22
|
+
|
|
23
|
+
def initialize( page )
|
|
24
|
+
@page = page
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def run( )
|
|
28
|
+
regexp = /^(?!000)([0-6]\d{2}|7([0-6]\d|7[012]))([ -]?)(?!00)\d\d\3(?!0000)\d{4}$/
|
|
29
|
+
match_and_log( regexp )
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
def self.info
|
|
33
|
+
{
|
|
34
|
+
:name => 'SSN',
|
|
35
|
+
:description => %q{Greps pages for disclosed US Social Security Numbers.},
|
|
36
|
+
:author => 'Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>',
|
|
37
|
+
:version => '0.1',
|
|
38
|
+
:targets => { 'Generic' => 'all' },
|
|
39
|
+
:issue => {
|
|
40
|
+
:name => %q{Disclosed US Social Security Number.},
|
|
41
|
+
:description => %q{A US Social Security Number is being disclosed.},
|
|
42
|
+
:cwe => '200',
|
|
43
|
+
:severity => Issue::Severity::HIGH,
|
|
44
|
+
:cvssv2 => '0',
|
|
45
|
+
:remedy_guidance => %q{Remove all SSN occurences from the page.},
|
|
46
|
+
:remedy_code => '',
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
end
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
|
|
13
|
+
module Modules
|
|
14
|
+
|
|
15
|
+
#
|
|
16
|
+
# @author: Tasos "Zapotek" Laskos
|
|
17
|
+
# <tasos.laskos@gmail.com>
|
|
18
|
+
# <zapotek@segfault.gr>
|
|
19
|
+
# @version: 0.1
|
|
20
|
+
#
|
|
21
|
+
class Htaccess < Arachni::Module::Base
|
|
22
|
+
|
|
23
|
+
include Arachni::Module::Utilities
|
|
24
|
+
|
|
25
|
+
def initialize( page )
|
|
26
|
+
super( page )
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
def run( )
|
|
30
|
+
return if @page.code != 401
|
|
31
|
+
|
|
32
|
+
@http.post( @page.url ).on_complete {
|
|
33
|
+
|res|
|
|
34
|
+
__log_results( res ) if res.code == 200
|
|
35
|
+
}
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
def self.info
|
|
39
|
+
{
|
|
40
|
+
:name => '.htaccess LIMIT misconfiguration',
|
|
41
|
+
:description => %q{Checks for misconfiguration in LIMIT directives that blocks
|
|
42
|
+
GET requests but allows POST.},
|
|
43
|
+
:elements => [ ],
|
|
44
|
+
:author => 'Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>',
|
|
45
|
+
:version => '0.1',
|
|
46
|
+
:references => {},
|
|
47
|
+
:targets => { 'Generic' => 'all' },
|
|
48
|
+
:issue => {
|
|
49
|
+
:name => %q{Misconfiguration in LIMIT directive of .htaccess file.},
|
|
50
|
+
:description => %q{The .htaccess file blocks GET requests but allows POST.},
|
|
51
|
+
:tags => [ 'htaccess', 'server', 'limit' ],
|
|
52
|
+
:cwe => '',
|
|
53
|
+
:severity => Issue::Severity::HIGH,
|
|
54
|
+
:cvssv2 => '',
|
|
55
|
+
:remedy_guidance => '',
|
|
56
|
+
:remedy_code => '',
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
def __log_results( res )
|
|
62
|
+
|
|
63
|
+
issue = Issue.new( {
|
|
64
|
+
:url => res.effective_url,
|
|
65
|
+
:method => res.request.method.to_s.upcase,
|
|
66
|
+
:elem => Issue::Element::SERVER,
|
|
67
|
+
:response => res.body,
|
|
68
|
+
:headers => {
|
|
69
|
+
:request => res.request.headers,
|
|
70
|
+
:response => res.headers,
|
|
71
|
+
}
|
|
72
|
+
}.merge( self.class.info ) )
|
|
73
|
+
|
|
74
|
+
# register our results with the system
|
|
75
|
+
register_results( [issue] )
|
|
76
|
+
|
|
77
|
+
print_ok( 'Request was accepted: ' + res.effective_url )
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
Arachni
|
|
3
|
+
Copyright (c) 2010-2011 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
|
|
4
|
+
|
|
5
|
+
This is free software; you can copy and distribute and modify
|
|
6
|
+
this program under the term of the GPL v2.0 License
|
|
7
|
+
(See LICENSE file for details)
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
module Arachni
|
|
12
|
+
|
|
13
|
+
module Modules
|
|
14
|
+
|
|
15
|
+
#
|
|
16
|
+
# HTTP PUT recon module.
|
|
17
|
+
#
|
|
18
|
+
# @author: Tasos "Zapotek" Laskos
|
|
19
|
+
# <tasos.laskos@gmail.com>
|
|
20
|
+
# <zapotek@segfault.gr>
|
|
21
|
+
# @version: 0.1.1
|
|
22
|
+
#
|
|
23
|
+
class HTTP_PUT < Arachni::Module::Base
|
|
24
|
+
|
|
25
|
+
include Arachni::Module::Utilities
|
|
26
|
+
|
|
27
|
+
def initialize( page )
|
|
28
|
+
super( page )
|
|
29
|
+
|
|
30
|
+
@@__checked ||= Set.new
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def run( )
|
|
34
|
+
|
|
35
|
+
path = get_path( @page.url ) + 'Arachni-' + seed.to_s[0..4].to_s
|
|
36
|
+
|
|
37
|
+
return if @@__checked.include?( path )
|
|
38
|
+
@@__checked << path
|
|
39
|
+
|
|
40
|
+
body = 'Created by Arachni. PUT' + seed
|
|
41
|
+
|
|
42
|
+
@http.request( path, :method => :put, :body => body ).on_complete {
|
|
43
|
+
|res|
|
|
44
|
+
next if res.code != 201
|
|
45
|
+
@http.get( path ).on_complete {
|
|
46
|
+
|res|
|
|
47
|
+
__log_results( res ) if res.body && res.body.substring?( 'PUT' + seed )
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
def self.info
|
|
53
|
+
{
|
|
54
|
+
:name => 'HTTP PUT',
|
|
55
|
+
:description => %q{Checks if uploading files is possible using the HTTP PUT method.},
|
|
56
|
+
:elements => [ ],
|
|
57
|
+
:author => 'Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>',
|
|
58
|
+
:version => '0.1.1',
|
|
59
|
+
:references => {},
|
|
60
|
+
:targets => { 'Generic' => 'all' },
|
|
61
|
+
:issue => {
|
|
62
|
+
:name => %q{HTTP PUT is enabled.},
|
|
63
|
+
:description => %q{3rd parties can upload files to the web-server.},
|
|
64
|
+
:tags => [ 'http', 'methods', 'put', 'server' ],
|
|
65
|
+
:cwe => '650',
|
|
66
|
+
:severity => Issue::Severity::HIGH,
|
|
67
|
+
:cvssv2 => '',
|
|
68
|
+
:remedy_guidance => '',
|
|
69
|
+
:remedy_code => '',
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
def __log_results( res )
|
|
75
|
+
|
|
76
|
+
issue = Issue.new( {
|
|
77
|
+
:url => res.effective_url,
|
|
78
|
+
:method => res.request.method.to_s.upcase,
|
|
79
|
+
:elem => Issue::Element::SERVER,
|
|
80
|
+
:response => res.body,
|
|
81
|
+
:headers => {
|
|
82
|
+
:request => res.request.headers,
|
|
83
|
+
:response => res.headers,
|
|
84
|
+
}
|
|
85
|
+
}.merge( self.class.info ) )
|
|
86
|
+
|
|
87
|
+
# register our results with the system
|
|
88
|
+
register_results( [issue] )
|
|
89
|
+
|
|
90
|
+
print_ok( 'File has been created: ' + res.effective_url )
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
end
|
|
94
|
+
end
|
|
95
|
+
end
|