41 lines
1.7 KiB
Ruby
41 lines
1.7 KiB
Ruby
class Exploitdb < Formula
|
|
desc "Database of public exploits and corresponding vulnerable software"
|
|
homepage "https://www.exploit-db.com/"
|
|
url "https://github.com/offensive-security/exploitdb.git",
|
|
tag: "2022-07-30",
|
|
revision: "dfb28913d0ef4e1c6f38520b44802566f44dcd1a"
|
|
version "2022-07-30"
|
|
license "GPL-2.0-or-later"
|
|
head "https://github.com/offensive-security/exploitdb.git", branch: "master"
|
|
|
|
bottle do
|
|
sha256 cellar: :any_skip_relocation, arm64_monterey: "744dd2e3ebb9f8cc959f31dbf107d856b793bdb96c856bc639d2a461d376f5c4"
|
|
sha256 cellar: :any_skip_relocation, arm64_big_sur: "f168d687afd4b7b06f14e8f6e64acaefb121fa1abaa58a91a0552437e9819b2e"
|
|
sha256 cellar: :any_skip_relocation, monterey: "5540fe66e45a13418a25f213090cac151a03f9d18ffe7f28b5ff889f4b269217"
|
|
sha256 cellar: :any_skip_relocation, big_sur: "a55378d1068bd9ae66d550678b7adab6e49d3672fe94177bb5d3538b2f7af111"
|
|
sha256 cellar: :any_skip_relocation, catalina: "cac3d1b7d0a2ebd0e2fa3ff9f1bf239ecb11606d9606c212ce01382e8143b9ba"
|
|
sha256 cellar: :any_skip_relocation, x86_64_linux: "19ee7c014a58e438c8098dacfd7133aad56a4605975a43ef761429cc90b8df2f"
|
|
end
|
|
|
|
def install
|
|
inreplace "searchsploit",
|
|
"rc_file=\"\"", "rc_file=\"#{etc}/searchsploit_rc\""
|
|
|
|
optpath = opt_share/"exploitdb"
|
|
inreplace ".searchsploit_rc" do |s|
|
|
s.gsub! "\"/opt/exploitdb\"", optpath
|
|
s.gsub! "\"/opt/exploitdb-papers\"", "#{optpath}-papers"
|
|
end
|
|
|
|
bin.install "searchsploit"
|
|
etc.install ".searchsploit_rc" => "searchsploit_rc"
|
|
|
|
pkgshare.install %w[.git exploits files_exploits.csv files_shellcodes.csv
|
|
shellcodes]
|
|
end
|
|
|
|
test do
|
|
system "#{bin}/searchsploit", "sendpage"
|
|
end
|
|
end
|