Skip to content

Commit 03b3675

Browse files
committed
Added session name to logfile name
1 parent 24379f9 commit 03b3675

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/msf/core/session.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,8 +214,9 @@ def log_file_name
214214

215215
dstr = sprintf("%.4d%.2d%.2d", dt.year, dt.mon, dt.mday)
216216
rhost = session_host.gsub(':', '_')
217+
sname = name.to_s.gsub(/\W+/,'_')
217218

218-
"#{dstr}_#{rhost}_#{type}"
219+
"#{dstr}_#{sname}_#{rhost}_#{type}"
219220
end
220221

221222
#

0 commit comments

Comments
 (0)