Index: head/net/mosquitto/Makefile =================================================================== --- head/net/mosquitto/Makefile (revision 495443) +++ head/net/mosquitto/Makefile (revision 495444) @@ -1,46 +1,52 @@ # Created by: Joseph Benden # $FreeBSD$ PORTNAME= mosquitto -PORTVERSION= 1.5.5 +PORTVERSION= 1.5.8 CATEGORIES= net MASTER_SITES= http://mosquitto.org/files/source/ MAINTAINER= joe@thrallingpenguin.com -COMMENT= Open-Source MQTT Broker +COMMENT= Open source MQTT broker LICENSE= EPL -LIB_DEPENDS= libcares.so:dns/c-ares \ - libuuid.so:misc/e2fsprogs-libuuid -BUILD_DEPENDS= xsltproc:textproc/libxslt +LIB_DEPENDS= libuuid.so:misc/e2fsprogs-libuuid +RUN_DEPENDS= ${LOCALBASE}/share/certs/ca-root-nss.crt:security/ca_root_nss USES= cmake ssl USE_RC_SUBR= mosquitto USE_LDCONFIG= yes CMAKE_ARGS= -DCMAKE_LIBDATADIR:PATH="${PREFIX}/libdata" USERS= nobody PLIST_SUB= PORTVERSION=${PORTVERSION} -OPTIONS_DEFINE= WS +OPTIONS_DEFINE= CARES WS +OPTIONS_DEFAULT= CARES +CARES_LIB_DEPENDS= libcares.so:dns/c-ares +CARES_CMAKE_ON= -DWITH_SRV:BOOL=ON + WS_DESC= MQTT over Websockets support WS_LIB_DEPENDS= libwebsockets.so:net/libwebsockets -WS_CMAKE_ON= -DWITH_WEBSOCKETS=ON +WS_CMAKE_ON= -DWITH_WEBSOCKETS:BOOL=ON post-patch: - @${REINPLACE_CMD} -e '45s,^,#include ,' \ - ${WRKSRC}/src/websockets.c @${REINPLACE_CMD} -e '/ldconfig/d' ${WRKSRC}/src/CMakeLists.txt \ ${WRKSRC}/lib/CMakeLists.txt ${WRKSRC}/lib/cpp/CMakeLists.txt @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' ${WRKSRC}/CMakeLists.txt post-install: - ${MV} ${STAGEDIR}${ETCDIR}/mosquitto.conf ${STAGEDIR}${ETCDIR}/mosquitto.conf.sample - ${MV} ${STAGEDIR}${ETCDIR}/pwfile.example ${STAGEDIR}${ETCDIR}/pwfile.sample - ${MV} ${STAGEDIR}${ETCDIR}/pskfile.example ${STAGEDIR}${ETCDIR}/pskfile.sample - ${MV} ${STAGEDIR}${ETCDIR}/aclfile.example ${STAGEDIR}${ETCDIR}/aclfile.sample + ${SED} -e '/cafile/s,/usr/local,${LOCALBASE},' \ + ${STAGEDIR}${ETCDIR}/mosquitto.conf > \ + ${STAGEDIR}${ETCDIR}/mosquitto.conf.sample + ${MV} ${STAGEDIR}${ETCDIR}/pwfile.example \ + ${STAGEDIR}${ETCDIR}/pwfile.sample + ${MV} ${STAGEDIR}${ETCDIR}/pskfile.example \ + ${STAGEDIR}${ETCDIR}/pskfile.sample + ${MV} ${STAGEDIR}${ETCDIR}/aclfile.example \ + ${STAGEDIR}${ETCDIR}/aclfile.sample .include Index: head/net/mosquitto/distinfo =================================================================== --- head/net/mosquitto/distinfo (revision 495443) +++ head/net/mosquitto/distinfo (revision 495444) @@ -1,3 +1,3 @@ -TIMESTAMP = 1545122205 -SHA256 (mosquitto-1.5.5.tar.gz) = fcdb47e340864c545146681af7253399cc292e41775afd76400fda5b0d23d668 -SIZE (mosquitto-1.5.5.tar.gz) = 431998 +TIMESTAMP = 1551386128 +SHA256 (mosquitto-1.5.8.tar.gz) = 78d7e70c3794dc3a1d484b4f2f8d3addebe9c2da3f5a1cebe557f7d13beb0da4 +SIZE (mosquitto-1.5.8.tar.gz) = 442834 Index: head/net/mosquitto/files/patch-mosquitto.conf =================================================================== --- head/net/mosquitto/files/patch-mosquitto.conf (revision 495443) +++ head/net/mosquitto/files/patch-mosquitto.conf (revision 495444) @@ -1,29 +1,38 @@ ---- mosquitto.conf.orig 2018-08-16 16:05:26 UTC +--- mosquitto.conf.orig 2019-02-06 15:54:59 UTC +++ mosquitto.conf @@ -28,7 +28,7 @@ # This should be set to /var/run/mosquitto.pid if mosquitto is # being run automatically on boot with an init script and # start-stop-daemon or similar. -#pid_file +pid_file /var/run/mosquitto.pid # When run as root, drop privileges to this user and its primary # group. @@ -36,7 +36,7 @@ # If run as a non-root user, this setting has no effect. # Note that on Windows this has no effect and so mosquitto should # be started by the user you wish it to run as. -#user mosquitto +user nobody # The maximum number of QoS 1 and 2 messages currently inflight per # client. -@@ -160,7 +160,7 @@ +@@ -173,7 +173,7 @@ #bind_address # Port to use for the default listener. -#port 1883 +port 1883 # The maximum number of client connections to allow. This is # a per listener setting. +@@ -224,7 +224,7 @@ + # containing the CA certificates. For capath to work correctly, the + # certificate files must have ".crt" as the file ending and you must run + # "openssl rehash " each time you add/remove a certificate. +-#cafile ++cafile /usr/local/share/certs/ca-root-nss.crt + #capath + + # Path to the PEM encoded server certificate. Index: head/net/mosquitto/files/patch-src_mosquitto__passwd.c =================================================================== --- head/net/mosquitto/files/patch-src_mosquitto__passwd.c (revision 495443) +++ head/net/mosquitto/files/patch-src_mosquitto__passwd.c (revision 495444) @@ -1,33 +1,20 @@ - lib/mosquitto_internal.h | 3 +++ - src/mosquitto_passwd.c | 4 ++-- - src/security_default.c | 2 +- - 3 files changed, 6 insertions(+), 3 deletions(-) - ---- src/mosquitto_passwd.c.orig 2018-10-11 00:27:05 UTC +--- src/mosquitto_passwd.c.orig 2019-02-28 17:18:59 UTC +++ src/mosquitto_passwd.c -@@ -17,6 +17,7 @@ Contributors: - #include "config.h" - - #include -+#include - #include - #include - #include -@@ -99,7 +100,7 @@ int output_new_password(FILE *fptr, const char *userna +@@ -100,7 +100,7 @@ int output_new_password(FILE *fptr, const char *userna unsigned char hash[EVP_MAX_MD_SIZE]; unsigned int hash_len; const EVP_MD *digest; -#if OPENSSL_VERSION_NUMBER < 0x10100000L -+#ifdef HAVE_OPENSSL_OPAQUE_STRUCTS ++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(HAVE_OPENSSL_OPAQUE_STRUCTS) EVP_MD_CTX context; #else EVP_MD_CTX *context; -@@ -126,7 +127,7 @@ int output_new_password(FILE *fptr, const char *userna +@@ -127,7 +127,7 @@ int output_new_password(FILE *fptr, const char *userna return 1; } -#if OPENSSL_VERSION_NUMBER < 0x10100000L -+#if OPENSSL_VERSION_NUMBER < 0x10100000L ++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(HAVE_OPENSSL_OPAQUE_STRUCTS) EVP_MD_CTX_init(&context); EVP_DigestInit_ex(&context, digest, NULL); EVP_DigestUpdate(&context, password, strlen(password));