Merge pull request #2328 from blshkv/master

NetExec
This commit is contained in:
github-actions[bot] 2025-05-22 07:23:17 +00:00 committed by GitHub
commit 1801043ac5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 150 additions and 7 deletions

View file

@ -1 +1,2 @@
DIST empire-6.0.2.tar.gz 38107974 BLAKE2B 7169a51aa22895a738d85b5ae18867dfb10f78e59ff65db82ba7fffc725c8590e7fdab902b943bc1a80a0f3a827c10fd3b63052b725774a388c7d9aab2be894b SHA512 448ff62446132d736c4a1a6bc2d8abb0168d8c32841ecf2073cf3577e906cc29ea7f09bb3d227e8a8da635f0f107f36cfeed50ddd48e4bdb237c3cc8ce3f99dc
DIST empire-6.1.2.tar.gz 38063525 BLAKE2B 6e909b433968c8f999ba849e0f1b5b58631e8ef802a623d942b759f10fdfef05e1f26179b4909d75c1efcd92c16aa6f827e3d5347d20ab960ae4d0cef60c5609 SHA512 07b7d37245dcb0eed96771b5a74e7bd5510f129cf1ab269e187510b6e68ff6588e03259239a967df6a86fe7a5616cabe8ff624bad32aea5c1ff96cb7f9b5b78c

View file

@ -0,0 +1,137 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=poetry
PYTHON_COMPAT=( python3_{11..13} )
PYTHON_REQ_USE="sqlite"
inherit wrapper python-single-r1
DESCRIPTION="A post-exploitation framework"
HOMEPAGE="https://github.com/BC-SECURITY/Empire"
SRC_URI="https://github.com/BC-SECURITY/Empire/archive/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/Empire-${PV}"
LICENSE="BSD"
SLOT="0"
KEYWORDS="amd64 ~arm64 ~x86"
IUSE="powershell java"
REQUIRED_USE="powershell? ( !x86 )
${PYTHON_REQUIRED_USE}"
# https://github.com/BC-SECURITY/Empire/issues/196
RDEPEND="${PYTHON_DEPS}
$(python_gen_cond_dep '
dev-python/urllib3[${PYTHON_USEDEP}]
dev-python/requests[${PYTHON_USEDEP}]
dev-python/macholib[${PYTHON_USEDEP}]
dev-python/pyopenssl[${PYTHON_USEDEP}]
dev-python/zlib_wrapper[${PYTHON_USEDEP}]
dev-python/jinja2[${PYTHON_USEDEP}]
dev-python/pyparsing[${PYTHON_USEDEP}]
dev-python/pymysql[${PYTHON_USEDEP}]
dev-python/sqlalchemy[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
dev-python/sqlalchemy_utc[${PYTHON_USEDEP}]
dev-python/terminaltables3[${PYTHON_USEDEP}]
dev-python/pycryptodome[${PYTHON_USEDEP}]
dev-python/cryptography[${PYTHON_USEDEP}]
>=dev-python/fastapi-0.115.11[${PYTHON_USEDEP}]
>=dev-python/uvicorn-0.34.0[${PYTHON_USEDEP}]
>=dev-python/jq-1.8.0[${PYTHON_USEDEP}]
>=dev-python/aiofiles-24.1.0[${PYTHON_USEDEP}]
>=dev-python/python-multipart-0.0.20[${PYTHON_USEDEP}]
>=dev-python/python-socketio-5.12.1[${PYTHON_USEDEP}]
>=dev-python/flask-3.1.0[${PYTHON_USEDEP}]
>=dev-python/python-obfuscator-0.0.2[${PYTHON_USEDEP}]
>=dev-python/pyinstaller-6.12.0[${PYTHON_USEDEP}]
>=dev-python/packaging-24.2[${PYTHON_USEDEP}]
>=dev-python/netaddr-1.3.0[${PYTHON_USEDEP}]
>=dev-python/bcrypt-4.0.1[${PYTHON_USEDEP}]
>=dev-python/requests-file-2.1.0[${PYTHON_USEDEP}]
dev-python/pysecretsocks[${PYTHON_USEDEP}]
dev-python/donut-shellcode[${PYTHON_USEDEP}]
')
powershell? (
!x86? ( app-shells/pwsh-bin ) )
java? (
|| ( virtual/jre:* virtual/jdk:* ) )"
DEPEND="${RDEPEND}"
pkg_setup() {
python-single-r1_pkg_setup
}
src_prepare() {
python_fix_shebang "${S}"
default
}
#https://github.com/BC-SECURITY/Empire/issues/39
src_install() {
insinto "/usr/share/${PN}"
doins -r empire/ empire.py
# python_optimize "${D}/usr/share/${PN}/lib"
make_wrapper $PN \
"${PYTHON} /usr/share/${PN}/empire.py" \
"/usr/share/${PN}"
dodoc README.md Dockerfile changelog
}
pkg_config() {
local _yesno_ask
local _em_home="${EROOT}/usr/share/${PN}"
pushd "${_em_home}" >/dev/null || die
if [ -f "${_em_home}/data/empire.db" ]; then
ewarn "Drop old database "${_em_home}/data/empire.db" for new configuring ..."
read -r -p " [>] Are you sure? [y/N] " _yesno_ask
if [[ ${_yesno_ask,,} =~ ^(yes|y)$ ]]; then
rm -f data/empire.db > /dev/null 2>&1 || die
else
return
fi
fi
ebegin "Press ENTER to create password for database or Control-C to abort now"
python3 setup/setup_database.py
eend ${?} || die
if [ -f "${_em_home}/data/empire-chain.pem" ] || [ -f "${_em_home}/data/empire-priv.key" ]; then
ewarn "Drop old ${_em_home}/data/empire-chain.pem and generate new cert ..."
read -r -p " [>] Are you sure? [y/N] " _yesno_ask
if [[ ${_yesno_ask,,} =~ ^(yes|y)$ ]]; then
rm -f data/{empire-chain.pem,empire-priv.key} > /dev/null 2>&1 || die
else
return
fi
fi
openssl req -newkey rsa:2048 -new -nodes -x509 \
-subj "/C=US/ST=Denial/L=Springfield/O=Dis/CN=www.pentoo.ch" \
-keyout data/empire-priv.key \
-out data/empire-chain.pem || die
popd >/dev/null || die
}
pkg_postinst() {
ewarn "\nWarning. This software does not support system-wide installation"
ewarn "See the following bug report for more details:"
ewarn "https://github.com/BC-SECURITY/Empire/issues/39"
ewarn
ewarn "You need to run it from /usr/share/${PN} directory under 'root' account"
ewarn "\nPlease configure your installation before using:"
ewarn " emerge --config \"=${CATEGORY}/${PF}\"\n"
}

View file

@ -1,2 +1,2 @@
DIST msldap-0.5.10.tar.gz 132376 BLAKE2B b389005417abc6f786bcae8b9bb841b605c75a9b48e5e41d42e6b3674198f69d65bfc9473d9a3914c2342f89f9bf3a043a0c1901a80904cefaefbbd6f6c10b4a SHA512 8a5afe4060a8bda0ab16e04b681d6b3270526c6113d911731d8ab5c7930404a1dfc552644533cc8faddd3919972d4130815eceb2c47736399d41f45434b465b6
DIST msldap-0.5.9.tar.gz 132024 BLAKE2B 41538cf24c2d8853e884bbfba82be0e77f01fc254916ee7292fedcbc8a8fcfc5b941360ef31ded923b0553b2b0b9a44569c72198ec9362ac12ff7ec4bd8eb0f4 SHA512 2c5798535a33480dfe10cfb525adcaa225e8a800b94d18869946069bcddd83e46e57201e72a9a25f59d3ee1220715810228d747b30e1d4c0f7681561be831dfb
DIST msldap-0.5.14.tar.gz 138720 BLAKE2B 7cefd942c9e8bb123a723a517dcd63a53a6c3710c56a0a29de323475869af5f1fb18da6d2985e5dfb301e61853a83a9ca35edfac08bb768d6a8ff333cbc324e4 SHA512 cbc7cd5e2d3a6263facbeff6f86834670ec5fa5f37dbeb7bcdc44c4c30ac735993e36a564317d2e646e76187336c62d876f470fef66e6ed3d8120f36982bfeec

View file

@ -5,4 +5,8 @@
<email>unknown@pentoo.ch</email>
<name>Author Unknown</name>
</maintainer>
<upstream>
<remote-id type="github">skelsec/msldap</remote-id>
<remote-id type="pypi">msldap</remote-id>
</upstream>
</pkgmetadata>

View file

@ -1,4 +1,4 @@
# Copyright 1999-2023 Gentoo Authors
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@ -14,7 +14,6 @@ HOMEPAGE="https://github.com/skelsec/msldap"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 arm64 x86"
IUSE=""
#'winsspi;platform_system=="Windows"',
# the last two (aiocmd and asciitree) are "Prerequisites"

View file

@ -1,4 +1,4 @@
# Copyright 1999-2023 Gentoo Authors
# Copyright2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@ -14,7 +14,6 @@ HOMEPAGE="https://github.com/skelsec/msldap"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 arm64 x86"
IUSE=""
#'winsspi;platform_system=="Windows"',
# the last two (aiocmd and asciitree) are "Prerequisites"
@ -24,7 +23,7 @@ RDEPEND="
>=dev-python/asyauth-0.0.18[${PYTHON_USEDEP}]
>=dev-python/asysocks-0.2.11[${PYTHON_USEDEP}]
>=dev-python/asn1crypto-1.3.0[${PYTHON_USEDEP}]
>=dev-python/winacl-0.1.8[${PYTHON_USEDEP}]
>=dev-python/winacl-0.1.9[${PYTHON_USEDEP}]
>=dev-python/prompt-toolkit-3.0.2[${PYTHON_USEDEP}]
dev-python/tqdm[${PYTHON_USEDEP}]
dev-python/wcwidth[${PYTHON_USEDEP}]

View file

@ -32,7 +32,7 @@ RDEPEND="
>=dev-python/lsassy-3.1.11[${PYTHON_USEDEP}]
>=dev-python/masky-0.2.0[${PYTHON_USEDEP}]
>=dev-python/minikerberos-0.4.1[${PYTHON_USEDEP}]
>=dev-python/msldap-0.5.10[${PYTHON_USEDEP}]
>=dev-python/msldap-0.5.14[${PYTHON_USEDEP}]
>=dev-python/neo4j-5.0.0[${PYTHON_USEDEP}]
>=dev-python/paramiko-3.3.1[${PYTHON_USEDEP}]
>=dev-python/pyasn1-modules-0.3.0[${PYTHON_USEDEP}]

View file

@ -341,3 +341,6 @@ dev-python/inquirer3
# dnsrecon
=dev-python/loguru-0*
# make stable ahead of stabilisation, to keep the latest stable h11
~dev-python/httpcore-1.0.9