61 lines
1.9 KiB
Makefile
Raw Normal View History

# $OpenBSD: Makefile,v 1.26 2021/02/23 19:39:33 sthen Exp $
2019-11-10 15:10:03 +00:00
FIX_EXTRACT_PERMISSIONS = Yes
COMMENT = Python classes providing access to network packets
MODPY_EGG_VERSION = 0.9.21
2014-09-29 08:11:31 +00:00
DISTNAME = impacket-${MODPY_EGG_VERSION}
PKGNAME = py-${DISTNAME}
EPOCH = 0
CATEGORIES = net security
REVISION = 0
HOMEPAGE = https://www.secureauth.com/labs/open-source-tools/impacket
2014-09-29 08:11:31 +00:00
# Apache modified
PERMIT_PACKAGE = Yes
MODULES = lang/python
MODPY_PI = Yes
MODPY_SETUPTOOLS = Yes
2014-09-29 08:11:31 +00:00
MODPY_ADJ_FILES = impacket/ese.py \
2015-06-04 08:03:49 +00:00
impacket/examples/logger.py \
2016-09-01 12:21:05 +00:00
impacket/examples/ntlmrelayx/clients/httprelayclient.py \
impacket/examples/ntlmrelayx/clients/ldaprelayclient.py \
impacket/examples/ntlmrelayx/clients/mssqlrelayclient.py \
impacket/examples/ntlmrelayx/clients/smbrelayclient.py \
impacket/examples/ntlmrelayx/servers/httprelayserver.py \
impacket/examples/ntlmrelayx/servers/smbrelayserver.py \
impacket/examples/ntlmrelayx/utils/config.py \
impacket/examples/ntlmrelayx/utils/targetsutils.py \
2014-09-29 08:11:31 +00:00
impacket/tds.py
# ntlmrelayx can additionaly use py-ldap3, py-flask and unported py-ldapdomaindump
RUN_DEPENDS = devel/py-asn1${MODPY_FLAVOR} \
devel/py-future${MODPY_FLAVOR} \
net/py-pcapy${MODPY_FLAVOR} \
security/py-cryptodome${MODPY_FLAVOR} \
security/py-openssl${MODPY_FLAVOR}
2013-03-11 11:35:43 +00:00
NO_TEST = Yes
2014-09-29 08:11:31 +00:00
pre-configure:
2016-01-11 09:28:16 +00:00
${SUBST_CMD} ${WRKSRC}/examples/goldenPac.py \
${WRKSRC}/examples/nmapAnswerMachine.py \
${WRKSRC}/examples/raiseChild.py
# Adjust Cryptodomex imports
find ${WRKSRC} -type f -name \*.py -exec sed -i 's,Cryptodome,Crypto,g' {} +
2014-09-29 08:11:31 +00:00
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/${PKGSTEM}
mv ${PREFIX}/bin/*.py ${PREFIX}/share/examples/${PKGSTEM}
mv ${PREFIX}/share/doc/impacket ${PREFIX}/share/doc/${PKGSTEM}
2014-09-29 08:11:31 +00:00
# Add missing shebangs
for i in ${PREFIX}/share/examples/${PKGSTEM}/*.py; do \
perl -pi -e 'print "#!${MODPY_BIN}\n" if $$. == 1' $${i}; \
done
.include <bsd.port.mk>