summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2024-03-16 12:50:17 -0400
committerMike Gilbert <floppym@gentoo.org>2024-03-17 12:34:02 -0400
commitc2081661cb30896789e361f9eaa8085e4adf30c2 (patch)
treeb452895b94ba24e66b7fadbe2784326b143f27fd /net-analyzer/hydra
parentnet-analyzer/hydra: drop 9.4 (diff)
downloadgentoo-c2081661cb30896789e361f9eaa8085e4adf30c2.tar.gz
gentoo-c2081661cb30896789e361f9eaa8085e4adf30c2.tar.bz2
gentoo-c2081661cb30896789e361f9eaa8085e4adf30c2.zip
net-analyzer/hydra: depend on slotted freerdp
Bug: https://bugs.gentoo.org/925662 Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'net-analyzer/hydra')
-rw-r--r--net-analyzer/hydra/hydra-9.5-r1.ebuild (renamed from net-analyzer/hydra/hydra-9.5.ebuild)4
-rw-r--r--net-analyzer/hydra/hydra-9.5-r10.ebuild128
2 files changed, 130 insertions, 2 deletions
diff --git a/net-analyzer/hydra/hydra-9.5.ebuild b/net-analyzer/hydra/hydra-9.5-r1.ebuild
index da02a32c17e6..daca94b7c580 100644
--- a/net-analyzer/hydra/hydra-9.5.ebuild
+++ b/net-analyzer/hydra/hydra-9.5-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -33,7 +33,7 @@ RDEPEND="
oracle? ( dev-db/oracle-instantclient[sdk] )
pcre? ( dev-libs/libpcre2 )
postgres? ( dev-db/postgresql:* )
- rdp? ( net-misc/freerdp )
+ rdp? ( <net-misc/freerdp-3:0= )
libssh? ( >=net-libs/libssh-0.4.0 )
samba? ( net-fs/samba )
subversion? ( dev-vcs/subversion )
diff --git a/net-analyzer/hydra/hydra-9.5-r10.ebuild b/net-analyzer/hydra/hydra-9.5-r10.ebuild
new file mode 100644
index 000000000000..c24df6641725
--- /dev/null
+++ b/net-analyzer/hydra/hydra-9.5-r10.ebuild
@@ -0,0 +1,128 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit edo toolchain-funcs
+
+DESCRIPTION="Parallelized network login hacker"
+HOMEPAGE="https://github.com/vanhauser-thc/thc-hydra"
+SRC_URI="https://github.com/vanhauser-thc/thc-hydra/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}"/thc-${P}
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="debug firebird gcrypt gtk idn memcached mongodb mysql ncurses oracle pcre postgres rdp libssh samba subversion zlib"
+
+RDEPEND="
+ dev-libs/openssl:=
+ gtk? (
+ >=app-accessibility/at-spi2-core-2.46.0
+ dev-libs/glib:2
+ x11-libs/gdk-pixbuf:2
+ x11-libs/gtk+:2
+ )
+ firebird? ( dev-db/firebird )
+ gcrypt? ( dev-libs/libgcrypt )
+ idn? ( net-dns/libidn:= )
+ memcached? ( dev-libs/libmemcached[sasl] )
+ mongodb? ( dev-libs/mongo-c-driver )
+ mysql? ( dev-db/mysql-connector-c:= )
+ ncurses? ( sys-libs/ncurses:= )
+ oracle? ( dev-db/oracle-instantclient[sdk] )
+ pcre? ( dev-libs/libpcre2 )
+ postgres? ( dev-db/postgresql:* )
+ rdp? ( net-misc/freerdp:2= )
+ libssh? ( >=net-libs/libssh-0.4.0 )
+ samba? ( net-fs/samba )
+ subversion? ( dev-vcs/subversion )
+ zlib? ( sys-libs/zlib )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-9.5-no-clobber-fortify-source.patch
+)
+
+src_prepare() {
+ default
+
+ # None of the settings in Makefile.unix are useful to us
+ mv Makefile.unix{,.gentoo_unused} || die
+ touch Makefile.unix || die
+
+ sed -i \
+ -e 's:|| echo.*$::' \
+ -e '/\t-$(CC)/s:-::' \
+ -e '/^OPTS/{s|=|+=|;s| -O3||}' \
+ -e '/ -o /s:$(OPTS):& $(LDFLAGS):g' \
+ Makefile.am || die
+
+ # Needed to get GTK+ 3 change in configure.in (.in got updated, but
+ # configure not regen'd.)
+ #cd hydra-gtk || die
+ #sed -i -e 's:AC_INIT(configure.in):AC_INIT(configure.ac):' configure.in || die
+ #eautoreconf
+}
+
+src_configure() {
+ # Note: the top level configure script is not autoconf-based
+ tc-export CC PKG_CONFIG
+
+ export OPTS="${CFLAGS}"
+
+ hydra_sed() {
+ if use ${1}; then
+ einfo "Enabling ${1}"
+ if [[ -n "${3}" ]]; then
+ sed -i 's#'"${2}"'#'"${3}"'#' configure || die
+ fi
+ else
+ einfo "Disabling ${1}"
+ sed -i 's#'"${2}"'##; s#'"${4}"'##' configure || die
+ fi
+ }
+
+ hydra_sed firebird '-lfbclient' '' '-DLIBFIREBIRD'
+ hydra_sed gcrypt '-lgcrypt' '$( ${CTARGET:-${CHOST}}-libgcrypt-config --libs )' '-DHAVE_GCRYPT'
+ hydra_sed idn '-lidn' '$( "${PKG_CONFIG}" --libs libidn )' '-DLIBIDN -DHAVE_PR29_H'
+ hydra_sed libssh '-lssh' '$( "${PKG_CONFIG}" --libs libssh )' '-DLIBSSH'
+ hydra_sed memcached '-lmemcached' '$( "${PKG_CONFIG}" --libs libmemcached )' '-DLIBMCACHED'
+ hydra_sed mongodb '-lmongoc-1.0' '$( "${PKG_CONFIG}" --libs libmongoc-1.0 )' '-DLIBMONGODB\|-DLIBBSON'
+ hydra_sed mysql '-lmysqlclient' '$( ${CTARGET:-${CHOST}}-mysql_config --libs )' '-DLIBMYSQLCLIENT'
+ hydra_sed ncurses '-lcurses' '$( "${PKG_CONFIG}" --libs ncurses )' '-DLIBNCURSES'
+ hydra_sed pcre '-lpcre2-8' '$( "${PKG_CONFIG}" --libs libpcre2-8 )' '-DHAVE_PCRE'
+ hydra_sed postgres '-lpq' '$( "${PKG_CONFIG}" --libs libpq )' '-DLIBPOSTGRES'
+ hydra_sed oracle '-locci -lclntsh' '' '-DLIBORACLE'
+ hydra_sed rdp '-lfreerdp2' '$( "${PKG_CONFIG}" --libs freerdp2 )' '-DLIBFREERDP'
+ # TODO: https://bugs.gentoo.org/686148
+ #hydra_sed subversion '-lsvn_client-1 -lapr-1 -laprutil-1 -lsvn_subr-1' '$( "${PKG_CONFIG}" --libs libsvn_client )' '-DLIBSVN'
+ hydra_sed samba '-lsmbclient' '$( "${PKG_CONFIG}" --libs smbclient )' '-DLIBSMBCLIENT'
+ hydra_sed subversion '-lsvn_client-1 -lapr-1 -laprutil-1 -lsvn_subr-1' '' '-DLIBSVN'
+ hydra_sed zlib '-lz' '$( "${PKG_CONFIG}" --libs zlib )' '-DHAVE_ZLIB'
+
+ edo ./configure \
+ $(usev !gtk '--disable-xhydra') \
+ $(usev debug '--debug') \
+ --nostrip \
+ --prefix=/usr \
+ || die
+
+ if use gtk ; then
+ pushd hydra-gtk || die
+ econf
+ fi
+}
+
+src_compile() {
+ emake XLIBPATHS=''
+ use gtk && emake -C hydra-gtk
+}
+
+src_install() {
+ dobin hydra pw-inspector
+ use gtk && dobin hydra-gtk/src/xhydra
+ dodoc CHANGES README
+}