File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
lib/metasploit/framework/jtr Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -119,6 +119,8 @@ def crack_command
119
119
120
120
if config . present?
121
121
cmd << ( "--config=" + config )
122
+ else
123
+ cmd << ( "--config=" + john_config_file )
122
124
end
123
125
124
126
if pot . present?
@@ -162,6 +164,13 @@ def each_cracked_password
162
164
end
163
165
end
164
166
167
+ # This method returns the path to a default john.conf file.
168
+ #
169
+ # @return [String] the path to the default john.conf file
170
+ def john_config_file
171
+ ::File . join ( ::Msf ::Config . data_directory , "john" , "confs" , "john.conf" )
172
+ end
173
+
165
174
# This method returns the path to a default john.pot file.
166
175
#
167
176
# @return [String] the path to the default john.pot file
@@ -189,6 +198,8 @@ def show_command
189
198
190
199
if config
191
200
cmd << "--config=#{ config } "
201
+ else
202
+ cmd << ( "--config=" + john_config_file )
192
203
end
193
204
194
205
cmd << hash_path
You can’t perform that action at this time.
0 commit comments