View | Details | Raw Unified | Return to bug 239850 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile (-25 / +28 lines)
Lines 1-10 Link Here
1
# $FreeBSD$
1
# $FreeBSD$
2
2
3
PORTNAME=	powerdns
3
PORTNAME=	powerdns
4
DISTVERSION=	4.1.10
4
DISTVERSION=	4.2.0
5
PORTREVISION=	4
6
CATEGORIES=	dns ipv6
5
CATEGORIES=	dns ipv6
7
MASTER_SITES=	http://downloads.powerdns.com/releases/
6
MASTER_SITES=	https://downloads.powerdns.com/releases/
8
DISTNAME=	pdns-${DISTVERSION}
7
DISTNAME=	pdns-${DISTVERSION}
9
8
10
MAINTAINER=	tremere@cainites.net
9
MAINTAINER=	tremere@cainites.net
Lines 14-24 Link Here
14
13
15
BROKEN_sparc64=		Does not compile: error: to_string is not a member of std
14
BROKEN_sparc64=		Does not compile: error: to_string is not a member of std
16
15
17
LIB_DEPENDS=	libboost_serialization.so:devel/boost-libs
16
LIB_DEPENDS=	libboost_serialization.so:devel/boost-libs \
17
		libcurl.so:ftp/curl
18
18
19
USES=		compiler:c++11-lib cpe gmake libtool localbase:ldflags pathfix \
19
USES=		compiler:c++11-lib cpe gmake libtool localbase:ldflags pathfix \
20
		pkgconfig ssl tar:bzip2
20
		pkgconfig ssl tar:bzip2
21
22
USE_LDCONFIG=	YES
21
USE_LDCONFIG=	YES
23
USE_RC_SUBR=	pdns
22
USE_RC_SUBR=	pdns
24
USE_SUBMAKE=	YES
23
USE_SUBMAKE=	YES
Lines 35-61 Link Here
35
SCRIPTS_ENV=	CURDIR2="${.CURDIR}" DISTNAME="${DISTNAME}" MKDIR="${MKDIR}" \
34
SCRIPTS_ENV=	CURDIR2="${.CURDIR}" DISTNAME="${DISTNAME}" MKDIR="${MKDIR}" \
36
		POWERDNS_OPTIONS="${POWERDNS_OPTIONS}" \
35
		POWERDNS_OPTIONS="${POWERDNS_OPTIONS}" \
37
		WRKDIRPREFIX="${WRKDIRPREFIX}"
36
		WRKDIRPREFIX="${WRKDIRPREFIX}"
38
39
SUB_FILES=	pkg-message
37
SUB_FILES=	pkg-message
40
38
41
OPTIONS_DEFINE=		DOCS EXAMPLES LUAJIT MYDNS MYSQL OPENDBX OPENLDAP \
39
OPTIONS_DEFINE=			DOCS EXAMPLES GEOIP LUABACKEND LUAJIT MYDNS \
42
			OPTALGO PGSQL PROTOBUF REMOTE SQLITE3 TINYDNS TOOLS \
40
				MYSQL OPENDBX OPENLDAP PGSQL PROTOBUF REMOTE \
43
			UNIXODBC
41
				SQLITE3 TINYDNS TOOLS UNIXODBC
44
OPTIONS_DEFAULT=	MYSQL PGSQL SQLITE3
42
OPTIONS_DEFAULT=		MYSQL PGSQL SQLITE3
45
43
OPTIONS_GROUP=			GEOIPOPT REMOTEOPT
46
OPTIONS_GROUP=			EXPERIMENTAL REMOTEOPT
47
OPTIONS_GROUP_EXPERIMENTAL=	LUABACKEND
48
OPTIONS_GROUP_REMOTEOPT=	ZEROMQ
44
OPTIONS_GROUP_REMOTEOPT=	ZEROMQ
49
45
50
OPTIONS_SUB=	yes
46
OPTIONS_SUB=	yes
51
47
52
LUABACKEND_DESC=	Lua backend
48
GEOIPOPT_DESC=		GeoIP DB options
49
GEOIP_DESC=		GeoIP backend (GeoIP2 DB)
50
LUABACKEND_DESC=	Lua2 backend
53
LUAJIT_DESC=		Use LuaJIT instead of Lua
51
LUAJIT_DESC=		Use LuaJIT instead of Lua
54
MYDNS_DESC=		MyDNS backend
52
MYDNS_DESC=		MyDNS backend
55
MYSQL_DESC=		MySQL backend
53
MYSQL_DESC=		MySQL backend
56
OPENDBX_DESC=		OpenDBX backend
54
OPENDBX_DESC=		OpenDBX backend
57
OPENLDAP_DESC=		OpenLDAP backend
55
OPENLDAP_DESC=		OpenLDAP backend
58
OPTALGO_DESC=		Enable optional algorithms (12, 15 & 16)
59
PGSQL_DESC=		PostgreSQL backend
56
PGSQL_DESC=		PostgreSQL backend
60
PROTOBUF_DESC=		Protobuf support
57
PROTOBUF_DESC=		Protobuf support
61
REMOTEOPT_DESC=		Remote backend connectors
58
REMOTEOPT_DESC=		Remote backend connectors
Lines 65-75 Link Here
65
TOOLS_DESC=		Build extra tools
62
TOOLS_DESC=		Build extra tools
66
ZEROMQ_DESC=		Enable ZeroMQ connector (Implies REMOTE enabled)
63
ZEROMQ_DESC=		Enable ZeroMQ connector (Implies REMOTE enabled)
67
64
68
LUABACKEND_VARS=	MODULES+=lua
65
GEOIP_LIB_DEPENDS=	libmaxminddb.so:net/libmaxminddb \
66
			libyaml-cpp.so:devel/yaml-cpp
67
GEOIP_VARS=		MODULES+=geoip
69
68
69
LUABACKEND_VARS=	MODULES+=lua2
70
70
LUAJIT_LIB_DEPENDS=	libluajit-5.1.so.2:lang/luajit
71
LUAJIT_LIB_DEPENDS=	libluajit-5.1.so.2:lang/luajit
71
LUAJIT_USES_OFF=	lua
72
LUAJIT_USES_OFF=	lua
72
LUAJIT_CONFIGURE_WITH=	luajit
73
LUAJIT_CONFIGURE_ON=	--with-lua=luajit
73
74
74
MYDNS_USES=		mysql
75
MYDNS_USES=		mysql
75
MYDNS_CONFIGURE_ON=	--with-mysql=${LOCALBASE}
76
MYDNS_CONFIGURE_ON=	--with-mysql=${LOCALBASE}
Lines 87-99 Link Here
87
OPENLDAP_CXXFLAGS=	-DLDAP_DEPRECATED=1
88
OPENLDAP_CXXFLAGS=	-DLDAP_DEPRECATED=1
88
OPENLDAP_VARS=		MODULES+=ldap
89
OPENLDAP_VARS=		MODULES+=ldap
89
90
90
OPTALGO_LIB_DEPENDS=	libbotan-2.so:security/botan2 \
91
			libdecaf.so:security/libdecaf \
92
			libsodium.so:security/libsodium
93
OPTALGO_CONFIGURE_ON=	--enable-botan \
94
			--enable-libdecaf \
95
			--enable-libsodium
96
97
PGSQL_USES=		pgsql
91
PGSQL_USES=		pgsql
98
PGSQL_CONFIGURE_ON=	--with-pg-config=${LOCALBASE}/bin/pg_config
92
PGSQL_CONFIGURE_ON=	--with-pg-config=${LOCALBASE}/bin/pg_config
99
PGSQL_VARS=		MODULES+=gpgsql
93
PGSQL_VARS=		MODULES+=gpgsql
Lines 120-128 Link Here
120
ZEROMQ_LIB_DEPENDS=	libzmq.so:net/libzmq4
114
ZEROMQ_LIB_DEPENDS=	libzmq.so:net/libzmq4
121
ZEROMQ_CONFIGURE_ON=	--enable-remotebackend-zeromq
115
ZEROMQ_CONFIGURE_ON=	--enable-remotebackend-zeromq
122
116
117
.include <bsd.port.pre.mk>
118
119
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1200085 && ${SSL_DEFAULT} != openssl111
120
CONFIGURE_ARGS+=	--with-libdecaf \
121
			--with-libsodium
122
LIB_DEPENDS+=		libdecaf.so:security/libdecaf \
123
			libsodium.so:security/libsodium
124
.endif
125
123
post-install::
126
post-install::
124
	@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
127
	@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
125
	@${STAGEDIR}${LOCALBASE}/sbin/pdns_server --module-dir=${STAGEDIR}${LOCALBASE}/lib/pdns --launch="pipe bind ${MODULES}" --config > ${STAGEDIR}${EXAMPLESDIR}/pdns.conf
128
	@${STAGEDIR}${LOCALBASE}/sbin/pdns_server --module-dir=${STAGEDIR}${LOCALBASE}/lib/pdns --launch="pipe bind ${MODULES}" --config > ${STAGEDIR}${EXAMPLESDIR}/pdns.conf
126
	@${REINPLACE_CMD} -e 's;${STAGEDIR};;' -i '' ${STAGEDIR}${EXAMPLESDIR}/pdns.conf
129
	@${REINPLACE_CMD} -e 's;${STAGEDIR};;' -i '' ${STAGEDIR}${EXAMPLESDIR}/pdns.conf
127
130
128
.include <bsd.port.mk>
131
.include <bsd.port.post.mk>
(-)distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1561114944
1
TIMESTAMP = 1567076172
2
SHA256 (pdns-4.1.10.tar.bz2) = 5a46cfde92caaaa2e85af9a15acb9ad81b56f4c8a8255c457e6938d8c0cb15c7
2
SHA256 (pdns-4.2.0.tar.bz2) = 222007f25e25aad71ac7d8b7f1797a4bcb30781e456d74ed00396e53828a903a
3
SIZE (pdns-4.1.10.tar.bz2) = 1117663
3
SIZE (pdns-4.2.0.tar.bz2) = 1249282
(-)files/patch-pdns_dns__random.cc (+12 lines)
Line 0 Link Here
1
--- pdns/dns_random.cc.orig	2018-11-29 12:53:42 UTC
2
+++ pdns/dns_random.cc
3
@@ -40,7 +40,9 @@
4
 #include <openssl/rand.h>
5
 #endif
6
 #if defined(HAVE_GETRANDOM)
7
+extern "C" {
8
 #include <sys/random.h>
9
+}
10
 #endif
11
 
12
 static enum DNS_RNG {
(-)files/pdns.in (-1 / +1 lines)
Lines 4-10 Link Here
4
#
4
#
5
5
6
# PROVIDE: pdns_server
6
# PROVIDE: pdns_server
7
# REQUIRE: DAEMON SERVERS
7
# REQUIRE: DAEMON SERVERS mysql postgresql slapd
8
# KEYWORD: shutdown
8
# KEYWORD: shutdown
9
9
10
#
10
#
(-)files/pkg-message.in (-3 / +3 lines)
Lines 15-23 Link Here
15
{ type: upgrade
15
{ type: upgrade
16
  maximum_versio: 3.4
16
  maximum_versio: 3.4
17
  message: <<EOM
17
  message: <<EOM
18
 ---------------------------------------------
18
 -----------------------------------------------
19
 IMPORTANT: PowerDNS Authoritive Server 3.4.0+:
19
 IMPORTANT: PowerDNS Authoritative Server 3.4.0+:
20
 ---------------------------------------------
20
 -----------------------------------------------
21
 This version needs a mandatory schema change for the gmsyql,
21
 This version needs a mandatory schema change for the gmsyql,
22
 gpgsql and gsqlite3 backends. SQL statements are available in
22
 gpgsql and gsqlite3 backends. SQL statements are available in
23
 %%DOCSDIR%% or http://doc.powerdns.com
23
 %%DOCSDIR%% or http://doc.powerdns.com
(-)pkg-install (+42 lines)
Line 0 Link Here
1
#! /bin/sh
2
3
# $FreeBSD$
4
5
PATH=/bin:/usr/bin:/usr/sbin
6
7
securitywarning() {
8
cat <<EOF
9
10
  === IMPORTANT FOR GPGSQL BACKEND USERS! ===
11
  The following only impacts anyone using the
12
  gpgsql (PostgreSQL) backend:
13
14
  An issue has been found in PowerDNS
15
  Authoritative Server allowing an authorized
16
  user to cause the server to exit by
17
  inserting a crafted record in a MASTER type
18
  zone under their control. The issue is due
19
  to the fact that the Authoritative Server
20
  will exit when it tries to store the
21
  notified serial in the PostgreSQL database,
22
  if this serial cannot be represented in 31
23
  bits.
24
25
  To fix the issue, run the following command
26
  against your PostgreSQL pdns database:
27
28
  ALTER TABLE domains ALTER notified_serial
29
  TYPE bigint USING CASE WHEN notified_serial
30
  >= 0 THEN notified_serial::bigint END;
31
32
  No software changes are required.
33
  ===========================================
34
EOF
35
}
36
37
case $2 in
38
PRE-INSTALL)
39
        securitywarning
40
        sleep 5
41
        ;;
42
esac
(-)pkg-plist (-1 / +9 lines)
Lines 4-11 Link Here
4
bin/zone2sql
4
bin/zone2sql
5
sbin/pdns_server
5
sbin/pdns_server
6
%%PROTOBUF%%bin/dnspcap2protobuf
6
%%PROTOBUF%%bin/dnspcap2protobuf
7
%%TOOLS%%bin/calidns
7
%%TOOLS%%bin/dnsbulktest
8
%%TOOLS%%bin/dnsbulktest
8
%%TOOLS%%bin/dnsgram
9
%%TOOLS%%bin/dnsgram
10
%%TOOLS%%bin/dnspcap2calidns
9
%%TOOLS%%bin/dnsreplay
11
%%TOOLS%%bin/dnsreplay
10
%%TOOLS%%bin/dnsscan
12
%%TOOLS%%bin/dnsscan
11
%%TOOLS%%bin/dnsscope
13
%%TOOLS%%bin/dnsscope
Lines 21-27 Link Here
21
%%TOOLS%%bin/stubquery
23
%%TOOLS%%bin/stubquery
22
lib/pdns/libbindbackend.so
24
lib/pdns/libbindbackend.so
23
lib/pdns/libpipebackend.so
25
lib/pdns/libpipebackend.so
24
%%LUABACKEND%%lib/pdns/libluabackend.so
26
%%GEOIP%%lib/pdns/libgeoipbackend.so
27
%%LUABACKEND%%lib/pdns/liblua2backend.so
25
%%MYDNS%%lib/pdns/libmydnsbackend.so
28
%%MYDNS%%lib/pdns/libmydnsbackend.so
26
%%MYSQL%%lib/pdns/libgmysqlbackend.so
29
%%MYSQL%%lib/pdns/libgmysqlbackend.so
27
%%OPENDBX%%lib/pdns/libopendbxbackend.so
30
%%OPENDBX%%lib/pdns/libopendbxbackend.so
Lines 35-40 Link Here
35
%%TOOLS%%man/man1/calidns.1.gz
38
%%TOOLS%%man/man1/calidns.1.gz
36
%%TOOLS%%man/man1/dnsbulktest.1.gz
39
%%TOOLS%%man/man1/dnsbulktest.1.gz
37
%%TOOLS%%man/man1/dnsgram.1.gz
40
%%TOOLS%%man/man1/dnsgram.1.gz
41
%%TOOLS%%man/man1/dnspcap2calidns.1.gz
38
%%TOOLS%%man/man1/dnsscan.1.gz
42
%%TOOLS%%man/man1/dnsscan.1.gz
39
%%TOOLS%%man/man1/dumresp.1.gz
43
%%TOOLS%%man/man1/dumresp.1.gz
40
%%TOOLS%%man/man1/ixplore.1.gz
44
%%TOOLS%%man/man1/ixplore.1.gz
Lines 59-64 Link Here
59
%%PORTEXAMPLES%%@dir %%EXAMPLESDIR%%
63
%%PORTEXAMPLES%%@dir %%EXAMPLESDIR%%
60
%%MYSQL%%%%PORTDOCS%%%%DOCSDIR%%/3.4.0_to_4.1.0_schema.mysql.sql
64
%%MYSQL%%%%PORTDOCS%%%%DOCSDIR%%/3.4.0_to_4.1.0_schema.mysql.sql
61
%%PGSQL%%%%PORTDOCS%%%%DOCSDIR%%/3.4.0_to_4.1.0_schema.pgsql.sql
65
%%PGSQL%%%%PORTDOCS%%%%DOCSDIR%%/3.4.0_to_4.1.0_schema.pgsql.sql
66
%%SQLITE3%%%%PORTDOCS%%%%DOCSDIR%%/3.4.0_to_4.0.0_schema.sqlite3.sql
67
%%SQLITE3%%%%PORTDOCS%%%%DOCSDIR%%/4.0.0_to_4.2.0_schema.sqlite3.sql
68
%%MYSQL%%%%PORTDOCS%%%%DOCSDIR%%/4.1.0_to_4.2.0_schema.mysql.sql
69
%%PGSQL%%%%PORTDOCS%%%%DOCSDIR%%/4.1.0_to_4.2.0_schema.pgsql.sql
62
%%MYSQL%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.mysql.sql
70
%%MYSQL%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.mysql.sql
63
%%PGSQL%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.pgsql.sql
71
%%PGSQL%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.pgsql.sql
64
%%SQLITE3%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.sqlite3.sql
72
%%SQLITE3%%%%PORTDOCS%%%%DOCSDIR%%/dnssec-3.x_to_3.4.0_schema.sqlite3.sql

Return to bug 239850