Update to 5.0.8 and fix the location of the Firefox plugin for recent

versions of Firefox.

PINs are now requested using pinentry.
This commit is contained in:
Tijl Coosemans 2020-09-02 17:01:38 +00:00
parent ed76fbb0e7
commit 01d725c9a0
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=547369
7 changed files with 23 additions and 63 deletions

View File

@ -1,7 +1,7 @@
# $FreeBSD$
PORTNAME= beid
PORTVERSION= 4.4.21
PORTVERSION= 5.0.8
DISTVERSIONPREFIX= v
CATEGORIES= security
@ -11,9 +11,11 @@ COMMENT= Belgian eID middleware
LICENSE= LGPL3
LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libcurl.so:ftp/curl \
LIB_DEPENDS= libassuan.so:security/libassuan \
libcurl.so:ftp/curl \
libpcsclite.so:devel/pcsc-lite \
libproxy.so:net/libproxy
RUN_DEPENDS= pinentry:security/pinentry
USE_GITHUB= yes
GH_ACCOUNT= Fedict
@ -27,7 +29,7 @@ GLIB_SCHEMAS= eid-viewer.gschema.xml
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --disable-p11kit --disable-static --with-gtkvers=3 \
--enable-webextension \
--with-mozext=${PREFIX}/lib/firefox/browser/extensions \
--with-mozext=${PREFIX}/lib/firefox/distribution/extensions \
SSL_CFLAGS="-I${OPENSSLINC}" \
SSL_LIBS="-L${OPENSSLLIB} -lcrypto" \
SSL_PREFIX="${OPENSSLBASE}"
@ -41,6 +43,9 @@ NLS_USES= gettext-runtime
post-patch:
@${ECHO_CMD} ${PORTVERSION}-release > ${WRKSRC}/.version
@${REINPLACE_CMD} -e 's,/usr/bin/pinentry,${LOCALBASE}/bin/pinentry,' \
-e 's,/proc/%d/exe,/proc/%d/file,' \
${WRKSRC}/cardcomm/pkcs11/src/dialogs/dialogspinentry/dlgs_pinentry.cpp
@${REINPLACE_CMD} -e '/^MODUTIL=/s,/usr/bin,${LOCALBASE}/bin,' \
-e '/^CERTUTIL=/s,/usr/bin,${LOCALBASE}/bin,' \
-e '/^LIBS=/s,=.*,=${PREFIX}/lib,' \

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1567671881
SHA256 (Fedict-eid-mw-v4.4.21_GH0.tar.gz) = 23199ce3140b7c0e6a06f148b63ebefa54dbd0ca7c62b0b66f1bb151b40595f5
SIZE (Fedict-eid-mw-v4.4.21_GH0.tar.gz) = 7501727
TIMESTAMP = 1598443353
SHA256 (Fedict-eid-mw-v5.0.8_GH0.tar.gz) = 843f1535cf6c54391e84ce9dba55a2d6de029ca4cb10e5f71880532d46fa9b83
SIZE (Fedict-eid-mw-v5.0.8_GH0.tar.gz) = 8782476

View File

@ -1,22 +0,0 @@
--- cardcomm/pkcs11/src/dialogs/dialogsgtk/beid-badpin.c.orig 2017-10-27 12:42:43 UTC
+++ cardcomm/pkcs11/src/dialogs/dialogsgtk/beid-badpin.c
@@ -43,7 +43,7 @@ int main(int argc, char *argv[]) {
// create new message dialog with CANCEL button in standard places, in center of user's screen
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- char* msg;
+ char const *msg;
int attempts;
if ((argc == 2) && (argv[1] != NULL) && (strlen(argv[1]) == 1)
--- cardcomm/pkcs11/src/dialogs/dialogsgtk/parent.c.orig 2017-10-27 12:42:43 UTC
+++ cardcomm/pkcs11/src/dialogs/dialogsgtk/parent.c
@@ -12,7 +12,7 @@ ssize_t get_parent_path(char *exec_path, size_t exec_p
ssize_t exec_path_len = -1;
pid_t ppid = getppid();
- snprintf(proc_path, sizeof(proc_path) - 1, "/proc/%d/exe", ppid);
+ snprintf(proc_path, sizeof(proc_path) - 1, "/proc/%d/file", ppid);
if ((exec_path_len = readlink(proc_path, exec_path, exec_path_size - 1)) != -1) {
exec_path[exec_path_len] = '\0';
} else {

View File

@ -1,19 +1,19 @@
--- plugins_tools/eid-viewer/Makefile.am.orig 2019-07-11 14:08:46 UTC
--- plugins_tools/eid-viewer/Makefile.am.orig 2020-07-09 08:00:33 UTC
+++ plugins_tools/eid-viewer/Makefile.am
@@ -121,7 +121,7 @@ dist_eidvinclude_HEADERS = \
@@ -120,7 +120,7 @@ dist_eidvinclude_HEADERS = \
eid_viewer_LDADD = @GTK_LIBS@ @GIO_LIBS@ @SSL_LIBS@ @XML2_LIBS@ @CURL_LIBS@ @libproxy_LIBS@ $(top_builddir)/plugins_tools/util/liblabels.la libeidviewer.la
libeidviewer_la_LIBADD = $(top_builddir)/plugins_tools/util/liblabels.la $(top_builddir)/cardcomm/pkcs11/src/libbeidpkcs11.la @SSL_LIBS@ @XML2_LIBS@
libeidviewer_la_LDFLAGS = -version-info 1:0:1
-AM_CFLAGS = @GTK_CFLAGS@ -I. -I$(srcdir)/include -Igtk -DDATAROOTDIR='"$(datarootdir)"' -I$(top_srcdir)/doc/sdk/include/rsaref220 -I$(top_srcdir)/plugins_tools/util @SSL_CFLAGS@ @GIO_CFLAGS@ @XML2_CFLAGS@ @CURL_CFLAGS@ @libproxy_CFLAGS@ -fvisibility=hidden
+AM_CPPFLAGS = -I. -I$(srcdir)/include -Igtk -DDATAROOTDIR='"$(datarootdir)"' -I$(top_srcdir)/doc/sdk/include/rsaref220 -I$(top_srcdir)/plugins_tools/util @GTK_CFLAGS@ @SSL_CFLAGS@ @GIO_CFLAGS@ @XML2_CFLAGS@ @CURL_CFLAGS@ @libproxy_CFLAGS@ -fvisibility=hidden
-AM_CFLAGS = @GTK_CFLAGS@ -I. -I$(srcdir)/include -Igtk -DDATAROOTDIR='"$(datarootdir)"' -I$(top_srcdir)/doc/sdk/include/rsaref220 -I$(top_srcdir)/plugins_tools/util @SSL_CFLAGS@ @GIO_CFLAGS@ @XML2_CFLAGS@ @CURL_CFLAGS@ @libproxy_CFLAGS@ -fvisibility=hidden @FUZZING@
+AM_CPPFLAGS = -I. -I$(srcdir)/include -Igtk -DDATAROOTDIR='"$(datarootdir)"' -I$(top_srcdir)/doc/sdk/include/rsaref220 -I$(top_srcdir)/plugins_tools/util @GTK_CFLAGS@ @SSL_CFLAGS@ @GIO_CFLAGS@ @XML2_CFLAGS@ @CURL_CFLAGS@ @libproxy_CFLAGS@ -fvisibility=hidden @FUZZING@
AM_CXXFLAGS = $(AM_CFLAGS) -std=c++98
SUBDIRS = . gtk/po test
SUBDIRS = . gtk/po test uml
@@ -200,7 +200,9 @@ dist_trust_DATA = \
@@ -199,7 +199,9 @@ dist_trust_DATA = \
certs/belgiumrca4.pem
install-data-hook:
- if ( $(SSL_PREFIX)/bin/openssl help | grep -q rehash); then $(SSL_PREFIX)/bin/openssl rehash $(DESTDIR)/$(trustdir); else $(SSL_PREFIX)/bin/c_rehash $(DESTDIR)/$(trustdir); fi
- if ( $(SSL_PREFIX)/bin/openssl help 2>&1 | grep -q rehash); then $(SSL_PREFIX)/bin/openssl rehash $(DESTDIR)/$(trustdir); else $(SSL_PREFIX)/bin/c_rehash $(DESTDIR)/$(trustdir); fi
+ (cd $(DESTDIR)$(trustdir) && for i in *.pem; do \
+ ln -sfh $$i $$($(SSL_PREFIX)/bin/openssl x509 -hash -noout -in $$i).0; \
+ done)

View File

@ -1,16 +0,0 @@
--- scripts/build-aux/genver.sh.orig 2017-10-27 12:42:43 UTC
+++ scripts/build-aux/genver.sh
@@ -1,11 +1,11 @@
#!/bin/sh
-GITDESC=$(git describe --dirty|sed -e 's/-/./g' 2>/dev/null)
+GITDESC=$(git describe --dirty 2>/dev/null | sed -e 's/-/./g')
VERCLEAN=$(echo $GITDESC|sed -Ee 's/^.*v([0-9]+\.[0-9]+(\.[0-9]+|bp)).*$/\1/')
GITDESC="$VERCLEAN-$GITDESC"
-if [ -z "$GITDESC" ]; then
+if [ "$GITDESC" = "-" ]; then
if [ -f ".version" ]; then
GITDESC=$(cat .version)
else

View File

@ -15,8 +15,10 @@ Make sure you have installed a pcsc-lite driver for your card reader (such
as devel/libccid) and that pcscd is running (add pcscd_enable="YES" to
/etc/rc.conf and start the service by running "service pcscd start").
To use your eID in Firefox you have to enable the "eID Belgium" extension
in the Add-ons Manager.
To use your eID card in Firefox you must have the "eID Belgium" extension
installed. Normally this happens automatically. If not, you can find it
at https://addons.mozilla.org/en-US/firefox/addon/belgium-eid/. The eID card
must be inserted before starting Firefox.
EOM
}
]

View File

@ -21,14 +21,8 @@ lib/libeidviewer.so.0.1.0
lib/mozilla/pkcs11-modules/beidp11kit.json
lib/mozilla/pkcs11-modules/beidpkcs11.json
lib/pkcs11/beidpkcs11.so
lib/firefox/browser/extensions/belgiumeid@eid.belgium.be.xpi
lib/firefox/distribution/extensions/belgiumeid@eid.belgium.be.xpi
libdata/pkgconfig/libbeidpkcs11.pc
libexec/beid-askaccess
libexec/beid-askpin
libexec/beid-badpin
libexec/beid-changepin
libexec/beid-spr-askpin
libexec/beid-spr-changepin
share/applications/eid-viewer.desktop
share/eid-mw/eidv4.xsd
share/eid-mw/trustdir/143b8e8e.0
@ -43,11 +37,8 @@ share/icons/hicolor/256x256/apps/eid-viewer.png
share/icons/hicolor/32x32/apps/eid-viewer.png
share/icons/hicolor/48x48/apps/eid-viewer.png
share/icons/hicolor/512x512/apps/eid-viewer.png
%%NLS%%share/locale/de/LC_MESSAGES/dialogs-beid.mo
%%NLS%%share/locale/de/LC_MESSAGES/eid-viewer.mo
%%NLS%%share/locale/fr/LC_MESSAGES/dialogs-beid.mo
%%NLS%%share/locale/fr/LC_MESSAGES/eid-viewer.mo
%%NLS%%share/locale/nl/LC_MESSAGES/dialogs-beid.mo
%%NLS%%share/locale/nl/LC_MESSAGES/eid-viewer.mo
share/metainfo/be.belgium.eid.eidmw.metainfo.xml
share/metainfo/eid-viewer.appdata.xml