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-09-16",
|
|
revision: "187c559c55e495ff70b2cbdfc31147ca48677a9d"
|
|
version "2022-09-16"
|
|
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: "19cc2c29cfccdfd097a6345d41f4e01907b40a201b5832c5e763a7e9bee99eb3"
|
|
sha256 cellar: :any_skip_relocation, arm64_big_sur: "a09fc9d0af7f86223745155b050d44a550154119eeea19a6ca0ec78bfc7259d4"
|
|
sha256 cellar: :any_skip_relocation, monterey: "499dec81f98d27b7f8da40e2662418ec1003614035e0e418e0874a11bb576dfe"
|
|
sha256 cellar: :any_skip_relocation, big_sur: "b0788eda0dbe29c77514ce213c870e5c4ae9b096f287396b1edac1f25e098187"
|
|
sha256 cellar: :any_skip_relocation, catalina: "ba9509868d842d0666a6b475a9ff1d97b7914b6490cc3b11966998c1ae908769"
|
|
sha256 cellar: :any_skip_relocation, x86_64_linux: "85b436ff2f3179c257ecf287c6a292d23041212aba5b8aa06000ad147dbf066f"
|
|
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
|