On Thu, 05 Sep 2024 21:06:15 +0200, Klemens Nanni <k...@openbsd.org> wrote: > > 05.09.2024 02:25, Kirill A. Korinsky пишет: > > ports@, Remi, > > > > Here an update of security/wapiti to the last version 3.2.0 from 3.0.1 which > > was released in May of 2018. > > > > So, time pasts, and it needs new dependencies which I ported as well. > > > > Thus, right now wapiti fails as: > > > > File > > "/usr/local/lib/python3.11/site-packages/wapitiCore/main/wapiti.py", line > > 39, in <module> > > from wapitiCore.language.language import _ > > File > > "/usr/local/lib/python3.11/site-packages/wapitiCore/language/language.py", > > line 62, in <module> > > lan = gettext.translation( > > ^^^^^^^^^^^^^^^^^^^^ > > TypeError: translation() got an unexpected keyword argument 'codeset' > > Do we know what broke this and when? > > Is there perhaps an small/easy fix to unbreak our port before we import 11 > ports for it? >
They simple had nuked internalization because it's pain to support: https://github.com/wapiti-scanner/wapiti/issues/324 Anyway, it is a good point and allows to make a 7.6 with working wapiti. So, here the diff to fix this issue. I had brifley tested it by scaning a few web sites, and it seems to work: Index: Makefile =================================================================== RCS file: /cvs/ports/security/wapiti/Makefile,v retrieving revision 1.15 diff -u -p -r1.15 Makefile --- Makefile 6 May 2024 12:23:58 -0000 1.15 +++ Makefile 5 Sep 2024 20:19:06 -0000 @@ -3,7 +3,7 @@ COMMENT = web-application vulnerability MODPY_EGG_VERSION = 3.0.1 DISTNAME = wapiti3-${MODPY_EGG_VERSION} PKGNAME = wapiti-${MODPY_EGG_VERSION} -REVISION = 7 +REVISION = 8 CATEGORIES = security www Index: patches/patch-wapitiCore_language_language_py =================================================================== RCS file: patches/patch-wapitiCore_language_language_py diff -N patches/patch-wapitiCore_language_language_py --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-wapitiCore_language_language_py 5 Sep 2024 20:19:06 -0000 @@ -0,0 +1,12 @@ +Index: wapitiCore/language/language.py +--- wapitiCore/language/language.py.orig ++++ wapitiCore/language/language.py +@@ -62,7 +62,6 @@ LANG_PATH = os.path.join(BASE_DIR, "config", "language + lan = gettext.translation( + "wapiti", + LANG_PATH, +- languages=[lang], +- codeset="UTF-8" ++ languages=[lang] + ) + _ = lan.gettext -- wbr, Kirill