Browse Source

admin updates

Danja Vasiliev 10 years ago
parent
commit
7daf53d9d1

+ 12 - 12
openwrt/common/etc/lighttpd/lighttpd.conf

@@ -47,11 +47,11 @@ url.access-deny = ( "~", ".inc", ".htaccess", ".htpasswd", "htpasswd", "/tmp/" )
 auth.backend = "htdigest"
 auth.backend.htdigest.userfile = "/opt/lib/htpasswd"
 auth.require = (
-#  "/admin"  => (
-#    "method"  =>  "digest",
-#    "realm"   =>  "superglue",
-#    "require" =>  "valid-user"
-#  ),
+  "/admin"  => (
+    "method"  =>  "digest",
+    "realm"   =>  "superglue",
+    "require" =>  "valid-user"
+  ),
   "/log"  => (
     "method"  =>  "digest",
     "realm"   =>  "superglue",
@@ -92,13 +92,13 @@ $HTTP["request-method"] == "POST" {
     "/admin"    =>  "/opt/lib/cgi/admin2.cgi",
     ""          =>  "/opt/lib/cgi/post.cgi"
   )
-#  auth.require = (
-#    "" => (
-#      "method"  =>  "digest",
-#      "realm"   =>  "superglue",
-#      "require" =>  "valid-user"
-#    )
-#  )
+  auth.require = (
+    "" => (
+      "method"  =>  "digest",
+      "realm"   =>  "superglue",
+      "require" =>  "valid-user"
+    )
+  )
 }
 
 ## can use this? per 

+ 23 - 3
openwrt/common/opt/lib/cgi/admin2.cgi

@@ -549,9 +549,29 @@ wankey=$(doUci get wankey)
 
 <section>
   <h2>Domain name:</h2>
-  <input type='text' name='dnsname' id='dnsname' value='<% _echo $dnsname %>' placeholder='domain name'>
-  <input type='text' name='dnstoken' id='dnstoken' value='<% _echo $dnstoken %>' placeholder='dns token'>
- 
+  <form>
+  <input type='text' name='dnsname' id='dnsname' value='<% _echo $dnsname %>' placeholder='domain name' class='inline'>
+  <input type='text' name='dnstoken' id='dnstoken' value='<% _echo $dnstoken %>' placeholder='dns token' class='inline'>
+  <input type='hidden' name='dns' value='apply' class='inline'>
+  <input type='submit' value='Apply'>
+  </form>
+  <h2>Free DNS:</h2>
+    Register your free domain name (external <a target='_new' href='http://freedns.afraid.org/'>Free DNS</a> service, will open in a new tab)
+    <form target='_new' action='http://freedns.afraid.org/subdomain/edit.php'>
+
+    <input type='text' size='15' name='subdomain' placeholder='yourname' class='inline'>
+    <select name='edit_domain_id' class='inline'>
+    <option value='1035903'>spgl.cc</option>
+    <option value='1035903'>spgl.it</option>
+    <option value='1035903'>superglue.it</option>
+    <option value='0'>Many more available..</option>
+    </select>
+
+    <input type=submit name=submit value="next &gt;&gt;">
+    <input type=hidden name=web_panel value=1>
+    <input type=hidden name=ref value=750930>
+    </form>
+   
  <span class='help'>help</span>
 </section>
 

+ 2 - 0
openwrt/make_fw.sh

@@ -14,8 +14,10 @@ _PWD=$(pwd)
 _IMAGEBUILDER="$_PWD/../../../openwrt/OpenWrt-ImageBuilder-ar71xx_generic-for-linux-x86_64"
 _BUILDS="$_PWD/../../../sg-builds"
 
+set -e
 [[ -e $_IMAGEBUILDER ]] || (echo 'ImageBuilder is missing'; exit 1;)
 [[ -e $_BUILDS ]] || (echo 'Builds directory is missing'; exit 1;)
+set +e
 
 ## dirs with platform specific files
 #_TARGETS='DIR505A1 TLWR710 WRT160NL'

+ 1 - 1
openwrt/sg_0.1.revision

@@ -1 +1 @@
-37
+38