Skip to content

Commit 17dad0e

Browse files
committed
Update the deprecation note, add to msfconsole
This will cause msfconsole to throw a warning as well as msfupdate. The deadline for action is also set at the end of February.
1 parent ee2fed8 commit 17dad0e

File tree

2 files changed

+27
-6
lines changed

2 files changed

+27
-6
lines changed

msfconsole

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ while File.symlink?(msfbase)
1414
msfbase = File.expand_path(File.readlink(msfbase), File.dirname(msfbase))
1515
end
1616

17+
@msfbase_dir = File.expand_path(File.dirname(msfbase))
18+
1719
$:.unshift(File.expand_path(File.join(File.dirname(msfbase), 'lib')))
1820
require 'fastlib'
1921
require 'msfenv'
2022

21-
22-
2323
$:.unshift(ENV['MSF_LOCAL_LIB']) if ENV['MSF_LOCAL_LIB']
2424

2525
require 'optparse'
@@ -30,6 +30,24 @@ if(RUBY_PLATFORM =~ /mswin32/)
3030
$stderr.puts " be handled correctly. Please install Cygwin or use Linux in VMWare.\n\n"
3131
end
3232

33+
def is_svn
34+
File.directory?(File.join(@msfbase_dir, ".svn"))
35+
end
36+
37+
def print_deprecation_warning
38+
$stdout.puts ""
39+
$stdout.puts "[*] Deprecation Note: After 2013-02-28 (February 28, 2013), Metasploit"
40+
$stdout.puts "[*] source checkouts will NO LONGER update over SVN, but will be using"
41+
$stdout.puts "[*] GitHub exclusively. You should either download a new Metasploit"
42+
$stdout.puts "[*] installer, or use a git clone of Metasploit Framework before"
43+
$stdout.puts "[*] then. You will also need outbound access to github.com:9418/TCP."
44+
end
45+
46+
if is_svn
47+
print_deprecation_warning
48+
end
49+
50+
3351
class OptsConsole
3452
#
3553
# Return a hash describing the options.

msfupdate

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,13 @@ def add_git_upstream
5353
end
5454

5555
def print_deprecation_warning
56-
$stdout.puts "[*] Deprecation Note: The next version of Metasploit will"
57-
$stdout.puts "[*] update over the git protocol, which requires outbound"
58-
$stdout.puts "[*] access to github.com:9418/TCP."
59-
$stdout.puts "[*] Please adjust your egress firewall rules accordingly."
56+
$stdout.puts ""
57+
$stdout.puts "[*] Deprecation Note: After 2013-02-28 (February 28, 2013), Metasploit"
58+
$stdout.puts "[*] source checkouts will NO LONGER update over SVN, but will be using"
59+
$stdout.puts "[*] GitHub exclusively. You should either download a new Metasploit"
60+
$stdout.puts "[*] installer, or use a git clone of Metasploit Framework before"
61+
$stdout.puts "[*] then. You will also need outbound access to github.com:9418/TCP."
62+
$stdout.puts ""
6063
end
6164

6265
def maybe_wait_and_exit(exit_code=0)

0 commit comments

Comments
 (0)