33 lines
1,012 B
Ruby
33 lines
1,012 B
Ruby
class Exploitdb < Formula
|
|
desc "The official Exploit Database"
|
|
homepage "https://www.exploit-db.com/"
|
|
url "https://github.com/offensive-security/exploit-database.git",
|
|
:tag => "2018-07-05",
|
|
:revision => "d659af98fdd50e0e9c67304ed7b7f5af6ade1974"
|
|
version "2018-07-05"
|
|
head "https://github.com/offensive-security/exploit-database.git"
|
|
|
|
bottle :unneeded
|
|
|
|
def install
|
|
inreplace "searchsploit",
|
|
"rc_file=\"\"", "rc_file=\"#{etc}/searchsploit_rc\""
|
|
|
|
optpath = opt_share/"exploit-database"
|
|
inreplace ".searchsploit_rc" do |s|
|
|
s.gsub! "\"/opt/exploit-database\"", optpath
|
|
s.gsub! "\"/opt/exploit-database-papers\"", "#{optpath}-papers"
|
|
end
|
|
|
|
bin.install "searchsploit"
|
|
etc.install ".searchsploit_rc" => "searchsploit_rc"
|
|
|
|
upshare = share/"exploit-database"
|
|
upshare.install %w[.git exploits files_exploits.csv files_shellcodes.csv
|
|
shellcodes]
|
|
end
|
|
|
|
test do
|
|
system "#{bin}/searchsploit", "sendpage"
|
|
end
|
|
end
|