Skip to content

Commit 72332b3

Browse files
committed
Version 0.1
0 parents  commit 72332b3

File tree

10 files changed

+604
-0
lines changed

10 files changed

+604
-0
lines changed

etc/config/dhcp

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
2+
config dnsmasq
3+
option domainneeded '1'
4+
option boguspriv '1'
5+
option filterwin2k '0'
6+
option localise_queries '1'
7+
option rebind_protection '1'
8+
option rebind_localhost '1'
9+
option local '/lan/'
10+
option domain 'lan'
11+
option expandhosts '1'
12+
option nonegcache '0'
13+
option authoritative '1'
14+
option readethers '1'
15+
option leasefile '/tmp/dhcp.leases'
16+
option resolvfile '/tmp/resolv.conf.auto'
17+
18+
config dhcp 'lan'
19+
option interface 'lan'
20+
option start '100'
21+
option limit '150'
22+
option leasetime '12h'
23+
option dhcpv6 'server'
24+
option ra 'server'
25+
26+
config dhcp 'wlan'
27+
option interface 'wlan'
28+
option start 100
29+
option limit 150
30+
option leastime 12h
31+
option ignore 0
32+
33+
config dhcp 'wan'
34+
option interface 'wan'
35+
option ignore '1'
36+
37+
config odhcpd 'odhcpd'
38+
option maindhcp '0'
39+
option leasefile '/tmp/hosts/odhcpd'
40+
option leasetrigger '/usr/sbin/odhcpd-update'
41+
42+

etc/config/firewall

Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
config defaults
2+
option syn_flood 1
3+
option input ACCEPT
4+
option output ACCEPT
5+
option forward REJECT
6+
option disable_ipv6 1
7+
8+
config zone
9+
option name lan
10+
list network 'lan'
11+
option input ACCEPT
12+
option output ACCEPT
13+
option forward REJECT
14+
15+
config zone
16+
option name 'wlan'
17+
option network 'wlan'
18+
option input ACCEPT
19+
option output ACCEPT
20+
option forward REJECT
21+
22+
config zone
23+
option name wan
24+
list network 'wan'
25+
option input REJECT
26+
option output ACCEPT
27+
option forward REJECT
28+
option masq 1
29+
option mtu_fix 1
30+
option network 'wan wwan'
31+
32+
# CAPTIVE WEB
33+
config redirect
34+
option src 'wlan'
35+
option proto 'tcp'
36+
option src_dip '!192.168.101.0/24'
37+
option dest_port '80'
38+
option enabled '1'
39+
40+
# ROUTER MODE
41+
config forwarding
42+
option src 'wlan'
43+
option dest 'wan'
44+
option enabled '0'
45+
46+
# TOR DNS
47+
config redirect
48+
option src 'wlan'
49+
option proto 'udp'
50+
option src_port '53'
51+
option dest_port '9053'
52+
option enabled '0'
53+
54+
# TOR PROXY
55+
config redirect
56+
option src 'wlan'
57+
option proto 'tcp'
58+
option src_dip !192.168.101.0/24
59+
option dest_port '9040'
60+
option enabled '0'
61+
62+
63+
# We need to accept udp packets on port 68,
64+
# see https://dev.openwrt.org/ticket/4108
65+
config rule
66+
option name Allow-DHCP-Renew
67+
option src wan
68+
option proto udp
69+
option dest_port 68
70+
option target ACCEPT
71+
option family ipv4
72+
73+
# Allow IPv4 ping
74+
config rule
75+
option name Allow-Ping
76+
option src wan
77+
option proto icmp
78+
option icmp_type echo-request
79+
option family ipv4
80+
option target ACCEPT
81+
82+
config rule
83+
option name 'Allow-Tor-DNS'
84+
option src 'wlan'
85+
option proto 'udp'
86+
option dest_port '9053'
87+
option target 'ACCEPT'
88+
option family 'ipv4'
89+
90+
config rule
91+
option name 'Allow-Tor-Transparent'
92+
option src 'wlan'
93+
option proto 'tcp'
94+
option dest_port '9040'
95+
option target 'ACCEPT'
96+
option family 'ipv4'
97+
98+
config rule
99+
option name 'Allow-Tor-Socks'
100+
option src 'wlan'
101+
option proto 'tcp'
102+
option dest_port '9050'
103+
option target 'ACCEPT'
104+
option family 'ipv4'
105+
106+
# include a file with users custom iptables rules
107+
config include
108+
option path /etc/firewall.user

etc/config/network

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
config interface 'loopback'
2+
option ifname 'lo'
3+
option proto 'static'
4+
option ipaddr '127.0.0.1'
5+
option netmask '255.0.0.0'
6+
7+
config interface 'wlan'
8+
option ifname 'eth0'
9+
option type 'bridge'
10+
option proto 'static'
11+
option ipaddr '192.168.101.1'
12+
option netmask '255.255.255.0'
13+
14+
config interface 'lan'
15+
option ifname 'eth1'
16+
#option force_link '1'
17+
#option type 'bridge'
18+
option proto 'static'
19+
option ipaddr '192.168.100.1'
20+
option netmask '255.255.255.0'
21+
22+
config interface 'wan'
23+
option ifname 'eth0'
24+
option proto 'dhcp'
25+
26+
config interface 'wwan'
27+
option proto 'dhcp'

etc/config/wireless

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
config wifi-device radio0
2+
option type mac80211
3+
option channel 11
4+
option hwmode 11g
5+
option path 'platform/ar933x_wmac'
6+
option htmode HT20
7+
# REMOVE THIS LINE TO ENABLE WIFI:
8+
# option disabled 1
9+
10+
config wifi-iface
11+
option device radio0
12+
option network wwan
13+
option mode sta
14+
15+
config wifi-iface
16+
option device radio0
17+
option mode ap
18+
option ssid NETAIDKIT
19+
option encryption psk2
20+
option key s3cr3tp4ss
21+
option network wlan
22+

etc/dnsmasq.conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
address=/#/192.168.101.1

etc/lighttpd/conf.d/30-cgi.conf

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#######################################################################
2+
##
3+
## CGI modules
4+
## ---------------
5+
##
6+
## http://www.lighttpd.net/documentation/cgi.html
7+
##
8+
server.modules += ( "mod_cgi" )
9+
10+
##
11+
## Plain old CGI handling
12+
##
13+
## For PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini.
14+
##
15+
cgi.assign = ( ".php" => "/usr/bin/php-cgi" )
16+
17+
##
18+
## to get the old cgi-bin behavior of apache
19+
##
20+
## Note: make sure that mod_alias is loaded if you uncomment the
21+
## next line. (see modules.conf)
22+
##
23+
#alias.url += ( "/cgi-bin" => server_root + "/cgi-bin" )
24+
#$HTTP["url"] =~ "^/cgi-bin" {
25+
# cgi.assign = ( "" => "" )
26+
#}
27+
28+
##
29+
#######################################################################

etc/lighttpd/lighttpd.conf

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
server.modules = (
2+
)
3+
4+
server.document-root = "/www"
5+
server.upload-dirs = ( "/tmp" )
6+
server.errorlog = "/var/log/lighttpd/error.log"
7+
server.pid-file = "/var/run/lighttpd.pid"
8+
server.username = "http"
9+
server.groupname = "www-data"
10+
11+
index-file.names = ( "index.php", "index.html",
12+
"index.htm", "default.htm",
13+
"index.lighttpd.html" )
14+
15+
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
16+
17+
### Options that are useful but not always necessary:
18+
#server.chroot = "/"
19+
#server.port = 81
20+
#server.bind = "localhost"
21+
#server.tag = "lighttpd"
22+
#server.errorlog-use-syslog = "enable"
23+
#server.network-backend = "write"
24+
25+
### Use IPv6 if available
26+
#include_shell "/usr/share/lighttpd/use-ipv6.pl"
27+
28+
#dir-listing.encoding = "utf-8"
29+
#server.dir-listing = "enable"
30+
31+
include "/etc/lighttpd/mime.conf"
32+
include_shell "cat /etc/lighttpd/conf.d/*.conf"
33+
34+
url.rewrite-if-not-file = ( "/(.*)$" => "/index.php?query=$1", )
35+

etc/shadow

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
root:$1$2YYqAk8V$GtJCs.DegSAfMf/nulCC//:16407:0:99999:7:::
2+
daemon:*:0:0:99999:7:::
3+
ftp:*:0:0:99999:7:::
4+
network:*:0:0:99999:7:::
5+
nobody:*:0:0:99999:7:::
6+
http:x:0:0:99999:7:::
7+

0 commit comments

Comments
 (0)