mirror of
http://thekelleys.org.uk/git/dnsmasq.git
synced 2026-11-06 15:51:41 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9828ab115e | ||
|
|
f77700aa27 | ||
|
|
0fbd980639 | ||
|
|
43cdf1c3d0 | ||
|
|
ff19b1a97d |
No files matched your search
@@ -115,6 +115,12 @@ version 2.77
|
|||||||
that privileged hosts are not given "guest" addresses by
|
that privileged hosts are not given "guest" addresses by
|
||||||
accident. Thanks to Todd Sanket for the suggestion.
|
accident. Thanks to Todd Sanket for the suggestion.
|
||||||
|
|
||||||
|
Remove historic automatic inclusion of IDN support when
|
||||||
|
building internationalisation support. This doesn't
|
||||||
|
fit now there is a choice of IDN libraries. Be sure
|
||||||
|
to include either -DHAVE_IDN or _DHAVE_LIBIDN2 for
|
||||||
|
IDN support.
|
||||||
|
|
||||||
|
|
||||||
version 2.76
|
version 2.76
|
||||||
Include 0.0.0.0/8 in DNS rebind checks. This range
|
Include 0.0.0.0/8 in DNS rebind checks. This range
|
||||||
|
|||||||
@@ -55,8 +55,8 @@ dbus_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DBUS $(PKG_CONFIG)
|
|||||||
dbus_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DBUS $(PKG_CONFIG) --libs dbus-1`
|
dbus_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DBUS $(PKG_CONFIG) --libs dbus-1`
|
||||||
idn_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_IDN $(PKG_CONFIG) --cflags libidn`
|
idn_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_IDN $(PKG_CONFIG) --cflags libidn`
|
||||||
idn_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_IDN $(PKG_CONFIG) --libs libidn`
|
idn_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_IDN $(PKG_CONFIG) --libs libidn`
|
||||||
idn2_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LIBIDN2 $(PKG_CONFIG) --cflags libidn2`
|
idn2_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LIBIDN2 $(PKG_CONFIG) --cflags libidn2`
|
||||||
idn2_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LIBIDN2 $(PKG_CONFIG) --libs libidn2`
|
idn2_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LIBIDN2 $(PKG_CONFIG) --libs libidn2`
|
||||||
ct_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_CONNTRACK $(PKG_CONFIG) --cflags libnetfilter_conntrack`
|
ct_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_CONNTRACK $(PKG_CONFIG) --cflags libnetfilter_conntrack`
|
||||||
ct_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_CONNTRACK $(PKG_CONFIG) --libs libnetfilter_conntrack`
|
ct_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_CONNTRACK $(PKG_CONFIG) --libs libnetfilter_conntrack`
|
||||||
lua_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LUASCRIPT $(PKG_CONFIG) --cflags lua5.2`
|
lua_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LUASCRIPT $(PKG_CONFIG) --cflags lua5.2`
|
||||||
@@ -108,8 +108,8 @@ all-i18n : $(BUILDDIR)
|
|||||||
@cd $(BUILDDIR) && $(MAKE) \
|
@cd $(BUILDDIR) && $(MAKE) \
|
||||||
top="$(top)" \
|
top="$(top)" \
|
||||||
i18n=-DLOCALEDIR=\'\"$(LOCALEDIR)\"\' \
|
i18n=-DLOCALEDIR=\'\"$(LOCALEDIR)\"\' \
|
||||||
build_cflags="$(version) $(dbus_cflags) $(ct_cflags) $(lua_cflags) $(nettle_cflags) `$(PKG_CONFIG) --cflags libidn`" \
|
build_cflags="$(version) $(dbus_cflags) $(idn2_cflags) $(idn_cflags) $(ct_cflags) $(lua_cflags) $(nettle_cflags)" \
|
||||||
build_libs="$(dbus_libs) $(ct_libs) $(lua_libs) $(sunos_libs) $(nettle_libs) $(gmp_libs) `$(PKG_CONFIG) --libs libidn`" \
|
build_libs="$(dbus_libs) $(idn2_libs) $(idn_libs) $(ct_libs) $(lua_libs) $(sunos_libs) $(nettle_libs) $(gmp_libs)" \
|
||||||
-f $(top)/Makefile dnsmasq
|
-f $(top)/Makefile dnsmasq
|
||||||
for f in `cd $(PO); echo *.po`; do \
|
for f in `cd $(PO); echo *.po`; do \
|
||||||
cd $(top) && cd $(BUILDDIR) && $(MAKE) top="$(top)" -f $(top)/Makefile $${f%.po}.mo; \
|
cd $(top) && cd $(BUILDDIR) && $(MAKE) top="$(top)" -f $(top)/Makefile $${f%.po}.mo; \
|
||||||
|
|||||||
Vendored
+4
-3
@@ -48,6 +48,10 @@ ifeq (,$(filter nodbus,$(DEB_BUILD_OPTIONS)))
|
|||||||
DEB_COPTS += -DHAVE_DBUS
|
DEB_COPTS += -DHAVE_DBUS
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq (,$(filter noidn, $(DEB_BUILD_OPTIONS)))
|
||||||
|
DEB_COPTS += -DHAVE_IDN
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq (,$(filter noconntrack,$(DEB_BUILD_OPTIONS)))
|
ifeq (,$(filter noconntrack,$(DEB_BUILD_OPTIONS)))
|
||||||
ifeq ($(DEB_HOST_ARCH_OS),linux)
|
ifeq ($(DEB_HOST_ARCH_OS),linux)
|
||||||
DEB_COPTS += -DHAVE_CONNTRACK
|
DEB_COPTS += -DHAVE_CONNTRACK
|
||||||
@@ -84,9 +88,6 @@ endif
|
|||||||
|
|
||||||
ifneq (,$(filter noi18n,$(DEB_BUILD_OPTIONS)))
|
ifneq (,$(filter noi18n,$(DEB_BUILD_OPTIONS)))
|
||||||
TARGET = install
|
TARGET = install
|
||||||
ifeq (,$(filter noidn, $(DEB_BUILD_OPTIONS)))
|
|
||||||
DEB_COPTS += -DHAVE_IDN
|
|
||||||
endif
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifneq (,$(filter uselua,$(DEB_BUILD_OPTIONS)))
|
ifneq (,$(filter uselua,$(DEB_BUILD_OPTIONS)))
|
||||||
|
|||||||
+7
-10
@@ -95,9 +95,6 @@ HAVE_DBUS
|
|||||||
|
|
||||||
HAVE_IDN
|
HAVE_IDN
|
||||||
define this if you want international domain name 2003 support.
|
define this if you want international domain name 2003 support.
|
||||||
NOTE: for backwards compatibility, IDN support is automatically
|
|
||||||
included when internationalisation support is built, using the
|
|
||||||
*-i18n makefile targets, even if HAVE_IDN is not explicitly set.
|
|
||||||
|
|
||||||
HAVE_LIBIDN2
|
HAVE_LIBIDN2
|
||||||
define this if you want international domain name 2008 support.
|
define this if you want international domain name 2008 support.
|
||||||
@@ -400,14 +397,14 @@ static char *compile_opts =
|
|||||||
"no-"
|
"no-"
|
||||||
#endif
|
#endif
|
||||||
"i18n "
|
"i18n "
|
||||||
#if !defined(LOCALEDIR) && !defined(HAVE_IDN)
|
#if defined(HAVE_LIBIDN2)
|
||||||
"no-"
|
|
||||||
#endif
|
|
||||||
"IDN "
|
|
||||||
#if !defined(HAVE_LIBIDN2)
|
|
||||||
"no-"
|
|
||||||
#endif
|
|
||||||
"IDN2 "
|
"IDN2 "
|
||||||
|
#else
|
||||||
|
#if !defined(HAVE_IDN)
|
||||||
|
"no-"
|
||||||
|
#endif
|
||||||
|
"IDN "
|
||||||
|
#endif
|
||||||
#ifndef HAVE_DHCP
|
#ifndef HAVE_DHCP
|
||||||
"no-"
|
"no-"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
+2
-2
@@ -304,7 +304,7 @@ static size_t calc_subnet_opt(struct subnet_opt *opt, union mysockaddr *source)
|
|||||||
/* http://tools.ietf.org/html/draft-vandergaast-edns-client-subnet-02 */
|
/* http://tools.ietf.org/html/draft-vandergaast-edns-client-subnet-02 */
|
||||||
|
|
||||||
int len;
|
int len;
|
||||||
void *addrp;
|
void *addrp = NULL;
|
||||||
int sa_family = source->sa.sa_family;
|
int sa_family = source->sa.sa_family;
|
||||||
|
|
||||||
opt->source_netmask = 0;
|
opt->source_netmask = 0;
|
||||||
@@ -344,7 +344,7 @@ static size_t calc_subnet_opt(struct subnet_opt *opt, union mysockaddr *source)
|
|||||||
|
|
||||||
len = 0;
|
len = 0;
|
||||||
|
|
||||||
if (opt->source_netmask != 0)
|
if (addrp && opt->source_netmask != 0)
|
||||||
{
|
{
|
||||||
len = ((opt->source_netmask - 1) >> 3) + 1;
|
len = ((opt->source_netmask - 1) >> 3) + 1;
|
||||||
memcpy(opt->addr, addrp, len);
|
memcpy(opt->addr, addrp, len);
|
||||||
|
|||||||
+2
-2
@@ -899,7 +899,7 @@ void reply_query(int fd, int family, time_t now)
|
|||||||
status = dnssec_validate_ds(now, header, n, daemon->namebuff, daemon->keyname, forward->class);
|
status = dnssec_validate_ds(now, header, n, daemon->namebuff, daemon->keyname, forward->class);
|
||||||
else
|
else
|
||||||
status = dnssec_validate_reply(now, header, n, daemon->namebuff, daemon->keyname, &forward->class,
|
status = dnssec_validate_reply(now, header, n, daemon->namebuff, daemon->keyname, &forward->class,
|
||||||
option_bool(OPT_DNSSEC_NO_SIGN) && (server->flags && SERV_DO_DNSSEC), NULL, NULL);
|
option_bool(OPT_DNSSEC_NO_SIGN) && (server->flags & SERV_DO_DNSSEC), NULL, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Can't validate, as we're missing key data. Put this
|
/* Can't validate, as we're missing key data. Put this
|
||||||
@@ -1477,7 +1477,7 @@ static int tcp_key_recurse(time_t now, int status, struct dns_header *header, si
|
|||||||
new_status = dnssec_validate_ds(now, header, n, name, keyname, class);
|
new_status = dnssec_validate_ds(now, header, n, name, keyname, class);
|
||||||
else
|
else
|
||||||
new_status = dnssec_validate_reply(now, header, n, name, keyname, &class,
|
new_status = dnssec_validate_reply(now, header, n, name, keyname, &class,
|
||||||
option_bool(OPT_DNSSEC_NO_SIGN) && (server->flags && SERV_DO_DNSSEC), NULL, NULL);
|
option_bool(OPT_DNSSEC_NO_SIGN) && (server->flags & SERV_DO_DNSSEC), NULL, NULL);
|
||||||
|
|
||||||
if (new_status != STAT_NEED_DS && new_status != STAT_NEED_KEY)
|
if (new_status != STAT_NEED_DS && new_status != STAT_NEED_KEY)
|
||||||
break;
|
break;
|
||||||
|
|||||||
+7
-4
@@ -383,7 +383,7 @@ size_t dhcp_reply(struct dhcp_context *context, char *iface_name, int int_index,
|
|||||||
{
|
{
|
||||||
len = option_uint(opt, offset + 4 , 1);
|
len = option_uint(opt, offset + 4 , 1);
|
||||||
/* Need to take care that bad data can't run us off the end of the packet */
|
/* Need to take care that bad data can't run us off the end of the packet */
|
||||||
if ((offset + len + 5 <= (option_len(opt))) &&
|
if ((offset + len + 5 <= (unsigned)(option_len(opt))) &&
|
||||||
(option_uint(opt, offset, 4) == (unsigned int)o->u.encap))
|
(option_uint(opt, offset, 4) == (unsigned int)o->u.encap))
|
||||||
for (o2 = offset + 5; o2 < offset + len + 5; o2 += elen + 1)
|
for (o2 = offset + 5; o2 < offset + len + 5; o2 += elen + 1)
|
||||||
{
|
{
|
||||||
@@ -834,9 +834,12 @@ size_t dhcp_reply(struct dhcp_context *context, char *iface_name, int int_index,
|
|||||||
else
|
else
|
||||||
mess->siaddr = context->local;
|
mess->siaddr = context->local;
|
||||||
|
|
||||||
snprintf((char *)mess->file, sizeof(mess->file),
|
if (strchr(service->basename, '.'))
|
||||||
strchr(service->basename, '.') ? "%s" :"%s.%d",
|
snprintf((char *)mess->file, sizeof(mess->file),
|
||||||
service->basename, layer);
|
"%s.%d", service->basename, layer);
|
||||||
|
else
|
||||||
|
snprintf((char *)mess->file, sizeof(mess->file),
|
||||||
|
"%s", service->basename);
|
||||||
|
|
||||||
option_put(mess, end, OPTION_MESSAGE_TYPE, 1, DHCPACK);
|
option_put(mess, end, OPTION_MESSAGE_TYPE, 1, DHCPACK);
|
||||||
option_put(mess, end, OPTION_SERVER_IDENTIFIER, INADDRSZ, htonl(context->local.s_addr));
|
option_put(mess, end, OPTION_SERVER_IDENTIFIER, INADDRSZ, htonl(context->local.s_addr));
|
||||||
|
|||||||
+5
-5
@@ -24,9 +24,9 @@
|
|||||||
#include <sys/times.h>
|
#include <sys/times.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_LIBIDN2
|
#if defined(HAVE_LIBIDN2)
|
||||||
#include <idn2.h>
|
#include <idn2.h>
|
||||||
#elif defined(LOCALEDIR) || defined(HAVE_IDN)
|
#elif defined(HAVE_IDN)
|
||||||
#include <idna.h>
|
#include <idna.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -136,7 +136,7 @@ static int check_name(char *in)
|
|||||||
else if (isascii((unsigned char)c) && iscntrl((unsigned char)c))
|
else if (isascii((unsigned char)c) && iscntrl((unsigned char)c))
|
||||||
/* iscntrl only gives expected results for ascii */
|
/* iscntrl only gives expected results for ascii */
|
||||||
return 0;
|
return 0;
|
||||||
#if !defined(LOCALEDIR) && !defined(HAVE_IDN) && !defined(HAVE_LIBIDN2)
|
#if !defined(HAVE_IDN) && !defined(HAVE_LIBIDN2)
|
||||||
else if (!isascii((unsigned char)c))
|
else if (!isascii((unsigned char)c))
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
#endif
|
||||||
@@ -186,7 +186,7 @@ int legal_hostname(char *name)
|
|||||||
char *canonicalise(char *in, int *nomem)
|
char *canonicalise(char *in, int *nomem)
|
||||||
{
|
{
|
||||||
char *ret = NULL;
|
char *ret = NULL;
|
||||||
#if defined(LOCALEDIR) || defined(HAVE_IDN) || defined(HAVE_LIBIDN2)
|
#if defined(HAVE_IDN) || defined(HAVE_LIBIDN2)
|
||||||
int rc;
|
int rc;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -196,7 +196,7 @@ char *canonicalise(char *in, int *nomem)
|
|||||||
if (!check_name(in))
|
if (!check_name(in))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
#if defined(LOCALEDIR) || defined(HAVE_IDN) || defined(HAVE_LIBIDN2)
|
#if defined(HAVE_IDN) || defined(HAVE_LIBIDN2)
|
||||||
#ifdef HAVE_LIBIDN2
|
#ifdef HAVE_LIBIDN2
|
||||||
rc = idn2_to_ascii_lz(in, &ret, IDN2_NONTRANSITIONAL);
|
rc = idn2_to_ascii_lz(in, &ret, IDN2_NONTRANSITIONAL);
|
||||||
if (rc == IDN2_DISALLOWED)
|
if (rc == IDN2_DISALLOWED)
|
||||||
|
|||||||
Reference in new issue
Block a user