Browse Source

net/safe-search: new package

This package forces the use of Google and Bing safe search by default.
It does this by adding hosts files for dnsmasq to use. These hosts replace the
normal IP addresses for Google and Bing with addresses that force safe
search to be turned on all the time.

Google and Bing Safe Search are suitable for most businesses, schools, and
families who wish to block adult content. This package also offers
YouTube's restricted and 'restricted moderate' via a configuration
option. The reason that this is not enabled is that it is probably more
suitable for children rather than a wide audience.

This package is designed so that other services that offer safe search can be
added easily in the future.

For more information about safe search please visit these URLs:
- https://support.google.com/websearch/answer/186669
- https://help.bing.microsoft.com/#apex/18/en-US/10003/0
- https://support.google.com/a/answer/6212415

Signed-off-by: Gregory L. Dietsche <gregory.dietsche@cuw.edu>
lilik-openwrt-22.03
Gregory L. Dietsche 6 years ago
committed by Yousong Zhou
parent
commit
ed6c58b84d
9 changed files with 993 additions and 0 deletions
  1. +73
    -0
      net/safe-search/Makefile
  2. +19
    -0
      net/safe-search/Readme.md
  3. +14
    -0
      net/safe-search/files/hosts/bing.default
  4. +785
    -0
      net/safe-search/files/hosts/google.default
  5. +25
    -0
      net/safe-search/files/hosts/youtube.restrict
  6. +25
    -0
      net/safe-search/files/hosts/youtube.restrictmoderate
  7. +23
    -0
      net/safe-search/files/safe-search-update
  8. +17
    -0
      net/safe-search/files/safe-search.conf
  9. +12
    -0
      net/safe-search/files/safe-search.defaults

+ 73
- 0
net/safe-search/Makefile View File

@ -0,0 +1,73 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
include $(TOPDIR)/rules.mk
PKG_NAME:=safe-search
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
PKG_LICENSE:=MIT
PKG_MAINTAINER:=Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
include $(INCLUDE_DIR)/package.mk
define Package/safe-search
SECTION:=net
CATEGORY:=Network
TITLE:=Safe Search
PKGARCH:=all
endef
define Package/safe-search/description
This package prevents adult content from appearing in search results by
configuring dnsmasq to force all devices on your network to use Google and
Bing's Safe Search IP addresses. This is designed to be approperiate for most
businesses and families. The default filtering rules do not interfere with
normal web browsing.
endef
define Package/safe-search/conffiles
/etc/config/safe-search
endef
define Build/Compile
endef
define Package/safe-search/install
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(CP) ./files/safe-search.defaults $(1)/etc/uci-defaults/safe-search
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_CONF) ./files/safe-search.conf $(1)/etc/config/safe-search
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) ./files/safe-search-update $(1)/usr/sbin/safe-search-update
$(INSTALL_DIR) $(1)/etc/safe-search/enabled
$(INSTALL_DIR) $(1)/etc/safe-search/available
$(INSTALL_DATA) ./files/hosts/* $(1)/etc/safe-search/available/
endef
define Package/safe-search/prerm
#!/bin/sh
if [ -z "$${IPGK_INSTROOT}" ]; then
uci del_list dhcp.@dnsmasq[0].addnhosts=/etc/safe-search/enabled
uci commit dhcp
/etc/init.d/dnsmasq reload
fi
exit 0
endef
define Package/safe-search/postrm
#!/bin/sh
if [ -z "$${IPGK_INSTROOT}" ]; then
rm -rf /etc/safe-search/enabled
rmdir /etc/safe-search/available
rmdir /etc/safe-search/
fi
exit 0
endef
$(eval $(call BuildPackage,safe-search))

+ 19
- 0
net/safe-search/Readme.md View File

@ -0,0 +1,19 @@
# Package: net/safe-search
This package prevents adult content from appearing in search results by
configuring dnsmasq to force all devices on your network to use Google and
Bing's Safe Search IP addresses. This is designed to be approperiate for most
businesses and families. The default filtering rules do not interfere with
normal web browsing.
Currently supported:
- Google Safe Search - enabled by default
- https://support.google.com/websearch/answer/186669
- Bing Safe Search - enabled by default
- https://help.bing.microsoft.com/#apex/18/en-US/10003/0
- youtube Safe Search
- https://support.google.com/a/answer/6214622
- https://support.google.com/a/answer/6212415
- https://www.youtube.com/check_content_restrictions
- Not enabled by default because it is designed for children.
- Enable by editing /etc/config/safe-search and then run safe-search-update

+ 14
- 0
net/safe-search/files/hosts/bing.default View File

@ -0,0 +1,14 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
#
# IMPORTANT: if this file is not working, make sure that dnsmasq is able to READ it!
#
#204.79.197.220 strict.bing.com
#::FFFF:CC4F:C5DC strict.bing.com
204.79.197.220 bing.com www.bing.com
::FFFF:CC4F:C5DC bing.com www.bing.com

+ 785
- 0
net/safe-search/files/hosts/google.default View File

@ -0,0 +1,785 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
# IMPORTANT: if this file is not working, make sure that dnsmasq is able to READ it!
#
# Google Safe Search Host List
# Generated on Wed Oct 10 10:18:34 CDT 2018
# From: https://www.google.com/supported_domains
#2001:4860:4802:32::78 forcesafesearch.google.com
#216.239.38.120 forcesafesearch.google.com
2001:4860:4802:32::78 google.com
2001:4860:4802:32::78 google.ad
2001:4860:4802:32::78 google.ae
2001:4860:4802:32::78 google.com.af
2001:4860:4802:32::78 google.com.ag
2001:4860:4802:32::78 google.com.ai
2001:4860:4802:32::78 google.al
2001:4860:4802:32::78 google.am
2001:4860:4802:32::78 google.co.ao
2001:4860:4802:32::78 google.com.ar
2001:4860:4802:32::78 google.as
2001:4860:4802:32::78 google.at
2001:4860:4802:32::78 google.com.au
2001:4860:4802:32::78 google.az
2001:4860:4802:32::78 google.ba
2001:4860:4802:32::78 google.com.bd
2001:4860:4802:32::78 google.be
2001:4860:4802:32::78 google.bf
2001:4860:4802:32::78 google.bg
2001:4860:4802:32::78 google.com.bh
2001:4860:4802:32::78 google.bi
2001:4860:4802:32::78 google.bj
2001:4860:4802:32::78 google.com.bn
2001:4860:4802:32::78 google.com.bo
2001:4860:4802:32::78 google.com.br
2001:4860:4802:32::78 google.bs
2001:4860:4802:32::78 google.bt
2001:4860:4802:32::78 google.co.bw
2001:4860:4802:32::78 google.by
2001:4860:4802:32::78 google.com.bz
2001:4860:4802:32::78 google.ca
2001:4860:4802:32::78 google.cd
2001:4860:4802:32::78 google.cf
2001:4860:4802:32::78 google.cg
2001:4860:4802:32::78 google.ch
2001:4860:4802:32::78 google.ci
2001:4860:4802:32::78 google.co.ck
2001:4860:4802:32::78 google.cl
2001:4860:4802:32::78 google.cm
2001:4860:4802:32::78 google.cn
2001:4860:4802:32::78 google.com.co
2001:4860:4802:32::78 google.co.cr
2001:4860:4802:32::78 google.com.cu
2001:4860:4802:32::78 google.cv
2001:4860:4802:32::78 google.com.cy
2001:4860:4802:32::78 google.cz
2001:4860:4802:32::78 google.de
2001:4860:4802:32::78 google.dj
2001:4860:4802:32::78 google.dk
2001:4860:4802:32::78 google.dm
2001:4860:4802:32::78 google.com.do
2001:4860:4802:32::78 google.dz
2001:4860:4802:32::78 google.com.ec
2001:4860:4802:32::78 google.ee
2001:4860:4802:32::78 google.com.eg
2001:4860:4802:32::78 google.es
2001:4860:4802:32::78 google.com.et
2001:4860:4802:32::78 google.fi
2001:4860:4802:32::78 google.com.fj
2001:4860:4802:32::78 google.fm
2001:4860:4802:32::78 google.fr
2001:4860:4802:32::78 google.ga
2001:4860:4802:32::78 google.ge
2001:4860:4802:32::78 google.gg
2001:4860:4802:32::78 google.com.gh
2001:4860:4802:32::78 google.com.gi
2001:4860:4802:32::78 google.gl
2001:4860:4802:32::78 google.gm
2001:4860:4802:32::78 google.gp
2001:4860:4802:32::78 google.gr
2001:4860:4802:32::78 google.com.gt
2001:4860:4802:32::78 google.gy
2001:4860:4802:32::78 google.com.hk
2001:4860:4802:32::78 google.hn
2001:4860:4802:32::78 google.hr
2001:4860:4802:32::78 google.ht
2001:4860:4802:32::78 google.hu
2001:4860:4802:32::78 google.co.id
2001:4860:4802:32::78 google.ie
2001:4860:4802:32::78 google.co.il
2001:4860:4802:32::78 google.im
2001:4860:4802:32::78 google.co.in
2001:4860:4802:32::78 google.iq
2001:4860:4802:32::78 google.is
2001:4860:4802:32::78 google.it
2001:4860:4802:32::78 google.je
2001:4860:4802:32::78 google.com.jm
2001:4860:4802:32::78 google.jo
2001:4860:4802:32::78 google.co.jp
2001:4860:4802:32::78 google.co.ke
2001:4860:4802:32::78 google.com.kh
2001:4860:4802:32::78 google.ki
2001:4860:4802:32::78 google.kg
2001:4860:4802:32::78 google.co.kr
2001:4860:4802:32::78 google.com.kw
2001:4860:4802:32::78 google.kz
2001:4860:4802:32::78 google.la
2001:4860:4802:32::78 google.com.lb
2001:4860:4802:32::78 google.li
2001:4860:4802:32::78 google.lk
2001:4860:4802:32::78 google.co.ls
2001:4860:4802:32::78 google.lt
2001:4860:4802:32::78 google.lu
2001:4860:4802:32::78 google.lv
2001:4860:4802:32::78 google.com.ly
2001:4860:4802:32::78 google.co.ma
2001:4860:4802:32::78 google.md
2001:4860:4802:32::78 google.me
2001:4860:4802:32::78 google.mg
2001:4860:4802:32::78 google.mk
2001:4860:4802:32::78 google.ml
2001:4860:4802:32::78 google.com.mm
2001:4860:4802:32::78 google.mn
2001:4860:4802:32::78 google.ms
2001:4860:4802:32::78 google.com.mt
2001:4860:4802:32::78 google.mu
2001:4860:4802:32::78 google.mv
2001:4860:4802:32::78 google.mw
2001:4860:4802:32::78 google.com.mx
2001:4860:4802:32::78 google.com.my
2001:4860:4802:32::78 google.co.mz
2001:4860:4802:32::78 google.com.na
2001:4860:4802:32::78 google.com.nf
2001:4860:4802:32::78 google.com.ng
2001:4860:4802:32::78 google.com.ni
2001:4860:4802:32::78 google.ne
2001:4860:4802:32::78 google.nl
2001:4860:4802:32::78 google.no
2001:4860:4802:32::78 google.com.np
2001:4860:4802:32::78 google.nr
2001:4860:4802:32::78 google.nu
2001:4860:4802:32::78 google.co.nz
2001:4860:4802:32::78 google.com.om
2001:4860:4802:32::78 google.com.pa
2001:4860:4802:32::78 google.com.pe
2001:4860:4802:32::78 google.com.pg
2001:4860:4802:32::78 google.com.ph
2001:4860:4802:32::78 google.com.pk
2001:4860:4802:32::78 google.pl
2001:4860:4802:32::78 google.pn
2001:4860:4802:32::78 google.com.pr
2001:4860:4802:32::78 google.ps
2001:4860:4802:32::78 google.pt
2001:4860:4802:32::78 google.com.py
2001:4860:4802:32::78 google.com.qa
2001:4860:4802:32::78 google.ro
2001:4860:4802:32::78 google.ru
2001:4860:4802:32::78 google.rw
2001:4860:4802:32::78 google.com.sa
2001:4860:4802:32::78 google.com.sb
2001:4860:4802:32::78 google.sc
2001:4860:4802:32::78 google.se
2001:4860:4802:32::78 google.com.sg
2001:4860:4802:32::78 google.sh
2001:4860:4802:32::78 google.si
2001:4860:4802:32::78 google.sk
2001:4860:4802:32::78 google.com.sl
2001:4860:4802:32::78 google.sn
2001:4860:4802:32::78 google.so
2001:4860:4802:32::78 google.sm
2001:4860:4802:32::78 google.sr
2001:4860:4802:32::78 google.st
2001:4860:4802:32::78 google.com.sv
2001:4860:4802:32::78 google.td
2001:4860:4802:32::78 google.tg
2001:4860:4802:32::78 google.co.th
2001:4860:4802:32::78 google.com.tj
2001:4860:4802:32::78 google.tk
2001:4860:4802:32::78 google.tl
2001:4860:4802:32::78 google.tm
2001:4860:4802:32::78 google.tn
2001:4860:4802:32::78 google.to
2001:4860:4802:32::78 google.com.tr
2001:4860:4802:32::78 google.tt
2001:4860:4802:32::78 google.com.tw
2001:4860:4802:32::78 google.co.tz
2001:4860:4802:32::78 google.com.ua
2001:4860:4802:32::78 google.co.ug
2001:4860:4802:32::78 google.co.uk
2001:4860:4802:32::78 google.com.uy
2001:4860:4802:32::78 google.co.uz
2001:4860:4802:32::78 google.com.vc
2001:4860:4802:32::78 google.co.ve
2001:4860:4802:32::78 google.vg
2001:4860:4802:32::78 google.co.vi
2001:4860:4802:32::78 google.com.vn
2001:4860:4802:32::78 google.vu
2001:4860:4802:32::78 google.ws
2001:4860:4802:32::78 google.rs
2001:4860:4802:32::78 google.co.za
2001:4860:4802:32::78 google.co.zm
2001:4860:4802:32::78 google.co.zw
2001:4860:4802:32::78 google.cat
2001:4860:4802:32::78 www.google.com
2001:4860:4802:32::78 www.google.ad
2001:4860:4802:32::78 www.google.ae
2001:4860:4802:32::78 www.google.com.af
2001:4860:4802:32::78 www.google.com.ag
2001:4860:4802:32::78 www.google.com.ai
2001:4860:4802:32::78 www.google.al
2001:4860:4802:32::78 www.google.am
2001:4860:4802:32::78 www.google.co.ao
2001:4860:4802:32::78 www.google.com.ar
2001:4860:4802:32::78 www.google.as
2001:4860:4802:32::78 www.google.at
2001:4860:4802:32::78 www.google.com.au
2001:4860:4802:32::78 www.google.az
2001:4860:4802:32::78 www.google.ba
2001:4860:4802:32::78 www.google.com.bd
2001:4860:4802:32::78 www.google.be
2001:4860:4802:32::78 www.google.bf
2001:4860:4802:32::78 www.google.bg
2001:4860:4802:32::78 www.google.com.bh
2001:4860:4802:32::78 www.google.bi
2001:4860:4802:32::78 www.google.bj
2001:4860:4802:32::78 www.google.com.bn
2001:4860:4802:32::78 www.google.com.bo
2001:4860:4802:32::78 www.google.com.br
2001:4860:4802:32::78 www.google.bs
2001:4860:4802:32::78 www.google.bt
2001:4860:4802:32::78 www.google.co.bw
2001:4860:4802:32::78 www.google.by
2001:4860:4802:32::78 www.google.com.bz
2001:4860:4802:32::78 www.google.ca
2001:4860:4802:32::78 www.google.cd
2001:4860:4802:32::78 www.google.cf
2001:4860:4802:32::78 www.google.cg
2001:4860:4802:32::78 www.google.ch
2001:4860:4802:32::78 www.google.ci
2001:4860:4802:32::78 www.google.co.ck
2001:4860:4802:32::78 www.google.cl
2001:4860:4802:32::78 www.google.cm
2001:4860:4802:32::78 www.google.cn
2001:4860:4802:32::78 www.google.com.co
2001:4860:4802:32::78 www.google.co.cr
2001:4860:4802:32::78 www.google.com.cu
2001:4860:4802:32::78 www.google.cv
2001:4860:4802:32::78 www.google.com.cy
2001:4860:4802:32::78 www.google.cz
2001:4860:4802:32::78 www.google.de
2001:4860:4802:32::78 www.google.dj
2001:4860:4802:32::78 www.google.dk
2001:4860:4802:32::78 www.google.dm
2001:4860:4802:32::78 www.google.com.do
2001:4860:4802:32::78 www.google.dz
2001:4860:4802:32::78 www.google.com.ec
2001:4860:4802:32::78 www.google.ee
2001:4860:4802:32::78 www.google.com.eg
2001:4860:4802:32::78 www.google.es
2001:4860:4802:32::78 www.google.com.et
2001:4860:4802:32::78 www.google.fi
2001:4860:4802:32::78 www.google.com.fj
2001:4860:4802:32::78 www.google.fm
2001:4860:4802:32::78 www.google.fr
2001:4860:4802:32::78 www.google.ga
2001:4860:4802:32::78 www.google.ge
2001:4860:4802:32::78 www.google.gg
2001:4860:4802:32::78 www.google.com.gh
2001:4860:4802:32::78 www.google.com.gi
2001:4860:4802:32::78 www.google.gl
2001:4860:4802:32::78 www.google.gm
2001:4860:4802:32::78 www.google.gp
2001:4860:4802:32::78 www.google.gr
2001:4860:4802:32::78 www.google.com.gt
2001:4860:4802:32::78 www.google.gy
2001:4860:4802:32::78 www.google.com.hk
2001:4860:4802:32::78 www.google.hn
2001:4860:4802:32::78 www.google.hr
2001:4860:4802:32::78 www.google.ht
2001:4860:4802:32::78 www.google.hu
2001:4860:4802:32::78 www.google.co.id
2001:4860:4802:32::78 www.google.ie
2001:4860:4802:32::78 www.google.co.il
2001:4860:4802:32::78 www.google.im
2001:4860:4802:32::78 www.google.co.in
2001:4860:4802:32::78 www.google.iq
2001:4860:4802:32::78 www.google.is
2001:4860:4802:32::78 www.google.it
2001:4860:4802:32::78 www.google.je
2001:4860:4802:32::78 www.google.com.jm
2001:4860:4802:32::78 www.google.jo
2001:4860:4802:32::78 www.google.co.jp
2001:4860:4802:32::78 www.google.co.ke
2001:4860:4802:32::78 www.google.com.kh
2001:4860:4802:32::78 www.google.ki
2001:4860:4802:32::78 www.google.kg
2001:4860:4802:32::78 www.google.co.kr
2001:4860:4802:32::78 www.google.com.kw
2001:4860:4802:32::78 www.google.kz
2001:4860:4802:32::78 www.google.la
2001:4860:4802:32::78 www.google.com.lb
2001:4860:4802:32::78 www.google.li
2001:4860:4802:32::78 www.google.lk
2001:4860:4802:32::78 www.google.co.ls
2001:4860:4802:32::78 www.google.lt
2001:4860:4802:32::78 www.google.lu
2001:4860:4802:32::78 www.google.lv
2001:4860:4802:32::78 www.google.com.ly
2001:4860:4802:32::78 www.google.co.ma
2001:4860:4802:32::78 www.google.md
2001:4860:4802:32::78 www.google.me
2001:4860:4802:32::78 www.google.mg
2001:4860:4802:32::78 www.google.mk
2001:4860:4802:32::78 www.google.ml
2001:4860:4802:32::78 www.google.com.mm
2001:4860:4802:32::78 www.google.mn
2001:4860:4802:32::78 www.google.ms
2001:4860:4802:32::78 www.google.com.mt
2001:4860:4802:32::78 www.google.mu
2001:4860:4802:32::78 www.google.mv
2001:4860:4802:32::78 www.google.mw
2001:4860:4802:32::78 www.google.com.mx
2001:4860:4802:32::78 www.google.com.my
2001:4860:4802:32::78 www.google.co.mz
2001:4860:4802:32::78 www.google.com.na
2001:4860:4802:32::78 www.google.com.nf
2001:4860:4802:32::78 www.google.com.ng
2001:4860:4802:32::78 www.google.com.ni
2001:4860:4802:32::78 www.google.ne
2001:4860:4802:32::78 www.google.nl
2001:4860:4802:32::78 www.google.no
2001:4860:4802:32::78 www.google.com.np
2001:4860:4802:32::78 www.google.nr
2001:4860:4802:32::78 www.google.nu
2001:4860:4802:32::78 www.google.co.nz
2001:4860:4802:32::78 www.google.com.om
2001:4860:4802:32::78 www.google.com.pa
2001:4860:4802:32::78 www.google.com.pe
2001:4860:4802:32::78 www.google.com.pg
2001:4860:4802:32::78 www.google.com.ph
2001:4860:4802:32::78 www.google.com.pk
2001:4860:4802:32::78 www.google.pl
2001:4860:4802:32::78 www.google.pn
2001:4860:4802:32::78 www.google.com.pr
2001:4860:4802:32::78 www.google.ps
2001:4860:4802:32::78 www.google.pt
2001:4860:4802:32::78 www.google.com.py
2001:4860:4802:32::78 www.google.com.qa
2001:4860:4802:32::78 www.google.ro
2001:4860:4802:32::78 www.google.ru
2001:4860:4802:32::78 www.google.rw
2001:4860:4802:32::78 www.google.com.sa
2001:4860:4802:32::78 www.google.com.sb
2001:4860:4802:32::78 www.google.sc
2001:4860:4802:32::78 www.google.se
2001:4860:4802:32::78 www.google.com.sg
2001:4860:4802:32::78 www.google.sh
2001:4860:4802:32::78 www.google.si
2001:4860:4802:32::78 www.google.sk
2001:4860:4802:32::78 www.google.com.sl
2001:4860:4802:32::78 www.google.sn
2001:4860:4802:32::78 www.google.so
2001:4860:4802:32::78 www.google.sm
2001:4860:4802:32::78 www.google.sr
2001:4860:4802:32::78 www.google.st
2001:4860:4802:32::78 www.google.com.sv
2001:4860:4802:32::78 www.google.td
2001:4860:4802:32::78 www.google.tg
2001:4860:4802:32::78 www.google.co.th
2001:4860:4802:32::78 www.google.com.tj
2001:4860:4802:32::78 www.google.tk
2001:4860:4802:32::78 www.google.tl
2001:4860:4802:32::78 www.google.tm
2001:4860:4802:32::78 www.google.tn
2001:4860:4802:32::78 www.google.to
2001:4860:4802:32::78 www.google.com.tr
2001:4860:4802:32::78 www.google.tt
2001:4860:4802:32::78 www.google.com.tw
2001:4860:4802:32::78 www.google.co.tz
2001:4860:4802:32::78 www.google.com.ua
2001:4860:4802:32::78 www.google.co.ug
2001:4860:4802:32::78 www.google.co.uk
2001:4860:4802:32::78 www.google.com.uy
2001:4860:4802:32::78 www.google.co.uz
2001:4860:4802:32::78 www.google.com.vc
2001:4860:4802:32::78 www.google.co.ve
2001:4860:4802:32::78 www.google.vg
2001:4860:4802:32::78 www.google.co.vi
2001:4860:4802:32::78 www.google.com.vn
2001:4860:4802:32::78 www.google.vu
2001:4860:4802:32::78 www.google.ws
2001:4860:4802:32::78 www.google.rs
2001:4860:4802:32::78 www.google.co.za
2001:4860:4802:32::78 www.google.co.zm
2001:4860:4802:32::78 www.google.co.zw
2001:4860:4802:32::78 www.google.cat
216.239.38.120 google.com
216.239.38.120 google.ad
216.239.38.120 google.ae
216.239.38.120 google.com.af
216.239.38.120 google.com.ag
216.239.38.120 google.com.ai
216.239.38.120 google.al
216.239.38.120 google.am
216.239.38.120 google.co.ao
216.239.38.120 google.com.ar
216.239.38.120 google.as
216.239.38.120 google.at
216.239.38.120 google.com.au
216.239.38.120 google.az
216.239.38.120 google.ba
216.239.38.120 google.com.bd
216.239.38.120 google.be
216.239.38.120 google.bf
216.239.38.120 google.bg
216.239.38.120 google.com.bh
216.239.38.120 google.bi
216.239.38.120 google.bj
216.239.38.120 google.com.bn
216.239.38.120 google.com.bo
216.239.38.120 google.com.br
216.239.38.120 google.bs
216.239.38.120 google.bt
216.239.38.120 google.co.bw
216.239.38.120 google.by
216.239.38.120 google.com.bz
216.239.38.120 google.ca
216.239.38.120 google.cd
216.239.38.120 google.cf
216.239.38.120 google.cg
216.239.38.120 google.ch
216.239.38.120 google.ci
216.239.38.120 google.co.ck
216.239.38.120 google.cl
216.239.38.120 google.cm
216.239.38.120 google.cn
216.239.38.120 google.com.co
216.239.38.120 google.co.cr
216.239.38.120 google.com.cu
216.239.38.120 google.cv
216.239.38.120 google.com.cy
216.239.38.120 google.cz
216.239.38.120 google.de
216.239.38.120 google.dj
216.239.38.120 google.dk
216.239.38.120 google.dm
216.239.38.120 google.com.do
216.239.38.120 google.dz
216.239.38.120 google.com.ec
216.239.38.120 google.ee
216.239.38.120 google.com.eg
216.239.38.120 google.es
216.239.38.120 google.com.et
216.239.38.120 google.fi
216.239.38.120 google.com.fj
216.239.38.120 google.fm
216.239.38.120 google.fr
216.239.38.120 google.ga
216.239.38.120 google.ge
216.239.38.120 google.gg
216.239.38.120 google.com.gh
216.239.38.120 google.com.gi
216.239.38.120 google.gl
216.239.38.120 google.gm
216.239.38.120 google.gp
216.239.38.120 google.gr
216.239.38.120 google.com.gt
216.239.38.120 google.gy
216.239.38.120 google.com.hk
216.239.38.120 google.hn
216.239.38.120 google.hr
216.239.38.120 google.ht
216.239.38.120 google.hu
216.239.38.120 google.co.id
216.239.38.120 google.ie
216.239.38.120 google.co.il
216.239.38.120 google.im
216.239.38.120 google.co.in
216.239.38.120 google.iq
216.239.38.120 google.is
216.239.38.120 google.it
216.239.38.120 google.je
216.239.38.120 google.com.jm
216.239.38.120 google.jo
216.239.38.120 google.co.jp
216.239.38.120 google.co.ke
216.239.38.120 google.com.kh
216.239.38.120 google.ki
216.239.38.120 google.kg
216.239.38.120 google.co.kr
216.239.38.120 google.com.kw
216.239.38.120 google.kz
216.239.38.120 google.la
216.239.38.120 google.com.lb
216.239.38.120 google.li
216.239.38.120 google.lk
216.239.38.120 google.co.ls
216.239.38.120 google.lt
216.239.38.120 google.lu
216.239.38.120 google.lv
216.239.38.120 google.com.ly
216.239.38.120 google.co.ma
216.239.38.120 google.md
216.239.38.120 google.me
216.239.38.120 google.mg
216.239.38.120 google.mk
216.239.38.120 google.ml
216.239.38.120 google.com.mm
216.239.38.120 google.mn
216.239.38.120 google.ms
216.239.38.120 google.com.mt
216.239.38.120 google.mu
216.239.38.120 google.mv
216.239.38.120 google.mw
216.239.38.120 google.com.mx
216.239.38.120 google.com.my
216.239.38.120 google.co.mz
216.239.38.120 google.com.na
216.239.38.120 google.com.nf
216.239.38.120 google.com.ng
216.239.38.120 google.com.ni
216.239.38.120 google.ne
216.239.38.120 google.nl
216.239.38.120 google.no
216.239.38.120 google.com.np
216.239.38.120 google.nr
216.239.38.120 google.nu
216.239.38.120 google.co.nz
216.239.38.120 google.com.om
216.239.38.120 google.com.pa
216.239.38.120 google.com.pe
216.239.38.120 google.com.pg
216.239.38.120 google.com.ph
216.239.38.120 google.com.pk
216.239.38.120 google.pl
216.239.38.120 google.pn
216.239.38.120 google.com.pr
216.239.38.120 google.ps
216.239.38.120 google.pt
216.239.38.120 google.com.py
216.239.38.120 google.com.qa
216.239.38.120 google.ro
216.239.38.120 google.ru
216.239.38.120 google.rw
216.239.38.120 google.com.sa
216.239.38.120 google.com.sb
216.239.38.120 google.sc
216.239.38.120 google.se
216.239.38.120 google.com.sg
216.239.38.120 google.sh
216.239.38.120 google.si
216.239.38.120 google.sk
216.239.38.120 google.com.sl
216.239.38.120 google.sn
216.239.38.120 google.so
216.239.38.120 google.sm
216.239.38.120 google.sr
216.239.38.120 google.st
216.239.38.120 google.com.sv
216.239.38.120 google.td
216.239.38.120 google.tg
216.239.38.120 google.co.th
216.239.38.120 google.com.tj
216.239.38.120 google.tk
216.239.38.120 google.tl
216.239.38.120 google.tm
216.239.38.120 google.tn
216.239.38.120 google.to
216.239.38.120 google.com.tr
216.239.38.120 google.tt
216.239.38.120 google.com.tw
216.239.38.120 google.co.tz
216.239.38.120 google.com.ua
216.239.38.120 google.co.ug
216.239.38.120 google.co.uk
216.239.38.120 google.com.uy
216.239.38.120 google.co.uz
216.239.38.120 google.com.vc
216.239.38.120 google.co.ve
216.239.38.120 google.vg
216.239.38.120 google.co.vi
216.239.38.120 google.com.vn
216.239.38.120 google.vu
216.239.38.120 google.ws
216.239.38.120 google.rs
216.239.38.120 google.co.za
216.239.38.120 google.co.zm
216.239.38.120 google.co.zw
216.239.38.120 google.cat
216.239.38.120 www.google.com
216.239.38.120 www.google.ad
216.239.38.120 www.google.ae
216.239.38.120 www.google.com.af
216.239.38.120 www.google.com.ag
216.239.38.120 www.google.com.ai
216.239.38.120 www.google.al
216.239.38.120 www.google.am
216.239.38.120 www.google.co.ao
216.239.38.120 www.google.com.ar
216.239.38.120 www.google.as
216.239.38.120 www.google.at
216.239.38.120 www.google.com.au
216.239.38.120 www.google.az
216.239.38.120 www.google.ba
216.239.38.120 www.google.com.bd
216.239.38.120 www.google.be
216.239.38.120 www.google.bf
216.239.38.120 www.google.bg
216.239.38.120 www.google.com.bh
216.239.38.120 www.google.bi
216.239.38.120 www.google.bj
216.239.38.120 www.google.com.bn
216.239.38.120 www.google.com.bo
216.239.38.120 www.google.com.br
216.239.38.120 www.google.bs
216.239.38.120 www.google.bt
216.239.38.120 www.google.co.bw
216.239.38.120 www.google.by
216.239.38.120 www.google.com.bz
216.239.38.120 www.google.ca
216.239.38.120 www.google.cd
216.239.38.120 www.google.cf
216.239.38.120 www.google.cg
216.239.38.120 www.google.ch
216.239.38.120 www.google.ci
216.239.38.120 www.google.co.ck
216.239.38.120 www.google.cl
216.239.38.120 www.google.cm
216.239.38.120 www.google.cn
216.239.38.120 www.google.com.co
216.239.38.120 www.google.co.cr
216.239.38.120 www.google.com.cu
216.239.38.120 www.google.cv
216.239.38.120 www.google.com.cy
216.239.38.120 www.google.cz
216.239.38.120 www.google.de
216.239.38.120 www.google.dj
216.239.38.120 www.google.dk
216.239.38.120 www.google.dm
216.239.38.120 www.google.com.do
216.239.38.120 www.google.dz
216.239.38.120 www.google.com.ec
216.239.38.120 www.google.ee
216.239.38.120 www.google.com.eg
216.239.38.120 www.google.es
216.239.38.120 www.google.com.et
216.239.38.120 www.google.fi
216.239.38.120 www.google.com.fj
216.239.38.120 www.google.fm
216.239.38.120 www.google.fr
216.239.38.120 www.google.ga
216.239.38.120 www.google.ge
216.239.38.120 www.google.gg
216.239.38.120 www.google.com.gh
216.239.38.120 www.google.com.gi
216.239.38.120 www.google.gl
216.239.38.120 www.google.gm
216.239.38.120 www.google.gp
216.239.38.120 www.google.gr
216.239.38.120 www.google.com.gt
216.239.38.120 www.google.gy
216.239.38.120 www.google.com.hk
216.239.38.120 www.google.hn
216.239.38.120 www.google.hr
216.239.38.120 www.google.ht
216.239.38.120 www.google.hu
216.239.38.120 www.google.co.id
216.239.38.120 www.google.ie
216.239.38.120 www.google.co.il
216.239.38.120 www.google.im
216.239.38.120 www.google.co.in
216.239.38.120 www.google.iq
216.239.38.120 www.google.is
216.239.38.120 www.google.it
216.239.38.120 www.google.je
216.239.38.120 www.google.com.jm
216.239.38.120 www.google.jo
216.239.38.120 www.google.co.jp
216.239.38.120 www.google.co.ke
216.239.38.120 www.google.com.kh
216.239.38.120 www.google.ki
216.239.38.120 www.google.kg
216.239.38.120 www.google.co.kr
216.239.38.120 www.google.com.kw
216.239.38.120 www.google.kz
216.239.38.120 www.google.la
216.239.38.120 www.google.com.lb
216.239.38.120 www.google.li
216.239.38.120 www.google.lk
216.239.38.120 www.google.co.ls
216.239.38.120 www.google.lt
216.239.38.120 www.google.lu
216.239.38.120 www.google.lv
216.239.38.120 www.google.com.ly
216.239.38.120 www.google.co.ma
216.239.38.120 www.google.md
216.239.38.120 www.google.me
216.239.38.120 www.google.mg
216.239.38.120 www.google.mk
216.239.38.120 www.google.ml
216.239.38.120 www.google.com.mm
216.239.38.120 www.google.mn
216.239.38.120 www.google.ms
216.239.38.120 www.google.com.mt
216.239.38.120 www.google.mu
216.239.38.120 www.google.mv
216.239.38.120 www.google.mw
216.239.38.120 www.google.com.mx
216.239.38.120 www.google.com.my
216.239.38.120 www.google.co.mz
216.239.38.120 www.google.com.na
216.239.38.120 www.google.com.nf
216.239.38.120 www.google.com.ng
216.239.38.120 www.google.com.ni
216.239.38.120 www.google.ne
216.239.38.120 www.google.nl
216.239.38.120 www.google.no
216.239.38.120 www.google.com.np
216.239.38.120 www.google.nr
216.239.38.120 www.google.nu
216.239.38.120 www.google.co.nz
216.239.38.120 www.google.com.om
216.239.38.120 www.google.com.pa
216.239.38.120 www.google.com.pe
216.239.38.120 www.google.com.pg
216.239.38.120 www.google.com.ph
216.239.38.120 www.google.com.pk
216.239.38.120 www.google.pl
216.239.38.120 www.google.pn
216.239.38.120 www.google.com.pr
216.239.38.120 www.google.ps
216.239.38.120 www.google.pt
216.239.38.120 www.google.com.py
216.239.38.120 www.google.com.qa
216.239.38.120 www.google.ro
216.239.38.120 www.google.ru
216.239.38.120 www.google.rw
216.239.38.120 www.google.com.sa
216.239.38.120 www.google.com.sb
216.239.38.120 www.google.sc
216.239.38.120 www.google.se
216.239.38.120 www.google.com.sg
216.239.38.120 www.google.sh
216.239.38.120 www.google.si
216.239.38.120 www.google.sk
216.239.38.120 www.google.com.sl
216.239.38.120 www.google.sn
216.239.38.120 www.google.so
216.239.38.120 www.google.sm
216.239.38.120 www.google.sr
216.239.38.120 www.google.st
216.239.38.120 www.google.com.sv
216.239.38.120 www.google.td
216.239.38.120 www.google.tg
216.239.38.120 www.google.co.th
216.239.38.120 www.google.com.tj
216.239.38.120 www.google.tk
216.239.38.120 www.google.tl
216.239.38.120 www.google.tm
216.239.38.120 www.google.tn
216.239.38.120 www.google.to
216.239.38.120 www.google.com.tr
216.239.38.120 www.google.tt
216.239.38.120 www.google.com.tw
216.239.38.120 www.google.co.tz
216.239.38.120 www.google.com.ua
216.239.38.120 www.google.co.ug
216.239.38.120 www.google.co.uk
216.239.38.120 www.google.com.uy
216.239.38.120 www.google.co.uz
216.239.38.120 www.google.com.vc
216.239.38.120 www.google.co.ve
216.239.38.120 www.google.vg
216.239.38.120 www.google.co.vi
216.239.38.120 www.google.com.vn
216.239.38.120 www.google.vu
216.239.38.120 www.google.ws
216.239.38.120 www.google.rs
216.239.38.120 www.google.co.za
216.239.38.120 www.google.co.zm
216.239.38.120 www.google.co.zw
216.239.38.120 www.google.cat

+ 25
- 0
net/safe-search/files/hosts/youtube.restrict View File

@ -0,0 +1,25 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
#
# IMPORTANT: if this file is not working, make sure that dnsmasq is able to READ it!
#
#216.239.38.120 restrict.youtube.com
#2001:4860:4802:32::78 restrict.youtube.com
#IPv6
2001:4860:4802:32::78 www.youtube.com
2001:4860:4802:32::78 m.youtube.com
2001:4860:4802:32::78 youtubei.googleapis.com
2001:4860:4802:32::78 youtube.googleapis.com
2001:4860:4802:32::78 www.youtube-nocookie.com
#IPv4
216.239.38.120 www.youtube.com
216.239.38.120 m.youtube.com
216.239.38.120 youtubei.googleapis.com
216.239.38.120 youtube.googleapis.com
216.239.38.120 www.youtube-nocookie.com

+ 25
- 0
net/safe-search/files/hosts/youtube.restrictmoderate View File

@ -0,0 +1,25 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
#
# IMPORTANT: if this file is not working, make sure that dnsmasq is able to READ it!
#
#216.239.38.119 restrictmoderate.youtube.com
#2001:4860:4802:32::77 restrictmoderate.youtube.com
#IPv6
2001:4860:4802:32::77 www.youtube.com
2001:4860:4802:32::77 m.youtube.com
2001:4860:4802:32::77 youtubei.googleapis.com
2001:4860:4802:32::77 youtube.googleapis.com
2001:4860:4802:32::77 www.youtube-nocookie.com
#IPv4
216.239.38.119 www.youtube.com
216.239.38.119 m.youtube.com
216.239.38.119 youtubei.googleapis.com
216.239.38.119 youtube.googleapis.com
216.239.38.119 www.youtube-nocookie.com

+ 23
- 0
net/safe-search/files/safe-search-update View File

@ -0,0 +1,23 @@
#!/bin/sh
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
. /lib/functions.sh
update() {
config_get_bool enabled $1 enabled 0
config_get mode $1 mode default
if [ ! -f /etc/safe-search/available/$1.$mode ]; then
echo Error: /etc/safe-search/available/$1.$mode does not exist. Please check your configuration in /etc/config/safe-search
else
if [ "$enabled" -eq 1 ]; then
ln -s /etc/safe-search/available/$1.$mode /etc/safe-search/enabled/
fi
fi
}
rm -f /etc/safe-search/enabled/*
config_load 'safe-search'
config_foreach update safe-search
/etc/init.d/dnsmasq reload

+ 17
- 0
net/safe-search/files/safe-search.conf View File

@ -0,0 +1,17 @@
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
# run safe-search-update after making configuration changes.
#
config safe-search 'bing'
option enabled 1
config safe-search 'google'
option enabled 1
# Valid modes for youtube are restrict and restrictmoderate
config safe-search 'youtube'
option enabled 0
option mode 'restrict'

+ 12
- 0
net/safe-search/files/safe-search.defaults View File

@ -0,0 +1,12 @@
#!/bin/sh
#
# Copyright (c) 2018 Gregory L. Dietsche <Gregory.Dietsche@cuw.edu>
# This is free software, licensed under the MIT License
#
uci add_list dhcp.@dnsmasq[0].addnhosts=/etc/safe-search/enabled
uci commit dhcp
#/etc/init.d/dnsmasq reload #safe-search-update does this for us.
/usr/sbin/safe-search-update
exit 0

Loading…
Cancel
Save