libexec_PROGRAMS = \
gnunet-service-gns \
- $(DO_W32_HELPER) \
gnunet-dns2gns \
+ $(DO_W32_HELPER) \
$(DO_PROXY)
bin_PROGRAMS = \
$(top_builddir)/src/dns/libgnunetdnsstub.la \
$(GN_LIBINTL)
+if LINUX
+HIJACKBIN = gnunet-dns2gns
+install-exec-hook:
+ $(SUDO_BINARY) setcap 'cap_net_bind_service=+ep' $(DESTDIR)$(libexecdir)/gnunet-dns2gns || true
+else
+install-exec-hook:
+endif
+
gnunet_gns_proxy_SOURCES = \
gnunet-gns-proxy.c
gnunet_gns_proxy_CPPFLAGS = $(AM_CPPFLAGS) $(CPP_GNURL)
/**
* UDP Port we listen on for inbound DNS requests.
*/
-static unsigned int listen_port = 2853;
+static unsigned int listen_port = 53;
/**
* Which GNS zone do we translate incoming DNS requests to?
};
int ret;
- if (GNUNET_OK != GNUNET_STRINGS_get_utf8_args (argc, argv,
- &argc, &argv))
+ if (GNUNET_OK !=
+ GNUNET_STRINGS_get_utf8_args (argc, argv,
+ &argc, &argv))
return 2;
- GNUNET_log_setup ("gnunet-dns2gns", "WARNING", NULL);
+ GNUNET_log_setup ("gnunet-dns2gns",
+ "WARNING",
+ NULL);
ret =
(GNUNET_OK ==
- GNUNET_PROGRAM_run (argc, argv, "gnunet-dns2gns",
+ GNUNET_PROGRAM_run (argc, argv,
+ "gnunet-dns2gns",
_("GNUnet DNS-to-GNS proxy (a DNS server)"),
options,
&run, NULL)) ? 0 : 1;