watobo 0.9.8.677

Sign up to get free protection for your applications and to get access to all the features.
Files changed (260) hide show
  1. data/bin/watobo_gui.rb +39 -0
  2. data/certificates/cert.pem +19 -0
  3. data/certificates/privkey.pem +15 -0
  4. data/certificates/watobo_dh.key +5 -0
  5. data/config/datastore.yml +5 -0
  6. data/config/forwarding_proxy.yml +12 -0
  7. data/config/general.yml +4 -0
  8. data/config/gui.yml +23 -0
  9. data/config/interceptor.yml +16 -0
  10. data/config/scan_policy.yml +13 -0
  11. data/config/scanner.yml +34 -0
  12. data/icons/Add.ico +0 -0
  13. data/icons/Add_24x24.ico +0 -0
  14. data/icons/Bandwidth.ico +0 -0
  15. data/icons/Bandwidth_24x24.ico +0 -0
  16. data/icons/Mr. Bomb.ico +0 -0
  17. data/icons/Mr. Bomb_16x16.ico +0 -0
  18. data/icons/Mr. Bomb_24x24.ico +0 -0
  19. data/icons/Orange Ball.ico +0 -0
  20. data/icons/Orange Ball_16x16.ico +0 -0
  21. data/icons/Orange Ball_24x24.ico +0 -0
  22. data/icons/Pause.ico +0 -0
  23. data/icons/Play.ico +0 -0
  24. data/icons/Play_24x24.ico +0 -0
  25. data/icons/Red Ball.ico +0 -0
  26. data/icons/Red Ball_16x16.ico +0 -0
  27. data/icons/Red Ball_24x24.ico +0 -0
  28. data/icons/Run.ico +0 -0
  29. data/icons/Stop.ico +0 -0
  30. data/icons/Stop_24x24.ico +0 -0
  31. data/icons/Terminal.ico +0 -0
  32. data/icons/Transfer.ico +0 -0
  33. data/icons/Transfer_16x16.ico +0 -0
  34. data/icons/User.ico +0 -0
  35. data/icons/User_16x16.ico +0 -0
  36. data/icons/User_24x24.ico +0 -0
  37. data/icons/Web Browser.ico +0 -0
  38. data/icons/Web Browser_16x16.ico +0 -0
  39. data/icons/Write Document.ico +0 -0
  40. data/icons/Yellow Ball.ico +0 -0
  41. data/icons/Yellow Ball_16x16.ico +0 -0
  42. data/icons/Yellow Ball_24x24.ico +0 -0
  43. data/icons/advanced.ico +0 -0
  44. data/icons/advanced_16x16.ico +0 -0
  45. data/icons/advanced_24x24.ico +0 -0
  46. data/icons/applications.ico +0 -0
  47. data/icons/applications_16x16.ico +0 -0
  48. data/icons/applications_24x24.ico +0 -0
  49. data/icons/browser_16x16.ico +0 -0
  50. data/icons/browser_24x24.ico +0 -0
  51. data/icons/burn.ico +0 -0
  52. data/icons/burn_16x16.ico +0 -0
  53. data/icons/burn_24x24.ico +0 -0
  54. data/icons/calculator.ico +0 -0
  55. data/icons/calculator_24x24.ico +0 -0
  56. data/icons/cb_checked.ico +0 -0
  57. data/icons/cb_checked_orange.ico +0 -0
  58. data/icons/cb_unchecked.ico +0 -0
  59. data/icons/coin_24x24.ico +0 -0
  60. data/icons/conversation.ico +0 -0
  61. data/icons/conversation_24x24.ico +0 -0
  62. data/icons/engine.ico +0 -0
  63. data/icons/filter.ico +0 -0
  64. data/icons/folder.ico +0 -0
  65. data/icons/folder_16x16.ico +0 -0
  66. data/icons/fuzzer_16x16.ico +0 -0
  67. data/icons/fuzzer_24x24.ico +0 -0
  68. data/icons/go-down_16x16.png +0 -0
  69. data/icons/go-up_16x16.png +0 -0
  70. data/icons/help.ico +0 -0
  71. data/icons/help_16x16.ico +0 -0
  72. data/icons/help_24x24.ico +0 -0
  73. data/icons/iChat.ico +0 -0
  74. data/icons/iChat_16x16.ico +0 -0
  75. data/icons/iChat_24x24.ico +0 -0
  76. data/icons/icons.txt +3 -0
  77. data/icons/info.ico +0 -0
  78. data/icons/info_16x16.ico +0 -0
  79. data/icons/info_24x24.ico +0 -0
  80. data/icons/interceptor_24x24.ico +0 -0
  81. data/icons/lock.ico +0 -0
  82. data/icons/lock_12x12.ico +0 -0
  83. data/icons/lock_16x16.ico +0 -0
  84. data/icons/monitor.ico +0 -0
  85. data/icons/plugin.ico +0 -0
  86. data/icons/plugin_24x24.ico +0 -0
  87. data/icons/scan_16x16.png +0 -0
  88. data/icons/send.ico +0 -0
  89. data/icons/server.ico +0 -0
  90. data/icons/server_16x16.ico +0 -0
  91. data/icons/siberas_logo_x24.gif +0 -0
  92. data/icons/tag_blue_32x32.ico +0 -0
  93. data/icons/watobo-48x48.png +0 -0
  94. data/icons/watobo-logo.png +0 -0
  95. data/icons/watobo.ico +0 -0
  96. data/lib/watobo/adapters/data_store.rb +38 -0
  97. data/lib/watobo/adapters/file/file_store.rb +211 -0
  98. data/lib/watobo/adapters/session_store.rb +27 -0
  99. data/lib/watobo/adapters.rb +26 -0
  100. data/lib/watobo/config.rb +143 -0
  101. data/lib/watobo/constants.rb +92 -0
  102. data/lib/watobo/core/active_check.rb +404 -0
  103. data/lib/watobo/core/cookie.rb +69 -0
  104. data/lib/watobo/core/fuzz_gen.rb +160 -0
  105. data/lib/watobo/core/http_socket.rb +142 -0
  106. data/lib/watobo/core/interceptor.rb +729 -0
  107. data/lib/watobo/core/passive_check.rb +141 -0
  108. data/lib/watobo/core/project.rb +1058 -0
  109. data/lib/watobo/core/scanner.rb +396 -0
  110. data/lib/watobo/core/session.rb +1320 -0
  111. data/lib/watobo/core/simple_ca.rb +393 -0
  112. data/lib/watobo/core.rb +34 -0
  113. data/lib/watobo/defaults.rb +40 -0
  114. data/lib/watobo/external/diff/lcs/array.rb +42 -0
  115. data/lib/watobo/external/diff/lcs/block.rb +72 -0
  116. data/lib/watobo/external/diff/lcs/callbacks.rb +343 -0
  117. data/lib/watobo/external/diff/lcs/change.rb +190 -0
  118. data/lib/watobo/external/diff/lcs/hunk.rb +279 -0
  119. data/lib/watobo/external/diff/lcs/ldiff.rb +247 -0
  120. data/lib/watobo/external/diff/lcs/string.rb +40 -0
  121. data/lib/watobo/external/diff/lcs.rb +1124 -0
  122. data/lib/watobo/external/ntlm/ntlm.rb +797 -0
  123. data/lib/watobo/externals.rb +28 -0
  124. data/lib/watobo/framework/create_project.rb +55 -0
  125. data/lib/watobo/framework/init.rb +149 -0
  126. data/lib/watobo/framework/init_modules.rb +116 -0
  127. data/lib/watobo/framework/license_text.rb +50 -0
  128. data/lib/watobo/framework.rb +26 -0
  129. data/lib/watobo/gui/about_watobo.rb +68 -0
  130. data/lib/watobo/gui/browser_preview.rb +460 -0
  131. data/lib/watobo/gui/certificate_dialog.rb +132 -0
  132. data/lib/watobo/gui/chat_diff.rb +415 -0
  133. data/lib/watobo/gui/chatviewer_frame.rb +427 -0
  134. data/lib/watobo/gui/checkboxtree.rb +221 -0
  135. data/lib/watobo/gui/checks_policy_frame.rb +123 -0
  136. data/lib/watobo/gui/client_cert_dialog.rb +227 -0
  137. data/lib/watobo/gui/confirm_scan_dialog.rb +67 -0
  138. data/lib/watobo/gui/conversation_table.rb +386 -0
  139. data/lib/watobo/gui/conversation_table_ctrl.rb +175 -0
  140. data/lib/watobo/gui/csrf_token_dialog.rb +446 -0
  141. data/lib/watobo/gui/dashboard.rb +341 -0
  142. data/lib/watobo/gui/define_scope_frame.rb +380 -0
  143. data/lib/watobo/gui/edit_comment.rb +70 -0
  144. data/lib/watobo/gui/edit_scope_dialog.rb +69 -0
  145. data/lib/watobo/gui/finding_info.rb +212 -0
  146. data/lib/watobo/gui/findings_tree.rb +459 -0
  147. data/lib/watobo/gui/full_scan_dialog.rb +269 -0
  148. data/lib/watobo/gui/fuzzer_gui.rb +1522 -0
  149. data/lib/watobo/gui/hex_viewer.rb +106 -0
  150. data/lib/watobo/gui/interceptor_gui.rb +994 -0
  151. data/lib/watobo/gui/interceptor_settings_dialog.rb +201 -0
  152. data/lib/watobo/gui/log_viewer.rb +97 -0
  153. data/lib/watobo/gui/login_wizzard.rb +301 -0
  154. data/lib/watobo/gui/main_window.rb +1815 -0
  155. data/lib/watobo/gui/manual_request_editor.rb +1105 -0
  156. data/lib/watobo/gui/master_pw_dialog.rb +142 -0
  157. data/lib/watobo/gui/password_policy_dialog.rb +98 -0
  158. data/lib/watobo/gui/plugin/base.rb +82 -0
  159. data/lib/watobo/gui/plugin_board.rb +95 -0
  160. data/lib/watobo/gui/preferences_dialog.rb +116 -0
  161. data/lib/watobo/gui/progress_window.rb +102 -0
  162. data/lib/watobo/gui/project_wizzard.rb +369 -0
  163. data/lib/watobo/gui/proxy_dialog.rb +550 -0
  164. data/lib/watobo/gui/quick_scan_dialog.rb +242 -0
  165. data/lib/watobo/gui/request_editor.rb +480 -0
  166. data/lib/watobo/gui/save_chat_dialog.rb +158 -0
  167. data/lib/watobo/gui/scanner_settings_dialog.rb +360 -0
  168. data/lib/watobo/gui/select_chat_dialog.rb +169 -0
  169. data/lib/watobo/gui/session_management_dialog.rb +688 -0
  170. data/lib/watobo/gui/sites_tree.rb +347 -0
  171. data/lib/watobo/gui/status_bar.rb +88 -0
  172. data/lib/watobo/gui/table_editor.rb +445 -0
  173. data/lib/watobo/gui/tagless_viewer.rb +62 -0
  174. data/lib/watobo/gui/templates/plugin.rb +80 -0
  175. data/lib/watobo/gui/templates/plugin2.rb +103 -0
  176. data/lib/watobo/gui/text_viewer.rb +247 -0
  177. data/lib/watobo/gui/transcoder_window.rb +215 -0
  178. data/lib/watobo/gui/utils/gui_utils.rb +129 -0
  179. data/lib/watobo/gui/utils/init_icons.rb +106 -0
  180. data/lib/watobo/gui/utils/load_icons.rb +54 -0
  181. data/lib/watobo/gui/utils/load_plugins.rb +94 -0
  182. data/lib/watobo/gui/utils/master_password.rb +90 -0
  183. data/lib/watobo/gui/utils/save_default_settings.rb +99 -0
  184. data/lib/watobo/gui/utils/save_project_settings.rb +21 -0
  185. data/lib/watobo/gui/utils/save_proxy_settings.rb +45 -0
  186. data/lib/watobo/gui/utils/save_session_settings.rb +21 -0
  187. data/lib/watobo/gui/utils/session_history.rb +134 -0
  188. data/lib/watobo/gui/workspace_dialog.rb +89 -0
  189. data/lib/watobo/gui/www_auth_dialog.rb +348 -0
  190. data/lib/watobo/gui/xml_viewer_frame.rb +114 -0
  191. data/lib/watobo/gui.rb +139 -0
  192. data/lib/watobo/mixins/httpparser.rb +664 -0
  193. data/lib/watobo/mixins/request_parser.rb +210 -0
  194. data/lib/watobo/mixins/shapers.rb +345 -0
  195. data/lib/watobo/mixins/transcoders.rb +88 -0
  196. data/lib/watobo/mixins.rb +32 -0
  197. data/lib/watobo/utils/check_regex.rb +36 -0
  198. data/lib/watobo/utils/copy_object.rb +29 -0
  199. data/lib/watobo/utils/crypto.rb +74 -0
  200. data/lib/watobo/utils/expand_range.rb +45 -0
  201. data/lib/watobo/utils/file_management.rb +73 -0
  202. data/lib/watobo/utils/load_chat.rb +219 -0
  203. data/lib/watobo/utils/load_icon.rb +47 -0
  204. data/lib/watobo/utils/print_debug.rb +34 -0
  205. data/lib/watobo/utils/response_hash.rb +143 -0
  206. data/lib/watobo/utils/secure_eval.rb +57 -0
  207. data/lib/watobo/utils/text2request.rb +96 -0
  208. data/lib/watobo/utils.rb +32 -0
  209. data/lib/watobo.rb +76 -0
  210. data/modules/active/Apache/mod_status.rb +123 -0
  211. data/modules/active/Flash/crossdomain.rb +102 -0
  212. data/modules/active/directories/dirwalker.rb +89 -0
  213. data/modules/active/discovery/fileextensions.rb +151 -0
  214. data/modules/active/discovery/http_methods.rb +135 -0
  215. data/modules/active/domino/domino_db.lst +164 -0
  216. data/modules/active/domino/domino_db.rb +128 -0
  217. data/modules/active/fileinclusion/lfi_simple.rb +134 -0
  218. data/modules/active/jboss/jboss_basic.rb +119 -0
  219. data/modules/active/sap/business_objects.rb +73 -0
  220. data/modules/active/sap/its_commands.rb +101 -0
  221. data/modules/active/sap/its_service_parameter.rb +105 -0
  222. data/modules/active/sap/its_services.rb +103 -0
  223. data/modules/active/sap/its_xss.rb +98 -0
  224. data/modules/active/sqlinjection/sql_boolean.rb +262 -0
  225. data/modules/active/sqlinjection/sqli_simple.rb +205 -0
  226. data/modules/active/xss/xss_simple.rb +179 -0
  227. data/modules/passive/cookie_options.rb +97 -0
  228. data/modules/passive/cookie_xss.rb +85 -0
  229. data/modules/passive/detect_code.rb +89 -0
  230. data/modules/passive/detect_fileupload.rb +80 -0
  231. data/modules/passive/detect_infrastructure.rb +98 -0
  232. data/modules/passive/detect_one_time_tokens.rb +86 -0
  233. data/modules/passive/dirindexing.rb +81 -0
  234. data/modules/passive/disclosure_emails.rb +82 -0
  235. data/modules/passive/disclosure_ipaddr.rb +87 -0
  236. data/modules/passive/filename_as_parameter.rb +85 -0
  237. data/modules/passive/form_spotter.rb +75 -0
  238. data/modules/passive/hotspots.rb +86 -0
  239. data/modules/passive/in_script_parameter.rb +92 -0
  240. data/modules/passive/multiple_server_headers.rb +98 -0
  241. data/modules/passive/possible_login.rb +134 -0
  242. data/modules/passive/redirect_url.rb +88 -0
  243. data/modules/passive/redirectionz.rb +96 -0
  244. data/modules/passive/xss_dom.rb +91 -0
  245. data/plugins/catalog/catalog.ico +0 -0
  246. data/plugins/catalog/catalog.rb +726 -0
  247. data/plugins/catalog/db_tests +6483 -0
  248. data/plugins/catalog/db_variables +29 -0
  249. data/plugins/filefinder/dbs/hbci.db +12 -0
  250. data/plugins/filefinder/filefinder.rb +602 -0
  251. data/plugins/sslchecker/cli/sslchecker_cli.rb +21 -0
  252. data/plugins/sslchecker/gui/cipher_table.rb +260 -0
  253. data/plugins/sslchecker/gui/gui.rb +245 -0
  254. data/plugins/sslchecker/gui/sslchecker.rb +26 -0
  255. data/plugins/sslchecker/icons/green_16x16.ico +0 -0
  256. data/plugins/sslchecker/icons/grey_16x16.ico +0 -0
  257. data/plugins/sslchecker/icons/red_16x16.ico +0 -0
  258. data/plugins/sslchecker/icons/sslchecker.ico +0 -0
  259. data/plugins/sslchecker/lib/check.rb +117 -0
  260. metadata +317 -0
@@ -0,0 +1,151 @@
1
+ # .
2
+ # fileextensions.rb
3
+ #
4
+ # Copyright 2012 by siberas, http://www.siberas.de
5
+ #
6
+ # This file is part of WATOBO (Web Application Tool Box)
7
+ # http://watobo.sourceforge.com
8
+ #
9
+ # WATOBO is free software; you can redistribute it and/or modify
10
+ # it under the terms of the GNU General Public License as published by
11
+ # the Free Software Foundation version 2 of the License.
12
+ #
13
+ # WATOBO is distributed in the hope that it will be useful,
14
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ # GNU General Public License for more details.
17
+ #
18
+ # You should have received a copy of the GNU General Public License
19
+ # along with WATOBO; if not, write to the Free Software
20
+ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21
+ # .
22
+ module Watobo
23
+ module Modules
24
+ module Active
25
+ module Discovery
26
+
27
+
28
+ class Fileextensions < Watobo::ActiveCheck
29
+
30
+ def initialize(session_name=nil, prefs={})
31
+ # @project = project
32
+ super(session_name, prefs)
33
+
34
+ @info.update(
35
+ :check_name => 'FileExtensions', # name of check which briefly describes functionality, will be used for tree and progress views
36
+ :description => "Checks for temporary- or backup-files", # description of checkfunction
37
+ :author => "Andreas Schmidt", # author of check
38
+ :version => "0.9" # check version
39
+ )
40
+
41
+ @finding.update(
42
+ :threat => 'Temporary- or backup files may contain sensitive information, e.g. source-code or username/password.', # thread of vulnerability, e.g. loss of information
43
+ :class => "File Extension", # vulnerability class, e.g. Stored XSS, SQL-Injection, ...
44
+ :rating => VULN_RATING_HIGH,
45
+ :type => FINDING_TYPE_VULN # FINDING_TYPE_HINT, FINDING_TYPE_INFO, FINDING_TYPE_VULN
46
+ )
47
+
48
+
49
+
50
+ # @tested_directories = Hash.new
51
+ @fext = %w( php asp aspx jsp cfm shtm htm html shml )
52
+ @prefixes = [ "", "~", "_"]
53
+ @suffixes = [ "tmp", "bak", "tgz", "tar.gz", "tar", "gz", "zip", "bz2", "old"]
54
+ end
55
+
56
+ def reset()
57
+
58
+ end
59
+
60
+ def generateChecks(chat)
61
+
62
+ begin
63
+ file = chat.request.file
64
+ #e = dummy.split('?').first
65
+
66
+ if file != "" and file =~ /\.(#{@fext.join("|")})$/ then
67
+
68
+ @prefixes.each do |pref|
69
+ @suffixes.each do |suf|
70
+
71
+ #sleep(1)
72
+ checker = proc{
73
+ test_request = nil
74
+ test_response = nil
75
+ new_file = pref + file.gsub(/\.\w{1,4}$/, ".#{suf}")
76
+ # puts new_file
77
+ # !!! ATTENTION !!!
78
+ # MAKE COPY BEFORE MODIFIYING REQUEST
79
+ test_request = chat.copyRequest
80
+
81
+ test_request.replaceFileExt(new_file)
82
+ # result_request, result_response = doRequest(test_request, :default => true)
83
+ # puts test_request.first
84
+
85
+ status, test_request, test_response = fileExists?(test_request, :default => true)
86
+ # puts new_e + " : " + test_response.status
87
+ if status == true then
88
+ puts "GOTCHA - #{self.class}!!!\n+ #{test_request.first}\n"
89
+ #test_chat = Chat.new(test_request, test_response, chat.id)
90
+ addFinding( test_request, test_response,
91
+ :check_pattern => "#{new_file}",
92
+ :test_item => file,
93
+ :proof_pattern => "#{test_response.status}",
94
+ :chat => chat,
95
+ :title => "#{new_file}"
96
+ #:debug => true
97
+ )
98
+ end
99
+ [ test_request, test_response ]
100
+ }
101
+ yield checker
102
+
103
+ checker = proc{
104
+ test_request = nil
105
+ test_response = nil
106
+ new_file = pref + file + ".#{suf}"
107
+
108
+ # !!! ATTENTION !!!
109
+ # MAKE COPY BEFORE MODIFIYING REQUEST
110
+ test_request = chat.copyRequest
111
+
112
+ test_request.replaceFileExt(new_file)
113
+ # result_request, result_response = doRequest(test_request, :default => true)
114
+
115
+
116
+ status, test_request, test_response = fileExists?(test_request, :default => true)
117
+ # puts new_e + " : " + test_response.status
118
+
119
+ if status == true then
120
+ # puts "\n+ #{test_request.first}\n"
121
+ # test_chat = Chat.new(test_request, test_response, chat.id)
122
+ addFinding( test_request, test_response,
123
+ :check_pattern => "#{new_file}",
124
+ :test_item => file,
125
+ :proof_pattern => "#{test_response.status}",
126
+ :chat => chat,
127
+ :title => "#{new_file}"
128
+ #:debug => true
129
+ )
130
+ end
131
+ [ test_request, test_response ]
132
+ }
133
+ yield checker
134
+
135
+ end
136
+ end
137
+ end
138
+ rescue => bang
139
+
140
+ puts "ERROR!! #{Module.nesting[0].name} "
141
+ puts "chatid: #{chat.id}"
142
+ puts bang
143
+ puts
144
+
145
+ end
146
+ end
147
+ end
148
+ end
149
+ end
150
+ end
151
+ end
@@ -0,0 +1,135 @@
1
+ # .
2
+ # http_methods.rb
3
+ #
4
+ # Copyright 2012 by siberas, http://www.siberas.de
5
+ #
6
+ # This file is part of WATOBO (Web Application Tool Box)
7
+ # http://watobo.sourceforge.com
8
+ #
9
+ # WATOBO is free software; you can redistribute it and/or modify
10
+ # it under the terms of the GNU General Public License as published by
11
+ # the Free Software Foundation version 2 of the License.
12
+ #
13
+ # WATOBO is distributed in the hope that it will be useful,
14
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ # GNU General Public License for more details.
17
+ #
18
+ # You should have received a copy of the GNU General Public License
19
+ # along with WATOBO; if not, write to the Free Software
20
+ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21
+ # .
22
+ module Watobo
23
+ module Modules
24
+ module Active
25
+ module Discovery
26
+
27
+
28
+ class Http_methods < Watobo::ActiveCheck
29
+ @@tested_directories = []
30
+ def initialize(project, prefs={})
31
+ @project = project
32
+ super(project, prefs)
33
+
34
+ @info.update(
35
+ :check_name => 'HTTP Methods', # name of check which briefly describes functionality, will be used for tree and progress views
36
+ :description => "Checks for supported HTTP Methods.", # description of checkfunction
37
+ :author => "Andreas Schmidt", # author of check
38
+ :version => "0.9" # check version
39
+ )
40
+
41
+ @finding.update(
42
+ :threat => 'Some HTTP methods can be exploited by an attacker to compromise the system.', # thread of vulnerability, e.g. loss of information
43
+ :class => "HTTP Methods", # vulnerability class, e.g. Stored XSS, SQL-Injection, ...
44
+ :type => FINDING_TYPE_HINT # FINDING_TYPE_HINT, FINDING_TYPE_INFO, FINDING_TYPE_VULN
45
+ )
46
+
47
+
48
+
49
+
50
+
51
+ @dummy_element = "WATOBO"
52
+
53
+ @not_allowed_response = [ "UNAUTHORIZED", "NOT IMPLEMENTED", "NOT ALLOWED", "NOT SUPPORTED", "FORBIDDEN", "BAD REQUEST", "302"]
54
+
55
+ @test_methods = %w[ PROPFIND PROPPATCH COPY UNLOCK MKCOL ] + # web_dav_methods - DELETE is too dangerous here
56
+ %w[ OPTIONS TRACE ]+ # common but unwanted methods
57
+ %w[ TRACK DEBUG ] + # IIS methods
58
+ %w[ CHECKOUT SHOWMETHOD LINK CHECKIN TEXTSEARCH SPACEJUMP SEARCH REPLY]+ # http://www.w3.org/Protocols/HTTP/Methods.html
59
+ %w[ VERSION_CONTROL CHECKIN UNCHECKOUT PATCH ] # eclipse_methods
60
+ @test_methods = %w[ TRACE ]
61
+ end
62
+
63
+ def reset()
64
+ @@tested_directories.clear
65
+ end
66
+
67
+ def generateChecks(chat)
68
+
69
+ begin
70
+ unless @@tested_directories.include?(chat.request.dir) then
71
+ @@tested_directories.push chat.request.dir
72
+ @test_methods.each do |method|
73
+ #sleep(1)
74
+ checker = proc{
75
+ begin
76
+ test_request = nil
77
+ test_response = nil
78
+ test_method = "#{method}"
79
+ # !!! ATTENTION !!!
80
+ # MAKE COPY BEFORE MODIFIYING REQUEST
81
+
82
+ test_request = chat.copyRequest
83
+
84
+ test_request.replaceMethod(test_method)
85
+
86
+ result_request, result_response = doRequest(test_request, :default => true)
87
+ is_vuln = true
88
+ if result_response.status then
89
+
90
+ @not_allowed_response.each do |nar|
91
+ if result_response.status =~ /#{nar}/i then
92
+ is_vuln = false
93
+ end
94
+ end
95
+
96
+ if is_vuln == true then
97
+ addFinding( result_request, result_response,
98
+ :check_pattern => "#{test_method}",
99
+ :proof_pattern => "#{result_response.status}",
100
+ :test_item => chat.request.dir,
101
+ :chat => chat,
102
+ :title => "#{test_method}"
103
+ #:debug => true
104
+ )
105
+ end
106
+ end
107
+ [ result_request, result_response ]
108
+ rescue => bang
109
+ puts bang
110
+ puts bang.backtrace if $DEBUG
111
+ [ nil, nil ]
112
+ end
113
+ }
114
+ yield checker
115
+ end
116
+
117
+
118
+ end
119
+
120
+ end
121
+ rescue => bang
122
+
123
+ puts "ERROR!! #{Module.nesting[0].name} "
124
+ puts "chatid: #{chat.id}"
125
+ puts bang
126
+ puts
127
+
128
+ end
129
+
130
+ end
131
+
132
+ end
133
+ end
134
+ end
135
+ end
@@ -0,0 +1,164 @@
1
+ AgentRunner.nsf
2
+ DEASAppDesign.nsf
3
+ DEASLog01.nsf
4
+ DEASLog02.nsf
5
+ DEASLog03.nsf
6
+ DEASLog04.nsf
7
+ DEASLog05.nsf
8
+ DEASLog.nsf
9
+ DEESAdmin.nsf
10
+ Forms5.nsf
11
+ SchedulerTr.nsf
12
+ account.nsf
13
+ accounts.nsf
14
+ admin4.nsf
15
+ admin5.nsf
16
+ adminisist.nsf
17
+ admin.nsf
18
+ agentrunner.nsf
19
+ alog.nsf
20
+ billing.nsf
21
+ bookmark.nsf
22
+ books.nsf
23
+ busytime.nsf
24
+ calendar.nsf
25
+ catalog.nsf
26
+ cersvr.nsf
27
+ certa.nsf
28
+ certlog.nsf
29
+ certsrv.nsf
30
+ chatlog.nsf
31
+ clbusy.nsf
32
+ cldbdir.nsf
33
+ clusta4.nsf
34
+ collect4.nsf
35
+ cpa.nsf
36
+ customerdata.nsf
37
+ da.nsf
38
+ database.nsf
39
+ dba4.nsf
40
+ db.nsf
41
+ dclf.nsf
42
+ decsadm.nsf
43
+ decsdoc.nsf
44
+ decslog.nsf
45
+ default.nsf
46
+ dirassist.nsf
47
+ doladmin.nsf
48
+ domadmin.nsf
49
+ domcfg.nsf
50
+ domguide.nsf
51
+ domino.nsf
52
+ domlog.nsf
53
+ dspug.nsf
54
+ event.nsf
55
+ events4.nsf
56
+ events5.nsf
57
+ events.nsf
58
+ faqw46.nsf
59
+ framew46.nsf
60
+ group.nsf
61
+ groups.nsf
62
+ help4.nsf
63
+ helpadmin.nsf
64
+ helpadmn.nsf
65
+ helplt4.nsf
66
+ hidden.nsf
67
+ homepage.nsf
68
+ internet.nsf
69
+ javapg.nsf
70
+ jotter.nsf
71
+ kbccv11.nsf
72
+ kbnv11.nsf
73
+ kbssvv11.nsf
74
+ lccon.nsf
75
+ lcon.nsf
76
+ ldap.nsf
77
+ leiadm.nsf
78
+ leilog.nsf
79
+ leivlt.nsf
80
+ log4a.nsf
81
+ loga4.nsf
82
+ log.nsf
83
+ lsxlc.nsf
84
+ mab.nsf
85
+ mailw46.nsf
86
+ main.nsf
87
+ migrate.nsf
88
+ msdwda.nsf
89
+ mtatbls.nsf
90
+ mtstore.nsf
91
+ names.nsf
92
+ nd000000.nsf
93
+ nd000001.nsf
94
+ nd000002.nsf
95
+ nd000003.nsf
96
+ nd000004.nsf
97
+ nntppost.nsf
98
+ notes.nsf
99
+ .nsf
100
+ ntsync45.nsf
101
+ ntsync4.nsf
102
+ pagesw46.nsf
103
+ perweb.nsf
104
+ private.nsf
105
+ products.nsf
106
+ public.nsf
107
+ qpadmin.nsf
108
+ qstart50.nsf
109
+ qstart.nsf
110
+ readmec.nsf
111
+ readme.nsf
112
+ readmes.nsf
113
+ reports.nsf
114
+ schema50.nsf
115
+ secret.nsf
116
+ secure.nsf
117
+ setup.nsf
118
+ setupweb.nsf
119
+ siregw46.nsf
120
+ site1w46.nsf
121
+ site2w46.nsf
122
+ site3w46.nsf
123
+ smbcfg.nsf
124
+ smconf.nsf
125
+ smency.nsf
126
+ smhelp.nsf
127
+ smmsg.nsf
128
+ smquar.nsf
129
+ smsolar.nsf
130
+ smtime.nsf
131
+ smtpibwq.nsf
132
+ smtp.nsf
133
+ smtpobwq.nsf
134
+ smtptbls.nsf
135
+ smvlog.nsf
136
+ software.nsf
137
+ srvinst.nsf
138
+ statmail.nsf
139
+ statrep.nsf
140
+ stats217.nsf
141
+ stats572.nsf
142
+ stats675.nsf
143
+ stats988.nsf
144
+ stauths.nsf
145
+ stautht.nsf
146
+ stconfig.nsf
147
+ stconf.nsf
148
+ stdnaset.nsf
149
+ stdomino.nsf
150
+ stlog.nsf
151
+ streg.nsf
152
+ stsrc.nsf
153
+ test.nsf
154
+ today.nsf
155
+ user.nsf
156
+ userreg.nsf
157
+ users.nsf
158
+ vpuserinfo.nsf
159
+ webadmin.nsf
160
+ web.nsf
161
+ webuser.nsf
162
+ welcome.nsf
163
+ wksinst.nsf
164
+ wwsample.nsf
@@ -0,0 +1,128 @@
1
+ # .
2
+ # domino_db.rb
3
+ #
4
+ # Copyright 2012 by siberas, http://www.siberas.de
5
+ #
6
+ # This file is part of WATOBO (Web Application Tool Box)
7
+ # http://watobo.sourceforge.com
8
+ #
9
+ # WATOBO is free software; you can redistribute it and/or modify
10
+ # it under the terms of the GNU General Public License as published by
11
+ # the Free Software Foundation version 2 of the License.
12
+ #
13
+ # WATOBO is distributed in the hope that it will be useful,
14
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ # GNU General Public License for more details.
17
+ #
18
+ # You should have received a copy of the GNU General Public License
19
+ # along with WATOBO; if not, write to the Free Software
20
+ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21
+ # .
22
+ require 'digest/md5'
23
+ require 'digest/sha1'
24
+
25
+ module Watobo
26
+ module Modules
27
+ module Active
28
+ module Domino
29
+
30
+
31
+ class Domino_db < Watobo::ActiveCheck
32
+
33
+ def initialize(project, prefs={})
34
+ super(project, prefs)
35
+
36
+ @info.update(
37
+ :check_name => 'Lotus Domino DB Enumeration', # name of check which briefly describes functionality, will be used for tree and progress views
38
+ :description => "Enumeration of well known Domino DBs.", # description of checkfunction
39
+ :author => "Andreas Schmidt", # author of check
40
+ :check_group => AC_GROUP_DOMINO,
41
+ :version => "0.9" # check version
42
+ )
43
+
44
+ @finding.update(
45
+ :threat => 'Information Disclosure and/or modifying of databases.', # thread of vulnerability, e.g. loss of information
46
+ :class => "Lotus Domino: Default Database", # vulnerability class, e.g. Stored XSS, SQL-Injection, ...
47
+ :type => FINDING_TYPE_HINT # FINDING_TYPE_HINT, FINDING_TYPE_INFO, FINDING_TYPE_VULN
48
+ )
49
+
50
+
51
+ @domino_dbs = []
52
+
53
+ filename = "domino_db.lst"
54
+ path = File.dirname(__FILE__)
55
+ db_file = File.join(path, filename)
56
+
57
+ begin
58
+ fh = open(db_file,"r")
59
+ fh.each_line do |dbname|
60
+ @domino_dbs.push dbname.strip
61
+ end
62
+ # puts "* #{@domino_dbs.length} Lotus Domino DB Names loaded"
63
+ rescue => bang
64
+ puts "!!! ERROR: Problems import Domino DB List"
65
+ puts "File:"
66
+ puts "#{db_file}"
67
+ puts bang
68
+ end
69
+ end
70
+
71
+ def generateChecks(chat)
72
+ begin
73
+ if chat.request.url =~ /(.*)\/\w*\.nsf/ then
74
+ @domino_dbs.each do |db|
75
+ checker = proc{
76
+ test_request = nil
77
+ test_response = nil
78
+ test = chat.copyRequest
79
+ line = test.shift
80
+ line.gsub!(/(\w*\.nsf.*) (HTTP\/.*)/, "#{db} \\2")
81
+ puts line
82
+ test.unshift line
83
+
84
+ test_request,test_response = doRequest(test,:default => true)
85
+
86
+
87
+ if test_response.status =~ /ok/i then
88
+ # test_chat = Chat.new(test, test_response, chat.id)
89
+ if test_response.join =~ /(names\.nsf\?Login)/ # if default db found, check for content
90
+ addFinding( test_request,test_response,
91
+ :test_item => chat.request.url,
92
+ :check_pattern => "#{db}",
93
+ :proof_pattern => "#{test_response.status}",
94
+ :chat=>chat,
95
+ :title => db
96
+ )
97
+ else
98
+ addFinding(test_request,test_response,
99
+ :check_pattern => "#{db}",
100
+ :proof_pattern => "#{test_response.status}",
101
+ :test_item => chat.request.url,
102
+ :class => "Lotus Domino: Unprotected Default DB",
103
+ :type => FINDING_TYPE_VULN,
104
+ :chat => chat,
105
+ :rating => VULN_RATING_HIGH,
106
+ :title => db
107
+ )
108
+ [ test_request, test_response ]
109
+ end
110
+ end
111
+ }
112
+ yield checker
113
+ end
114
+ end
115
+ rescue => bang
116
+ puts bang
117
+ puts "ERROR!! #{Module.nesting[0].name}"
118
+ raise
119
+
120
+ end
121
+ end
122
+
123
+ end
124
+ # --> eo namespace
125
+ end
126
+ end
127
+ end
128
+ end