From: <abe...@us...> - 2014-02-07 21:54:49
|
Revision: 6406 http://sourceforge.net/p/astlinux/code/6406 Author: abelbeck Date: 2014-02-07 21:54:46 +0000 (Fri, 07 Feb 2014) Log Message: ----------- New packages: libsodium and dnscrypt-proxy, both disabled by default. Hooks added to dnsmasq to make it work Modified Paths: -------------- branches/1.0/astlinux-ast11.config branches/1.0/astlinux18.config branches/1.0/initrd.config branches/1.0/package/Config.in branches/1.0/package/dnsmasq/dnsmasq.init branches/1.0/runnix-uclibc.config branches/1.0/runnix.config Added Paths: ----------- branches/1.0/package/dnscrypt-proxy/ branches/1.0/package/dnscrypt-proxy/Config.in branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.init branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.mk branches/1.0/package/libsodium/ branches/1.0/package/libsodium/Config.in branches/1.0/package/libsodium/libsodium.mk Modified: branches/1.0/astlinux-ast11.config =================================================================== --- branches/1.0/astlinux-ast11.config 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/astlinux-ast11.config 2014-02-07 21:54:46 UTC (rev 6406) @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Buildroot 2011.08-svn6398-dirty Configuration -# Mon Feb 3 16:09:22 2014 +# Buildroot 2011.08-svn6405-dirty Configuration +# Fri Feb 7 15:08:32 2014 # BR2_HAVE_DOT_CONFIG=y # BR2_arm is not set @@ -514,6 +514,7 @@ BR2_PACKAGE_OPENSSL_BIN=y BR2_PACKAGE_OPENSSL_ENGINES=y # BR2_PACKAGE_OPENSSL_OCF is not set +# BR2_PACKAGE_LIBSODIUM is not set BR2_PACKAGE_LIBSRTP=y # @@ -672,6 +673,7 @@ # BR2_PACKAGE_CUPS is not set BR2_PACKAGE_DARKSTAT=y BR2_PACKAGE_DHCPDUMP=y +# BR2_PACKAGE_DNSCRYPT_PROXY is not set BR2_PACKAGE_DNSMASQ=y BR2_PACKAGE_DNSMASQ_TFTP=y BR2_PACKAGE_DNSMASQ_DHCP=y Modified: branches/1.0/astlinux18.config =================================================================== --- branches/1.0/astlinux18.config 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/astlinux18.config 2014-02-07 21:54:46 UTC (rev 6406) @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Buildroot 2011.08-svn6398-dirty Configuration -# Mon Feb 3 16:09:18 2014 +# Buildroot 2011.08-svn6405-dirty Configuration +# Fri Feb 7 15:08:28 2014 # BR2_HAVE_DOT_CONFIG=y # BR2_arm is not set @@ -514,6 +514,7 @@ BR2_PACKAGE_OPENSSL_BIN=y BR2_PACKAGE_OPENSSL_ENGINES=y # BR2_PACKAGE_OPENSSL_OCF is not set +# BR2_PACKAGE_LIBSODIUM is not set BR2_PACKAGE_LIBSRTP=y # @@ -672,6 +673,7 @@ # BR2_PACKAGE_CUPS is not set BR2_PACKAGE_DARKSTAT=y BR2_PACKAGE_DHCPDUMP=y +# BR2_PACKAGE_DNSCRYPT_PROXY is not set BR2_PACKAGE_DNSMASQ=y BR2_PACKAGE_DNSMASQ_TFTP=y BR2_PACKAGE_DNSMASQ_DHCP=y Modified: branches/1.0/initrd.config =================================================================== --- branches/1.0/initrd.config 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/initrd.config 2014-02-07 21:54:46 UTC (rev 6406) @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Buildroot 2011.08-svn6398-dirty Configuration -# Mon Feb 3 16:09:36 2014 +# Buildroot 2011.08-svn6405-dirty Configuration +# Fri Feb 7 15:08:43 2014 # BR2_HAVE_DOT_CONFIG=y # BR2_arm is not set @@ -408,6 +408,7 @@ # BR2_PACKAGE_LIBGPG_ERROR is not set # BR2_PACKAGE_LIBNSS is not set # BR2_PACKAGE_OPENSSL is not set +# BR2_PACKAGE_LIBSODIUM is not set # BR2_PACKAGE_LIBSRTP is not set # @@ -551,6 +552,7 @@ # BR2_PACKAGE_CUPS is not set # BR2_PACKAGE_DARKSTAT is not set # BR2_PACKAGE_DHCPDUMP is not set +# BR2_PACKAGE_DNSCRYPT_PROXY is not set # BR2_PACKAGE_DNSMASQ is not set # BR2_PACKAGE_DROPBEAR is not set # BR2_PACKAGE_EBTABLES is not set Modified: branches/1.0/package/Config.in =================================================================== --- branches/1.0/package/Config.in 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/package/Config.in 2014-02-07 21:54:46 UTC (rev 6406) @@ -282,6 +282,7 @@ source "package/libgpg-error/Config.in" source "package/libnss/Config.in" source "package/openssl/Config.in" +source "package/libsodium/Config.in" source "package/libsrtp/Config.in" endmenu @@ -444,6 +445,7 @@ source "package/dhcp/Config.in" endif source "package/dhcpdump/Config.in" +source "package/dnscrypt-proxy/Config.in" source "package/dnsmasq/Config.in" source "package/dropbear/Config.in" source "package/ebtables/Config.in" Added: branches/1.0/package/dnscrypt-proxy/Config.in =================================================================== --- branches/1.0/package/dnscrypt-proxy/Config.in (rev 0) +++ branches/1.0/package/dnscrypt-proxy/Config.in 2014-02-07 21:54:46 UTC (rev 6406) @@ -0,0 +1,11 @@ +config BR2_PACKAGE_DNSCRYPT_PROXY + bool "dnscrypt-proxy" + select BR2_PACKAGE_LIBSODIUM + default n + help + dnscrypt-proxy is a slight variation on DNSCurve. + DNSCurve improves the confidentiality and integrity of DNS requests using + high-speed high-security elliptic-curve cryptography. Best of all, DNSCurve + has very low overhead and adds virtually no latency to queries. + + http://dnscrypt.org/ Added: branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.init =================================================================== --- branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.init (rev 0) +++ branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.init 2014-02-07 21:54:46 UTC (rev 6406) @@ -0,0 +1,58 @@ +#!/bin/sh + +. /etc/rc.conf + +PIDFILE="/var/run/dnscrypt-proxy.pid" + +init () { + : +} + +start () { + + if [ "$DNSCRYPT_PROXY" = "yes" ]; then + echo "Starting dnscrypt..." + + dnscrypt-proxy -d --local-address 127.0.0.1:2053 -n 128 -p $PIDFILE \ + ${DNSCRYPT_SERVER_ADDRESS:+--resolver-address "$DNSCRYPT_SERVER_ADDRESS"} \ + ${DNSCRYPT_PROVIDER_KEY:+--provider-key "$DNSCRYPT_PROVIDER_KEY"} \ + ${DNSCRYPT_PROVIDER_NAME:+--provider-name "$DNSCRYPT_PROVIDER_NAME"} + fi +} + +stop () { + + if [ -f $PIDFILE ]; then + echo "Stopping dnscrypt..." + + kill $(cat $PIDFILE) >/dev/null 2>&1 + fi +} + +case $1 in + +start) + start + ;; + +stop) + stop + ;; + +init) + init + start + ;; + +restart) + stop + sleep 2 + start + ;; + +*) + echo "Usage: start|stop|restart" + ;; + +esac + Added: branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.mk =================================================================== --- branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.mk (rev 0) +++ branches/1.0/package/dnscrypt-proxy/dnscrypt-proxy.mk 2014-02-07 21:54:46 UTC (rev 6406) @@ -0,0 +1,26 @@ +############################################################# +# +# dnscrypt-proxy +# +############################################################# +DNSCRYPT_PROXY_VERSION = 1.3.3 +DNSCRYPT_PROXY_SOURCE = dnscrypt-proxy-$(DNSCRYPT_PROXY_VERSION).tar.gz +DNSCRYPT_PROXY_SITE = http://download.dnscrypt.org/dnscrypt-proxy + +DNSCRYPT_PROXY_DEPENDENCIES += libsodium + +define DNSCRYPT_PROXY_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 $(@D)/src/proxy/dnscrypt-proxy $(TARGET_DIR)/usr/sbin/ + $(INSTALL) -D -m 0755 package/dnscrypt-proxy/dnscrypt-proxy.init $(TARGET_DIR)/etc/init.d/dnscrypt + ln -sf ../../init.d/dnscrypt $(TARGET_DIR)/etc/runlevels/default/S18dnscrypt + ln -sf ../../init.d/dnscrypt $(TARGET_DIR)/etc/runlevels/default/K15dnscrypt +endef + +define DNSCRYPT_PROXY_UNINSTALL_TARGET_CMDS + rm -f $(TARGET_DIR)/usr/sbin/dnscrypt-proxy + rm -f $(TARGET_DIR)/etc/init.d/dnscrypt + rm -f $(TARGET_DIR)/etc/runlevels/default/S18dnscrypt + rm -f $(TARGET_DIR)/etc/runlevels/default/K15dnscrypt +endef + +$(eval $(call AUTOTARGETS,package,dnscrypt-proxy)) Modified: branches/1.0/package/dnsmasq/dnsmasq.init =================================================================== --- branches/1.0/package/dnsmasq/dnsmasq.init 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/package/dnsmasq/dnsmasq.init 2014-02-07 21:54:46 UTC (rev 6406) @@ -4,6 +4,17 @@ . /etc/init.d/functions +dnscrypt_proxy_check() +{ + if [ -f /etc/init.d/dnscrypt ]; then + if [ "$DNSCRYPT_PROXY" = "yes" ]; then + return 0 + fi + fi + + return 1 +} + tftpd_check() { if [ -f /etc/init.d/tftpd ]; then @@ -123,9 +134,15 @@ ${local_domain}local=/$DOMAIN/ expand-hosts domain=$DOMAIN -resolv-file=/etc/resolv-extern.conf cache-size=2048" + if dnscrypt_proxy_check; then + echo "no-resolv +server=127.0.0.1#2053" + else + echo "resolv-file=/etc/resolv-extern.conf" + fi + # TFTP options if tftpd_check; then echo "enable-tftp Added: branches/1.0/package/libsodium/Config.in =================================================================== --- branches/1.0/package/libsodium/Config.in (rev 0) +++ branches/1.0/package/libsodium/Config.in 2014-02-07 21:54:46 UTC (rev 6406) @@ -0,0 +1,8 @@ +config BR2_PACKAGE_LIBSODIUM + bool "libsodium" + default n + help + Sodium is a portable, cross-compilable, installable, packageable + fork of the NaCl Cryptograpy & Networking library, with a compatible API. + + http://github.com/jedisct1/libsodium Added: branches/1.0/package/libsodium/libsodium.mk =================================================================== --- branches/1.0/package/libsodium/libsodium.mk (rev 0) +++ branches/1.0/package/libsodium/libsodium.mk 2014-02-07 21:54:46 UTC (rev 6406) @@ -0,0 +1,20 @@ +############################################################# +# +# libsodium +# +############################################################# +LIBSODIUM_VERSION = 0.4.5 +LIBSODIUM_SOURCE = libsodium-$(LIBSODIUM_VERSION).tar.gz +LIBSODIUM_SITE = http://github.com/jedisct1/libsodium/releases/download/$(LIBSODIUM_VERSION) + +LIBSODIUM_INSTALL_STAGING = YES + +define LIBSODIUM_INSTALL_TARGET_CMDS + cp -a $(STAGING_DIR)/usr/lib/libsodium.so* $(TARGET_DIR)/usr/lib/ +endef + +define LIBSODIUM_UNINSTALL_TARGET_CMDS + rm -f $(TARGET_DIR)/usr/lib/libsodium.so* +endef + +$(eval $(call AUTOTARGETS,package,libsodium)) Modified: branches/1.0/runnix-uclibc.config =================================================================== --- branches/1.0/runnix-uclibc.config 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/runnix-uclibc.config 2014-02-07 21:54:46 UTC (rev 6406) @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Buildroot 2011.08-svn6398-dirty Configuration -# Mon Feb 3 16:09:32 2014 +# Buildroot 2011.08-svn6405-dirty Configuration +# Fri Feb 7 15:08:40 2014 # BR2_HAVE_DOT_CONFIG=y # BR2_arm is not set @@ -625,6 +625,7 @@ # libnss requires a toolchain with LARGEFILE support # # BR2_PACKAGE_OPENSSL is not set +# BR2_PACKAGE_LIBSODIUM is not set # BR2_PACKAGE_LIBSRTP is not set # @@ -843,6 +844,7 @@ # BR2_PACKAGE_DARKSTAT is not set # BR2_PACKAGE_DHCP is not set # BR2_PACKAGE_DHCPDUMP is not set +# BR2_PACKAGE_DNSCRYPT_PROXY is not set # BR2_PACKAGE_DNSMASQ is not set BR2_PACKAGE_DROPBEAR=y # BR2_PACKAGE_DROPBEAR_DISABLE_REVERSEDNS is not set Modified: branches/1.0/runnix.config =================================================================== --- branches/1.0/runnix.config 2014-02-04 19:42:00 UTC (rev 6405) +++ branches/1.0/runnix.config 2014-02-07 21:54:46 UTC (rev 6406) @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Buildroot 2011.08-svn6398-dirty Configuration -# Mon Feb 3 16:09:30 2014 +# Buildroot 2011.08-svn6405-dirty Configuration +# Fri Feb 7 15:08:37 2014 # BR2_HAVE_DOT_CONFIG=y # BR2_arm is not set @@ -434,6 +434,7 @@ # BR2_PACKAGE_LIBGPG_ERROR is not set # BR2_PACKAGE_LIBNSS is not set # BR2_PACKAGE_OPENSSL is not set +# BR2_PACKAGE_LIBSODIUM is not set # BR2_PACKAGE_LIBSRTP is not set # @@ -582,6 +583,7 @@ # BR2_PACKAGE_DARKSTAT is not set # BR2_PACKAGE_DHCP is not set # BR2_PACKAGE_DHCPDUMP is not set +# BR2_PACKAGE_DNSCRYPT_PROXY is not set # BR2_PACKAGE_DNSMASQ is not set BR2_PACKAGE_DROPBEAR=y # BR2_PACKAGE_DROPBEAR_DISABLE_REVERSEDNS is not set This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |