luci-0.9: merge r5027 - r5112
authorJo-Philipp Wich <jow@openwrt.org>
Thu, 23 Jul 2009 03:32:30 +0000 (03:32 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Thu, 23 Jul 2009 03:32:30 +0000 (03:32 +0000)
111 files changed:
Makefile
applications/luci-ddns/luasrc/controller/ddns.lua
applications/luci-hd_idle/luasrc/controller/hd_idle.lua
applications/luci-hd_idle/luasrc/model/cbi/hd_idle.lua
applications/luci-initmgr/luasrc/controller/init.lua
applications/luci-mmc_over_gpio/luasrc/controller/mmc_over_gpio.lua
applications/luci-ntpc/luasrc/controller/ntpc.lua
applications/luci-olsr/luasrc/controller/olsr.lua
applications/luci-olsr/luasrc/model/cbi/olsr/olsrdplugins.lua
applications/luci-openvpn/luasrc/model/cbi/openvpn-advanced.lua
applications/luci-openvpn/luasrc/model/cbi/openvpn-basic.lua
applications/luci-openvpn/luasrc/model/cbi/openvpn.lua
applications/luci-p910nd/luasrc/controller/p910nd.lua
applications/luci-polipo/luasrc/controller/polipo.lua
applications/luci-qos/luasrc/controller/qos.lua
applications/luci-qos/luasrc/model/cbi/qos/qos.lua
applications/luci-qos/luasrc/model/cbi/qos/qosmini.lua
applications/luci-samba/luasrc/controller/samba.lua
applications/luci-splash/luasrc/controller/splash/splash.lua
applications/luci-splash/luasrc/view/admin_status/splash.htm
applications/luci-splash/root/usr/sbin/luci-splash
applications/luci-statistics/luasrc/statistics/rrdtool.lua
applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua
applications/luci-statistics/luasrc/view/admin_statistics/networkplugins.htm
applications/luci-statistics/luasrc/view/admin_statistics/outputplugins.htm
applications/luci-statistics/luasrc/view/admin_statistics/systemplugins.htm
applications/luci-tinyproxy/luasrc/controller/tinyproxy.lua
applications/luci-upnp/luasrc/controller/upnp.lua
applications/luci-ushare/luasrc/controller/ushare.lua
applications/luci-uvc_streamer/luasrc/controller/uvc_streamer.lua
applications/luci-voice-core/Makefile [new file with mode: 0644]
applications/luci-voice-core/luasrc/controller/luci_voice.lua [new file with mode: 0644]
applications/luci-voice-core/luasrc/view/luci_voice/index.htm [new file with mode: 0644]
applications/luci-voice-core/luasrc/view/luci_voice/phone_index.htm [new file with mode: 0644]
build/i18n-po2lua.pl
build/module.mk
contrib/package/luci/Makefile
libs/cbi/luasrc/cbi.lua
libs/cbi/luasrc/view/cbi/filebrowser.htm
libs/cbi/luasrc/view/cbi/upload.htm
libs/core/luasrc/debug.lua
libs/core/luasrc/util.lua
libs/lmo/Makefile [new file with mode: 0644]
libs/lmo/src/lmo.h [new file with mode: 0644]
libs/lmo/src/lmo_core.c [new file with mode: 0644]
libs/lmo/src/lmo_hash.c [new file with mode: 0644]
libs/lmo/src/lmo_lookup.c [new file with mode: 0644]
libs/lmo/src/lmo_lualib.c [new file with mode: 0644]
libs/lmo/src/lmo_lualib.h [new file with mode: 0644]
libs/lmo/src/lmo_po2lmo.c [new file with mode: 0644]
libs/lmo/standalone.mk [new file with mode: 0644]
libs/lucid-http/luasrc/lucid/http/server.lua
libs/lucid/luasrc/lucid.lua
libs/lucid/luasrc/lucid/tcpserver.lua
libs/lucid/root/etc/config/lucid
libs/nixio/Makefile
libs/nixio/docsrc/CHANGELOG.lua [new file with mode: 0644]
libs/nixio/docsrc/README.lua
libs/nixio/docsrc/nixio.UnifiedIO.lua
libs/nixio/docsrc/nixio.bit.lua
libs/nixio/lua/nixio/util.lua
libs/nixio/nixio-0.3-1.rockspec [new file with mode: 0644]
libs/nixio/src/address.c
libs/nixio/src/bit.c
libs/nixio/src/file.c
libs/nixio/standalone.mk
libs/sys/luasrc/sys.lua
libs/sys/luasrc/sys/zoneinfo.lua
libs/sys/luasrc/sys/zoneinfo/tzdata.lua [new file with mode: 0644]
libs/sys/luasrc/sys/zoneinfo/tzoffset.lua [new file with mode: 0644]
libs/uvl/luasrc/uvl.lua
libs/uvl/luasrc/uvl/datatypes.lua
libs/uvl/luasrc/uvl/validation.lua
libs/uvldoc/luasrc/uvldoc/renderer.lua
libs/web/Makefile
libs/web/luasrc/dispatcher.lua
libs/web/luasrc/i18n.lua
libs/web/luasrc/sauth.lua
libs/web/luasrc/template.lua
libs/web/src/template_lualib.c [new file with mode: 0644]
libs/web/src/template_lualib.h [new file with mode: 0644]
libs/web/src/template_parser.c [new file with mode: 0644]
libs/web/src/template_parser.h [new file with mode: 0644]
modules/admin-full/luasrc/controller/admin/services.lua
modules/admin-full/luasrc/controller/admin/status.lua
modules/admin-full/luasrc/controller/admin/system.lua
modules/admin-full/luasrc/model/cbi/admin_index/luci.lua
modules/admin-full/luasrc/model/cbi/admin_network/dhcpleases.lua
modules/admin-full/luasrc/model/cbi/admin_network/ifaces.lua
modules/admin-full/luasrc/model/cbi/admin_network/network.lua
modules/admin-full/luasrc/model/cbi/admin_network/wifi.lua
modules/admin-full/luasrc/model/cbi/admin_services/crontab.lua
modules/admin-full/luasrc/model/cbi/admin_system/fstab.lua
modules/admin-full/luasrc/model/cbi/admin_system/ipkg.lua
modules/admin-full/luasrc/model/cbi/admin_system/leds.lua
modules/admin-full/luasrc/model/cbi/admin_system/sshkeys.lua
modules/admin-full/luasrc/view/admin_status/conntrack.htm [new file with mode: 0644]
modules/admin-full/luasrc/view/admin_status/interfaces.htm
modules/admin-full/luasrc/view/admin_status/routes.htm [new file with mode: 0644]
modules/admin-mini/luasrc/controller/mini/system.lua
modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua
modules/admin-mini/luasrc/model/cbi/mini/luci.lua
modules/admin-mini/luasrc/model/cbi/mini/network.lua
modules/admin-mini/luasrc/model/cbi/mini/wifi.lua
modules/freifunk/luasrc/controller/freifunk/freifunk.lua
modules/rpc/luasrc/controller/rpc.lua
po/es/admin-core.po
po/es/default.po
po/es/freifunk.po
po/es/luci-fw.po
po/es/olsr.po

index 1343884..9052067 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -12,6 +12,7 @@ all: build
 build: gccbuild luabuild
 
 gccbuild:
+       make -C libs/lmo CC="cc" CFLAGS="" LDFLAGS="" host-install
        for i in $(MODULES); do \
                make -C$$i compile || { \
                        echo "*** Compilation of $$i failed!"; \
@@ -28,6 +29,7 @@ i18nbuild:
 
 clean:
        rm -rf docs
+       make -C libs/lmo host-clean
        for i in $(MODULES); do make -C$$i clean; done
 
 
index 6adbbb0..7a81d9a 100644 (file)
@@ -17,7 +17,7 @@ module("luci.controller.ddns", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("ddns")
-       if not luci.fs.access("/etc/config/ddns") then
+       if not nixio.fs.access("/etc/config/ddns") then
                return
        end
        
@@ -29,4 +29,4 @@ function index()
        local page = entry({"mini", "network", "ddns"}, cbi("ddns/ddnsmini", {autoapply=true}), luci.i18n.translate("ddns"), 60)
        page.i18n = "ddns"
        page.dependent = true
-end
\ No newline at end of file
+end
index 5dfbe16..57ff10d 100644 (file)
@@ -18,7 +18,7 @@ module("luci.controller.hd_idle", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("hd_idle")
-       if not luci.fs.access("/etc/config/hd-idle") then
+       if not nixio.fs.access("/etc/config/hd-idle") then
                return
        end
 
index b59df82..60817db 100644 (file)
@@ -13,7 +13,7 @@ $Id$
 
 ]]--
 
-require("luci.fs")
+require("nixio.fs")
 
 m = Map("hd-idle", translate("hd_idle"), translate("hd_idle_desc"))
 
@@ -24,8 +24,8 @@ s:option(Flag, "enabled", translate("enable", "Enable"))
 
 disk = s:option(Value, "disk", translate("disk"))
 disk.rmempty = true
-for _, dev in ipairs(luci.fs.glob("/dev/[sh]d[a-z]")) do
-       disk:value(luci.fs.basename(dev))
+for _, dev in nixio.fs.glob("/dev/[sh]d[a-z]") do
+       disk:value(nixio.fs.basename(dev))
 end
 
 s:option(Value, "idle_time_interval", translate("idle_time_interval")).default = 10
index fbbc727..c7ef43f 100644 (file)
@@ -15,7 +15,7 @@ $Id$
 module("luci.controller.init", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/rc.common") then
+       if not nixio.fs.access("/etc/rc.common") then
                return
        end
 
index 7beaa14..57fe5ee 100644 (file)
@@ -18,7 +18,7 @@ module("luci.controller.mmc_over_gpio", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("mmc_over_gpio")
-       if not luci.fs.access("/etc/config/mmc_over_gpio") then
+       if not nixio.fs.access("/etc/config/mmc_over_gpio") then
                return
        end
 
index 9290644..0d656a4 100644 (file)
@@ -17,7 +17,7 @@ module("luci.controller.ntpc", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("ntpc")
-       if not luci.fs.access("/etc/config/ntpclient") then
+       if not nixio.fs.access("/etc/config/ntpclient") then
                return
        end
        
index 652f6b9..837873a 100644 (file)
@@ -1,7 +1,7 @@
 module("luci.controller.olsr", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/olsrd") then
+       if not nixio.fs.access("/etc/config/olsrd") then
                return
        end
 
@@ -182,7 +182,7 @@ function fetch_txtinfo(otable)
        local rawdata = luci.sys.httpget("http://127.0.0.1:2006/"..otable)
 
        if #rawdata == 0 then
-               if luci.fs.access("/proc/net/ipv6_route", "r") then
+               if nixio.fs.access("/proc/net/ipv6_route", "r") then
                        rawdata = luci.sys.httpget("http://[::1]:2006/"..otable)
                        if #rawdata == 0 then
                                return nil
index 03f18a8..f81a4a4 100644 (file)
@@ -13,9 +13,8 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-require("luci.fs")
-require("luci.ip")
-
+local ip = require "luci.ip"
+local fs = require "nixio.fs"
 
 if arg[1] then
        mp = Map("olsrd", translate("olsrd_plugins", "OLSR - Plugins"))
@@ -44,7 +43,7 @@ if arg[1] then
        local function Cidr2IpMask(val)
                if val then
                        for i = 1, #val do
-                               local cidr = luci.ip.IPv4(val[i]) or luci.ip.IPv6(val[i])
+                               local cidr = ip.IPv4(val[i]) or ip.IPv6(val[i])
                                if cidr then
                                        val[i] = cidr:network():string() .. " " .. cidr:mask():string()
                                end
@@ -59,9 +58,9 @@ if arg[1] then
                                local ip, mask = val[i]:gmatch("([^%s]+)%s+([^%s]+)")()
                                local cidr
                                if ip and mask and ip:match(":") then
-                                       cidr = luci.ip.IPv6(ip, mask)
+                                       cidr = ip.IPv6(ip, mask)
                                elseif ip and mask then
-                                       cidr = luci.ip.IPv4(ip, mask)
+                                       cidr = ip.IPv4(ip, mask)
                                end
 
                                if cidr then
@@ -220,7 +219,7 @@ else
        )
 
        -- create a loadplugin section for each found plugin
-       for k, v in pairs(luci.fs.dir("/usr/lib")) do
+       for v in fs.dir("/usr/lib") do
                if v:sub(1, 6) == "olsrd_" then
                        if not plugins[v] then
                                mpi.uci:section(
index 1d4cc4d..b3e22d4 100644 (file)
@@ -12,7 +12,6 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-require("luci.fs")
 require("luci.ip")
 require("luci.model.uci")
 
index 863be2f..e71becd 100644 (file)
@@ -12,13 +12,9 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-require("luci.fs")
-require("luci.ip")
-require("luci.sys")
-require("luci.model.uci")
-
-
-local uci = luci.model.uci.cursor()
+local fs  = require "nixio.fs"
+local sys = require "luci.sys"
+local uci = require "luci.model.uci".cursor()
 
 local m = Map("openvpn", translate("openvpn"))
 local s = m:section( TypedSection, "openvpn", translate("openvpn_overview"), translate("openvpn_overview_desc") )
@@ -74,13 +70,11 @@ s:option( Flag, "enable", translate("openvpn_enable") )
 
 local active = s:option( DummyValue, "_active", translate("openvpn_active") )
 function active.cfgvalue(self, section)
-       if luci.fs.isfile("/var/run/openvpn_%s.pid" % section) then
-               local pid = io.lines("/var/run/openvpn_%s.pid" % section)()
-               if pid and #pid > 0 and tonumber(pid) ~= nil then
-                       return (luci.sys.process.signal(pid, 0))
-                               and translatef("openvpn_active_yes", pid)
-                               or  translate("openvpn_active_no")
-               end
+       local pid = fs.readfile("/var/run/openvpn_%s.pid" % section)
+       if pid and #pid > 0 and tonumber(pid) ~= nil then
+               return (sys.process.signal(pid, 0))
+                       and translatef("openvpn_active_yes", pid)
+                       or  translate("openvpn_active_no")
        end
        return translate("openvpn_active_no")
 end
index 75b2693..1316701 100644 (file)
@@ -18,7 +18,7 @@ module("luci.controller.p910nd", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("p910nd")
-       if not luci.fs.access("/etc/config/p910nd") then
+       if not nixio.fs.access("/etc/config/p910nd") then
                return
        end
 
index 949f80a..3d9f7d1 100644 (file)
@@ -14,7 +14,7 @@ $Id$
 module("luci.controller.polipo", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/polipo") then
+       if not nixio.fs.access("/etc/config/polipo") then
                return
        end
        
index 970dd3d..af9b114 100644 (file)
@@ -14,7 +14,7 @@ $Id$
 module("luci.controller.qos", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/qos") then
+       if not nixio.fs.access("/etc/config/qos") then
                return
        end
        
@@ -26,4 +26,4 @@ function index()
        local page = entry({"mini", "network", "qos"}, cbi("qos/qosmini", {autoapply=true}), "QoS")
        page.i18n = "qos"
        page.dependent = true
-end
\ No newline at end of file
+end
index 22dfbea..ec450cf 100644 (file)
@@ -11,7 +11,10 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.tools.webadmin")
+
+local wa = require "luci.tools.webadmin"
+local fs = require "nixio.fs"
+
 m = Map("qos")
 
 s = m:section(TypedSection, "interface", translate("interfaces"))
@@ -46,19 +49,19 @@ t.default = "Normal"
 srch = s:option(Value, "srchost")
 srch.rmempty = true
 srch:value("", translate("all"))
-luci.tools.webadmin.cbi_add_knownips(srch)
+wa.cbi_add_knownips(srch)
 
 dsth = s:option(Value, "dsthost")
 dsth.rmempty = true
 dsth:value("", translate("all"))
-luci.tools.webadmin.cbi_add_knownips(dsth)
+wa.cbi_add_knownips(dsth)
 
 l7 = s:option(ListValue, "layer7", translate("service"))
 l7.rmempty = true
 l7:value("", translate("all"))
-local pats = luci.fs.dir("/etc/l7-protocols")
+local pats = fs.dir("/etc/l7-protocols")
 if pats then
-       for i,f in ipairs(pats) do
+       for f in pats do
                if f:sub(-4) == ".pat" then
                        l7:value(f:sub(1, #f-4))
                end
index ec93694..cb79682 100644 (file)
@@ -12,7 +12,10 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.tools.webadmin")
+
+local wa = require "luci.tools.webadmin"
+local fs = require "nixio.fs"
+
 m = Map("qos")
 
 s = m:section(NamedSection, "wan", "interface", translate("m_n_inet"))
@@ -37,19 +40,19 @@ t.default = "Normal"
 srch = s:option(Value, "srchost")
 srch.rmempty = true
 srch:value("", translate("all"))
-luci.tools.webadmin.cbi_add_knownips(srch)
+wa.cbi_add_knownips(srch)
 
 dsth = s:option(Value, "dsthost")
 dsth.rmempty = true
 dsth:value("", translate("all"))
-luci.tools.webadmin.cbi_add_knownips(dsth)
+wa.cbi_add_knownips(dsth)
 
 l7 = s:option(ListValue, "layer7", translate("service"))
 l7.rmempty = true
 l7:value("", translate("all"))
-local pats = luci.fs.dir("/etc/l7-protocols")
+local pats = fs.dir("/etc/l7-protocols")
 if pats then
-       for i,f in ipairs(pats) do
+       for f in pats do
                if f:sub(-4) == ".pat" then
                        l7:value(f:sub(1, #f-4))
                end
index 75cb65a..c2d5d84 100644 (file)
@@ -15,7 +15,7 @@ $Id$
 module("luci.controller.samba", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/samba") then
+       if not nixio.fs.access("/etc/config/samba") then
                return
        end
        require("luci.i18n")
index 13f9f41..362ad9d 100644 (file)
@@ -11,9 +11,18 @@ function index()
 end
 
 function action_dispatch()
+       local uci = luci.model.uci.cursor_state()
        local mac = luci.sys.net.ip4mac(luci.http.getenv("REMOTE_ADDR")) or ""
-       local status = luci.util.execl("luci-splash status "..mac)[1]
-       if #mac > 0 and ( status == "whitelisted" or status == "lease" ) then
+       local access = false
+
+       uci:foreach("luci_splash", "lease", function(s)
+               if s.mac and s.mac:lower() == mac then access = true end
+       end)
+       uci:foreach("luci_splash", "whitelist", function(s)
+               if s.mac and s.mac:lower() == mac then access = true end
+       end)
+
+       if #mac > 0 and access then
                luci.http.redirect(luci.dispatcher.build_url())
        else
                luci.http.redirect(luci.dispatcher.build_url("splash", "splash"))
index 9939520..4151c66 100644 (file)
@@ -18,6 +18,8 @@ local utl = require "luci.util"
 local ipt = require "luci.sys.iptparser".IptParser()
 local uci = require "luci.model.uci".cursor_state()
 local wat = require "luci.tools.webadmin"
+local fs  = require "nixio.fs"
+
 local clients = { }
 local leasetime = tonumber(uci:get("luci_splash", "general", "leasetime") or 1) * 60 * 60
 local leasefile = "/tmp/dhcp.leases"
@@ -94,7 +96,7 @@ uci:foreach("luci_splash", "blacklist",
                end
        end)            
 
-if luci.fs.access(leasefile) then
+if fs.access(leasefile) then
        for l in io.lines(leasefile) do
                local time, mac, ip, name = l:match("^(%d+) (%S+) (%S+) (%S+)")
                if time and mac and ip then
index 017cfeb..1adcb09 100755 (executable)
@@ -29,7 +29,7 @@ function main(argv)
        limit_down = tonumber(uci:get("luci_splash", "general", "limit_down")) or 0
 
        if ( cmd == "lease" or cmd == "add-rules" or cmd == "remove" or
-            cmd == "whitelist" or cmd == "blacklist" ) and #argv > 0
+            cmd == "whitelist" or cmd == "blacklist" or cmd == "status" ) and #argv > 0
        then
                lock()
 
@@ -59,6 +59,11 @@ function main(argv)
                                elseif whitelist_macs[mac] then
                                        add_whitelist_rule(mac)
                                end
+                       elseif mac and cmd == "status" then
+                               print(leased_macs[mac] and "lease"
+                                       or whitelist_macs[mac] and "whitelist"
+                                       or blacklist_macs[mac] and "blacklist"
+                                       or "new")
                        elseif mac and ( cmd == "whitelist" or cmd == "blacklist" or cmd == "lease" ) then
                                if cmd ~= "lease" and leased_macs[mac] then
                                        print("Removing %s from leases" % mac)
index 911b38b..eb5c266 100644 (file)
@@ -22,7 +22,8 @@ require("luci.statistics.i18n")
 require("luci.model.uci")
 require("luci.util")
 require("luci.sys")
-require("luci.fs")
+
+local fs = require "nixio.fs"
 
 
 Graph = luci.util.class()
@@ -96,7 +97,7 @@ function Graph._rrdtool( self, def, rrd )
 
        -- prepare directory
        local dir = def[1]:gsub("/[^/]+$","")
-       luci.fs.mkdir( dir, true )
+       fs.mkdirr( dir )
 
        -- construct commandline
        local cmdline = "rrdtool graph"
@@ -500,7 +501,7 @@ function Graph.render( self, plugin, plugin_instance )
 
        -- check for a whole graph handler
        local plugin_def = "luci.statistics.rrdtool.definitions." .. plugin
-       local stat, def = luci.util.copcall( require, plugin_def )
+       local stat, def = pcall( require, plugin_def )
 
        if stat and def and type(def.rrdargs) == "function" then
 
@@ -539,7 +540,7 @@ function Graph.render( self, plugin, plugin_instance )
 
                        -- check for data type handler
                        local dtype_def = plugin_def .. "." .. dtype
-                       local stat, def = luci.util.copcall( require, dtype_def )
+                       local stat, def = pcall( require, dtype_def )
 
                        if stat and def and type(def.rrdargs) == "function" then
 
index 7e0b605..8832613 100644 (file)
@@ -16,7 +16,6 @@ $Id$
 module("luci.statistics.rrdtool.definitions", package.seeall)
 
 require("luci.util")
-require("luci.fs")
 
 
 Instance = luci.util.class()
index 54ba2b0..13e5225 100644 (file)
@@ -22,7 +22,7 @@ about open tcp connections, interface traffic, iptables rules etc.%></p>
 <p><%:stat_networkplugins_installed Installed network plugins:%>
        <ul>
                <% for plugin, desc in pairs(plugins) do %>
-                       <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
+                       <% if nixio.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
                                <li><a href="<%=controller%>/admin/statistics/collectd/network/<%=plugin%>"><%=desc%></a></li>
                        <% end %>
                <% end %>
index e79e2f4..ef9ae23 100644 (file)
@@ -23,7 +23,7 @@ and to transmit the data over the network to other collectd instances.%></p>
 <p><%:stat_outputplugins_installed Installed output plugins:%>
        <ul>
                <% for plugin, desc in pairs(plugins) do %>
-                       <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
+                       <% if nixio.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
                                <li><a href="<%=controller%>/admin/statistics/collectd/output/<%=plugin%>"><%=desc%></a></li>
                        <% end %>
                <% end %>
index 0c1b2b5..0e801c7 100644 (file)
@@ -19,7 +19,7 @@ $Id$
 <p><%:stat_systemplugins_desc System plugins collecting values about system state and ressource usage on the device.:%>
        <ul>
                <% for plugin, desc in pairs(plugins) do %>
-                       <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
+                       <% if nixio.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %>
                                <li><a href="<%=controller%>/admin/statistics/collectd/system/<%=plugin%>"><%=desc%></a></li>
                        <% end %>
                <% end %>
index fb8d9e2..f21b0fc 100644 (file)
@@ -15,11 +15,11 @@ $Id$
 module("luci.controller.tinyproxy", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/tinyproxy") then
+       if not nixio.fs.access("/etc/config/tinyproxy") then
                return
        end
        
        local page = entry({"admin", "services", "tinyproxy"}, cbi("tinyproxy"), "Tinyproxy")
        page.dependent = true
        page.i18n = "tinyproxy"
-end
\ No newline at end of file
+end
index c88abdd..fd31755 100644 (file)
@@ -15,7 +15,7 @@ $Id$
 module("luci.controller.upnp", package.seeall)
 
 function index()
-       if not luci.fs.access("/etc/config/upnpd") then
+       if not nixio.fs.access("/etc/config/upnpd") then
                return
        end
        
index 958f247..b9c16a4 100644 (file)
@@ -18,7 +18,7 @@ module("luci.controller.ushare", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("ushare")
-       if not luci.fs.access("/etc/config/ushare") then
+       if not nixio.fs.access("/etc/config/ushare") then
                return
        end
 
index 64491dc..8363454 100644 (file)
@@ -18,7 +18,7 @@ module("luci.controller.uvc_streamer", package.seeall)
 function index()
        require("luci.i18n")
        luci.i18n.loadc("uvc_streamer")
-       if not luci.fs.access("/etc/config/uvc-streamer") then
+       if not nixio.fs.access("/etc/config/uvc-streamer") then
                return
        end
 
diff --git a/applications/luci-voice-core/Makefile b/applications/luci-voice-core/Makefile
new file mode 100644 (file)
index 0000000..d57c456
--- /dev/null
@@ -0,0 +1,4 @@
+PO=voice_core
+
+include ../../build/config.mk
+include ../../build/module.mk
diff --git a/applications/luci-voice-core/luasrc/controller/luci_voice.lua b/applications/luci-voice-core/luasrc/controller/luci_voice.lua
new file mode 100644 (file)
index 0000000..4d8873e
--- /dev/null
@@ -0,0 +1,37 @@
+--[[
+
+Luci Voice Core
+(c) 2009 Daniel Dickinson
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+]]--
+
+
+module("luci.controller.luci_voice", package.seeall)
+
+function index()
+   require("luci.i18n")
+   luci.i18n.loadc("voice_core")
+
+   local e = entry({"admin", "voice"}, template("luci_voice/index") , luci.i18n.translate("l_v_adminvoice", "Voice"), 90)
+   e.index = true
+   e.i18n = "voice_core"
+
+   e = entry({"mini", "voice"}, template("luci_voice/index"), luci.i18n.translate("l_v_minivoice", "Voice"), 90)
+   e.index = true
+   e.i18n = "voice_core"
+
+   e = entry({"mini", "voice", "phones"}, template("luci_voice/phone_index"), luci.i18n.translate("l_v_miniphones"), 90)
+   e.index = true
+   e.i18n = "voice_core"
+
+   e = entry({"admin", "voice", "phones"}, template("luci_voice/phone_index"), luci.i18n.translate("l_v_adminphones"), 90)
+   e.index = true
+   e.i18n = "voice_core"
+
+end
diff --git a/applications/luci-voice-core/luasrc/view/luci_voice/index.htm b/applications/luci-voice-core/luasrc/view/luci_voice/index.htm
new file mode 100644 (file)
index 0000000..73d2ce4
--- /dev/null
@@ -0,0 +1,24 @@
+<%#
+LuCI - Lua Configuration Interface
+(c) 2009 Daniel Dickinson
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+-%>
+<%+header%>
+<h2><a id="content" name="content">Voice</a></h2>
+<p>Here you can control OpenWRT voice-related settings and see
+  voice-related information from OpenWRT</p>
+<p>In particular Asterisk configuration and information is displayed
+  here, as well as diagnostics that specifically apply to voice but are
+  not general networking diagnostics (e.g. includes SIP device scans, but not
+  ping tests).  Includes PSTN phones as well as VoIP and possibly
+  non-telephony related options.
+</p>
+<%+footer%>
diff --git a/applications/luci-voice-core/luasrc/view/luci_voice/phone_index.htm b/applications/luci-voice-core/luasrc/view/luci_voice/phone_index.htm
new file mode 100644 (file)
index 0000000..89b8661
--- /dev/null
@@ -0,0 +1,20 @@
+<%#
+LuCI - Lua Configuration Interface
+(c) 2009 Daniel Dickinson
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+-%>
+<%+header%>
+<h2><a id="content" name="content">Phones</a></h2>
+<p>Here you can control phone configuration and information in OpenWRT</p>
+<p>You can control the setup of phone clients and servers and see
+  information such as diagnostics related to phone devices from this menu.
+</p>
+<%+footer%>
index c57198f..5129055 100755 (executable)
@@ -10,67 +10,17 @@ if( ! -d $target_dir )
        system('mkdir', '-p', $target_dir);
 }
 
-
-my %target_strings;
-
-
 if( open F, "find $source_dir -type f -name '*.po' |" )
 {
        while( chomp( my $file = readline F ) )
        {
-               if( open L, "< $file" )
-               {
-                       my $content = 0;
-                       my ( $lang, $basename ) = $file =~ m{.+/(\w+)/([^/]+)\.po$};
-                       $lang = lc $lang;
-                       $lang =~ s/_/-/g;
-                       
-                       if( open D, "> $target_dir/$basename.$lang.lua" )
-                       {
-                               printf "Generating %-40s ", "$target_dir/$basename.$lang.lua";
-
-                               my ( $k, $v );
-
-                               while( chomp( my $line = readline L ) || ( defined($k) && defined($v) ) )
-                               {
-                                       if( $line =~ /^msgid "(.+)"/ )
-                                       {
-                                               $k = $1;
-                                       }
-                                       elsif( $k && $line =~ /^msgstr "(.*)"/ )
-                                       {
-                                               $v = $1;
-                                       }
-                                       elsif( $k && defined($v) && $line =~ /^"(.+)"/ )
-                                       {
-                                               $v .= $1;
-                                       }
-                                       else
-                                       {
-                                               if( $k && defined($v) && length($v) > 0 )
-                                               {
-                                                       $v =~ s/\\(['"\\])/$1/g;
-                                                       $v =~ s/(['\\])/\\$1/g;
-
-                                                       printf D "%s='%s'\n", $k, $v;
-                                                       $content++;
-                                               }
-               
-                                               $k = $v = undef;
-                                       }
-                               }
-
-                               print $content ? "done ($content strings)\n" : "empty\n";
-
-                               close D;
-
-
-                               unlink("$target_dir/$basename.$lang.lua")
-                                       unless( $content > 0 );
-                       }
+               my ( $lang, $basename ) = $file =~ m{.+/(\w+)/([^/]+)\.po$};
+               $lang = lc $lang;
+               $lang =~ s/_/-/g;
 
-                       close L;
-               }
+               printf "Generating %-40s ", "$target_dir/$basename.$lang.lmo";
+               system("./build/po2lmo", $file, "$target_dir/$basename.$lang.lmo");
+               print ( -f "$target_dir/$basename.$lang.lmo" ? "done\n" : "empty\n" );
        }
 
        close F;
index 569de10..8d64d6b 100644 (file)
@@ -27,7 +27,7 @@ luasource:
   ifneq ($(PO),)
        mkdir -p dist$(LUCI_I18NDIR)
        for file in $(PO); do \
-         cp $(HOST)/lua-po/$$file.$(if $(PO_LANG),$(PO_LANG),*).lua dist$(LUCI_I18NDIR)/ 2>/dev/null || true; \
+         cp $(HOST)/lua-po/$$file.$(if $(PO_LANG),$(PO_LANG),*).* dist$(LUCI_I18NDIR)/ 2>/dev/null || true; \
        done
   endif
 
index 4f5036f..26db2d0 100644 (file)
@@ -211,6 +211,16 @@ define Package/luci-json/install
 endef
 
 
+define Package/luci-lmo
+  $(call Package/luci/libtemplate)
+  TITLE:=lmo
+endef
+
+define Package/luci-lmo/install
+       $(call Package/luci/install/template,$(1),libs/lmo)
+endef
+
+
 define Package/luci-luanet
   $(call Package/luci/libtemplate)
   TITLE:=luanet
@@ -298,7 +308,7 @@ endef
 
 define Package/luci-web
   $(call Package/luci/libtemplate)
-  DEPENDS+=+luci-http +luci-sys +luci-uci +luci-lucid +luci-sgi-cgi
+  DEPENDS+=+luci-http +luci-sys +luci-uci +luci-lucid +luci-sgi-cgi +luci-lmo
   TITLE:=MVC Webframework
   $(call Config,luci.main.lang,string,en,Default Language)
 endef
@@ -506,6 +516,49 @@ define Package/luci-app-statistics/install
        $(call Package/luci/install/template,$(1),applications/luci-statistics)
 endef
 
+define Package/luci-app-diag-core
+  $(call Package/luci/webtemplate)
+  DEPENDS+=+luci-admin-core 
+  TITLE:=LuCI Diagnostics Tools (Core)
+endef
+
+define Package/luci-app-diag-devinfo
+  $(call Package/luci/webtemplate)
+  DEPENDS+=+luci-app-diag-core +smap +netdiscover +mac-to-devinfo +httping +smap-to-devinfo +netdiscover-to-devinfo
+  TITLE:=LuCI Diagnostics Tools (Device Info)
+endef
+
+define Package/luci-app-voice-core
+  $(call Package/luci/webtemplate)
+  DEPENDS+=+luci-admin-core 
+  TITLE:=LuCI Voice Software (Core)
+endef
+
+define Package/luci-app-voice-diag
+  $(call Package/luci/webtemplate)
+  DEPENDS+=+luci-app-voice-core +luci-app-diag-devinfo
+  TITLE:=LuCI Voice Software (Diagnostics)
+endef
+
+define Package/luci-app-diag-devinfo/conffiles
+/etc/config/luci_devinfo
+endef
+
+define Package/luci-app-diag-core/install
+       $(call Package/luci/install/template,$(1),applications/luci-diag-core)
+endef
+
+define Package/luci-app-diag-devinfo/install
+       $(call Package/luci/install/template,$(1),applications/luci-diag-devinfo)
+endef
+
+define Package/luci-app-voice-core/install
+       $(call Package/luci/install/template,$(1),applications/luci-voice-core)
+endef
+
+define Package/luci-app-voice-diag/install
+       $(call Package/luci/install/template,$(1),applications/luci-voice-diag)
+endef
 
 define Package/luci-app-upnp
   $(call Package/luci/webtemplate)
@@ -885,6 +938,9 @@ endif
 ifneq ($(CONFIG_PACKAGE_luci-json),)
        PKG_SELECTED_MODULES+=libs/json
 endif
+ifneq ($(CONFIG_PACKAGE_luci-lmo),)
+       PKG_SELECTED_MODULES+=libs/lmo
+endif
 ifneq ($(CONFIG_PACKAGE_luci-luanet),)
        PKG_SELECTED_MODULES+=libs/luanet
 endif
@@ -951,6 +1007,18 @@ endif
 ifneq ($(CONFIG_PACKAGE_luci-app-statistics),)
        PKG_SELECTED_MODULES+=applications/luci-statistics
 endif
+ifneq ($(CONFIG_PACKAGE_luci-app-voice-core),)
+       PKG_SELECTED_MODULES+=applications/luci-voice-core
+endif
+ifneq ($(CONFIG_PACKAGE_luci-app-voice-diag),)
+       PKG_SELECTED_MODULES+=applications/luci-voice-diag
+endif
+ifneq ($(CONFIG_PACKAGE_luci-app-diag-core),)
+       PKG_SELECTED_MODULES+=applications/luci-diag-core
+endif
+ifneq ($(CONFIG_PACKAGE_luci-app-diag-devinfo),)
+       PKG_SELECTED_MODULES+=applications/luci-diag-devinfo
+endif
 ifneq ($(CONFIG_PACKAGE_luci-app-upnp),)
        PKG_SELECTED_MODULES+=applications/luci-upnp
 endif
@@ -1078,6 +1146,7 @@ $(eval $(call BuildPackage,luci-http))
 $(eval $(call BuildPackage,luci-httpclient))
 $(eval $(call BuildPackage,luci-ipkg))
 $(eval $(call BuildPackage,luci-json))
+$(eval $(call BuildPackage,luci-lmo))
 $(eval $(call BuildPackage,luci-luanet))
 $(eval $(call BuildPackage,luci-lucid))
 $(eval $(call BuildPackage,luci-nixio))
@@ -1102,6 +1171,10 @@ $(eval $(call BuildPackage,luci-app-olsr))
 $(eval $(call BuildPackage,luci-app-qos))
 $(eval $(call BuildPackage,luci-app-splash))
 $(eval $(call BuildPackage,luci-app-statistics))
+$(eval $(call BuildPackage,luci-app-diag-core))
+$(eval $(call BuildPackage,luci-app-diag-devinfo))
+$(eval $(call BuildPackage,luci-app-voice-core))
+$(eval $(call BuildPackage,luci-app-voice-diag))
 $(eval $(call BuildPackage,luci-app-upnp))
 $(eval $(call BuildPackage,luci-app-ntpc))
 $(eval $(call BuildPackage,luci-app-ddns))
index e513053..f3c481c 100644 (file)
@@ -30,9 +30,10 @@ require("luci.template")
 local util = require("luci.util")
 require("luci.http")
 require("luci.uvl")
-require("luci.fs")
+
 
 --local event      = require "luci.sys.event"
+local fs         = require("nixio.fs")
 local uci        = require("luci.model.uci")
 local class      = util.class
 local instanceof = util.instanceof
@@ -52,7 +53,7 @@ REMOVE_PREFIX = "cbi.rts."
 
 -- Loads a CBI map from given file, creating an environment and returns it
 function load(cbimap, ...)
-       require("luci.fs")
+       local fs   = require "nixio.fs"
        local i18n = require "luci.i18n"
        require("luci.config")
        require("luci.util")
@@ -60,9 +61,9 @@ function load(cbimap, ...)
        local upldir = "/lib/uci/upload/"
        local cbidir = luci.util.libpath() .. "/model/cbi/"
 
-       assert(luci.fs.stat(cbimap) or
-               luci.fs.stat(cbidir..cbimap..".lua") or
-               luci.fs.stat(cbidir..cbimap..".lua.gz"),
+       assert(fs.stat(cbimap) or
+               fs.stat(cbidir..cbimap..".lua") or
+               fs.stat(cbidir..cbimap..".lua.gz"),
                        "Model not found!")
 
        local func, err = loadfile(cbimap)
@@ -1703,7 +1704,7 @@ end
 
 function FileUpload.cfgvalue(self, section)
        local val = AbstractValue.cfgvalue(self, section)
-       if val and luci.fs.access(val) then
+       if val and fs.access(val) then
                return val
        end
        return nil
@@ -1717,7 +1718,7 @@ function FileUpload.formvalue(self, section)
                then
                        return val
                end
-               luci.fs.unlink(val)
+               fs.unlink(val)
                self.value = nil
        end
        return nil
@@ -1725,7 +1726,7 @@ end
 
 function FileUpload.remove(self, section)
        local val = AbstractValue.formvalue(self, section)
-       if val and luci.fs.access(val) then luci.fs.unlink(val) end
+       if val and fs.access(val) then fs.unlink(val) end
        return AbstractValue.remove(self, section)
 end
 
index 5eda993..f829572 100644 (file)
@@ -48,7 +48,8 @@ $Id$
 </head>
 <body>
        <%
-               require("luci.fs")
+               require("nixio.fs")
+               require("nixio.util")
                require("luci.http")
                require("luci.dispatcher")
 
@@ -63,7 +64,7 @@ $Id$
                end
 
                local filepath = table.concat( path, '/' )
-               local filestat = luci.fs.stat( filepath )
+               local filestat = nixio.fs.stat( filepath )
                local baseurl  = luci.dispatcher.build_url('admin', 'filebrowser')
 
                if filestat and filestat.type == "reg" then
@@ -76,7 +77,7 @@ $Id$
                        filepath = filepath .. '/'
                end
 
-               local entries = luci.fs.dir(filepath)
+               local entries = nixio.util.consume((nixio.fs.dir(filepath)))
        -%>
     <div id="path">
                Location:
@@ -98,8 +99,8 @@ $Id$
        <div id="listing">
                <ul>
                        <% for _, e in luci.util.vspairs(entries) do
-                           local stat = luci.fs.stat(filepath..e)
-                               if e ~= '.' and e ~= '..' and stat and stat.type == 'dir' then
+                           local stat = nixio.fs.stat(filepath..e)
+                               if stat and stat.type == 'dir' then
                        -%>
                                <li class="dir">
                                        <img src="/luci-static/resources/cbi/folder.png" alt="Directory" />
@@ -108,7 +109,7 @@ $Id$
                        <% end end -%>
 
                        <% for _, e in luci.util.vspairs(entries) do
-                           local stat = luci.fs.stat(filepath..e)
+                           local stat = nixio.fs.stat(filepath..e)
                                if stat and stat.type ~= 'dir' then
                        -%>
                                <li class="file">
index a4ab0c9..7bde74b 100644 (file)
@@ -16,10 +16,11 @@ $Id$
 <%
        local t = require("luci.tools.webadmin")
        local v = self:cfgvalue(section)
+       v = v and nixio.fs.stat(v)
 -%>
 <%+cbi/valueheader%>
        <% if v then %>
-               <%:cbi_upload Uploaded File%> (<%=t.byte_format(luci.fs.stat(v, "size") or 0)%>)
+               <%:cbi_upload Uploaded File%> (<%=t.byte_format(v.size)%>)
                <input type="hidden"<%= attr("value", v) .. attr("name", cbid) .. attr("id", cbid) %> />
                <input class="cbi-input-image" type="image" value="<%:cbi_replace%>" name="cbi.rlf.<%=section .. "." .. self.option%>" alt="<%:cbi_replace%>" title="<%:cbi_replace%>" src="<%=resource%>/cbi/reload.gif" />
        <% else %>
index f991ab8..3969254 100644 (file)
@@ -6,13 +6,24 @@ module "luci.debug"
 __file__ = debug.getinfo(1, 'S').source:sub(2)
 
 -- Enables the memory tracer with given flags and returns a function to disable the tracer again
-function trap_memtrace(flags)
-       flags = flags or "l"
-       local tracefile = io.open("/tmp/memtrace", "w")
+function trap_memtrace(flags, dest)
+       flags = flags or "clr"
+       local tracefile = io.open(dest or "/tmp/memtrace", "w")
+       local peak = 0
 
        local function trap(what, line)
                local info = debug.getinfo(2, "Sn")
-               tracefile:write(info.source..":"..line.."\t"..(info.namewhat or "").."\t"..(info.name or "").."\t"..collectgarbage("count").."\n")
+               if collectgarbage("count") > peak then
+                       peak = collectgarbage("count")
+               end
+               if tracefile then
+                       tracefile:write(
+                               "[", what, "] ", info.source, ":", (line or "?"), "\t",
+                               (info.namewhat or ""), "\t",
+                               (info.name or ""), "\t",
+                               collectgarbage("count"), " (", peak, ")\n"
+                       )
+               end
        end
 
        debug.sethook(trap, flags)
index 79f01a6..f83cac5 100644 (file)
@@ -37,6 +37,7 @@ local rawget, rawset, unpack = rawget, rawset, unpack
 local tostring, type, assert = tostring, type, assert
 local ipairs, pairs, loadstring = ipairs, pairs, loadstring
 local require, pcall, xpcall = require, pcall, xpcall
+local collectgarbage, get_memory_limit = collectgarbage, get_memory_limit
 
 --- LuCI utility functions.
 module "luci.util"
@@ -554,10 +555,10 @@ function strip_bytecode(code)
                end
        end
 
-       local strip_function
-       strip_function = function(code)
+       local function strip_function(code)
                local count, offset = subint(code, 1, size)
-               local stripped, dirty = string.rep("\0", size), offset + count
+               local stripped = { string.rep("\0", size) }
+               local dirty = offset + count
                offset = offset + count + int * 2 + 4
                offset = offset + int + subint(code, offset, int) * ins
                count, offset = subint(code, offset, int)
@@ -575,10 +576,11 @@ function strip_bytecode(code)
                        end
                end
                count, offset = subint(code, offset, int)
-               stripped = stripped .. code:sub(dirty, offset - 1)
+               stripped[#stripped+1] = code:sub(dirty, offset - 1)
                for n = 1, count do
                        local proto, off = strip_function(code:sub(offset, -1))
-                       stripped, offset = stripped .. proto, offset + off - 1
+                       stripped[#stripped+1] = proto
+                       offset = offset + off - 1
                end
                offset = offset + subint(code, offset, int) * int + int
                count, offset = subint(code, offset, int)
@@ -589,8 +591,8 @@ function strip_bytecode(code)
                for n = 1, count do
                        offset = offset + subint(code, offset, size) + size
                end
-               stripped = stripped .. string.rep("\0", int * 3)
-               return stripped, offset
+               stripped[#stripped+1] = string.rep("\0", int * 3)
+               return table.concat(stripped), offset
        end
 
        return code:sub(1,12) .. strip_function(code:sub(13,-1))
@@ -703,7 +705,7 @@ end
 --- Returns the absolute path to LuCI base directory.
 -- @return             String containing the directory path
 function libpath()
-       return require "luci.fs".dirname(ldebug.__file__)
+       return require "nixio.fs".dirname(ldebug.__file__)
 end
 
 
@@ -783,5 +785,11 @@ end
 
 -- Resume execution of protected function call
 function performResume(err, co, ...)
+       if get_memory_limit and get_memory_limit() > 0 and
+          collectgarbage("count") > (get_memory_limit() * 0.8)
+       then
+               collectgarbage("collect")
+       end
+
        return handleReturnValue(err, co, coroutine.resume(co, ...))
 end
diff --git a/libs/lmo/Makefile b/libs/lmo/Makefile
new file mode 100644 (file)
index 0000000..a15390c
--- /dev/null
@@ -0,0 +1,46 @@
+ifneq (,$(wildcard ../../build/config.mk))
+include ../../build/config.mk
+include ../../build/module.mk
+include ../../build/gccconfig.mk
+else
+include standalone.mk
+endif
+
+LMO_LDFLAGS    =
+LMO_CFLAGS     =
+LMO_SO         = lmo.so
+LMO_PO2LMO     = po2lmo
+LMO_LOOKUP     = lookup
+LMO_COMMON_OBJ = src/lmo_core.o src/lmo_hash.o
+LMO_PO2LMO_OBJ = src/lmo_po2lmo.o
+LMO_LOOKUP_OBJ = src/lmo_lookup.o
+LMO_LUALIB_OBJ = src/lmo_lualib.o
+
+%.o: %.c
+       $(COMPILE) $(LMO_CFLAGS) $(LUA_CFLAGS) $(FPIC) -c -o $@ $< 
+
+compile: build-clean $(LMO_COMMON_OBJ) $(LMO_PO2LMO_OBJ) $(LMO_LOOKUP_OBJ) $(LMO_LUALIB_OBJ)
+       $(LINK) $(SHLIB_FLAGS) $(LMO_LDFLAGS) -o src/$(LMO_SO) \
+               $(LMO_COMMON_OBJ) $(LMO_LUALIB_OBJ)
+       $(LINK) $(LMO_LDFLAGS) -o src/$(LMO_PO2LMO) $(LMO_COMMON_OBJ) $(LMO_PO2LMO_OBJ)
+       $(LINK) $(LMO_LDFLAGS) -o src/$(LMO_LOOKUP) $(LMO_COMMON_OBJ) $(LMO_LOOKUP_OBJ)
+       mkdir -p dist$(LUA_LIBRARYDIR)
+       cp src/$(LMO_SO) dist$(LUA_LIBRARYDIR)/$(LMO_SO)
+
+install: build
+       cp -pR dist$(LUA_LIBRARYDIR)/* $(LUA_LIBRARYDIR)
+
+clean: build-clean
+
+build-clean:
+       rm -f src/*.o src/lookup src/po2lmo src/lmo.so
+
+host-compile: build-clean host-clean $(LMO_COMMON_OBJ) $(LMO_PO2LMO_OBJ)
+       $(LINK) $(LMO_LDFLAGS) -o src/$(LMO_PO2LMO) $(LMO_COMMON_OBJ) $(LMO_PO2LMO_OBJ)
+
+host-install: host-compile
+       cp src/$(LMO_PO2LMO) ../../build/$(LMO_PO2LMO)
+
+host-clean:
+       rm -f ../../build/$(LMO_PO2LMO)
+
diff --git a/libs/lmo/src/lmo.h b/libs/lmo/src/lmo.h
new file mode 100644 (file)
index 0000000..ab17e87
--- /dev/null
@@ -0,0 +1,72 @@
+/*
+ * lmo - Lua Machine Objects - General header
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#ifndef _LMO_H_
+#define _LMO_H_
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <string.h>
+#include <fcntl.h>
+#include <sys/stat.h>
+#include <sys/mman.h>
+#include <arpa/inet.h>
+#include <unistd.h>
+#include <errno.h>
+
+
+#if (defined(__GNUC__) && defined(__i386__))
+#define sfh_get16(d) (*((const uint16_t *) (d)))
+#else
+#define sfh_get16(d) ((((uint32_t)(((const uint8_t *)(d))[1])) << 8)\
+                                          +(uint32_t)(((const uint8_t *)(d))[0]) )
+#endif
+
+
+struct lmo_entry {
+       uint32_t key_id;
+       uint32_t val_id;
+       uint32_t offset;
+       uint32_t length;
+       struct lmo_entry *next;
+} __attribute__((packed));
+
+typedef struct lmo_entry lmo_entry_t;
+
+
+struct lmo_archive {
+       int         fd;
+       uint32_t    length;
+       lmo_entry_t *index;
+       char        *mmap;
+};
+
+typedef struct lmo_archive lmo_archive_t;
+
+
+uint32_t sfh_hash(const char * data, int len);
+
+char _lmo_error[1024];
+const char * lmo_error(void);
+
+lmo_archive_t * lmo_open(const char *file);
+int lmo_lookup(lmo_archive_t *ar, const char *key, char *dest, int len);
+void lmo_close(lmo_archive_t *ar);
+
+#endif
diff --git a/libs/lmo/src/lmo_core.c b/libs/lmo/src/lmo_core.c
new file mode 100644 (file)
index 0000000..b3cb7c0
--- /dev/null
@@ -0,0 +1,231 @@
+/*
+ * lmo - Lua Machine Objects - Base functions
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "lmo.h"
+
+extern char _lmo_error[1024];
+
+static int lmo_read32( int fd, uint32_t *val )
+{
+       uint8_t buffer[5];
+
+       if( read(fd, buffer, 4) < 4 )
+               return -1;
+
+       buffer[4] = 0;
+       *val = ntohl(*((uint32_t *) buffer));
+
+       return 4;
+}
+
+static char * error(const char *message, int add_errno)
+{
+       memset(_lmo_error, 0, sizeof(_lmo_error));
+
+       if( add_errno )
+               snprintf(_lmo_error, sizeof(_lmo_error),
+                       "%s: %s", message, strerror(errno));
+       else
+               snprintf(_lmo_error, sizeof(_lmo_error), "%s", message);
+
+       return NULL;
+}
+
+const char * lmo_error(void)
+{
+       return _lmo_error;
+}
+
+lmo_archive_t * lmo_open(const char *file)
+{
+       int in = -1;
+       uint32_t idx_offset = 0;
+       uint32_t i;
+       struct stat s;
+
+       lmo_archive_t *ar    = NULL;
+       lmo_entry_t   *head  = NULL;
+       lmo_entry_t   *entry = NULL;
+
+       if( stat(file, &s) == -1 )
+       {
+               error("Can not stat file", 1);
+               goto cleanup;
+       }
+
+       if( (in = open(file, O_RDONLY)) == -1 )
+       {
+               error("Can not open file", 1);
+               goto cleanup;
+       }
+
+       if( lseek(in, -sizeof(uint32_t), SEEK_END) == -1 )
+       {
+               error("Can not seek to eof", 1);
+               goto cleanup;
+       }
+
+       if( lmo_read32(in, &idx_offset) != 4 )
+       {
+               error("Unexpected EOF while reading index offset", 0);
+               goto cleanup;
+       }
+
+       if( lseek(in, idx_offset, SEEK_SET) == -1 )
+       {
+               error("Can not seek to index offset", 1);
+               goto cleanup;
+       }
+
+       if( (ar = (lmo_archive_t *) malloc(sizeof(lmo_archive_t))) != NULL )
+       {
+               ar->fd     = in;
+               ar->length = idx_offset;
+
+               for( i = idx_offset;
+                    i < (s.st_size - sizeof(uint32_t));
+                    i += (4 * sizeof(uint32_t))
+               ) {
+                       if( (entry = (lmo_entry_t *) malloc(sizeof(lmo_entry_t))) != NULL )
+                       {
+                               if( (lmo_read32(ar->fd, &entry->key_id) == 4) &&
+                                   (lmo_read32(ar->fd, &entry->val_id) == 4) &&
+                                   (lmo_read32(ar->fd, &entry->offset) == 4) &&
+                                   (lmo_read32(ar->fd, &entry->length) == 4)
+                               ) {
+                                       entry->next = head;
+                                       head = entry;
+                               }
+                               else
+                               {
+                                       error("Unexpected EOF while reading index entry", 0);
+                                       goto cleanup;
+                               }
+                       }
+                       else
+                       {
+                               error("Out of memory", 0);
+                               goto cleanup;
+                       }
+               }
+
+               ar->index = head;
+
+               if( lseek(ar->fd, 0, SEEK_SET) == -1 )
+               {
+                       error("Can not seek to start", 1);
+                       goto cleanup;
+               }
+
+               if( (ar->mmap = mmap(NULL, ar->length, PROT_READ, MAP_SHARED, ar->fd, 0)) == MAP_FAILED )
+               {
+                       error("Failed to memory map archive contents", 1);
+                       goto cleanup;
+               }
+
+               return ar;
+       }
+       else
+       {
+               error("Out of memory", 0);
+               goto cleanup;
+       }
+
+
+       cleanup:
+
+       if( in > -1 )
+               close(in);
+
+       if( head != NULL )
+       {
+               entry = head;
+
+               while( entry != NULL )
+               {
+                       head = entry->next;
+                       free(entry);
+                       entry = head;
+               }
+
+               head = entry = NULL;
+       }
+
+       if( ar != NULL )
+       {
+               if( (ar->mmap != NULL) && (ar->mmap != MAP_FAILED) )
+                       munmap(ar->mmap, ar->length);
+
+               free(ar);
+               ar = NULL;
+       }
+
+       return NULL;
+}
+
+void lmo_close(lmo_archive_t *ar)
+{
+       lmo_entry_t *head  = NULL;
+       lmo_entry_t *entry = NULL;
+
+       if( ar != NULL )
+       {
+               entry = ar->index;
+
+               while( entry != NULL )
+               {
+                       head = entry->next;
+                       free(entry);
+                       entry = head;
+               }
+
+               head = entry = NULL;
+
+               if( (ar->mmap != NULL) && (ar->mmap != MAP_FAILED) )
+                       munmap(ar->mmap, ar->length);
+
+               close(ar->fd);
+               free(ar);
+
+               ar = NULL;
+       }
+}
+
+int lmo_lookup(lmo_archive_t *ar, const char *key, char *dest, int len)
+{
+       uint32_t look_key = sfh_hash(key, strlen(key));
+       int copy_len = -1;
+
+       lmo_entry_t *entry = ar->index;
+
+       while( entry != NULL )
+       {
+               if( entry->key_id == look_key )
+               {
+                       copy_len = (len > entry->length) ? entry->length : len;
+                       memcpy(dest, &ar->mmap[entry->offset], copy_len);
+
+                       break;
+               }
+
+               entry = entry->next;
+       }
+
+       return copy_len;
+}
+
diff --git a/libs/lmo/src/lmo_hash.c b/libs/lmo/src/lmo_hash.c
new file mode 100644 (file)
index 0000000..bc8e6fe
--- /dev/null
@@ -0,0 +1,53 @@
+/*
+ * Hash function from http://www.azillionmonkeys.com/qed/hash.html
+ * Copyright (C) 2004-2008 by Paul Hsieh
+ */
+
+#include "lmo.h"
+
+uint32_t sfh_hash(const char * data, int len)
+{
+       uint32_t hash = len, tmp;
+       int rem;
+
+       if (len <= 0 || data == NULL) return 0;
+
+       rem = len & 3;
+       len >>= 2;
+
+       /* Main loop */
+       for (;len > 0; len--) {
+               hash  += sfh_get16(data);
+               tmp    = (sfh_get16(data+2) << 11) ^ hash;
+               hash   = (hash << 16) ^ tmp;
+               data  += 2*sizeof(uint16_t);
+               hash  += hash >> 11;
+       }
+
+       /* Handle end cases */
+       switch (rem) {
+               case 3: hash += sfh_get16(data);
+                       hash ^= hash << 16;
+                       hash ^= data[sizeof(uint16_t)] << 18;
+                       hash += hash >> 11;
+                       break;
+               case 2: hash += sfh_get16(data);
+                       hash ^= hash << 11;
+                       hash += hash >> 17;
+                       break;
+               case 1: hash += *data;
+                       hash ^= hash << 10;
+                       hash += hash >> 1;
+       }
+
+       /* Force "avalanching" of final 127 bits */
+       hash ^= hash << 3;
+       hash += hash >> 5;
+       hash ^= hash << 4;
+       hash += hash >> 17;
+       hash ^= hash << 25;
+       hash += hash >> 6;
+
+       return hash;
+}
+
diff --git a/libs/lmo/src/lmo_lookup.c b/libs/lmo/src/lmo_lookup.c
new file mode 100644 (file)
index 0000000..8b48f7f
--- /dev/null
@@ -0,0 +1,58 @@
+/*
+ * lmo - Lua Machine Objects - Lookup utility
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "lmo.h"
+
+extern char _lmo_error[1024];
+
+static void die(const char *msg)
+{
+       printf("Error: %s\n", msg);
+       exit(1);
+}
+
+static void usage(const char *name)
+{
+       printf("Usage: %s input.lmo key\n", name);
+       exit(1);
+}
+
+int main(int argc, char *argv[])
+{
+       char val[4096];
+       lmo_archive_t *ar = NULL;
+
+       if( argc != 3 )
+               usage(argv[0]);
+
+       if( (ar = (lmo_archive_t *) lmo_open(argv[1])) != NULL )
+       {
+               if( lmo_lookup(ar, argv[2], val, sizeof(val)) > -1 )
+               {
+                       printf("%s\n", val);
+               }
+
+               lmo_close(ar);
+       }
+       else
+       {
+               die(lmo_error());
+       }
+
+       return 0;
+}
diff --git a/libs/lmo/src/lmo_lualib.c b/libs/lmo/src/lmo_lualib.c
new file mode 100644 (file)
index 0000000..676f788
--- /dev/null
@@ -0,0 +1,152 @@
+/*
+ * lmo - Lua Machine Objects - Lua binding
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "lmo_lualib.h"
+
+extern char _lmo_error[1024];
+
+
+static int lmo_L_open(lua_State *L) {
+       const char *filename = luaL_checklstring(L, 1, NULL);
+       lmo_archive_t *ar, **udata;
+
+       if( (ar = lmo_open(filename)) != NULL )
+       {
+               if( (udata = lua_newuserdata(L, sizeof(lmo_archive_t *))) != NULL )
+               {
+                       *udata = ar;
+                       luaL_getmetatable(L, LMO_ARCHIVE_META);
+                       lua_setmetatable(L, -2);
+                       return 1;
+               }
+
+               lmo_close(ar);
+               lua_pushnil(L);
+               lua_pushstring(L, "out of memory");
+               return 2;
+       }
+
+       lua_pushnil(L);
+       lua_pushstring(L, lmo_error());
+       return 2;
+}
+
+static int lmo_L_hash(lua_State *L) {
+       const char *data = luaL_checkstring(L, 1);
+       uint32_t hash = sfh_hash(data, strlen(data));
+       lua_pushinteger(L, (lua_Integer)hash);
+       return 1;
+}
+
+static int _lmo_lookup(lua_State *L, lmo_archive_t *ar, uint32_t hash) {
+       lmo_entry_t *e = ar->index;
+
+       while( e != NULL )
+       {
+               if( e->key_id == hash )
+               {
+                       lua_pushlstring(L, &ar->mmap[e->offset], e->length);
+                       return 1;
+               }
+
+               e = e->next;
+       }
+
+       lua_pushnil(L);
+       return 1;
+}
+
+static int lmo_L_get(lua_State *L) {
+       lmo_archive_t **ar = luaL_checkudata(L, 1, LMO_ARCHIVE_META);
+       uint32_t hash = (uint32_t) luaL_checkinteger(L, 2);
+       return _lmo_lookup(L, *ar, hash);
+}
+
+static int lmo_L_lookup(lua_State *L) {
+       lmo_archive_t **ar = luaL_checkudata(L, 1, LMO_ARCHIVE_META);
+       const char *key = luaL_checkstring(L, 2);
+       uint32_t hash = sfh_hash(key, strlen(key));
+       return _lmo_lookup(L, *ar, hash);
+}
+
+static int lmo_L_foreach(lua_State *L) {
+       lmo_archive_t **ar = luaL_checkudata(L, 1, LMO_ARCHIVE_META);
+       lmo_entry_t *e = (*ar)->index;
+
+       if( lua_isfunction(L, 2) )
+       {
+               while( e != NULL )
+               {
+                       lua_pushvalue(L, 2);
+                       lua_pushinteger(L, e->key_id);
+                       lua_pushlstring(L, &(*ar)->mmap[e->offset], e->length);
+                       lua_pcall(L, 2, 0, 0);
+                       e = e->next;
+               }
+       }
+
+       return 0;
+}
+
+static int lmo_L__gc(lua_State *L) {
+       lmo_archive_t **ar = luaL_checkudata(L, 1, LMO_ARCHIVE_META);
+
+       if( (*ar) != NULL )
+               lmo_close(*ar);
+
+       *ar = NULL;
+
+       return 0;
+}
+
+static int lmo_L__tostring(lua_State *L) {
+       lmo_archive_t **ar = luaL_checkudata(L, 1, LMO_ARCHIVE_META);
+       lua_pushfstring(L, "LMO Archive (%d bytes)", (*ar)->length);
+       return 1;
+}
+
+
+/* method table */
+static const luaL_reg M[] = {
+       {"close",       lmo_L__gc},
+       {"get",         lmo_L_get},
+       {"lookup",      lmo_L_lookup},
+       {"foreach",     lmo_L_foreach},
+       {"__tostring",  lmo_L__tostring},
+       {"__gc",        lmo_L__gc},
+       {NULL,          NULL}
+};
+
+/* module table */
+static const luaL_reg R[] = {
+       {"open",        lmo_L_open},
+       {"hash",        lmo_L_hash},
+       {NULL,          NULL}
+};
+
+LUALIB_API int luaopen_lmo(lua_State *L) {
+       luaL_newmetatable(L, LMO_ARCHIVE_META);
+       luaL_register(L, NULL, M);
+       lua_pushvalue(L, -1);
+       lua_setfield(L, -2, "__index");
+       lua_setglobal(L, LMO_ARCHIVE_META);
+
+       luaL_register(L, LMO_LUALIB_META, R);
+
+       return 1;
+}
diff --git a/libs/lmo/src/lmo_lualib.h b/libs/lmo/src/lmo_lualib.h
new file mode 100644 (file)
index 0000000..096fa02
--- /dev/null
@@ -0,0 +1,33 @@
+/*
+ * lmo - Lua Machine Objects - Lua library header
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#ifndef _LMO_LUALIB_H_
+#define _LMO_LUALIB_H_
+
+#include <lua.h>
+#include <lualib.h>
+#include <lauxlib.h>
+
+#include "lmo.h"
+
+#define LMO_LUALIB_META  "lmo"
+#define LMO_ARCHIVE_META "lmo.archive"
+
+LUALIB_API int luaopen_lmo(lua_State *L);
+
+#endif
diff --git a/libs/lmo/src/lmo_po2lmo.c b/libs/lmo/src/lmo_po2lmo.c
new file mode 100644 (file)
index 0000000..9f78ff2
--- /dev/null
@@ -0,0 +1,199 @@
+/*
+ * lmo - Lua Machine Objects - PO to LMO conversion tool
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "lmo.h"
+
+static void die(const char *msg)
+{
+       fprintf(stderr, "Error: %s\n", msg);
+       exit(1);
+}
+
+static void usage(const char *name)
+{
+       fprintf(stderr, "Usage: %s input.po output.lmo\n", name);
+       exit(1);
+}
+
+static void print(const void *ptr, size_t size, size_t nmemb, FILE *stream)
+{
+       if( fwrite(ptr, size, nmemb, stream) == 0 )
+               die("Failed to write stdout");
+}
+
+static int extract_string(const char *src, char *dest, int len)
+{
+       int pos = 0;
+       int esc = 0;
+       int off = -1;
+
+       for( pos = 0; (pos < strlen(src)) && (pos < len); pos++ )
+       {
+               if( (off == -1) && (src[pos] == '"') )
+               {
+                       off = pos + 1;
+               }
+               else if( off >= 0 )
+               {
+                       if( esc == 1 )
+                       {
+                               dest[pos-off] = src[pos];
+                               esc = 0;
+                       }
+                       else if( src[pos] == '\\' )
+                       {
+                               off++;
+                               esc = 1;
+                               
+                       }
+                       else if( src[pos] != '"' )
+                       {
+                               dest[pos-off] = src[pos];
+                       }
+                       else
+                       {
+                               dest[pos-off] = '\0';
+                               break;
+                       }
+               }
+       }
+
+       return (off > -1) ? strlen(dest) : -1;
+}
+
+int main(int argc, char *argv[])
+{
+       char line[4096];
+       char key[4096];
+       char val[4096];
+       char tmp[4096];
+       int state  = 0;
+       int offset = 0;
+       int length = 0;
+
+       FILE *in;
+       FILE *out;
+
+       lmo_entry_t *head  = NULL;
+       lmo_entry_t *entry = NULL;
+
+       if( (argc != 3) || ((in = fopen(argv[1], "r")) == NULL) || ((out = fopen(argv[2], "w")) == NULL) )
+               usage(argv[0]);
+
+       memset(line, 0, sizeof(key));
+       memset(key, 0, sizeof(val));
+       memset(val, 0, sizeof(val));
+
+       while( (NULL != fgets(line, sizeof(line), in)) || (state >= 2 && feof(in)) )
+       {
+               if( state == 0 && strstr(line, "msgid \"") == line )
+               {
+                       switch(extract_string(line, key, sizeof(key)))
+                       {
+                               case -1:
+                                       die("Syntax error in msgid");
+                               case 0:
+                                       continue;
+                               default:
+                                       state = 1;
+                       }
+               }
+               else if( state == 1 && strstr(line, "msgstr \"") == line )
+               {
+                       switch(extract_string(line, val, sizeof(val)))
+                       {
+                               case -1:
+                                       die("Syntax error in msgstr");
+                               case 0:
+                                       state = 2;
+                                       break;
+                               default:
+                                       state = 3;
+                       }
+               }
+               else if( state == 2 )
+               {
+                       switch(extract_string(line, tmp, sizeof(tmp)))
+                       {
+                               case -1:
+                                       state = 3;
+                                       break;
+                               default:
+                                       strcat(val, tmp);
+                       }
+               }
+               else if( state == 3 )
+               {
+                       if( strlen(key) > 0 && strlen(val) > 0 )
+                       {
+                               if( (entry = (lmo_entry_t *) malloc(sizeof(lmo_entry_t))) != NULL )
+                               {
+                                       memset(entry, 0, sizeof(entry));
+                                       length = strlen(val) + ((4 - (strlen(val) % 4)) % 4);
+
+                                       entry->key_id = htonl(sfh_hash(key, strlen(key)));
+                                       entry->val_id = htonl(sfh_hash(val, strlen(val)));
+                                       entry->offset = htonl(offset);
+                                       entry->length = htonl(strlen(val));
+
+                                       print(val, length, 1, out);
+                                       offset += length;
+
+                                       entry->next = head;
+                                       head = entry;
+                               }
+                               else
+                               {
+                                       die("Out of memory");
+                               }
+                       }
+
+                       state = 0;
+                       memset(key, 0, sizeof(key));
+                       memset(val, 0, sizeof(val));
+               }
+
+               memset(line, 0, sizeof(line));
+       }
+
+       entry = head;
+       while( entry != NULL )
+       {
+               print(&entry->key_id, sizeof(uint32_t), 1, out);
+               print(&entry->val_id, sizeof(uint32_t), 1, out);
+               print(&entry->offset, sizeof(uint32_t), 1, out);
+               print(&entry->length, sizeof(uint32_t), 1, out);
+               entry = entry->next;
+       }
+
+       if( offset > 0 )
+       {
+               offset = htonl(offset);
+               print(&offset, sizeof(uint32_t), 1, out);
+               fsync(fileno(out));
+               fclose(out);
+       }
+       else
+       {
+               fclose(out);
+               unlink(argv[2]);
+       }
+
+       fclose(in);
+       return(0);
+}
diff --git a/libs/lmo/standalone.mk b/libs/lmo/standalone.mk
new file mode 100644 (file)
index 0000000..66a0e5a
--- /dev/null
@@ -0,0 +1,56 @@
+LUAC = luac
+LUAC_OPTIONS = -s
+LUA_TARGET ?= source
+
+LUA_MODULEDIR = /usr/local/share/lua/5.1
+LUA_LIBRARYDIR = /usr/local/lib/lua/5.1
+
+OS ?= $(shell uname)
+
+LUA_SHLIBS = $(shell pkg-config --silence-errors --libs lua5.1 || pkg-config --silence-errors --libs lua-5.1 || pkg-config --silence-errors --libs lua)
+LUA_LIBS = $(if $(LUA_SHLIBS),$(LUA_SHLIBS),$(firstword $(wildcard /usr/lib/liblua.a /usr/local/lib/liblua.a /opt/local/lib/liblua.a)))
+LUA_CFLAGS = $(shell pkg-config --silence-errors --cflags lua5.1 || pkg-config --silence-errors --cflags lua-5.1 || pkg-config --silence-errors --cflags lua)
+
+CC = gcc
+AR = ar
+RANLIB = ranlib
+CFLAGS = -O2
+FPIC = -fPIC
+EXTRA_CFLAGS = --std=gnu99
+WFLAGS = -Wall -Werror -pedantic
+CPPFLAGS =
+COMPILE = $(CC) $(CPPFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) $(WFLAGS)
+ifeq ($(OS),Darwin)
+  SHLIB_FLAGS = -bundle -undefined dynamic_lookup
+else
+  SHLIB_FLAGS = -shared
+endif
+LINK = $(CC) $(LDFLAGS)
+
+.PHONY: all build compile luacompile luasource clean luaclean
+
+all: build
+
+build: luabuild gccbuild
+
+luabuild: lua$(LUA_TARGET)
+
+gccbuild: compile
+compile:
+
+clean: luaclean
+
+luasource:
+       mkdir -p dist$(LUA_MODULEDIR)
+       cp -pR root/* dist 2>/dev/null || true
+       cp -pR lua/* dist$(LUA_MODULEDIR) 2>/dev/null || true
+       for i in $$(find dist -name .svn); do rm -rf $$i || true; done
+
+luastrip: luasource
+       for i in $$(find dist -type f -name '*.lua'); do perl -e 'undef $$/; open( F, "< $$ARGV[0]" ) || die $$!; $$src = <F>; close F; $$src =~ s/--\[\[.*?\]\](--)?//gs; $$src =~ s/^\s*--.*?\n//gm; open( F, "> $$ARGV[0]" ) || die $$!; print F $$src; close F' $$i; done
+
+luacompile: luasource
+       for i in $$(find dist -name *.lua -not -name debug.lua); do $(LUAC) $(LUAC_OPTIONS) -o $$i $$i; done
+
+luaclean:
+       rm -rf dist
index 95484a0..4c3016a 100644 (file)
@@ -14,6 +14,7 @@ $Id$
 local ipairs, pairs = ipairs, pairs
 local tostring, tonumber = tostring, tonumber
 local pcall, assert, type = pcall, assert, type
+local set_memory_limit = set_memory_limit
 
 local os = require "os"
 local nixio = require "nixio"
@@ -358,6 +359,11 @@ function Server.process(self, client, env)
        local close = false
        local stat, code, msg, message, err
        
+       env.config.memlimit = tonumber(env.config.memlimit)
+       if env.config.memlimit and set_memory_limit then
+               set_memory_limit(env.config.memlimit)
+       end
+
        client:setsockopt("socket", "rcvtimeo", 5)
        client:setsockopt("socket", "sndtimeo", 5)
        
index 89ada3c..d743269 100644 (file)
@@ -41,7 +41,7 @@ local UCINAME = UCINAME
 local SSTATE = "/tmp/.lucid_store"
 
 
-
+--- Starts a new LuCId superprocess.
 function start()
        prepare()
 
@@ -60,6 +60,7 @@ function start()
        run()
 end
 
+--- Stops any running LuCId superprocess. 
 function stop()
        local pid = tonumber(state:get(UCINAME, "main", "pid"))
        if pid then
@@ -68,6 +69,7 @@ function stop()
        return false
 end
 
+--- Prepares the slaves, daemons and publishers, allocate resources.
 function prepare()
        local debug = tonumber((cursor:get(UCINAME, "main", "debug")))
        
@@ -104,24 +106,29 @@ function prepare()
        end)
 end
        
+--- Run the superprocess if prepared before. 
+-- This main function of LuCId will wait for events on given file descriptors.
 function run()
        local pollint = tonumber((cursor:get(UCINAME, "main", "pollinterval")))
-       local threadlimit = tonumber(cursor:get(UCINAME, "main", "threadlimit"))
+       local threadlimit = tonumber((cursor:get(UCINAME, "main", "threadlimit")))
 
        while true do
-               if not threadlimit or tcount < threadlimit then
-                       local stat, code = nixio.poll(pollt, pollint)
+               local stat, code = nixio.poll(pollt, pollint)
                
-                       if stat and stat > 0 then
-                               for _, polle in ipairs(pollt) do
-                                       if polle.revents ~= 0 and polle.handler then
-                                               polle.handler(polle)
-                                       end
+               if stat and stat > 0 then
+                       local ok = false
+                       for _, polle in ipairs(pollt) do
+                               if polle.revents ~= 0 and polle.handler then
+                                       ok = ok or polle.handler(polle)
                                end
-                       elseif stat == 0 then
-                               ifaddrs = nixio.getifaddrs()
-                               collectgarbage("collect")
                        end
+                       if not ok then
+                               -- Avoid high CPU usage if thread limit is reached
+                               nixio.nanosleep(0, 100000000)
+                       end
+               elseif stat == 0 then
+                       ifaddrs = nixio.getifaddrs()
+                       collectgarbage("collect")
                end
                
                for _, cb in ipairs(tickt) do
@@ -139,11 +146,20 @@ function run()
        end
 end
 
+--- Add a file descriptor for the main loop and associate handler functions.
+-- @param polle Table containing: {fd = FILE DESCRIPTOR, events = POLL EVENTS,
+-- handler = EVENT HANDLER CALLBACK}
+-- @see unregister_pollfd
+-- @return boolean status
 function register_pollfd(polle)
        pollt[#pollt+1] = polle
        return true 
 end
 
+--- Unregister a file desciptor and associate handler from the main loop.
+-- @param polle Poll descriptor
+-- @see register_pollfd
+-- @return boolean status
 function unregister_pollfd(polle)
        for k, v in ipairs(pollt) do
                if v == polle then
@@ -154,6 +170,8 @@ function unregister_pollfd(polle)
        return false
 end
 
+--- Close all registered file descriptors from main loop.
+-- This is useful for forked child processes. 
 function close_pollfds()
        for k, v in ipairs(pollt) do
                if v.fd and v.fd.close then
@@ -162,11 +180,19 @@ function close_pollfds()
        end
 end
 
+--- Register a tick function that will be called at each cycle of the main loop.
+-- @param cb Callback
+-- @see unregister_tick
+-- @return boolean status
 function register_tick(cb)
        tickt[#tickt+1] = cb
        return true
 end
 
+--- Unregister a tick function from the main loop.
+-- @param cb Callback
+-- @see register_tick
+-- @return boolean status
 function unregister_tick(cb)
        for k, v in ipairs(tickt) do
                if v == cb then
@@ -177,10 +203,22 @@ function unregister_tick(cb)
        return false
 end
 
+--- Tests whether a given number of processes can be created.
+-- @oaram num Processes to be created
+-- @return boolean status
+function try_process(num)
+       local threadlimit = tonumber((cursor:get(UCINAME, "main", "threadlimit")))
+       return not threadlimit or (threadlimit - tcount) >= (num or 1)
+end
+
+--- Create a new child process from a Lua function and assign a destructor.
+-- @param threadcb main function of the new process
+-- @param waitcb destructor callback
+-- @return process identifier or nil, error code, error message
 function create_process(threadcb, waitcb)
        local threadlimit = tonumber(cursor:get(UCINAME, "main", "threadlimit"))
        if threadlimit and tcount >= threadlimit then
-               nixio.syslog("warning", "Unable to create thread: process limit reached")
+               nixio.syslog("warning", "Cannot create thread: process limit reached")
                return nil
        end
        local pid, code, err = nixio.fork()
@@ -196,6 +234,9 @@ function create_process(threadcb, waitcb)
        return pid, code, err
 end
 
+--- Prepare a daemon from a given configuration table.
+-- @param config Configuration data.
+-- @return boolean status or nil, error code, error message
 function prepare_daemon(config)
        nixio.syslog("info", "Preparing daemon " .. config[".name"])
        local modname = cursor:get(UCINAME, config.slave)
@@ -213,6 +254,9 @@ function prepare_daemon(config)
        return module.prepare_daemon(config, _M)
 end
 
+--- Prepare a slave.
+-- @param name slave name
+-- @return table containing slave module and configuration or nil, error message
 function prepare_slave(name)
        local slave = slaves[name]
        if not slave then
@@ -231,16 +275,24 @@ function prepare_slave(name)
        end
 end
 
+--- Return a list of available network interfaces on the host.
+-- @return table returned by nixio.getifaddrs()
 function get_interfaces()
        return ifaddrs
 end
 
+--- Revoke process privileges.
+-- @param user new user name or uid
+-- @param group new group name or gid
+-- @return boolean status or nil, error code, error message
 function revoke_privileges(user, group)
        if nixio.getuid() == 0 then
                return nixio.setgid(group) and nixio.setuid(user)
        end
 end
 
+--- Return a secure UCI cursor.
+-- @return UCI cursor
 function securestate()
        local stat = nixio.fs.stat(SSTATE) or {}
        local uid = nixio.getuid()
@@ -256,6 +308,8 @@ function securestate()
        return uci.cursor(nil, SSTATE)
 end
 
+--- Daemonize the process.
+-- @return boolean status or nil, error code, error message
 function daemonize()
        if nixio.getppid() == 1 then
                return
index b1b95c1..6c61ff6 100644 (file)
@@ -105,6 +105,9 @@ function prepare_daemon(config, server)
 end
 
 function accept(polle)
+       if not lucid.try_process() then
+               return false
+       end
        local socket, host, port = polle.fd:accept()
        if not socket then
                return nixio.syslog("warn", "accept() failed: " .. port)
index a8f70da..c5a3f3d 100644 (file)
@@ -30,6 +30,7 @@ config daemon http
        list publisher webroot
        list publisher luciweb
        option nokeepalive 1
+       option memlimit 1572864
        option enabled 1
        
 config daemon https
@@ -38,6 +39,7 @@ config daemon https
        list publisher webroot
        list publisher luciweb
        option nokeepalive 1
+       option memlimit 1572864
        option enabled 1
        option tls maincert
        option encryption enable
index 044764e..f70f754 100644 (file)
@@ -87,6 +87,18 @@ $(AXTLS_DIR)/.prepared:
 src/libaxtls.a: $(AXTLS_DIR)/.prepared
        $(MAKE) -C $(AXTLS_DIR) CC="$(CC)" CFLAGS="$(CFLAGS) $(EXTRA_CFLAGS) $(FPIC) -Wall -pedantic -I../config -I../ssl -I../crypto" LDFLAGS="$(LDFLAGS)" OS="$(OS)" clean all
        cp -p $(AXTLS_DIR)/_stage/libaxtls.a src
+       # *************************************************************************
+       #
+       #
+       #
+       # *** WARNING ***
+       # The use of the axTLS cryptographical provider is discouraged!
+       # Please switch to either CyaSSL or OpenSSL.
+       # Support for axTLS might be removed in the near future.
+       #
+       #
+       #
+       #**************************************************************************
 
 clean: luaclean
        rm -f src/*.o src/*.so src/*.a src/*.dll
diff --git a/libs/nixio/docsrc/CHANGELOG.lua b/libs/nixio/docsrc/CHANGELOG.lua
new file mode 100644 (file)
index 0000000..fb1cf16
--- /dev/null
@@ -0,0 +1,29 @@
+--- Changes and improvements.
+module "CHANGELOG"
+
+--- Service Release.
+-- <ul>
+-- <li>Added getifaddrs() function.</li>
+-- <li>Added getsockopt(), setsockopt(), getsockname() and getpeername()
+-- directly to TLS-socket objects unifying the socket interface.</li>
+-- <li>Added support for CyaSSL as cryptographical backend.</li>
+-- <li>Added support for x509 certificates in DER format.</li>
+-- <li>Added support for splice() in UnifiedIO.copyz().</li>
+-- <li>Added interface to inject chunks into UnifiedIO.linesource() buffer.</li>
+-- <li>Changed TLS behaviour to explicitely separate servers and clients.</li>
+-- <li>Fixed usage of signed datatype breaking Base64 decoding.</li>
+-- <li>Fixed namespace clashes for nixio.fs.</li>
+-- <li>Fixed splice() support for some exotic C libraries.</li>
+-- <li>Reconfigure axTLS cryptographical provider and mark it as obsolete.</li>
+-- </ul>
+-- @class table
+-- @name 0.3
+-- @return !
+
+--- Initial Release.
+-- <ul>
+-- <li>Initial Release</li>  
+-- </ul>
+-- @class table
+-- @name 0.2
+-- @return !
\ No newline at end of file
index 20793ce..b957a69 100644 (file)
@@ -80,15 +80,12 @@ module "README"
 
 --- Cryptography and TLS libraries.
 -- <ul>
--- <li>Currently 2 underlying cryptography libraries are supported: openssl and
--- axTLS. The name of the library in use is written to 
+-- <li>Currently 3 underlying cryptography libraries are supported: openssl,
+-- cyassl and axTLS. The name of the library in use is written to 
 -- <strong>nixio.tls_provider</strong></li>
--- <li>You should whenever possible use openssl as axTLS has only limited 
--- support. It does not provide support for non-blocking sockets and
--- is probably less audited than openssl.</li>
--- <li>However in embedded development if you don't need openssl anyway
--- you may safe an essential amount of flash space (about 1 MB for the openssl
--- library) by choosing axTLS over openssl.</li>
+-- <li>You should whenever possible use openssl or cyassl as axTLS has only 
+-- limited support. It does not provide support for non-blocking sockets and
+-- is probably less audited than the other ones.</li>
 -- <li>As the supported Windows versions are not suitable for embedded devices
 -- axTLS is at the moment not supported on Windows.</li>  
 -- </ul>
index d0b189c..6e407ff 100644 (file)
@@ -111,7 +111,6 @@ module "nixio.UnifiedIO"
 -- @usage This function uses the sendfile() syscall to copy the data or the
 -- blocksource function of the source descriptor and the sink function
 -- of the target descriptor as a fallback mechanism.
--- @usage Support for splice() on Linux is not implemented yet.
 -- @usage If the limit parameter is ommited, data is copied
 -- until an end-of-file, end-of-stream, connection shutdown or similar happens.
 -- @usage If the descriptor is non-blocking the function may fail with EAGAIN.
index 3bdad51..6951dd5 100644 (file)
@@ -10,6 +10,12 @@ module "nixio.bit"
 -- @param ...  More Operands
 -- @return number
 
+--- Invert given number.
+-- @class function
+-- @name bnot
+-- @param oper Operand
+-- @return number
+
 --- Bitwise AND several numbers.
 -- @class function
 -- @name band
@@ -28,21 +34,21 @@ module "nixio.bit"
 
 --- Left shift a number.
 -- @class function
--- @name shl
+-- @name lshift
 -- @param oper number
 -- @param shift        bits to shift 
 -- @return number
 
 --- Right shift a number.
 -- @class function
--- @name shr
+-- @name rshift
 -- @param oper number
 -- @param shift        bits to shift 
 -- @return number
 
 --- Arithmetically right shift a number.
 -- @class function
--- @name ashr
+-- @name arshift
 -- @param oper number
 -- @param shift        bits to shift 
 -- @return number
index 0e8c90c..ecefb4c 100644 (file)
@@ -26,10 +26,12 @@ local file = nixio.meta_file
 local uname = nixio.uname()
 local ZBUG = uname.sysname == "Linux" and uname.release:sub(1, 3) == "2.4"
 
-function consume(iter)
-       local tbl = {}
-       for obj in iter do
-               tbl[#tbl+1] = obj
+function consume(iter, append)
+       local tbl = append or {}
+       if iter then
+               for obj in iter do
+                       tbl[#tbl+1] = obj
+               end
        end
        return tbl
 end
@@ -259,4 +261,4 @@ for k, v in pairs(meta) do
        file[k] = v
        socket[k] = v
        tls_socket[k] = v
-end
\ No newline at end of file
+end
diff --git a/libs/nixio/nixio-0.3-1.rockspec b/libs/nixio/nixio-0.3-1.rockspec
new file mode 100644 (file)
index 0000000..755cf81
--- /dev/null
@@ -0,0 +1,37 @@
+package = "nixio"
+version = "0.3-1"
+source = {
+   url = "http://dev.luci.freifunk-halle.net/nixio/nixio-0.3.tar.bz2"
+}
+description = {
+   summary = "System, Networking and I/O library for Lua",
+   detailed = [[
+      Nixio is a multi-platform library offering a wide variety
+      of features such as IPv4, IPv6 and UNIX networking, large file I/O, file
+      system operations, system and process control, POSIX user/group management,
+      basic cryptographical hashing, hmac and TLS support, bit operations and
+      binary conversion.
+   ]],
+   homepage = "http://luci.subsignal.org",
+   license = "Apache 2.0",
+   maintainer = "Steven Barth",
+}
+dependencies = {
+   "lua >= 5.1"
+}
+external_dependencies = {
+   OPENSSL = {
+      header = "openssl/ssl.h",
+   }
+}
+build = {
+   type = "make",
+   build_variables = {
+      NIXIO_LDFLAGS = "-lcrypt -L$(OPENSSL_LIBDIR) -I$(OPENSSL_INCDIR)",
+      LUA_CFLAGS = "$(CFLAGS) -I$(LUA_INCDIR)",
+   },
+   install_variables = {
+      LUA_MODULEDIR = "$(LUADIR)",
+      LUA_LIBRARYDIR = "$(LIBDIR)",
+   },
+}
index 3547f19..41ab8a3 100644 (file)
@@ -18,6 +18,7 @@
 
 #include "nixio.h"
 #include <sys/types.h>
+#include <sys/param.h>
 #include <errno.h>
 #include <string.h>
 
@@ -346,6 +347,9 @@ static int nixio_sock_getpeername(lua_State *L) {
 }
 
 #if defined(__linux__) || defined(BSD)
+#ifdef BSD
+#include <net/if.h>
+#endif
 #include <ifaddrs.h>
 
 static int nixio_getifaddrs(lua_State *L) {
index 14fdeca..9991a7c 100644 (file)
@@ -97,6 +97,13 @@ static int nixio_bit_cast(lua_State *L) {
        return 1;
 }
 
+static int nixio_bit_swap(lua_State *L) {
+       uint64_t op = luaL_checknumber(L, 1);
+       op = (op >> 24) | ((op >> 8) & 0xff00) | ((op & 0xff00) << 8) | (op << 24);
+       lua_pushnumber(L, op);
+       return 1;
+}
+
 /* module table */
 static const luaL_reg R[] = {
        {"bor",                 nixio_bit_or},
@@ -111,6 +118,8 @@ static const luaL_reg R[] = {
        {"div",                 nixio_bit_div},
        {"check",               nixio_bit_check},
        {"cast",                nixio_bit_cast},
+       {"tobit",               nixio_bit_cast},
+       {"bswap",               nixio_bit_swap},
        {NULL,                  NULL}
 };
 
index 4827525..9f99fb8 100644 (file)
@@ -123,14 +123,18 @@ static int nixio_dup(lua_State *L) {
        if (stat == -1) {
                return nixio__perror(L);
        } else {
-               int *udata = lua_newuserdata(L, sizeof(int));
-               if (!udata) {
-                       return luaL_error(L, "out of memory");
-               }
+               if (newfd == -1) {
+                       int *udata = lua_newuserdata(L, sizeof(int));
+                       if (!udata) {
+                               return luaL_error(L, "out of memory");
+                       }
 
-               *udata = stat;
-               luaL_getmetatable(L, NIXIO_FILE_META);
-               lua_setmetatable(L, -2);
+                       *udata = stat;
+                       luaL_getmetatable(L, NIXIO_FILE_META);
+                       lua_setmetatable(L, -2);
+               } else {
+                       lua_pushvalue(L, 2);
+               }
                return 1;
        }
 }
@@ -325,7 +329,7 @@ static int nixio_file_close(lua_State *L) {
 static int nixio_file__gc(lua_State *L) {
        int *fdp = luaL_checkudata(L, 1, NIXIO_FILE_META);
        int res;
-       if (*fdp != -1) {
+       if (*fdp > 2) {
                do {
                        res = close(*fdp);
                } while (res == -1 && errno == EINTR);
index fe71f58..95f6bec 100644 (file)
@@ -42,7 +42,6 @@ clean: luaclean
 
 luasource:
        mkdir -p dist$(LUA_MODULEDIR)
-       cp -pR root/* dist 2>/dev/null || true
        cp -pR lua/* dist$(LUA_MODULEDIR) 2>/dev/null || true
        for i in $$(find dist -name .svn); do rm -rf $$i || true; done
 
@@ -53,4 +52,4 @@ luacompile: luasource
        for i in $$(find dist -name *.lua -not -name debug.lua); do $(LUAC) $(LUAC_OPTIONS) -o $$i $$i; done
 
 luaclean:
-       rm -rf dist
\ No newline at end of file
+       rm -rf dist
index c9f0bcc..d570770 100644 (file)
@@ -27,16 +27,16 @@ limitations under the License.
 
 local io    = require "io"
 local os    = require "os"
-local nixio = require "nixio"
 local table = require "table"
+local nixio = require "nixio"
+local fs    = require "nixio.fs"
 
 local luci  = {}
 luci.util   = require "luci.util"
-luci.fs     = require "luci.fs"
 luci.ip     = require "luci.ip"
 
-local tonumber, ipairs, pairs, pcall, type =
-       tonumber, ipairs, pairs, pcall, type
+local tonumber, ipairs, pairs, pcall, type, next =
+       tonumber, ipairs, pairs, pcall, type, next
 
 
 --- LuCI Linux and POSIX system utilities.
@@ -135,7 +135,7 @@ getenv = nixio.getenv
 -- @return             String containing the system hostname
 function hostname(newname)
        if type(newname) == "string" and #newname > 0 then
-               luci.fs.writefile( "/proc/sys/kernel/hostname", newname .. "\n" )
+               fs.writefile( "/proc/sys/kernel/hostname", newname )
                return newname
        else
                return nixio.uname().nodename
@@ -180,8 +180,8 @@ end
 -- @return     String containing the memory used for buffering in kB
 -- @return     String containing the free memory amount in kB
 function sysinfo()
-       local cpuinfo = luci.fs.readfile("/proc/cpuinfo")
-       local meminfo = luci.fs.readfile("/proc/meminfo")
+       local cpuinfo = fs.readfile("/proc/cpuinfo")
+       local meminfo = fs.readfile("/proc/meminfo")
 
        local system = cpuinfo:match("system typ.-:%s*([^\n]+)")
        local model = ""
@@ -219,26 +219,14 @@ end
 -- @param bytes        Number of bytes for the unique id
 -- @return             String containing hex encoded id
 function uniqueid(bytes)
-       local fp    = io.open("/dev/urandom")
-       local chunk = { fp:read(bytes):byte(1, bytes) }
-       fp:close()
-
-       local hex = ""
-
-       local pattern = "%02X"
-       for i, byte in ipairs(chunk) do
-               hex = hex .. pattern:format(byte)
-       end
-
-       return hex
+       local rand = fs.readfile("/dev/urandom", bytes)
+       return rand and nixio.bin.hexlify(rand)
 end
 
 --- Returns the current system uptime stats.
 -- @return     String containing total uptime in seconds
--- @return     String containing idle time in seconds
 function uptime()
-       local loadavg = io.lines("/proc/uptime")()
-       return loadavg:match("^(.-) (.-)$")
+       return nixio.sysinfo().uptime
 end
 
 
@@ -251,15 +239,15 @@ net = {}
 -- @return     Table of table containing the current arp entries.
 --                     The following fields are defined for arp entry objects:
 --                     { "IP address", "HW address", "HW type", "Flags", "Mask", "Device" }
-function net.arptable()
-       return _parse_delimited_table(io.lines("/proc/net/arp"), "%s%s+")
+function net.arptable(callback)
+       return _parse_delimited_table(io.lines("/proc/net/arp"), "%s%s+", callback)
 end
 
 --- Returns conntrack information
 -- @return     Table with the currently tracked IP connections
-function net.conntrack()
+function net.conntrack(callback)
        local connt = {}
-       if luci.fs.access("/proc/net/nf_conntrack", "r") then
+       if fs.access("/proc/net/nf_conntrack", "r") then
                for line in io.lines("/proc/net/nf_conntrack") do
                        line = line:match "^(.-( [^ =]+=).-)%2"
                        local entry, flags = _parse_mixed_record(line, " +")
@@ -269,9 +257,13 @@ function net.conntrack()
                                entry[i] = nil
                        end
 
-                       connt[#connt+1] = entry
+                       if callback then
+                               callback(entry)
+                       else
+                               connt[#connt+1] = entry
+                       end
                end
-       elseif luci.fs.access("/proc/net/ip_conntrack", "r") then
+       elseif fs.access("/proc/net/ip_conntrack", "r") then
                for line in io.lines("/proc/net/ip_conntrack") do
                        line = line:match "^(.-( [^ =]+=).-)%2"
                        local entry, flags = _parse_mixed_record(line, " +")
@@ -281,7 +273,11 @@ function net.conntrack()
                                entry[i] = nil
                        end
 
-                       connt[#connt+1] = entry
+                       if callback then
+                               callback(entry)
+                       else
+                               connt[#connt+1] = entry
+                       end
                end
        else
                return nil
@@ -296,12 +292,14 @@ end
 --                     { "dest", "gateway", "metric", "refcount", "usecount", "irtt",
 --                       "flags", "device" }
 function net.defaultroute()
-       local route = nil
-       for _, r in pairs(net.routes()) do
-               if r.dest:prefix() == 0 and (not route or route.metric > r.metric) then
-                       route = r
+       local route
+
+       net.routes(function(rt)
+               if rt.dest:prefix() == 0 and (not route or route.metric > rt.metric) then
+                       route = rt
                end
-       end
+       end)
+
        return route
 end
 
@@ -312,42 +310,57 @@ end
 --                     { "source", "dest", "nexthop", "metric", "refcount", "usecount",
 --                       "flags", "device" }
 function net.defaultroute6()
-       local route   = nil
-       local routes6 = net.routes6()
-       if routes6 then
-               for _, r in pairs(routes6) do
-                       if r.dest:prefix() == 0 and
-                          (not route or route.metric > r.metric)
-                       then
-                               route = r
-                       end
+       local route
+
+       net.routes6(function(rt)
+               if rt.dest:prefix() == 0 and (not route or route.metric > rt.metric) then
+                       route = rt
                end
-       end
+       end)
+
        return route
 end
 
 --- Determine the names of available network interfaces.
 -- @return     Table containing all current interface names
 function net.devices()
-       local devices = {}
-       for line in io.lines("/proc/net/dev") do
-               table.insert(devices, line:match(" *(.-):"))
+       local devs = {}
+       for k, v in ipairs(nixio.getifaddrs()) do
+               if v.family == "packet" then
+                       devs[#devs+1] = v.name
+               end
        end
-       return devices
+       return devs
 end
 
 
 --- Return information about available network interfaces.
 -- @return     Table containing all current interface names and their information
 function net.deviceinfo()
-       local devices = {}
-       for line in io.lines("/proc/net/dev") do
-               local name, data = line:match("^ *(.-): *(.*)$")
-               if name and data then
-                       devices[name] = luci.util.split(data, " +", nil, true)
+       local devs = {}
+       for k, v in ipairs(nixio.getifaddrs()) do
+               if v.family == "packet" then
+                       local d = v.data
+                       d[1] = d.rx_bytes
+                       d[2] = d.rx_packets
+                       d[3] = d.rx_errors
+                       d[4] = d.rx_dropped
+                       d[5] = 0
+                       d[6] = 0
+                       d[7] = 0
+                       d[8] = d.multicast
+                       d[9] = d.tx_bytes
+                       d[10] = d.tx_packets
+                       d[11] = d.tx_errors
+                       d[12] = d.tx_dropped
+                       d[13] = 0
+                       d[14] = d.collisions
+                       d[15] = 0
+                       d[16] = 0
+                       devs[v.name] = d
                end
        end
-       return devices
+       return devs
 end
 
 
@@ -356,13 +369,11 @@ end
 -- @return             String containing the MAC address or nil if it cannot be found
 function net.ip4mac(ip)
        local mac = nil
-
-       for i, l in ipairs(net.arptable()) do
-               if l["IP address"] == ip then
-                       mac = l["HW address"]
+       net.arptable(function(e)
+               if e["IP address"] == ip then
+                       mac = e["HW address"]
                end
-       end
-
+       end)
        return mac
 end
 
@@ -371,7 +382,7 @@ end
 --                     The following fields are defined for route entry tables:
 --                     { "dest", "gateway", "metric", "refcount", "usecount", "irtt",
 --                       "flags", "device" }
-function net.routes()
+function net.routes(callback)
        local routes = { }
 
        for line in io.lines("/proc/net/route") do
@@ -389,7 +400,7 @@ function net.routes()
                                dst_ip, dst_mask:prefix(dst_mask), luci.ip.FAMILY_INET4
                        )
 
-                       routes[#routes+1] = {
+                       local rt = {
                                dest     = dst_ip,
                                gateway  = gateway,
                                metric   = tonumber(metric),
@@ -401,6 +412,12 @@ function net.routes()
                                flags    = tonumber(flags, 16),
                                device   = dev
                        }
+
+                       if callback then
+                               callback(rt)
+                       else
+                               routes[#routes+1] = rt
+                       end
                end
        end
 
@@ -412,8 +429,8 @@ end
 --                     The following fields are defined for route entry tables:
 --                     { "source", "dest", "nexthop", "metric", "refcount", "usecount",
 --                       "flags", "device" }
-function net.routes6()
-       if luci.fs.access("/proc/net/ipv6_route", "r") then
+function net.routes6(callback)
+       if fs.access("/proc/net/ipv6_route", "r") then
                local routes = { }
 
                for line in io.lines("/proc/net/ipv6_route") do
@@ -437,7 +454,7 @@ function net.routes6()
 
                        nexthop = luci.ip.Hex( nexthop, 128, luci.ip.FAMILY_INET6, false )
 
-                       routes[#routes+1] = {
+                       local rt = {
                                source   = src_ip,
                                dest     = dst_ip,
                                nexthop  = nexthop,
@@ -447,6 +464,12 @@ function net.routes6()
                                flags    = tonumber(flags, 16),
                                device   = dev
                        }
+
+                       if callback then
+                               callback(rt)
+                       else
+                               routes[#routes+1] = rt
+                       end
                end
 
                return routes
@@ -665,7 +688,7 @@ function wifi.channels(iface)
                fd:close()
        end
 
-       if not ((pairs(cns))(cns)) then
+       if not next(cns) then
                cns = {
                        2.412, 2.417, 2.422, 2.427, 2.432, 2.437,
                        2.442, 2.447, 2.452, 2.457, 2.462
@@ -686,8 +709,8 @@ init.dir = "/etc/init.d/"
 -- @return     Table containing the names of all inistalled init scripts
 function init.names()
        local names = { }
-       for _, name in ipairs(luci.fs.glob(init.dir.."*")) do
-               names[#names+1] = luci.fs.basename(name)
+       for name in fs.glob(init.dir.."*") do
+               names[#names+1] = fs.basename(name)
        end
        return names
 end
@@ -696,7 +719,7 @@ end
 -- @param name Name of the init script
 -- @return             Boolean indicating whether init is enabled
 function init.enabled(name)
-       if luci.fs.access(init.dir..name) then
+       if fs.access(init.dir..name) then
                return ( call(init.dir..name.." enabled") == 0 )
        end
        return false
@@ -706,7 +729,7 @@ end
 -- @param name Name of the init script
 -- @return             Numeric index value
 function init.index(name)
-       if luci.fs.access(init.dir..name) then
+       if fs.access(init.dir..name) then
                return call("source "..init.dir..name.."; exit $START")
        end
 end
@@ -715,7 +738,7 @@ end
 -- @param name Name of the init script
 -- @return             Boolean indicating success
 function init.enable(name)
-       if luci.fs.access(init.dir..name) then
+       if fs.access(init.dir..name) then
                return ( call(init.dir..name.." enable") == 1 )
        end
 end
@@ -724,7 +747,7 @@ end
 -- @param name Name of the init script
 -- @return             Boolean indicating success
 function init.disable(name)
-       if luci.fs.access(init.dir..name) then
+       if fs.access(init.dir..name) then
                return ( call(init.dir..name.." disable") == 0 )
        end
 end
@@ -732,7 +755,7 @@ end
 
 -- Internal functions
 
-function _parse_delimited_table(iter, delimiter)
+function _parse_delimited_table(iter, delimiter, callback)
        delimiter = delimiter or "%s+"
 
        local data  = {}
@@ -754,7 +777,12 @@ function _parse_delimited_table(iter, delimiter)
                                end
                        end
                end
-               table.insert(data, row)
+
+               if callback then
+                       callback(row)
+               else
+                       data[#data+1] = row
+               end
        end
 
        return data
index 4bae1e1..f5a12bf 100644 (file)
@@ -9,565 +9,20 @@ You may obtain a copy of the License at
 
 ]]--
 
+local setmetatable, require, rawget, rawset = setmetatable, require, rawget, rawset
+
 module "luci.sys.zoneinfo"
 
-TZ = {
-       { 'Africa/Abidjan', 'GMT0' },
-       { 'Africa/Accra', 'GMT0' },
-       { 'Africa/Addis Ababa', 'EAT-3' },
-       { 'Africa/Algiers', 'CET-1' },
-       { 'Africa/Asmara', 'EAT-3' },
-       { 'Africa/Bamako', 'GMT0' },
-       { 'Africa/Bangui', 'WAT-1' },
-       { 'Africa/Banjul', 'GMT0' },
-       { 'Africa/Bissau', 'GMT0' },
-       { 'Africa/Blantyre', 'CAT-2' },
-       { 'Africa/Brazzaville', 'WAT-1' },
-       { 'Africa/Bujumbura', 'CAT-2' },
-       { 'Africa/Casablanca', 'WET0' },
-       { 'Africa/Ceuta', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Africa/Conakry', 'GMT0' },
-       { 'Africa/Dakar', 'GMT0' },
-       { 'Africa/Dar es Salaam', 'EAT-3' },
-       { 'Africa/Djibouti', 'EAT-3' },
-       { 'Africa/Douala', 'WAT-1' },
-       { 'Africa/El Aaiun', 'WET0' },
-       { 'Africa/Freetown', 'GMT0' },
-       { 'Africa/Gaborone', 'CAT-2' },
-       { 'Africa/Harare', 'CAT-2' },
-       { 'Africa/Johannesburg', 'SAST-2' },
-       { 'Africa/Kampala', 'EAT-3' },
-       { 'Africa/Khartoum', 'EAT-3' },
-       { 'Africa/Kigali', 'CAT-2' },
-       { 'Africa/Kinshasa', 'WAT-1' },
-       { 'Africa/Lagos', 'WAT-1' },
-       { 'Africa/Libreville', 'WAT-1' },
-       { 'Africa/Lome', 'GMT0' },
-       { 'Africa/Luanda', 'WAT-1' },
-       { 'Africa/Lubumbashi', 'CAT-2' },
-       { 'Africa/Lusaka', 'CAT-2' },
-       { 'Africa/Malabo', 'WAT-1' },
-       { 'Africa/Maputo', 'CAT-2' },
-       { 'Africa/Maseru', 'SAST-2' },
-       { 'Africa/Mbabane', 'SAST-2' },
-       { 'Africa/Mogadishu', 'EAT-3' },
-       { 'Africa/Monrovia', 'GMT0' },
-       { 'Africa/Nairobi', 'EAT-3' },
-       { 'Africa/Ndjamena', 'WAT-1' },
-       { 'Africa/Niamey', 'WAT-1' },
-       { 'Africa/Nouakchott', 'GMT0' },
-       { 'Africa/Ouagadougou', 'GMT0' },
-       { 'Africa/Porto-Novo', 'WAT-1' },
-       { 'Africa/Sao Tome', 'GMT0' },
-       { 'Africa/Tripoli', 'EET-2' },
-       { 'Africa/Tunis', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Africa/Windhoek', 'WAT-1WAST,M9.1.0,M4.1.0' },
-       { 'America/Adak', 'HAST10HADT,M3.2.0,M11.1.0' },
-       { 'America/Anchorage', 'AKST9AKDT,M3.2.0,M11.1.0' },
-       { 'America/Anguilla', 'AST4' },
-       { 'America/Antigua', 'AST4' },
-       { 'America/Araguaina', 'BRT3' },
-       { 'America/Argentina/Buenos Aires', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
-       { 'America/Argentina/Catamarca', 'ART3' },
-       { 'America/Argentina/Cordoba', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
-       { 'America/Argentina/Jujuy', 'ART3' },
-       { 'America/Argentina/La Rioja', 'ART3' },
-       { 'America/Argentina/Mendoza', 'ART3' },
-       { 'America/Argentina/Rio Gallegos', 'ART3' },
-       { 'America/Argentina/Salta', 'ART3' },
-       { 'America/Argentina/San Juan', 'ART3' },
-       { 'America/Argentina/San Luis', 'WART4WARST,M10.3.0/0,M3.3.0/0' },
-       { 'America/Argentina/Tucuman', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
-       { 'America/Argentina/Ushuaia', 'ART3' },
-       { 'America/Aruba', 'AST4' },
-       { 'America/Asuncion', 'PYT4PYST,M10.3.0/0,M3.2.0/0' },
-       { 'America/Atikokan', 'EST5' },
-       { 'America/Bahia', 'BRT3' },
-       { 'America/Barbados', 'AST4' },
-       { 'America/Belem', 'BRT3' },
-       { 'America/Belize', 'CST6' },
-       { 'America/Blanc-Sablon', 'AST4' },
-       { 'America/Boa Vista', 'AMT4' },
-       { 'America/Bogota', 'COT5' },
-       { 'America/Boise', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/Cambridge Bay', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/Campo Grande', 'AMT4AMST,M10.3.0/0,M2.3.0/0' },
-       { 'America/Cancun', 'CST6CDT,M4.1.0,M10.5.0' },
-       { 'America/Caracas', 'VET4:30' },
-       { 'America/Cayenne', 'GFT3' },
-       { 'America/Cayman', 'EST5' },
-       { 'America/Chicago', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Chihuahua', 'MST7MDT,M4.1.0,M10.5.0' },
-       { 'America/Costa Rica', 'CST6' },
-       { 'America/Cuiaba', 'AMT4AMST,M10.3.0/0,M2.3.0/0' },
-       { 'America/Curacao', 'AST4' },
-       { 'America/Danmarkshavn', 'GMT0' },
-       { 'America/Dawson', 'PST8PDT,M3.2.0,M11.1.0' },
-       { 'America/Dawson Creek', 'MST7' },
-       { 'America/Denver', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/Detroit', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Dominica', 'AST4' },
-       { 'America/Edmonton', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/Eirunepe', 'AMT4' },
-       { 'America/El Salvador', 'CST6' },
-       { 'America/Fortaleza', 'BRT3' },
-       { 'America/Glace Bay', 'AST4ADT,M3.2.0,M11.1.0' },
-       { 'America/Goose Bay', 'AST4ADT,M3.2.0/0:01,M11.1.0/0:01' },
-       { 'America/Grand Turk', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Grenada', 'AST4' },
-       { 'America/Guadeloupe', 'AST4' },
-       { 'America/Guatemala', 'CST6' },
-       { 'America/Guayaquil', 'ECT5' },
-       { 'America/Guyana', 'GYT4' },
-       { 'America/Halifax', 'AST4ADT,M3.2.0,M11.1.0' },
-       { 'America/Havana', 'CST5CDT,M3.2.0/0,M10.5.0/1' },
-       { 'America/Hermosillo', 'MST7' },
-       { 'America/Indiana/Indianapolis', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Knox', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Marengo', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Petersburg', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Tell City', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Vevay', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Vincennes', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Indiana/Winamac', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Inuvik', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/Iqaluit', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Jamaica', 'EST5' },
-       { 'America/Juneau', 'AKST9AKDT,M3.2.0,M11.1.0' },
-       { 'America/Kentucky/Louisville', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Kentucky/Monticello', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/La Paz', 'BOT4' },
-       { 'America/Lima', 'PET5' },
-       { 'America/Los Angeles', 'PST8PDT,M3.2.0,M11.1.0' },
-       { 'America/Maceio', 'BRT3' },
-       { 'America/Managua', 'CST6' },
-       { 'America/Manaus', 'AMT4' },
-       { 'America/Marigot', 'AST4' },
-       { 'America/Martinique', 'AST4' },
-       { 'America/Mazatlan', 'MST7MDT,M4.1.0,M10.5.0' },
-       { 'America/Menominee', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Merida', 'CST6CDT,M4.1.0,M10.5.0' },
-       { 'America/Mexico City', 'CST6CDT,M4.1.0,M10.5.0' },
-       { 'America/Miquelon', 'PMST3PMDT,M3.2.0,M11.1.0' },
-       { 'America/Moncton', 'AST4ADT,M3.2.0,M11.1.0' },
-       { 'America/Monterrey', 'CST6CDT,M4.1.0,M10.5.0' },
-       { 'America/Montevideo', 'UYT3UYST,M10.1.0,M3.2.0' },
-       { 'America/Montreal', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Montserrat', 'AST4' },
-       { 'America/Nassau', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/New York', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Nipigon', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Nome', 'AKST9AKDT,M3.2.0,M11.1.0' },
-       { 'America/Noronha', 'FNT2' },
-       { 'America/North Dakota/Center', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/North Dakota/New Salem', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Panama', 'EST5' },
-       { 'America/Pangnirtung', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Paramaribo', 'SRT3' },
-       { 'America/Phoenix', 'MST7' },
-       { 'America/Port of Spain', 'AST4' },
-       { 'America/Port-au-Prince', 'EST5' },
-       { 'America/Porto Velho', 'AMT4' },
-       { 'America/Puerto Rico', 'AST4' },
-       { 'America/Rainy River', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Rankin Inlet', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Recife', 'BRT3' },
-       { 'America/Regina', 'CST6' },
-       { 'America/Rio Branco', 'AMT4' },
-       { 'America/Santarem', 'BRT3' },
-       { 'America/Santo Domingo', 'AST4' },
-       { 'America/Sao Paulo', 'BRT3BRST,M10.3.0/0,M2.3.0/0' },
-       { 'America/Scoresbysund', 'EGT1EGST,M3.5.0/0,M10.5.0/1' },
-       { 'America/Shiprock', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'America/St Barthelemy', 'AST4' },
-       { 'America/St Johns', 'NST3:30NDT,M3.2.0/0:01,M11.1.0/0:01' },
-       { 'America/St Kitts', 'AST4' },
-       { 'America/St Lucia', 'AST4' },
-       { 'America/St Thomas', 'AST4' },
-       { 'America/St Vincent', 'AST4' },
-       { 'America/Swift Current', 'CST6' },
-       { 'America/Tegucigalpa', 'CST6' },
-       { 'America/Thule', 'AST4ADT,M3.2.0,M11.1.0' },
-       { 'America/Thunder Bay', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Tijuana', 'PST8PDT,M4.1.0,M10.5.0' },
-       { 'America/Toronto', 'EST5EDT,M3.2.0,M11.1.0' },
-       { 'America/Tortola', 'AST4' },
-       { 'America/Vancouver', 'PST8PDT,M3.2.0,M11.1.0' },
-       { 'America/Whitehorse', 'PST8PDT,M3.2.0,M11.1.0' },
-       { 'America/Winnipeg', 'CST6CDT,M3.2.0,M11.1.0' },
-       { 'America/Yakutat', 'AKST9AKDT,M3.2.0,M11.1.0' },
-       { 'America/Yellowknife', 'MST7MDT,M3.2.0,M11.1.0' },
-       { 'Antarctica/Casey', 'WST-8' },
-       { 'Antarctica/Davis', 'DAVT-7' },
-       { 'Antarctica/DumontDUrville', 'DDUT-10' },
-       { 'Antarctica/Mawson', 'MAWT-6' },
-       { 'Antarctica/McMurdo', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
-       { 'Antarctica/Rothera', 'ROTT3' },
-       { 'Antarctica/South Pole', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
-       { 'Antarctica/Syowa', 'SYOT-3' },
-       { 'Antarctica/Vostok', 'VOST-6' },
-       { 'Arctic/Longyearbyen', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Aden', 'AST-3' },
-       { 'Asia/Almaty', 'ALMT-6' },
-       { 'Asia/Amman', 'EET-2EEST,M3.5.4/0,M10.5.5/1' },
-       { 'Asia/Anadyr', 'ANAT-12ANAST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Aqtau', 'AQTT-5' },
-       { 'Asia/Aqtobe', 'AQTT-5' },
-       { 'Asia/Ashgabat', 'TMT-5' },
-       { 'Asia/Baghdad', 'AST-3' },
-       { 'Asia/Bahrain', 'AST-3' },
-       { 'Asia/Baku', 'AZT-4AZST,M3.5.0/4,M10.5.0/5' },
-       { 'Asia/Bangkok', 'ICT-7' },
-       { 'Asia/Beirut', 'EET-2EEST,M3.5.0/0,M10.5.0/0' },
-       { 'Asia/Bishkek', 'KGT-6' },
-       { 'Asia/Brunei', 'BNT-8' },
-       { 'Asia/Choibalsan', 'CHOT-8' },
-       { 'Asia/Chongqing', 'CST-8' },
-       { 'Asia/Colombo', 'IST-5:30' },
-       { 'Asia/Damascus', 'EET-2EEST,M3.5.5/0,J305/0' },
-       { 'Asia/Dhaka', 'BDT-6' },
-       { 'Asia/Dili', 'TLT-9' },
-       { 'Asia/Dubai', 'GST-4' },
-       { 'Asia/Dushanbe', 'TJT-5' },
-       { 'Asia/Gaza', 'EET-2EEST,J91/0,M8.5.4' },
-       { 'Asia/Harbin', 'CST-8' },
-       { 'Asia/Ho Chi Minh', 'ICT-7' },
-       { 'Asia/Hong Kong', 'HKT-8' },
-       { 'Asia/Hovd', 'HOVT-7' },
-       { 'Asia/Irkutsk', 'IRKT-8IRKST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Jakarta', 'WIT-7' },
-       { 'Asia/Jayapura', 'EIT-9' },
-       { 'Asia/Kabul', 'AFT-4:30' },
-       { 'Asia/Kamchatka', 'PETT-12PETST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Karachi', 'PKT-5' },
-       { 'Asia/Kashgar', 'CST-8' },
-       { 'Asia/Kathmandu', 'NPT-5:45' },
-       { 'Asia/Kolkata', 'IST-5:30' },
-       { 'Asia/Krasnoyarsk', 'KRAT-7KRAST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Kuala Lumpur', 'MYT-8' },
-       { 'Asia/Kuching', 'MYT-8' },
-       { 'Asia/Kuwait', 'AST-3' },
-       { 'Asia/Macau', 'CST-8' },
-       { 'Asia/Magadan', 'MAGT-11MAGST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Makassar', 'CIT-8' },
-       { 'Asia/Manila', 'PHT-8' },
-       { 'Asia/Muscat', 'GST-4' },
-       { 'Asia/Nicosia', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Asia/Novosibirsk', 'NOVT-6NOVST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Omsk', 'OMST-6OMSST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Oral', 'ORAT-5' },
-       { 'Asia/Phnom Penh', 'ICT-7' },
-       { 'Asia/Pontianak', 'WIT-7' },
-       { 'Asia/Pyongyang', 'KST-9' },
-       { 'Asia/Qatar', 'AST-3' },
-       { 'Asia/Qyzylorda', 'QYZT-6' },
-       { 'Asia/Rangoon', 'MMT-6:30' },
-       { 'Asia/Riyadh', 'AST-3' },
-       { 'Asia/Sakhalin', 'SAKT-10SAKST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Samarkand', 'UZT-5' },
-       { 'Asia/Seoul', 'KST-9' },
-       { 'Asia/Shanghai', 'CST-8' },
-       { 'Asia/Singapore', 'SGT-8' },
-       { 'Asia/Taipei', 'CST-8' },
-       { 'Asia/Tashkent', 'UZT-5' },
-       { 'Asia/Tbilisi', 'GET-4' },
-       { 'Asia/Thimphu', 'BTT-6' },
-       { 'Asia/Tokyo', 'JST-9' },
-       { 'Asia/Ulaanbaatar', 'ULAT-8' },
-       { 'Asia/Urumqi', 'CST-8' },
-       { 'Asia/Vientiane', 'ICT-7' },
-       { 'Asia/Vladivostok', 'VLAT-10VLAST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Yakutsk', 'YAKT-9YAKST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Yekaterinburg', 'YEKT-5YEKST,M3.5.0,M10.5.0/3' },
-       { 'Asia/Yerevan', 'AMT-4AMST,M3.5.0,M10.5.0/3' },
-       { 'Atlantic/Azores', 'AZOT1AZOST,M3.5.0/0,M10.5.0/1' },
-       { 'Atlantic/Bermuda', 'AST4ADT,M3.2.0,M11.1.0' },
-       { 'Atlantic/Canary', 'WET0WEST,M3.5.0/1,M10.5.0' },
-       { 'Atlantic/Cape Verde', 'CVT1' },
-       { 'Atlantic/Faroe', 'WET0WEST,M3.5.0/1,M10.5.0' },
-       { 'Atlantic/Madeira', 'WET0WEST,M3.5.0/1,M10.5.0' },
-       { 'Atlantic/Reykjavik', 'GMT0' },
-       { 'Atlantic/South Georgia', 'GST2' },
-       { 'Atlantic/St Helena', 'GMT0' },
-       { 'Atlantic/Stanley', 'FKT4FKST,M9.1.0,M4.3.0' },
-       { 'Australia/Adelaide', 'CST-9:30CST,M10.1.0,M4.1.0/3' },
-       { 'Australia/Brisbane', 'EST-10' },
-       { 'Australia/Broken Hill', 'CST-9:30CST,M10.1.0,M4.1.0/3' },
-       { 'Australia/Currie', 'EST-10EST,M10.1.0,M4.1.0/3' },
-       { 'Australia/Darwin', 'CST-9:30' },
-       { 'Australia/Eucla', 'CWST-8:45' },
-       { 'Australia/Hobart', 'EST-10EST,M10.1.0,M4.1.0/3' },
-       { 'Australia/Lindeman', 'EST-10' },
-       { 'Australia/Lord Howe', 'LHST-10:30LHST-11,M10.1.0,M4.1.0' },
-       { 'Australia/Melbourne', 'EST-10EST,M10.1.0,M4.1.0/3' },
-       { 'Australia/Perth', 'WST-8' },
-       { 'Australia/Sydney', 'EST-10EST,M10.1.0,M4.1.0/3' },
-       { 'Europe/Amsterdam', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Andorra', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Athens', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Belgrade', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Berlin', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Bratislava', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Brussels', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Bucharest', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Budapest', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Chisinau', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Copenhagen', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Dublin', 'GMT0IST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Gibraltar', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Guernsey', 'GMT0BST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Helsinki', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Isle of Man', 'GMT0BST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Istanbul', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Jersey', 'GMT0BST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Kaliningrad', 'EET-2EEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Kiev', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Lisbon', 'WET0WEST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Ljubljana', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/London', 'GMT0BST,M3.5.0/1,M10.5.0' },
-       { 'Europe/Luxembourg', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Madrid', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Malta', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Mariehamn', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Minsk', 'EET-2EEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Monaco', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Moscow', 'MSK-3MSD,M3.5.0,M10.5.0/3' },
-       { 'Europe/Oslo', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Paris', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Podgorica', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Prague', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Riga', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Rome', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Samara', 'SAMT-4SAMST,M3.5.0,M10.5.0/3' },
-       { 'Europe/San Marino', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Sarajevo', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Simferopol', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Skopje', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Sofia', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Stockholm', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Tallinn', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Tirane', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Uzhgorod', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Vaduz', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Vatican', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Vienna', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Vilnius', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Volgograd', 'VOLT-3VOLST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Warsaw', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Zagreb', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Europe/Zaporozhye', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
-       { 'Europe/Zurich', 'CET-1CEST,M3.5.0,M10.5.0/3' },
-       { 'Indian/Antananarivo', 'EAT-3' },
-       { 'Indian/Chagos', 'IOT-6' },
-       { 'Indian/Christmas', 'CXT-7' },
-       { 'Indian/Cocos', 'CCT-6:30' },
-       { 'Indian/Comoro', 'EAT-3' },
-       { 'Indian/Kerguelen', 'TFT-5' },
-       { 'Indian/Mahe', 'SCT-4' },
-       { 'Indian/Maldives', 'MVT-5' },
-       { 'Indian/Mauritius', 'MUT-4MUST,M10.5.0,M3.5.0/3' },
-       { 'Indian/Mayotte', 'EAT-3' },
-       { 'Indian/Reunion', 'RET-4' },
-       { 'Pacific/Apia', 'WST11' },
-       { 'Pacific/Auckland', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
-       { 'Pacific/Chatham', 'CHAST-12:45CHADT,M9.5.0/2:45,M4.1.0/3:45' },
-       { 'Pacific/Efate', 'VUT-11' },
-       { 'Pacific/Enderbury', 'PHOT-13' },
-       { 'Pacific/Fakaofo', 'TKT10' },
-       { 'Pacific/Fiji', 'FJT-12' },
-       { 'Pacific/Funafuti', 'TVT-12' },
-       { 'Pacific/Galapagos', 'GALT6' },
-       { 'Pacific/Gambier', 'GAMT9' },
-       { 'Pacific/Guadalcanal', 'SBT-11' },
-       { 'Pacific/Guam', 'ChST-10' },
-       { 'Pacific/Honolulu', 'HST10' },
-       { 'Pacific/Johnston', 'HST10' },
-       { 'Pacific/Kiritimati', 'LINT-14' },
-       { 'Pacific/Kosrae', 'KOST-11' },
-       { 'Pacific/Kwajalein', 'MHT-12' },
-       { 'Pacific/Majuro', 'MHT-12' },
-       { 'Pacific/Marquesas', 'MART9:30' },
-       { 'Pacific/Midway', 'SST11' },
-       { 'Pacific/Nauru', 'NRT-12' },
-       { 'Pacific/Niue', 'NUT11' },
-       { 'Pacific/Norfolk', 'NFT-11:30' },
-       { 'Pacific/Noumea', 'NCT-11' },
-       { 'Pacific/Pago Pago', 'SST11' },
-       { 'Pacific/Palau', 'PWT-9' },
-       { 'Pacific/Pitcairn', 'PST8' },
-       { 'Pacific/Ponape', 'PONT-11' },
-       { 'Pacific/Port Moresby', 'PGT-10' },
-       { 'Pacific/Rarotonga', 'CKT10' },
-       { 'Pacific/Saipan', 'ChST-10' },
-       { 'Pacific/Tahiti', 'TAHT10' },
-       { 'Pacific/Tarawa', 'GILT-12' },
-       { 'Pacific/Tongatapu', 'TOT-13' },
-       { 'Pacific/Truk', 'TRUT-10' },
-       { 'Pacific/Wake', 'WAKT-12' },
-       { 'Pacific/Wallis', 'WFT-12' },
-}
+setmetatable(_M, {
+       __index = function(t, k)
+               if k == "TZ" and not rawget(t, k) then
+                       local m = require "luci.sys.zoneinfo.tzdata"
+                       rawset(t, k, rawget(m, k))
+               elseif k == "OFFSET" and not rawget(t, k) then
+                       local m = require "luci.sys.zoneinfo.tzoffset"
+                       rawset(t, k, rawget(m, k))
+               end
 
-OFFSET = {
-       gmt   =      0, -- GMT
-       eat   =  10800, -- EAT
-       cet   =   3600, -- CET
-       wat   =   3600, -- WAT
-       cat   =   7200, -- CAT
-       wet   =      0, -- WET
-       sast  =   7200, -- SAST
-       eet   =   7200, -- EET
-       hast  = -36000, -- HAST
-       hadt  = -32400, -- HADT
-       akst  = -32400, -- AKST
-       akdt  = -28800, -- AKDT
-       ast   = -14400, -- AST
-       brt   = -10800, -- BRT
-       art   = -10800, -- ART
-       arst  =  -7200, -- ARST
-       wart  = -14400, -- WART
-       warst = -10800, -- WARST
-       pyt   = -14400, -- PYT
-       pyst  = -10800, -- PYST
-       est   = -18000, -- EST
-       cst   = -21600, -- CST
-       amt   = -14400, -- AMT
-       cot   = -18000, -- COT
-       mst   = -25200, -- MST
-       mdt   = -21600, -- MDT
-       vet   = -16200, -- VET
-       gft   = -10800, -- GFT
-       pst   = -28800, -- PST
-       pdt   = -25200, -- PDT
-       ect   = -18000, -- ECT
-       gyt   = -14400, -- GYT
-       bot   = -14400, -- BOT
-       pet   = -18000, -- PET
-       pmst  = -10800, -- PMST
-       pmdt  =  -7200, -- PMDT
-       uyt   = -10800, -- UYT
-       uyst  =  -7200, -- UYST
-       fnt   =  -7200, -- FNT
-       srt   = -10800, -- SRT
-       egt   =  -3600, -- EGT
-       egst  =      0, -- EGST
-       nst   = -12600, -- NST
-       ndt   =  -9000, -- NDT
-       wst   =  28800, -- WST
-       davt  =  25200, -- DAVT
-       ddut  =  36000, -- DDUT
-       mawt  =  21600, -- MAWT
-       nzst  =  43200, -- NZST
-       nzdt  =  46800, -- NZDT
-       rott  = -10800, -- ROTT
-       syot  =  10800, -- SYOT
-       vost  =  21600, -- VOST
-       almt  =  21600, -- ALMT
-       anat  =  43200, -- ANAT
-       anast =  46800, -- ANAST
-       aqtt  =  18000, -- AQTT
-       tmt   =  18000, -- TMT
-       azt   =  14400, -- AZT
-       azst  =  18000, -- AZST
-       ict   =  25200, -- ICT
-       kgt   =  21600, -- KGT
-       bnt   =  28800, -- BNT
-       chot  =  28800, -- CHOT
-       ist   =  19800, -- IST
-       bdt   =  21600, -- BDT
-       tlt   =  32400, -- TLT
-       gst   =  14400, -- GST
-       tjt   =  18000, -- TJT
-       hkt   =  28800, -- HKT
-       hovt  =  25200, -- HOVT
-       irkt  =  28800, -- IRKT
-       irkst =  32400, -- IRKST
-       wit   =  25200, -- WIT
-       eit   =  32400, -- EIT
-       aft   =  16200, -- AFT
-       pett  =  43200, -- PETT
-       petst =  46800, -- PETST
-       pkt   =  18000, -- PKT
-       npt   =  20700, -- NPT
-       krat  =  25200, -- KRAT
-       krast =  28800, -- KRAST
-       myt   =  28800, -- MYT
-       magt  =  39600, -- MAGT
-       magst =  43200, -- MAGST
-       cit   =  28800, -- CIT
-       pht   =  28800, -- PHT
-       novt  =  21600, -- NOVT
-       novst =  25200, -- NOVST
-       omst  =  21600, -- OMST
-       omsst =  25200, -- OMSST
-       orat  =  18000, -- ORAT
-       kst   =  32400, -- KST
-       qyzt  =  21600, -- QYZT
-       mmt   =  23400, -- MMT
-       sakt  =  36000, -- SAKT
-       sakst =  39600, -- SAKST
-       uzt   =  18000, -- UZT
-       sgt   =  28800, -- SGT
-       get   =  14400, -- GET
-       btt   =  21600, -- BTT
-       jst   =  32400, -- JST
-       ulat  =  28800, -- ULAT
-       vlat  =  36000, -- VLAT
-       vlast =  39600, -- VLAST
-       yakt  =  32400, -- YAKT
-       yakst =  36000, -- YAKST
-       yekt  =  18000, -- YEKT
-       yekst =  21600, -- YEKST
-       azot  =  -3600, -- AZOT
-       azost =      0, -- AZOST
-       cvt   =  -3600, -- CVT
-       fkt   = -14400, -- FKT
-       fkst  = -10800, -- FKST
-       cwst  =  31500, -- CWST
-       lhst  =  37800, -- LHST
-       lhst  =  39600, -- LHST
-       msk   =  10800, -- MSK
-       msd   =  14400, -- MSD
-       samt  =  14400, -- SAMT
-       samst =  18000, -- SAMST
-       volt  =  10800, -- VOLT
-       volst =  14400, -- VOLST
-       iot   =  21600, -- IOT
-       cxt   =  25200, -- CXT
-       cct   =  23400, -- CCT
-       tft   =  18000, -- TFT
-       sct   =  14400, -- SCT
-       mvt   =  18000, -- MVT
-       mut   =  14400, -- MUT
-       must  =  18000, -- MUST
-       ret   =  14400, -- RET
-       chast =  45900, -- CHAST
-       chadt =  49500, -- CHADT
-       vut   =  39600, -- VUT
-       phot  =  46800, -- PHOT
-       tkt   = -36000, -- TKT
-       fjt   =  43200, -- FJT
-       tvt   =  43200, -- TVT
-       galt  = -21600, -- GALT
-       gamt  = -32400, -- GAMT
-       sbt   =  39600, -- SBT
-       hst   = -36000, -- HST
-       lint  =  50400, -- LINT
-       kost  =  39600, -- KOST
-       mht   =  43200, -- MHT
-       mart  = -34200, -- MART
-       sst   = -39600, -- SST
-       nrt   =  43200, -- NRT
-       nut   = -39600, -- NUT
-       nft   =  41400, -- NFT
-       nct   =  39600, -- NCT
-       pwt   =  32400, -- PWT
-       pont  =  39600, -- PONT
-       pgt   =  36000, -- PGT
-       ckt   = -36000, -- CKT
-       taht  = -36000, -- TAHT
-       gilt  =  43200, -- GILT
-       tot   =  46800, -- TOT
-       trut  =  36000, -- TRUT
-       wakt  =  43200, -- WAKT
-       wft   =  43200, -- WFT
-}
+               return rawget(t, k)
+       end
+})
diff --git a/libs/sys/luasrc/sys/zoneinfo/tzdata.lua b/libs/sys/luasrc/sys/zoneinfo/tzdata.lua
new file mode 100644 (file)
index 0000000..1fd02c4
--- /dev/null
@@ -0,0 +1,408 @@
+--[[
+LuCI - Autogenerated Zoneinfo Module
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+]]--
+
+module "luci.sys.zoneinfo.tzdata"
+
+TZ = {
+       { 'Africa/Abidjan', 'GMT0' },
+       { 'Africa/Accra', 'GMT0' },
+       { 'Africa/Addis Ababa', 'EAT-3' },
+       { 'Africa/Algiers', 'CET-1' },
+       { 'Africa/Asmara', 'EAT-3' },
+       { 'Africa/Bamako', 'GMT0' },
+       { 'Africa/Bangui', 'WAT-1' },
+       { 'Africa/Banjul', 'GMT0' },
+       { 'Africa/Bissau', 'GMT0' },
+       { 'Africa/Blantyre', 'CAT-2' },
+       { 'Africa/Brazzaville', 'WAT-1' },
+       { 'Africa/Bujumbura', 'CAT-2' },
+       { 'Africa/Casablanca', 'WET0' },
+       { 'Africa/Ceuta', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Africa/Conakry', 'GMT0' },
+       { 'Africa/Dakar', 'GMT0' },
+       { 'Africa/Dar es Salaam', 'EAT-3' },
+       { 'Africa/Djibouti', 'EAT-3' },
+       { 'Africa/Douala', 'WAT-1' },
+       { 'Africa/El Aaiun', 'WET0' },
+       { 'Africa/Freetown', 'GMT0' },
+       { 'Africa/Gaborone', 'CAT-2' },
+       { 'Africa/Harare', 'CAT-2' },
+       { 'Africa/Johannesburg', 'SAST-2' },
+       { 'Africa/Kampala', 'EAT-3' },
+       { 'Africa/Khartoum', 'EAT-3' },
+       { 'Africa/Kigali', 'CAT-2' },
+       { 'Africa/Kinshasa', 'WAT-1' },
+       { 'Africa/Lagos', 'WAT-1' },
+       { 'Africa/Libreville', 'WAT-1' },
+       { 'Africa/Lome', 'GMT0' },
+       { 'Africa/Luanda', 'WAT-1' },
+       { 'Africa/Lubumbashi', 'CAT-2' },
+       { 'Africa/Lusaka', 'CAT-2' },
+       { 'Africa/Malabo', 'WAT-1' },
+       { 'Africa/Maputo', 'CAT-2' },
+       { 'Africa/Maseru', 'SAST-2' },
+       { 'Africa/Mbabane', 'SAST-2' },
+       { 'Africa/Mogadishu', 'EAT-3' },
+       { 'Africa/Monrovia', 'GMT0' },
+       { 'Africa/Nairobi', 'EAT-3' },
+       { 'Africa/Ndjamena', 'WAT-1' },
+       { 'Africa/Niamey', 'WAT-1' },
+       { 'Africa/Nouakchott', 'GMT0' },
+       { 'Africa/Ouagadougou', 'GMT0' },
+       { 'Africa/Porto-Novo', 'WAT-1' },
+       { 'Africa/Sao Tome', 'GMT0' },
+       { 'Africa/Tripoli', 'EET-2' },
+       { 'Africa/Tunis', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Africa/Windhoek', 'WAT-1WAST,M9.1.0,M4.1.0' },
+       { 'America/Adak', 'HAST10HADT,M3.2.0,M11.1.0' },
+       { 'America/Anchorage', 'AKST9AKDT,M3.2.0,M11.1.0' },
+       { 'America/Anguilla', 'AST4' },
+       { 'America/Antigua', 'AST4' },
+       { 'America/Araguaina', 'BRT3' },
+       { 'America/Argentina/Buenos Aires', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
+       { 'America/Argentina/Catamarca', 'ART3' },
+       { 'America/Argentina/Cordoba', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
+       { 'America/Argentina/Jujuy', 'ART3' },
+       { 'America/Argentina/La Rioja', 'ART3' },
+       { 'America/Argentina/Mendoza', 'ART3' },
+       { 'America/Argentina/Rio Gallegos', 'ART3' },
+       { 'America/Argentina/Salta', 'ART3' },
+       { 'America/Argentina/San Juan', 'ART3' },
+       { 'America/Argentina/San Luis', 'WART4WARST,M10.3.0/0,M3.3.0/0' },
+       { 'America/Argentina/Tucuman', 'ART3ARST,M10.3.0/0,M3.3.0/0' },
+       { 'America/Argentina/Ushuaia', 'ART3' },
+       { 'America/Aruba', 'AST4' },
+       { 'America/Asuncion', 'PYT4PYST,M10.3.0/0,M3.2.0/0' },
+       { 'America/Atikokan', 'EST5' },
+       { 'America/Bahia', 'BRT3' },
+       { 'America/Barbados', 'AST4' },
+       { 'America/Belem', 'BRT3' },
+       { 'America/Belize', 'CST6' },
+       { 'America/Blanc-Sablon', 'AST4' },
+       { 'America/Boa Vista', 'AMT4' },
+       { 'America/Bogota', 'COT5' },
+       { 'America/Boise', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/Cambridge Bay', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/Campo Grande', 'AMT4AMST,M10.3.0/0,M2.3.0/0' },
+       { 'America/Cancun', 'CST6CDT,M4.1.0,M10.5.0' },
+       { 'America/Caracas', 'VET4:30' },
+       { 'America/Cayenne', 'GFT3' },
+       { 'America/Cayman', 'EST5' },
+       { 'America/Chicago', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Chihuahua', 'MST7MDT,M4.1.0,M10.5.0' },
+       { 'America/Costa Rica', 'CST6' },
+       { 'America/Cuiaba', 'AMT4AMST,M10.3.0/0,M2.3.0/0' },
+       { 'America/Curacao', 'AST4' },
+       { 'America/Danmarkshavn', 'GMT0' },
+       { 'America/Dawson', 'PST8PDT,M3.2.0,M11.1.0' },
+       { 'America/Dawson Creek', 'MST7' },
+       { 'America/Denver', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/Detroit', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Dominica', 'AST4' },
+       { 'America/Edmonton', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/Eirunepe', 'AMT4' },
+       { 'America/El Salvador', 'CST6' },
+       { 'America/Fortaleza', 'BRT3' },
+       { 'America/Glace Bay', 'AST4ADT,M3.2.0,M11.1.0' },
+       { 'America/Goose Bay', 'AST4ADT,M3.2.0/0:01,M11.1.0/0:01' },
+       { 'America/Grand Turk', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Grenada', 'AST4' },
+       { 'America/Guadeloupe', 'AST4' },
+       { 'America/Guatemala', 'CST6' },
+       { 'America/Guayaquil', 'ECT5' },
+       { 'America/Guyana', 'GYT4' },
+       { 'America/Halifax', 'AST4ADT,M3.2.0,M11.1.0' },
+       { 'America/Havana', 'CST5CDT,M3.2.0/0,M10.5.0/1' },
+       { 'America/Hermosillo', 'MST7' },
+       { 'America/Indiana/Indianapolis', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Knox', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Marengo', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Petersburg', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Tell City', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Vevay', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Vincennes', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Indiana/Winamac', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Inuvik', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/Iqaluit', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Jamaica', 'EST5' },
+       { 'America/Juneau', 'AKST9AKDT,M3.2.0,M11.1.0' },
+       { 'America/Kentucky/Louisville', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Kentucky/Monticello', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/La Paz', 'BOT4' },
+       { 'America/Lima', 'PET5' },
+       { 'America/Los Angeles', 'PST8PDT,M3.2.0,M11.1.0' },
+       { 'America/Maceio', 'BRT3' },
+       { 'America/Managua', 'CST6' },
+       { 'America/Manaus', 'AMT4' },
+       { 'America/Marigot', 'AST4' },
+       { 'America/Martinique', 'AST4' },
+       { 'America/Mazatlan', 'MST7MDT,M4.1.0,M10.5.0' },
+       { 'America/Menominee', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Merida', 'CST6CDT,M4.1.0,M10.5.0' },
+       { 'America/Mexico City', 'CST6CDT,M4.1.0,M10.5.0' },
+       { 'America/Miquelon', 'PMST3PMDT,M3.2.0,M11.1.0' },
+       { 'America/Moncton', 'AST4ADT,M3.2.0,M11.1.0' },
+       { 'America/Monterrey', 'CST6CDT,M4.1.0,M10.5.0' },
+       { 'America/Montevideo', 'UYT3UYST,M10.1.0,M3.2.0' },
+       { 'America/Montreal', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Montserrat', 'AST4' },
+       { 'America/Nassau', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/New York', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Nipigon', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Nome', 'AKST9AKDT,M3.2.0,M11.1.0' },
+       { 'America/Noronha', 'FNT2' },
+       { 'America/North Dakota/Center', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/North Dakota/New Salem', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Panama', 'EST5' },
+       { 'America/Pangnirtung', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Paramaribo', 'SRT3' },
+       { 'America/Phoenix', 'MST7' },
+       { 'America/Port of Spain', 'AST4' },
+       { 'America/Port-au-Prince', 'EST5' },
+       { 'America/Porto Velho', 'AMT4' },
+       { 'America/Puerto Rico', 'AST4' },
+       { 'America/Rainy River', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Rankin Inlet', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Recife', 'BRT3' },
+       { 'America/Regina', 'CST6' },
+       { 'America/Rio Branco', 'AMT4' },
+       { 'America/Santarem', 'BRT3' },
+       { 'America/Santo Domingo', 'AST4' },
+       { 'America/Sao Paulo', 'BRT3BRST,M10.3.0/0,M2.3.0/0' },
+       { 'America/Scoresbysund', 'EGT1EGST,M3.5.0/0,M10.5.0/1' },
+       { 'America/Shiprock', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'America/St Barthelemy', 'AST4' },
+       { 'America/St Johns', 'NST3:30NDT,M3.2.0/0:01,M11.1.0/0:01' },
+       { 'America/St Kitts', 'AST4' },
+       { 'America/St Lucia', 'AST4' },
+       { 'America/St Thomas', 'AST4' },
+       { 'America/St Vincent', 'AST4' },
+       { 'America/Swift Current', 'CST6' },
+       { 'America/Tegucigalpa', 'CST6' },
+       { 'America/Thule', 'AST4ADT,M3.2.0,M11.1.0' },
+       { 'America/Thunder Bay', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Tijuana', 'PST8PDT,M4.1.0,M10.5.0' },
+       { 'America/Toronto', 'EST5EDT,M3.2.0,M11.1.0' },
+       { 'America/Tortola', 'AST4' },
+       { 'America/Vancouver', 'PST8PDT,M3.2.0,M11.1.0' },
+       { 'America/Whitehorse', 'PST8PDT,M3.2.0,M11.1.0' },
+       { 'America/Winnipeg', 'CST6CDT,M3.2.0,M11.1.0' },
+       { 'America/Yakutat', 'AKST9AKDT,M3.2.0,M11.1.0' },
+       { 'America/Yellowknife', 'MST7MDT,M3.2.0,M11.1.0' },
+       { 'Antarctica/Casey', 'WST-8' },
+       { 'Antarctica/Davis', 'DAVT-7' },
+       { 'Antarctica/DumontDUrville', 'DDUT-10' },
+       { 'Antarctica/Mawson', 'MAWT-6' },
+       { 'Antarctica/McMurdo', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
+       { 'Antarctica/Rothera', 'ROTT3' },
+       { 'Antarctica/South Pole', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
+       { 'Antarctica/Syowa', 'SYOT-3' },
+       { 'Antarctica/Vostok', 'VOST-6' },
+       { 'Arctic/Longyearbyen', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Aden', 'AST-3' },
+       { 'Asia/Almaty', 'ALMT-6' },
+       { 'Asia/Amman', 'EET-2EEST,M3.5.4/0,M10.5.5/1' },
+       { 'Asia/Anadyr', 'ANAT-12ANAST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Aqtau', 'AQTT-5' },
+       { 'Asia/Aqtobe', 'AQTT-5' },
+       { 'Asia/Ashgabat', 'TMT-5' },
+       { 'Asia/Baghdad', 'AST-3' },
+       { 'Asia/Bahrain', 'AST-3' },
+       { 'Asia/Baku', 'AZT-4AZST,M3.5.0/4,M10.5.0/5' },
+       { 'Asia/Bangkok', 'ICT-7' },
+       { 'Asia/Beirut', 'EET-2EEST,M3.5.0/0,M10.5.0/0' },
+       { 'Asia/Bishkek', 'KGT-6' },
+       { 'Asia/Brunei', 'BNT-8' },
+       { 'Asia/Choibalsan', 'CHOT-8' },
+       { 'Asia/Chongqing', 'CST-8' },
+       { 'Asia/Colombo', 'IST-5:30' },
+       { 'Asia/Damascus', 'EET-2EEST,M3.5.5/0,J305/0' },
+       { 'Asia/Dhaka', 'BDT-6' },
+       { 'Asia/Dili', 'TLT-9' },
+       { 'Asia/Dubai', 'GST-4' },
+       { 'Asia/Dushanbe', 'TJT-5' },
+       { 'Asia/Gaza', 'EET-2EEST,J91/0,M8.5.4' },
+       { 'Asia/Harbin', 'CST-8' },
+       { 'Asia/Ho Chi Minh', 'ICT-7' },
+       { 'Asia/Hong Kong', 'HKT-8' },
+       { 'Asia/Hovd', 'HOVT-7' },
+       { 'Asia/Irkutsk', 'IRKT-8IRKST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Jakarta', 'WIT-7' },
+       { 'Asia/Jayapura', 'EIT-9' },
+       { 'Asia/Kabul', 'AFT-4:30' },
+       { 'Asia/Kamchatka', 'PETT-12PETST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Karachi', 'PKT-5' },
+       { 'Asia/Kashgar', 'CST-8' },
+       { 'Asia/Kathmandu', 'NPT-5:45' },
+       { 'Asia/Kolkata', 'IST-5:30' },
+       { 'Asia/Krasnoyarsk', 'KRAT-7KRAST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Kuala Lumpur', 'MYT-8' },
+       { 'Asia/Kuching', 'MYT-8' },
+       { 'Asia/Kuwait', 'AST-3' },
+       { 'Asia/Macau', 'CST-8' },
+       { 'Asia/Magadan', 'MAGT-11MAGST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Makassar', 'CIT-8' },
+       { 'Asia/Manila', 'PHT-8' },
+       { 'Asia/Muscat', 'GST-4' },
+       { 'Asia/Nicosia', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Asia/Novosibirsk', 'NOVT-6NOVST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Omsk', 'OMST-6OMSST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Oral', 'ORAT-5' },
+       { 'Asia/Phnom Penh', 'ICT-7' },
+       { 'Asia/Pontianak', 'WIT-7' },
+       { 'Asia/Pyongyang', 'KST-9' },
+       { 'Asia/Qatar', 'AST-3' },
+       { 'Asia/Qyzylorda', 'QYZT-6' },
+       { 'Asia/Rangoon', 'MMT-6:30' },
+       { 'Asia/Riyadh', 'AST-3' },
+       { 'Asia/Sakhalin', 'SAKT-10SAKST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Samarkand', 'UZT-5' },
+       { 'Asia/Seoul', 'KST-9' },
+       { 'Asia/Shanghai', 'CST-8' },
+       { 'Asia/Singapore', 'SGT-8' },
+       { 'Asia/Taipei', 'CST-8' },
+       { 'Asia/Tashkent', 'UZT-5' },
+       { 'Asia/Tbilisi', 'GET-4' },
+       { 'Asia/Thimphu', 'BTT-6' },
+       { 'Asia/Tokyo', 'JST-9' },
+       { 'Asia/Ulaanbaatar', 'ULAT-8' },
+       { 'Asia/Urumqi', 'CST-8' },
+       { 'Asia/Vientiane', 'ICT-7' },
+       { 'Asia/Vladivostok', 'VLAT-10VLAST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Yakutsk', 'YAKT-9YAKST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Yekaterinburg', 'YEKT-5YEKST,M3.5.0,M10.5.0/3' },
+       { 'Asia/Yerevan', 'AMT-4AMST,M3.5.0,M10.5.0/3' },
+       { 'Atlantic/Azores', 'AZOT1AZOST,M3.5.0/0,M10.5.0/1' },
+       { 'Atlantic/Bermuda', 'AST4ADT,M3.2.0,M11.1.0' },
+       { 'Atlantic/Canary', 'WET0WEST,M3.5.0/1,M10.5.0' },
+       { 'Atlantic/Cape Verde', 'CVT1' },
+       { 'Atlantic/Faroe', 'WET0WEST,M3.5.0/1,M10.5.0' },
+       { 'Atlantic/Madeira', 'WET0WEST,M3.5.0/1,M10.5.0' },
+       { 'Atlantic/Reykjavik', 'GMT0' },
+       { 'Atlantic/South Georgia', 'GST2' },
+       { 'Atlantic/St Helena', 'GMT0' },
+       { 'Atlantic/Stanley', 'FKT4FKST,M9.1.0,M4.3.0' },
+       { 'Australia/Adelaide', 'CST-9:30CST,M10.1.0,M4.1.0/3' },
+       { 'Australia/Brisbane', 'EST-10' },
+       { 'Australia/Broken Hill', 'CST-9:30CST,M10.1.0,M4.1.0/3' },
+       { 'Australia/Currie', 'EST-10EST,M10.1.0,M4.1.0/3' },
+       { 'Australia/Darwin', 'CST-9:30' },
+       { 'Australia/Eucla', 'CWST-8:45' },
+       { 'Australia/Hobart', 'EST-10EST,M10.1.0,M4.1.0/3' },
+       { 'Australia/Lindeman', 'EST-10' },
+       { 'Australia/Lord Howe', 'LHST-10:30LHST-11,M10.1.0,M4.1.0' },
+       { 'Australia/Melbourne', 'EST-10EST,M10.1.0,M4.1.0/3' },
+       { 'Australia/Perth', 'WST-8' },
+       { 'Australia/Sydney', 'EST-10EST,M10.1.0,M4.1.0/3' },
+       { 'Europe/Amsterdam', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Andorra', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Athens', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Belgrade', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Berlin', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Bratislava', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Brussels', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Bucharest', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Budapest', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Chisinau', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Copenhagen', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Dublin', 'GMT0IST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Gibraltar', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Guernsey', 'GMT0BST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Helsinki', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Isle of Man', 'GMT0BST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Istanbul', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Jersey', 'GMT0BST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Kaliningrad', 'EET-2EEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Kiev', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Lisbon', 'WET0WEST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Ljubljana', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/London', 'GMT0BST,M3.5.0/1,M10.5.0' },
+       { 'Europe/Luxembourg', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Madrid', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Malta', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Mariehamn', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Minsk', 'EET-2EEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Monaco', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Moscow', 'MSK-3MSD,M3.5.0,M10.5.0/3' },
+       { 'Europe/Oslo', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Paris', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Podgorica', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Prague', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Riga', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Rome', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Samara', 'SAMT-4SAMST,M3.5.0,M10.5.0/3' },
+       { 'Europe/San Marino', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Sarajevo', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Simferopol', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Skopje', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Sofia', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Stockholm', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Tallinn', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Tirane', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Uzhgorod', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Vaduz', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Vatican', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Vienna', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Vilnius', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Volgograd', 'VOLT-3VOLST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Warsaw', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Zagreb', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Europe/Zaporozhye', 'EET-2EEST,M3.5.0/3,M10.5.0/4' },
+       { 'Europe/Zurich', 'CET-1CEST,M3.5.0,M10.5.0/3' },
+       { 'Indian/Antananarivo', 'EAT-3' },
+       { 'Indian/Chagos', 'IOT-6' },
+       { 'Indian/Christmas', 'CXT-7' },
+       { 'Indian/Cocos', 'CCT-6:30' },
+       { 'Indian/Comoro', 'EAT-3' },
+       { 'Indian/Kerguelen', 'TFT-5' },
+       { 'Indian/Mahe', 'SCT-4' },
+       { 'Indian/Maldives', 'MVT-5' },
+       { 'Indian/Mauritius', 'MUT-4MUST,M10.5.0,M3.5.0/3' },
+       { 'Indian/Mayotte', 'EAT-3' },
+       { 'Indian/Reunion', 'RET-4' },
+       { 'Pacific/Apia', 'WST11' },
+       { 'Pacific/Auckland', 'NZST-12NZDT,M9.5.0,M4.1.0/3' },
+       { 'Pacific/Chatham', 'CHAST-12:45CHADT,M9.5.0/2:45,M4.1.0/3:45' },
+       { 'Pacific/Efate', 'VUT-11' },
+       { 'Pacific/Enderbury', 'PHOT-13' },
+       { 'Pacific/Fakaofo', 'TKT10' },
+       { 'Pacific/Fiji', 'FJT-12' },
+       { 'Pacific/Funafuti', 'TVT-12' },
+       { 'Pacific/Galapagos', 'GALT6' },
+       { 'Pacific/Gambier', 'GAMT9' },
+       { 'Pacific/Guadalcanal', 'SBT-11' },
+       { 'Pacific/Guam', 'ChST-10' },
+       { 'Pacific/Honolulu', 'HST10' },
+       { 'Pacific/Johnston', 'HST10' },
+       { 'Pacific/Kiritimati', 'LINT-14' },
+       { 'Pacific/Kosrae', 'KOST-11' },
+       { 'Pacific/Kwajalein', 'MHT-12' },
+       { 'Pacific/Majuro', 'MHT-12' },
+       { 'Pacific/Marquesas', 'MART9:30' },
+       { 'Pacific/Midway', 'SST11' },
+       { 'Pacific/Nauru', 'NRT-12' },
+       { 'Pacific/Niue', 'NUT11' },
+       { 'Pacific/Norfolk', 'NFT-11:30' },
+       { 'Pacific/Noumea', 'NCT-11' },
+       { 'Pacific/Pago Pago', 'SST11' },
+       { 'Pacific/Palau', 'PWT-9' },
+       { 'Pacific/Pitcairn', 'PST8' },
+       { 'Pacific/Ponape', 'PONT-11' },
+       { 'Pacific/Port Moresby', 'PGT-10' },
+       { 'Pacific/Rarotonga', 'CKT10' },
+       { 'Pacific/Saipan', 'ChST-10' },
+       { 'Pacific/Tahiti', 'TAHT10' },
+       { 'Pacific/Tarawa', 'GILT-12' },
+       { 'Pacific/Tongatapu', 'TOT-13' },
+       { 'Pacific/Truk', 'TRUT-10' },
+       { 'Pacific/Wake', 'WAKT-12' },
+       { 'Pacific/Wallis', 'WFT-12' },
+}
diff --git a/libs/sys/luasrc/sys/zoneinfo/tzoffset.lua b/libs/sys/luasrc/sys/zoneinfo/tzoffset.lua
new file mode 100644 (file)
index 0000000..b396345
--- /dev/null
@@ -0,0 +1,177 @@
+--[[
+LuCI - Autogenerated Zoneinfo Module
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+]]--
+
+module "luci.sys.zoneinfo.tzoffset"
+
+OFFSET = {
+       gmt   =      0, -- GMT
+       eat   =  10800, -- EAT
+       cet   =   3600, -- CET
+       wat   =   3600, -- WAT
+       cat   =   7200, -- CAT
+       wet   =      0, -- WET
+       sast  =   7200, -- SAST
+       eet   =   7200, -- EET
+       hast  = -36000, -- HAST
+       hadt  = -32400, -- HADT
+       akst  = -32400, -- AKST
+       akdt  = -28800, -- AKDT
+       ast   = -14400, -- AST
+       brt   = -10800, -- BRT
+       art   = -10800, -- ART
+       arst  =  -7200, -- ARST
+       wart  = -14400, -- WART
+       warst = -10800, -- WARST
+       pyt   = -14400, -- PYT
+       pyst  = -10800, -- PYST
+       est   = -18000, -- EST
+       cst   = -21600, -- CST
+       amt   = -14400, -- AMT
+       cot   = -18000, -- COT
+       mst   = -25200, -- MST
+       mdt   = -21600, -- MDT
+       vet   = -16200, -- VET
+       gft   = -10800, -- GFT
+       pst   = -28800, -- PST
+       pdt   = -25200, -- PDT
+       ect   = -18000, -- ECT
+       gyt   = -14400, -- GYT
+       bot   = -14400, -- BOT
+       pet   = -18000, -- PET
+       pmst  = -10800, -- PMST
+       pmdt  =  -7200, -- PMDT
+       uyt   = -10800, -- UYT
+       uyst  =  -7200, -- UYST
+       fnt   =  -7200, -- FNT
+       srt   = -10800, -- SRT
+       egt   =  -3600, -- EGT
+       egst  =      0, -- EGST
+       nst   = -12600, -- NST
+       ndt   =  -9000, -- NDT
+       wst   =  28800, -- WST
+       davt  =  25200, -- DAVT
+       ddut  =  36000, -- DDUT
+       mawt  =  21600, -- MAWT
+       nzst  =  43200, -- NZST
+       nzdt  =  46800, -- NZDT
+       rott  = -10800, -- ROTT
+       syot  =  10800, -- SYOT
+       vost  =  21600, -- VOST
+       almt  =  21600, -- ALMT
+       anat  =  43200, -- ANAT
+       anast =  46800, -- ANAST
+       aqtt  =  18000, -- AQTT
+       tmt   =  18000, -- TMT
+       azt   =  14400, -- AZT
+       azst  =  18000, -- AZST
+       ict   =  25200, -- ICT
+       kgt   =  21600, -- KGT
+       bnt   =  28800, -- BNT
+       chot  =  28800, -- CHOT
+       ist   =  19800, -- IST
+       bdt   =  21600, -- BDT
+       tlt   =  32400, -- TLT
+       gst   =  14400, -- GST
+       tjt   =  18000, -- TJT
+       hkt   =  28800, -- HKT
+       hovt  =  25200, -- HOVT
+       irkt  =  28800, -- IRKT
+       irkst =  32400, -- IRKST
+       wit   =  25200, -- WIT
+       eit   =  32400, -- EIT
+       aft   =  16200, -- AFT
+       pett  =  43200, -- PETT
+       petst =  46800, -- PETST
+       pkt   =  18000, -- PKT
+       npt   =  20700, -- NPT
+       krat  =  25200, -- KRAT
+       krast =  28800, -- KRAST
+       myt   =  28800, -- MYT
+       magt  =  39600, -- MAGT
+       magst =  43200, -- MAGST
+       cit   =  28800, -- CIT
+       pht   =  28800, -- PHT
+       novt  =  21600, -- NOVT
+       novst =  25200, -- NOVST
+       omst  =  21600, -- OMST
+       omsst =  25200, -- OMSST
+       orat  =  18000, -- ORAT
+       kst   =  32400, -- KST
+       qyzt  =  21600, -- QYZT
+       mmt   =  23400, -- MMT
+       sakt  =  36000, -- SAKT
+       sakst =  39600, -- SAKST
+       uzt   =  18000, -- UZT
+       sgt   =  28800, -- SGT
+       get   =  14400, -- GET
+       btt   =  21600, -- BTT
+       jst   =  32400, -- JST
+       ulat  =  28800, -- ULAT
+       vlat  =  36000, -- VLAT
+       vlast =  39600, -- VLAST
+       yakt  =  32400, -- YAKT
+       yakst =  36000, -- YAKST
+       yekt  =  18000, -- YEKT
+       yekst =  21600, -- YEKST
+       azot  =  -3600, -- AZOT
+       azost =      0, -- AZOST
+       cvt   =  -3600, -- CVT
+       fkt   = -14400, -- FKT
+       fkst  = -10800, -- FKST
+       cwst  =  31500, -- CWST
+       lhst  =  37800, -- LHST
+       lhst  =  39600, -- LHST
+       msk   =  10800, -- MSK
+       msd   =  14400, -- MSD
+       samt  =  14400, -- SAMT
+       samst =  18000, -- SAMST
+       volt  =  10800, -- VOLT
+       volst =  14400, -- VOLST
+       iot   =  21600, -- IOT
+       cxt   =  25200, -- CXT
+       cct   =  23400, -- CCT
+       tft   =  18000, -- TFT
+       sct   =  14400, -- SCT
+       mvt   =  18000, -- MVT
+       mut   =  14400, -- MUT
+       must  =  18000, -- MUST
+       ret   =  14400, -- RET
+       chast =  45900, -- CHAST
+       chadt =  49500, -- CHADT
+       vut   =  39600, -- VUT
+       phot  =  46800, -- PHOT
+       tkt   = -36000, -- TKT
+       fjt   =  43200, -- FJT
+       tvt   =  43200, -- TVT
+       galt  = -21600, -- GALT
+       gamt  = -32400, -- GAMT
+       sbt   =  39600, -- SBT
+       hst   = -36000, -- HST
+       lint  =  50400, -- LINT
+       kost  =  39600, -- KOST
+       mht   =  43200, -- MHT
+       mart  = -34200, -- MART
+       sst   = -39600, -- SST
+       nrt   =  43200, -- NRT
+       nut   = -39600, -- NUT
+       nft   =  41400, -- NFT
+       nct   =  39600, -- NCT
+       pwt   =  32400, -- PWT
+       pont  =  39600, -- PONT
+       pgt   =  36000, -- PGT
+       ckt   = -36000, -- CKT
+       taht  = -36000, -- TAHT
+       gilt  =  43200, -- GILT
+       tot   =  46800, -- TOT
+       trut  =  36000, -- TRUT
+       wakt  =  43200, -- WAKT
+       wft   =  43200, -- WFT
+}
index dd8058f..7f149cf 100644 (file)
@@ -19,9 +19,10 @@ $Id$
 -- @class      module
 -- @cstyle     instance
 
-local fs = require "luci.fs"
+local fs = require "nixio.fs"
 local uci = require "luci.model.uci"
 local util = require "luci.util"
+local nutil = require "nixio.util"
 local table = require "table"
 local string = require "string"
 
@@ -403,11 +404,11 @@ function UVL.read_scheme( self, shm, alias )
        local bc = "%s/bytecode/%s.lua" %{ self.schemedir, shm }
 
        if not fs.access(bc) then
-               local files = fs.glob(self.schemedir .. '/*/' .. shm)
+               local files = nutil.consume((fs.glob(self.schemedir .. '/*/' .. shm)))
 
-               if files then
+               if #files > 0 then
                        local ok, err
-                       for i, file in ipairs( files ) do
+                       for _, file in ipairs(files) do
                                if not fs.access(file) then
                                        return false, so:error(ERR.SME_READ(so,file))
                                end
index 1ad0891..c6a5de3 100644 (file)
@@ -14,7 +14,7 @@ $Id$
 
 ]]--
 
-local fs = require "luci.fs"
+local fs = require "nixio.fs"
 local ip = require "luci.ip"
 local math = require "math"
 local util = require "luci.util"
index 90fde64..47eed6b 100644 (file)
@@ -15,7 +15,7 @@ $Id$
 ]]--
 
 local os = require "os"
-local fs = require "luci.fs"
+local fs = require "nixio.fs"
 local sys = require "luci.sys"
 local ERR = require "luci.uvl.errors"
 
index 7a188f6..79b6cdb 100644 (file)
@@ -14,7 +14,7 @@ $Id$
 ]]--
 
 local io = require "io"
-local fs = require "luci.fs"
+local fs = require "nixio.fs"
 local uvl = require "luci.uvl"
 local util = require "luci.util"
 local ltn12 = require "luci.ltn12"
@@ -48,7 +48,7 @@ function Generator.make(self)
        fs.mkdir(self.output)
 
        for i, file in ipairs(self.additionals) do
-               fs.copy(self.sourcedir .. file, self.output .. "/" .. file)
+               fs.datacopy(self.sourcedir .. file, self.output .. "/" .. file)
        end
 
        template.compiler_mode = "memory"
index f7fac77..cc3bc96 100644 (file)
@@ -1,2 +1,28 @@
 include ../../build/config.mk
 include ../../build/module.mk
+include ../../build/gccconfig.mk
+
+TPL_LDFLAGS    =
+TPL_CFLAGS     =
+TPL_SO         = parser.so
+TPL_COMMON_OBJ = src/template_parser.o
+TPL_LUALIB_OBJ = src/template_lualib.o
+
+%.o: %.c
+       $(COMPILE) $(TPL_CFLAGS) $(LUA_CFLAGS) $(FPIC) -c -o $@ $< 
+
+compile: build-clean $(TPL_COMMON_OBJ) $(TPL_LUALIB_OBJ)
+       $(LINK) $(SHLIB_FLAGS) $(TPL_LDFLAGS) -o src/$(TPL_SO) \
+               $(TPL_COMMON_OBJ) $(TPL_LUALIB_OBJ)
+       mkdir -p dist$(LUCI_LIBRARYDIR)/template
+       cp src/$(TPL_SO) dist$(LUCI_LIBRARYDIR)/template/$(TPL_SO)
+
+install: build
+       cp -pR dist$(LUA_LIBRARYDIR)/* $(LUA_LIBRARYDIR)
+
+clean: build-clean
+
+build-clean:
+       rm -f src/*.o src/$(TPL_SO)
+
+
index b0f6c1e..37008b5 100644 (file)
@@ -25,7 +25,7 @@ limitations under the License.
 ]]--
 
 --- LuCI web dispatcher.
-local fs = require "luci.fs"
+local fs = require "nixio.fs"
 local sys = require "luci.sys"
 local init = require "luci.init"
 local util = require "luci.util"
@@ -258,7 +258,7 @@ function dispatch(request)
                local verifytoken = false
                if not sess then
                        sess = luci.http.getcookie("sysauth")
-                       sess = sess and sess:match("^[A-F0-9]+$")
+                       sess = sess and sess:match("^[a-f0-9]+$")
                        verifytoken = true
                end
 
@@ -394,19 +394,16 @@ end
 function createindex_plain(path, suffixes)
        local controllers = { }
        for _, suffix in ipairs(suffixes) do
-               controllers = util.combine(
-                       controllers,
-                       luci.fs.glob(path .. "*" .. suffix) or {},
-                       luci.fs.glob(path .. "*/*" .. suffix) or {}
-               )
+               nixio.util.consume((fs.glob(path .. "*" .. suffix)), controllers)
+               nixio.util.consume((fs.glob(path .. "*/*" .. suffix)), controllers)
        end
 
        if indexcache then
-               local cachedate = fs.mtime(indexcache)
+               local cachedate = fs.stat(indexcache, "mtime")
                if cachedate then
                        local realdate = 0
                        for _, obj in ipairs(controllers) do
-                               local omtime = fs.mtime(path .. "/" .. obj)
+                               local omtime = fs.stat(path .. "/" .. obj, "mtime")
                                realdate = (omtime and omtime > realdate) and omtime or realdate
                        end
 
index 082a600..dcca13e 100644 (file)
@@ -27,6 +27,7 @@ limitations under the License.
 --- LuCI translation library.
 module("luci.i18n", package.seeall)
 require("luci.util")
+require("lmo")
 
 table   = {}
 i18ndir = luci.util.libpath() .. "/i18n/"
@@ -47,13 +48,22 @@ end
 function load(file, lang, force)
        lang = lang and lang:gsub("_", "-") or ""
        if force or not loaded[lang] or not loaded[lang][file] then
-               local f = loadfile(i18ndir .. file .. "." .. lang .. ".lua") or
-                       loadfile(i18ndir .. file .. "." .. lang .. ".lua.gz")
-
+               local f = lmo.open(i18ndir .. file .. "." .. lang .. ".lmo")
                if f then
-                       table[lang] = table[lang] or {}
-                       setfenv(f, table[lang])
-                       f()
+                       if not table[lang] then
+                               table[lang] = { f }
+                               setmetatable(table[lang], {
+                                       __index = function(tbl, key)
+                                               for i = 1, #tbl do
+                                                       local s = rawget(tbl, i):lookup(key)
+                                                       if s then return s end
+                                               end
+                                       end
+                               })
+                       else
+                               table[lang][#table[lang]+1] = f
+                       end
+
                        loaded[lang] = loaded[lang] or {}
                        loaded[lang][file] = true
                        return true
index e5cb178..8ae24a5 100644 (file)
@@ -15,7 +15,6 @@ $Id$
 
 --- LuCI session library.
 module("luci.sauth", package.seeall)
-require("luci.fs")
 require("luci.util")
 require("luci.sys")
 require("luci.config")
@@ -30,17 +29,17 @@ sessiontime = tonumber(luci.config.sauth.sessiontime) or 15 * 60
 --- Manually clean up expired sessions.
 function clean()
        local now   = os.time()
-       local files = luci.fs.dir(sessionpath)
+       local files = fs.dir(sessionpath)
        
        if not files then
                return nil
        end
        
-       for i, file in pairs(files) do
+       for file in files do
                local fname = sessionpath .. "/" .. file
-               local stat = luci.fs.stat(fname)
+               local stat = fs.stat(fname)
                if stat and stat.type == "reg" and stat.mtime + sessiontime < now then
-                       luci.fs.unlink(fname)
+                       fs.unlink(fname)
                end 
        end
 end
@@ -68,8 +67,8 @@ function read(id)
        if not sane(sessionpath .. "/" .. id) then
                return
        end
-       luci.fs.utime(sessionpath .. "/" .. id)
-       return luci.fs.readfile(sessionpath .. "/" .. id)
+       fs.utimes(sessionpath .. "/" .. id)
+       return fs.readfile(sessionpath .. "/" .. id)
 end
 
 
@@ -77,8 +76,8 @@ end
 -- @return Boolean status
 function sane(file)
        return luci.sys.process.info("uid")
-                       == luci.fs.stat(file or sessionpath, "uid")
-               and luci.fs.stat(file or sessionpath, "modestr")
+                       == fs.stat(file or sessionpath, "uid")
+               and fs.stat(file or sessionpath, "modestr")
                        == (file and "rw-------" or "rwx------")
 end
 
@@ -106,5 +105,5 @@ function kill(id)
        if not id:match("^%w+$") then
                error("Session ID is not sane!")
        end
-       luci.fs.unlink(sessionpath .. "/" .. id)
-end
\ No newline at end of file
+       fs.unlink(sessionpath .. "/" .. id)
+end
index 83efd22..7cc6e11 100644 (file)
@@ -24,7 +24,7 @@ limitations under the License.
 
 ]]--
 
-local fs = require"luci.fs"
+local fs = require "nixio.fs"
 local sys = require "luci.sys"
 local util = require "luci.util"
 local table = require "table"
@@ -32,6 +32,7 @@ local string = require "string"
 local config = require "luci.config"
 local coroutine = require "coroutine"
 local nixio = require "nixio", require "nixio.util"
+local tparser = require "luci.template.parser"
 
 local tostring, pairs, loadstring = tostring, pairs, loadstring
 local setmetatable, loadfile = setmetatable, loadfile
@@ -89,9 +90,9 @@ function compile(template)
        
        -- Replacements
        local r_include = '")\ninclude("%s")\nwrite("'
-       local r_i18n    = '"..translate("%1","%2").."'
-       local r_i18n2    = '"..translate("%1", "").."'
-       local r_pexec   = '"..(%s or "").."'
+       local r_i18n    = '")\nwrite(translate("%1","%2"))\nwrite("'
+       local r_i18n2   = '")\nwrite(translate("%1", ""))\nwrite("'
+       local r_pexec   = '")\nwrite(tostring(%s or ""))\nwrite("'
        local r_exec    = '")\n%s\nwrite("'
        
        -- Parse the expressions
@@ -173,18 +174,18 @@ function Template.__init__(self, name)
        local err       
        
        if compiler_mode == "file" then
-               local tplmt = fs.mtime(sourcefile) or fs.mtime(sourcefile .. ".htm")
-               local commt = fs.mtime(compiledfile)
+               local tplmt = fs.stat(sourcefile, "mtime") or fs.stat(sourcefile .. ".htm", "mtime")
+               local commt = fs.stat(compiledfile, "mtime")
                
-               if not fs.mtime(cdir) then
-                       fs.mkdir(cdir, true)
+               if not fs.stat(cdir, "mtime") then
+                       fs.mkdirr(cdir)
                        fs.chmod(fs.dirname(cdir), 777)
                end
                
                assert(tplmt or commt, "No such template: " .. name)
                                
                -- Build if there is no compiled file or if compiled file is outdated
-               if not commt or (commt  and tplmt and commt < tplmt) then
+               if not commt or (commt and tplmt and commt < tplmt) then
                        local source
                        source, err = fs.readfile(sourcefile) or fs.readfile(sourcefile .. ".htm")
                        
@@ -206,12 +207,7 @@ function Template.__init__(self, name)
                end
                
        elseif compiler_mode == "memory" then
-               local source
-               source, err = fs.readfile(sourcefile) or fs.readfile(sourcefile .. ".htm")
-               if source then
-                       self.template, err = compile(source)
-               end
-                       
+               self.template, _, err = tparser.parse(sourcefile .. ".htm")
        end
        
        -- If we have no valid template throw error, otherwise cache the template
diff --git a/libs/web/src/template_lualib.c b/libs/web/src/template_lualib.c
new file mode 100644 (file)
index 0000000..685613f
--- /dev/null
@@ -0,0 +1,62 @@
+/*
+ * LuCI Template - Lua binding
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "template_lualib.h"
+
+int template_L_parse(lua_State *L)
+{
+       const char *file = luaL_checkstring(L, 1);
+       struct template_parser parser;
+       int lua_status;
+
+       if( (parser.fd = open(file, O_RDONLY)) > 0 )
+       {
+               parser.flags   = 0;
+               parser.bufsize = 0;
+               parser.state   = T_STATE_TEXT_NEXT;
+               
+               if( !(lua_status = lua_load(L, template_reader, &parser, file)) )
+               {
+                       return 1;
+               }
+               else
+               {
+                       lua_pushnil(L);
+                       lua_pushinteger(L, lua_status);
+                       lua_pushlstring(L, parser.out, parser.outsize);
+                       return 3;
+               }
+       }
+
+       lua_pushnil(L);
+       lua_pushinteger(L, 255);
+       lua_pushstring(L, "No such file or directory");
+       return 3;
+}
+
+/* module table */
+static const luaL_reg R[] = {
+       {"parse",       template_L_parse},
+       {NULL,          NULL}
+};
+
+LUALIB_API int luaopen_luci_template_parser(lua_State *L) {
+       luaL_register(L, TEMPLATE_LUALIB_META, R);
+       return 1;
+}
+
diff --git a/libs/web/src/template_lualib.h b/libs/web/src/template_lualib.h
new file mode 100644 (file)
index 0000000..de915e1
--- /dev/null
@@ -0,0 +1,28 @@
+/*
+ * LuCI Template - Lua library header
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#ifndef _TEMPLATE_LUALIB_H_
+#define _TEMPLATE_LUALIB_H_
+
+#include "template_parser.h"
+
+#define TEMPLATE_LUALIB_META  "template.parser"
+
+LUALIB_API int luaopen_luci_template_parser(lua_State *L);
+
+#endif
diff --git a/libs/web/src/template_parser.c b/libs/web/src/template_parser.c
new file mode 100644 (file)
index 0000000..58de5bb
--- /dev/null
@@ -0,0 +1,463 @@
+/*
+ * LuCI Template - Parser implementation
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#include "template_parser.h"
+
+
+/* leading and trailing code for different types */
+const char * gen_code[6][2] = {
+       { "write(\"",                   "\")"   },
+       { NULL,                                 NULL    },
+       { "write(tostring(",    "))"    },
+       { "include(\"",                 "\")"   },
+       { "write(translate(\"", "\"))"  },
+       { NULL,                                 " "             }
+};
+
+/* Simple strstr() like function that takes len arguments for both haystack and needle. */
+static char *strfind(char *haystack, int hslen, const char *needle, int ndlen)
+{
+       int match = 0;
+       int i, j;
+
+       for( i = 0; i < hslen; i++ )
+       {
+               if( haystack[i] == needle[0] )
+               {
+                       match = ((ndlen == 1) || ((i + ndlen) <= hslen));
+
+                       for( j = 1; (j < ndlen) && ((i + j) < hslen); j++ )
+                       {
+                               if( haystack[i+j] != needle[j] )
+                               {
+                                       match = 0;
+                                       break;
+                               }
+                       }
+
+                       if( match )
+                               return &haystack[i];
+               }
+       }
+
+       return NULL;
+}
+
+/* 
+ * Inspect current read buffer and find the number of "vague" characters at the end 
+ * which could indicate an opening token. Returns the number of "vague" chars.
+ * The last continuous sequence of whitespace, optionally followed by a "<" is
+ * treated as "vague" because whitespace may be discarded if the upcoming opening
+ * token indicates pre-whitespace-removal ("<%-"). A single remaining "<" char 
+ * can't be differentiated from an opening token ("<%"), so it's kept to be processed
+ * in the next cycle.
+ */
+static int stokscan(struct template_parser *data, int off, int no_whitespace)
+{
+       int i;
+       int skip = 0;
+       int tokoff = data->bufsize - 1;
+
+       for( i = tokoff; i >= off; i-- )
+       {
+               if( data->buf[i] == T_TOK_START[0] )
+               {
+                       skip = tokoff - i + 1;
+                       tokoff = i - 1;
+                       break;
+               }
+       }
+
+       if( !no_whitespace )
+       {
+               for( i = tokoff; i >= off; i-- )
+               {
+                       if( isspace(data->buf[i]) )
+                               skip++;
+                       else
+                               break;
+               }
+       }
+
+       return skip;
+}
+
+/*
+ * Similar to stokscan() but looking for closing token indicators.
+ * Matches "-", optionally followed by a "%" char.
+ */
+static int etokscan(struct template_parser *data)
+{
+       int skip = 0;
+
+       if( (data->bufsize > 0) && (data->buf[data->bufsize-1] == T_TOK_END[0]) )
+               skip++;
+
+       if( (data->bufsize > skip) && (data->buf[data->bufsize-skip-1] == T_TOK_SKIPWS[0]) )
+               skip++;
+
+       return skip;
+}
+
+/*
+ * Generate Lua expressions from the given raw code, write it into the
+ * output buffer and set the lua_Reader specific size pointer.
+ * Takes parser-state, lua_Reader's size pointer and generator flags
+ * as parameter. The given flags indicate whether leading or trailing
+ * code should be added. Returns a pointer to the output buffer.
+ */
+static const char * generate_expression(struct template_parser *data, size_t *sz, int what)
+{
+       char tmp[T_OUTBUFSZ];
+       int i;
+       int size = 0;
+       int start = 0;
+       int i18n_hasdef = 0;
+
+       memset(tmp, 0, T_OUTBUFSZ);
+
+       /* Inject leading expression code (if any) */
+       if( (what & T_GEN_START) && (gen_code[data->type][0] != NULL) )
+       {
+               memcpy(tmp, gen_code[data->type][0], strlen(gen_code[data->type][0]));
+               size += strlen(gen_code[data->type][0]);
+       }
+
+       /* Parse source buffer */
+       for( i = 0; i < data->outsize; i++ )
+       {
+               /* Skip leading whitespace for non-raw and non-expr chunks */
+               if( !start && isspace(data->out[i]) && (data->type == T_TYPE_I18N || data->type == T_TYPE_INCLUDE) )
+                       continue;
+               else if( !start )
+                       start = 1;
+
+               /* Found whitespace after i18n key */
+               if( (data->type == T_TYPE_I18N) && (i18n_hasdef == 1) )
+               {
+                       /* At non-whitespace char, inject seperator token */
+                       if( !isspace(data->out[i]) )
+                       {
+                               memcpy(&tmp[size], T_TOK_I18NSEP, strlen(T_TOK_I18NSEP));
+                               size += strlen(T_TOK_I18NSEP);
+                               i18n_hasdef = 2;
+                       }
+
+                       /* At further whitespace, skip */
+                       else
+                       {
+                               continue;
+                       }
+               }
+
+               /* Escape quotes, backslashes and newlines for plain, i18n and include expressions */
+               if( (data->type == T_TYPE_TEXT || data->type == T_TYPE_I18N || data->type == T_TYPE_INCLUDE) &&
+                   (data->out[i] == '\\' || data->out[i] == '"' || data->out[i] == '\n' || data->out[i] == '\t') )
+               {
+                       tmp[size++] = '\\';
+
+                       switch(data->out[i])
+                       {
+                               case '\n':
+                                       tmp[size++] = 'n';
+                                       break;
+
+                               case '\t':
+                                       tmp[size++] = 't';
+                                       break;
+
+                               default:
+                                       tmp[size++] = data->out[i];
+                       }
+               }
+
+               /* Found whitespace in i18n expression, raise flag */
+               else if( isspace(data->out[i]) && (data->type == T_TYPE_I18N) )
+               {
+                       i18n_hasdef = 1;
+               }
+
+               /* Normal char */
+               else
+               {
+                       tmp[size++] = data->out[i];
+               }
+       }
+
+       /* Processed i18n expression without default text, inject separator */
+       if( (data->type == T_TYPE_I18N) && (i18n_hasdef < 2) )
+       {
+               memcpy(&tmp[size], T_TOK_I18NSEP, strlen(T_TOK_I18NSEP));
+               size += strlen(T_TOK_I18NSEP);
+       }
+
+       /* Inject trailing expression code (if any) */
+       if( (what & T_GEN_END) && (gen_code[data->type][1] != NULL) )
+       {
+               memcpy(&tmp[size], gen_code[data->type][1], strlen(gen_code[data->type][1]));
+               size += strlen(gen_code[data->type][1]);
+       }
+
+       *sz = data->outsize = size;
+       memset(data->out, 0, T_OUTBUFSZ);
+       memcpy(data->out, tmp, size);
+
+       //printf("<<<%i|%i|%i|%s>>>\n", what, data->type, *sz, data->out);
+
+       return data->out;
+}
+
+/*
+ * Move the number of bytes specified in data->bufsize from the
+ * given source pointer to the beginning of the read buffer.
+ */
+static void bufmove(struct template_parser *data, const char *src)
+{
+       if( data->bufsize > 0 )
+               memmove(data->buf, src, data->bufsize);
+       else if( data->bufsize < 0 )
+               data->bufsize = 0;
+
+       data->buf[data->bufsize] = 0;
+}
+
+/*
+ * Move the given amount of bytes from the given source pointer
+ * to the output buffer and set data->outputsize.
+ */
+static void bufout(struct template_parser *data, const char *src, int len)
+{
+       if( len >= 0 )
+       {
+               memset(data->out, 0, T_OUTBUFSZ);
+               memcpy(data->out, src, len);
+               data->outsize = len;
+       }
+       else
+       {
+               data->outsize = 0;
+       }
+}
+
+/*
+ * lua_Reader compatible function that parses template code on demand from
+ * the given file handle.
+ */
+const char *template_reader(lua_State *L, void *ud, size_t *sz)
+{
+       struct template_parser *data = ud;
+       char *match = NULL;
+       int off = 0;
+       int ignore = 0;
+       int genflags = 0;
+       int readlen = 0;
+       int vague = 0;
+
+       while( !(data->flags & T_FLAG_EOF) || (data->bufsize > 0) )
+       {
+               /* Fill buffer */
+               if( !(data->flags & T_FLAG_EOF) && (data->bufsize < T_READBUFSZ) )
+               {
+                       if( (readlen = read(data->fd, &data->buf[data->bufsize], T_READBUFSZ - data->bufsize)) > 0 )
+                               data->bufsize += readlen;
+                       else if( readlen == 0 )
+                               data->flags |= T_FLAG_EOF;
+                       else
+                               return NULL;
+               }
+
+               /* Evaluate state */
+               switch(data->state)
+               {
+                       /* Plain text chunk (before "<%") */
+                       case T_STATE_TEXT_INIT:
+                       case T_STATE_TEXT_NEXT:
+                               off = 0; ignore = 0; *sz = 0;
+                               data->type = T_TYPE_TEXT;
+
+                               /* Skip leading whitespace if requested */
+                               if( data->flags & T_FLAG_SKIPWS )
+                               {
+                                       data->flags &= ~T_FLAG_SKIPWS;
+                                       while( (off < data->bufsize) && isspace(data->buf[off]) )
+                                               off++;
+                               }
+
+                               /* Found "<%" */
+                               if( (match = strfind(&data->buf[off], data->bufsize - off - 1, T_TOK_START, strlen(T_TOK_START))) != NULL )
+                               {
+                                       readlen = (int)(match - &data->buf[off]);
+                                       data->bufsize -= (readlen + strlen(T_TOK_START) + off);
+                                       match += strlen(T_TOK_START);
+
+                                       /* Check for leading '-' */
+                                       if( match[0] == T_TOK_SKIPWS[0] )
+                                       {
+                                               data->bufsize--;
+                                               match++;
+
+                                               while( (readlen > 1) && isspace(data->buf[off+readlen-1]) )
+                                               {
+                                                       readlen--;
+                                               }
+                                       }
+
+                                       bufout(data, &data->buf[off], readlen);
+                                       bufmove(data, match);
+                                       data->state = T_STATE_CODE_INIT;
+                               }
+
+                               /* Maybe plain chunk */
+                               else
+                               {
+                                       /* Preserve trailing "<" or white space, maybe a start token */
+                                       vague = stokscan(data, off, 0);
+
+                                       /* We can process some bytes ... */
+                                       if( vague < data->bufsize )
+                                       {
+                                               readlen = data->bufsize - vague - off;
+                                       }
+
+                                       /* No bytes to process, so try to remove at least whitespace ... */
+                                       else
+                                       {
+                                               /* ... but try to preserve trailing "<" ... */
+                                               vague = stokscan(data, off, 1);
+
+                                               if( vague < data->bufsize )
+                                               {
+                                                       readlen = data->bufsize - vague - off;
+                                               }
+
+                                               /* ... no chance, push out buffer */
+                                               else
+                                               {
+                                                       readlen = vague - off;
+                                                       vague   = 0;
+                                               }
+                                       }
+
+                                       bufout(data, &data->buf[off], readlen);
+
+                                       data->state   = T_STATE_TEXT_NEXT;
+                                       data->bufsize = vague;
+                                       bufmove(data, &data->buf[off+readlen]);
+                               }
+
+                               if( ignore || data->outsize == 0 )
+                                       continue;
+                               else
+                                       return generate_expression(data, sz, T_GEN_START | T_GEN_END);
+
+                               break;
+
+                       /* Ignored chunk (inside "<%# ... %>") */
+                       case T_STATE_SKIP:
+                               ignore = 1;
+
+                       /* Initial code chunk ("<% ...") */
+                       case T_STATE_CODE_INIT:
+                               off = 0;
+
+                               /* Check for leading '-' */
+                               if( data->buf[off] == T_TOK_SKIPWS[0] )
+                                       off++;
+
+                               /* Determine code type */
+                               switch(data->buf[off])
+                               {
+                                       case '#':
+                                               ignore = 1;
+                                               off++;
+                                               data->type = T_TYPE_COMMENT;
+                                               break;
+
+                                       case '=':
+                                               off++;
+                                               data->type = T_TYPE_EXPR;
+                                               break;
+
+                                       case '+':
+                                               off++;
+                                               data->type = T_TYPE_INCLUDE;
+                                               break;
+
+                                       case ':':
+                                               off++;
+                                               data->type = T_TYPE_I18N;
+                                               break;
+
+                                       default:
+                                               data->type = T_TYPE_CODE;
+                                               break;
+                               }
+
+                       /* Subsequent code chunk ("..." or "... %>") */ 
+                       case T_STATE_CODE_NEXT:
+                               /* Found "%>" */
+                               if( (match = strfind(&data->buf[off], data->bufsize - off, T_TOK_END, strlen(T_TOK_END))) != NULL )
+                               {
+                                       genflags = ( data->state == T_STATE_CODE_INIT )
+                                               ? (T_GEN_START | T_GEN_END) : T_GEN_END;
+
+                                       readlen = (int)(match - &data->buf[off]);
+
+                                       /* Check for trailing '-' */
+                                       if( (match > data->buf) && (*(match-1) == T_TOK_SKIPWS[0]) )
+                                       {
+                                               readlen--;
+                                               data->flags |= T_FLAG_SKIPWS;
+                                       }
+
+                                       bufout(data, &data->buf[off], readlen);
+
+                                       data->state = T_STATE_TEXT_INIT;
+                                       data->bufsize -= ((int)(match - &data->buf[off]) + strlen(T_TOK_END) + off);
+                                       bufmove(data, &match[strlen(T_TOK_END)]);
+                               }
+
+                               /* Code chunk */
+                               else
+                               {
+                                       genflags = ( data->state == T_STATE_CODE_INIT ) ? T_GEN_START : 0;
+
+                                       /* Preserve trailing "%" and "-", maybe an end token */
+                                       vague   = etokscan(data);
+                                       readlen = data->bufsize - off - vague;
+                                       bufout(data, &data->buf[off], readlen);
+
+                                       data->state   = T_STATE_CODE_NEXT;
+                                       data->bufsize = vague;
+                                       bufmove(data, &data->buf[readlen+off]);
+                               }
+
+                               if( ignore || (data->outsize == 0 && !genflags) )
+                                       continue;
+                               else
+                                       return generate_expression(data, sz, genflags);
+
+                               break;
+               }
+       }
+
+       *sz = 0;
+       return NULL;
+}
+
+
diff --git a/libs/web/src/template_parser.h b/libs/web/src/template_parser.h
new file mode 100644 (file)
index 0000000..42ebdff
--- /dev/null
@@ -0,0 +1,81 @@
+/*
+ * LuCI Template - Parser header
+ *
+ *   Copyright (C) 2009 Jo-Philipp Wich <xm@subsignal.org>
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+#ifndef _TEMPLATE_PARSER_H_
+#define _TEMPLATE_PARSER_H_
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <fcntl.h>
+#include <string.h>
+#include <ctype.h>
+
+#include <lua.h>
+#include <lualib.h>
+#include <lauxlib.h>
+
+
+#define T_READBUFSZ                    1024
+#define T_OUTBUFSZ                     T_READBUFSZ * 3
+
+/* parser states */
+#define T_STATE_TEXT_INIT      0
+#define T_STATE_TEXT_NEXT      1
+#define T_STATE_CODE_INIT      2
+#define T_STATE_CODE_NEXT      3
+#define T_STATE_SKIP           4
+
+/* parser flags */
+#define T_FLAG_EOF                     0x01
+#define T_FLAG_SKIPWS          0x02
+
+/* tokens used in matching and expression generation */
+#define T_TOK_START                    "<%"
+#define T_TOK_END                      "%>"
+#define T_TOK_SKIPWS           "-"
+#define T_TOK_I18NSEP          "\", \""
+
+/* generator flags */
+#define T_GEN_START                    0x01
+#define T_GEN_END                      0x02
+
+/* code types */
+#define T_TYPE_TEXT                    0
+#define T_TYPE_COMMENT         1
+#define T_TYPE_EXPR                    2
+#define T_TYPE_INCLUDE                 3
+#define T_TYPE_I18N                    4
+#define T_TYPE_CODE                    5
+
+/* parser state */
+struct template_parser {
+       int fd;
+       int bufsize;
+       int outsize;
+       int state;
+       int flags;
+       int type;
+       char buf[T_READBUFSZ];
+       char out[T_OUTBUFSZ];
+};
+
+
+const char *template_reader(lua_State *L, void *ud, size_t *sz);
+
+#endif
index a137377..50c79f6 100644 (file)
@@ -28,14 +28,14 @@ function index()
        page.order  = 40
        page.index  = true
        
-       if luci.fs.access("/etc/config/lucittpd") then
+       if nixio.fs.access("/etc/config/lucittpd") then
                local page  = node("admin", "services", "lucittpd")
                page.target = cbi("admin_services/lucittpd")
                page.title  = "LuCIttpd"
                page.order  = 10
        end
 
-       if luci.fs.access("/etc/config/httpd") then
+       if nixio.fs.access("/etc/config/httpd") then
                local page  = node("admin", "services", "httpd")
                page.target = cbi("admin_services/httpd")
                page.title  = "Busybox HTTPd"
@@ -51,4 +51,4 @@ function index()
        page.target = cbi("admin_services/dnsmasq")
        page.title  = "Dnsmasq"
        page.order  = 30
-end
\ No newline at end of file
+end
index d8fa9e9..5d2df9c 100644 (file)
@@ -20,8 +20,8 @@ function index()
        entry({"admin", "status"}, template("admin_status/index"), i18n("status", "Status"), 20).index = true
        entry({"admin", "status", "interfaces"}, template("admin_status/interfaces"), i18n("interfaces", "Interfaces"), 1)
        entry({"admin", "status", "iptables"}, call("action_iptables"), i18n("a_s_ipt", "Firewall"), 2)
-       entry({"admin", "status", "conntrack"}, form("admin_status/conntrack"), i18n("a_n_conntrack"), 3)
-       entry({"admin", "status", "routes"}, form("admin_status/routes"), i18n("a_n_routes"), 4)
+       entry({"admin", "status", "conntrack"}, template("admin_status/conntrack"), i18n("a_n_conntrack"), 3)
+       entry({"admin", "status", "routes"}, template("admin_status/routes"), i18n("a_n_routes"), 4)
        entry({"admin", "status", "syslog"}, call("action_syslog"), i18n("syslog", "System Log"), 5)
        entry({"admin", "status", "dmesg"}, call("action_dmesg"), i18n("dmesg", "Kernel Log"), 6)
 
index 56010ea..a273ff3 100644 (file)
@@ -27,7 +27,7 @@ function index()
        entry({"admin", "system", "processes"}, form("admin_system/processes"), i18n("process_head"), 45)
        entry({"admin", "system", "fstab"}, cbi("admin_system/fstab"), i18n("a_s_fstab"), 50)
 
-       if luci.fs.isdirectory("/sys/class/leds") then
+       if nixio.fs.access("/sys/class/leds") then
                entry({"admin", "system", "leds"}, cbi("admin_system/leds"), i18n("leds", "LEDs"), 60)
        end
 
@@ -124,7 +124,7 @@ function action_packages()
         
        -- Remove index cache
        if changes then
-               luci.fs.unlink("/tmp/luci-indexcache")
+               nixio.fs.unlink("/tmp/luci-indexcache")
        end     
 end
 
@@ -215,7 +215,7 @@ function action_upgrade()
        
        local function storage_size()
                local size = 0
-               if luci.fs.access("/proc/mtd") then
+               if nixio.fs.access("/proc/mtd") then
                        for l in io.lines("/proc/mtd") do
                                local d, s, e, n = l:match('^([^%s]+)%s+([^%s]+)%s+([^%s]+)%s+"([^%s]+)"')
                                if n == "linux" then
@@ -223,7 +223,7 @@ function action_upgrade()
                                        break
                                end
                        end
-               elseif luci.fs.access("/proc/partitions") then
+               elseif nixio.fs.access("/proc/partitions") then
                        for l in io.lines("/proc/partitions") do
                                local x, y, b, n = l:match('^%s*(%d+)%s+(%d+)%s+([^%s]+)%s+([^%s]+)')
                                if b and n and not n:match('[0-9]') then
@@ -240,7 +240,7 @@ function action_upgrade()
        local file
        luci.http.setfilehandler(
                function(meta, chunk, eof)
-                       if not luci.fs.access(tmpfile) and not file and chunk and #chunk > 0 then
+                       if not nixio.fs.access(tmpfile) and not file and chunk and #chunk > 0 then
                                file = io.open(tmpfile, "w")
                        end
                        if file and chunk then
@@ -256,9 +256,9 @@ function action_upgrade()
        -- Determine state
        local keep_avail   = true
        local step         = tonumber(luci.http.formvalue("step") or 1)
-       local has_image    = luci.fs.access(tmpfile)
+       local has_image    = nixio.fs.access(tmpfile)
        local has_support  = image_supported()
-       local has_platform = luci.fs.access("/lib/upgrade/platform.sh")
+       local has_platform = nixio.fs.access("/lib/upgrade/platform.sh")
        local has_upload   = luci.http.formvalue("image")
        
        -- This does the actual flashing which is invoked inside an iframe
@@ -299,7 +299,7 @@ function action_upgrade()
                -- If there is an image but user has requested step 1
                -- or type is not supported, then remove it.
                if has_image then
-                       luci.fs.unlink(tmpfile)
+                       nixio.fs.unlink(tmpfile)
                end
                        
                luci.template.render("admin_system/upgrade", {
@@ -314,7 +314,7 @@ function action_upgrade()
                luci.template.render("admin_system/upgrade", {
                        step=2,
                        checksum=image_checksum(),
-                       filesize=luci.fs.stat(tmpfile).size,
+                       filesize=nixio.fs.stat(tmpfile).size,
                        flashsize=storage_size(),
                        keepconfig=(keep_avail and luci.http.formvalue("keepcfg") == "1")
                } )
@@ -334,7 +334,7 @@ function _keep_pattern()
        if files then
                kpattern = ""
                for k, v in pairs(files) do
-                       if k:sub(1,1) ~= "." and luci.fs.glob(v) then
+                       if k:sub(1,1) ~= "." and nixio.fs.glob(v)() then
                                kpattern = kpattern .. " " ..  v
                        end
                end
index caf7c97..30e8ddc 100644 (file)
@@ -15,6 +15,8 @@ require("luci.config")
 m = Map("luci", translate("webui"), translate("a_i_luci1",
  "Hier können Eigenschaften und die Funktionalität der Oberfläche angepasst werden."))
 
+local fs = require "nixio.fs"
+
 -- force reload of global luci config namespace to reflect the changes
 function m.commit_handler(self)
        package.loaded["luci.config"] = nil
@@ -31,8 +33,8 @@ local i18ndir = luci.i18n.i18ndir .. "default."
 for k, v in luci.util.kspairs(luci.config.languages) do
        local file = i18ndir .. k:gsub("_", "-")
        if k:sub(1, 1) ~= "." and (
-               luci.fs.access(file .. ".lua") or
-               luci.fs.access(file .. ".lua.gz")
+               fs.access(file .. ".lua") or
+               fs.access(file .. ".lua.gz")
        ) then
                l:value(k, v)
        end
index 0b2f55a..31a27b3 100644 (file)
@@ -11,17 +11,21 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.sys")
-require("luci.tools.webadmin")
+
+local uci = require "luci.model.uci".cursor()
+local sys = require "luci.sys"
+local wa  = require "luci.tools.webadmin"
+local fs  = require "nixio.fs"
+
 m2 = Map("luci_ethers", translate("dhcp_leases"))
 
 local leasefn, leasefp, leases
-luci.model.uci.cursor():foreach("dhcp", "dnsmasq",
+uci:foreach("dhcp", "dnsmasq",
  function(section)
        leasefn = section.leasefile
  end
 ) 
-local leasefp = leasefn and luci.fs.access(leasefn) and io.lines(leasefn)
+local leasefp = leasefn and fs.access(leasefn) and io.lines(leasefn)
 if leasefp then
        leases = {}
        for lease in leasefp do
@@ -38,9 +42,7 @@ if leases then
        ltime = v:option(DummyValue, 1, translate("dhcp_timeremain"))
        function ltime.cfgvalue(self, ...)
                local value = DummyValue.cfgvalue(self, ...)
-               return luci.tools.webadmin.date_format(
-                os.difftime(tonumber(value), os.time())
-               )
+               return wa.date_format(os.difftime(tonumber(value), os.time()))
        end
 end
 
@@ -51,11 +53,13 @@ s.template = "cbi/tblsection"
 
 mac = s:option(Value, "macaddr", translate("macaddress"))
 ip = s:option(Value, "ipaddr", translate("ipaddress"))
-for i, dataset in ipairs(luci.sys.net.arptable()) do
-       ip:value(dataset["IP address"])
-       mac:value(dataset["HW address"],
-        dataset["HW address"] .. " (" .. dataset["IP address"] .. ")")
-end
+sys.net.arptable(function(entry)
+       ip:value(entry["IP address"])
+       mac:value(
+               entry["HW address"],
+               entry["HW address"] .. " (" .. entry["IP address"] .. ")"
+       )
+end)
 
        
 return m2
index b9e65fb..8758f73 100644 (file)
@@ -13,14 +13,16 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-require("luci.tools.webadmin")
+local wa = require "luci.tools.webadmin"
+local fs = require "nixio.fs"
+
 arg[1] = arg[1] or ""
 
-local has_3g    = luci.fs.mtime("/usr/bin/gcom")
-local has_pptp  = luci.fs.mtime("/usr/sbin/pptp")
-local has_pppd  = luci.fs.mtime("/usr/sbin/pppd")
-local has_pppoe = luci.fs.glob("/usr/lib/pppd/*/rp-pppoe.so")
-local has_pppoa = luci.fs.glob("/usr/lib/pppd/*/pppoatm.so")
+local has_3g    = fs.access("/usr/bin/gcom")
+local has_pptp  = fs.access("/usr/sbin/pptp")
+local has_pppd  = fs.access("/usr/sbin/pppd")
+local has_pppoe = fs.glob("/usr/lib/pppd/*/rp-pppoe.so")()
+local has_pppoa = fs.glob("/usr/lib/pppd/*/pppoatm.so")()
 
 m = Map("network", translate("interfaces"), translate("a_n_ifaces1"))
 
@@ -64,7 +66,7 @@ for i,d in ipairs(luci.sys.net.devices()) do
        end
 end
 
-local zones = luci.tools.webadmin.network_get_zones(arg[1])
+local zones = wa.network_get_zones(arg[1])
 if zones then
        if #zones == 0 then
                m:chain("firewall")
@@ -83,7 +85,7 @@ if zones then
                )
 
                function fwzone.write(self, section, value)
-                       local zone = luci.tools.webadmin.firewall_find_zone(value)
+                       local zone = wa.firewall_find_zone(value)
                        local stat
 
                        if not zone then
index 300535d..8fd5368 100644 (file)
@@ -12,14 +12,16 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.sys")
-require("luci.tools.webadmin")
+
+local sys = require "luci.sys"
+local wa  = require "luci.tools.webadmin"
+local fs  = require "nixio.fs"
 
 local netstate = luci.model.uci.cursor_state():get_all("network")
 m = Map("network", translate("interfaces"))
 
 local created
-local netstat = luci.sys.net.deviceinfo()
+local netstat = sys.net.deviceinfo()
 
 s = m:section(TypedSection, "interface", "")
 s.addremove = true
@@ -76,25 +78,22 @@ if luci.model.uci.cursor():load("firewall") then
        zone.titleref = luci.dispatcher.build_url("admin", "network", "firewall", "zones")
 
        function zone.cfgvalue(self, section)
-               local zones = luci.tools.webadmin.network_get_zones(section)
-               return zones and table.concat(zones, ", ") or "-"
+               return table.concat(wa.network_get_zones(section) or { "-" }, ", ")
        end
 end
 
 hwaddr = s:option(DummyValue, "_hwaddr")
 function hwaddr.cfgvalue(self, section)
        local ix = self.map:get(section, "ifname") or ""
-       return luci.fs.readfile("/sys/class/net/" .. ix .. "/address")
+       return fs.readfile("/sys/class/net/" .. ix .. "/address")
         or luci.util.exec("ifconfig " .. ix):match(" ([A-F0-9:]+)%s*\n")
         or "n/a"
-
 end
 
 
 ipaddr = s:option(DummyValue, "ipaddr", translate("addresses"))
 function ipaddr.cfgvalue(self, section)
-       local addr = luci.tools.webadmin.network_get_addresses(section)
-       return table.concat(addr, ", ")
+       return table.concat(wa.network_get_addresses(section), ", ")
 end
 
 txrx = s:option(DummyValue, "_txrx")
@@ -103,10 +102,10 @@ function txrx.cfgvalue(self, section)
        local ix = self.map:get(section, "ifname")
 
        local rx = netstat and netstat[ix] and netstat[ix][1]
-       rx = rx and luci.tools.webadmin.byte_format(tonumber(rx)) or "-"
+       rx = rx and wa.byte_format(tonumber(rx)) or "-"
 
        local tx = netstat and netstat[ix] and netstat[ix][9]
-       tx = tx and luci.tools.webadmin.byte_format(tonumber(tx)) or "-"
+       tx = tx and wa.byte_format(tonumber(tx)) or "-"
 
        return string.format("%s / %s", tx, rx)
 end
index 3499227..6e92492 100644 (file)
@@ -11,7 +11,10 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.tools.webadmin")
+
+local wa = require "luci.tools.webadmin"
+local fs = require "nixio.fs"
+
 arg[1] = arg[1] or ""
 
 m = Map("wireless", translate("networks"), translate("a_w_networks1"))
@@ -143,7 +146,7 @@ network = s:option(Value, "network", translate("network"), translate("a_w_networ
 network.rmempty = true
 network:value("")
 network.combobox_manual = translate("a_w_netmanual")
-luci.tools.webadmin.cbi_add_networks(network)
+wa.cbi_add_networks(network)
 
 function network.write(self, section, value)
        if not m.uci:get("network", value) then
@@ -173,7 +176,7 @@ bssid = s:option(Value, "bssid", translate("wifi_bssid"))
 -------------------- MAC80211 Interface ----------------------
 
 if hwtype == "mac80211" then
-       if luci.fs.mtime("/usr/sbin/iw") then
+       if fs.access("/usr/sbin/iw") then
                mode:value("mesh", "802.11s")
        end
 
@@ -322,8 +325,8 @@ encr:value("none", "No Encryption")
 encr:value("wep", "WEP")
 
 if hwtype == "atheros" or hwtype == "mac80211" or hwtype == "prism2" then
-       local supplicant = luci.fs.mtime("/usr/sbin/wpa_supplicant")
-       local hostapd = luci.fs.mtime("/usr/sbin/hostapd")
+       local supplicant = fs.access("/usr/sbin/wpa_supplicant")
+       local hostapd = fs.access("/usr/sbin/hostapd")
 
        if hostapd and supplicant then
                encr:value("psk", "WPA-PSK")
index 521e0a2..05442dd 100644 (file)
@@ -12,6 +12,8 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
+
+local fs = require "nixio.fs"
 local cronfile = "/etc/crontabs/root" 
 
 f = SimpleForm("crontab", translate("a_s_crontab"), translate("a_s_crontab1"))
@@ -20,13 +22,13 @@ t = f:field(TextValue, "crons")
 t.rmempty = true
 t.rows = 10
 function t.cfgvalue()
-       return luci.fs.readfile(cronfile) or ""
+       return fs.readfile(cronfile) or ""
 end
 
 function f.handle(self, state, data)
        if state == FORM_VALID then
                if data.crons then
-                       luci.fs.writefile(cronfile, data.crons:gsub("\r\n", "\n"))
+                       fs.writefile(cronfile, data.crons:gsub("\r\n", "\n"))
                end
        end
        return true
index 1e2a12f..aa4f12e 100644 (file)
@@ -13,16 +13,18 @@ $Id$
 ]]--
 require("luci.tools.webadmin")
 
-local fs = require "luci.fs"
+local fs   = require "nixio.fs"
+local util = require "nixio.util"
+
 local devices = {}
-luci.util.update(devices, fs.glob("/dev/sd*") or {})
-luci.util.update(devices, fs.glob("/dev/hd*") or {})
-luci.util.update(devices, fs.glob("/dev/scd*") or {})
-luci.util.update(devices, fs.glob("/dev/mmc*") or {})
+util.consume((fs.glob("/dev/sd*")), devices)
+util.consume((fs.glob("/dev/hd*")), devices)
+util.consume((fs.glob("/dev/scd*")), devices)
+util.consume((fs.glob("/dev/mmc*")), devices)
 
 local size = {}
 for i, dev in ipairs(devices) do
-       local s = tonumber((luci.fs.readfile("/sys/class/block/%s/size" % dev:sub(6))))
+       local s = tonumber((fs.readfile("/sys/class/block/%s/size" % dev:sub(6))))
        size[dev] = s and math.floor(s / 2048)
 end
 
index fecc294..1b540b7 100644 (file)
@@ -19,11 +19,11 @@ f = SimpleForm("ipkgconf", translate("a_s_p_ipkg"))
 t = f:field(TextValue, "lines")
 t.rows = 10
 function t.cfgvalue()
-       return luci.fs.readfile(ipkgfile) or ""
+       return nixio.fs.readfile(ipkgfile) or ""
 end
 
 function t.write(self, section, data)
-       return luci.fs.writefile(ipkgfile, data:gsub("\r\n", "\n"))
+       return nixio.fs.writefile(ipkgfile, data:gsub("\r\n", "\n"))
 end
 
 f:append(Template("admin_system/ipkg"))
index 5074a73..71bd7d0 100644 (file)
@@ -16,12 +16,11 @@ m = Map("system", translate("leds"), translate("leds_desc"))
 local sysfs_path = "/sys/class/leds/"
 local leds = {}
 
-if luci.fs.access(sysfs_path) then
-       for k, v in pairs(luci.fs.dir(sysfs_path)) do
-               if v ~= "." and v ~= ".." then
-                       table.insert(leds, v)
-               end
-       end
+local fs   = require "nixio.fs"
+local util = require "nixio.util"
+
+if fs.access(sysfs_path) then
+       leds = util.consume((fs.dir(sysfs_path)))
 end
 
 if #leds == 0 then
@@ -52,7 +51,7 @@ s:option(Flag, "default").rmempty = true
 
 trigger = s:option(ListValue, "trigger")
 
-local triggers = luci.fs.readfile(sysfs_path .. leds[1] .. "/trigger")
+local triggers = fs.readfile(sysfs_path .. leds[1] .. "/trigger")
 for t in triggers:gmatch("[%w-]+") do
        trigger:value(t, translate("system_led_trigger_" .. t:gsub("-", "")))
 end 
@@ -83,4 +82,4 @@ mode:value("link", translate("system_led_mode_link"))
 mode:value("tx", translate("system_led_mode_tx"))
 mode:value("rx", translate("system_led_mode_rx"))
 
-return m
\ No newline at end of file
+return m
index 26410c9..b7ff482 100644 (file)
@@ -20,13 +20,13 @@ t = f:field(TextValue, "keys")
 t.rmempty = true
 t.rows = 10
 function t.cfgvalue()
-       return luci.fs.readfile(keyfile) or ""
+       return nixio.fs.readfile(keyfile) or ""
 end
 
 function f.handle(self, state, data)
        if state == FORM_VALID then
                if data.keys then
-                       luci.fs.writefile(keyfile, data.keys:gsub("\r\n", "\n"))
+                       nixio.fs.writefile(keyfile, data.keys:gsub("\r\n", "\n"))
                end
        end
        return true
diff --git a/modules/admin-full/luasrc/view/admin_status/conntrack.htm b/modules/admin-full/luasrc/view/admin_status/conntrack.htm
new file mode 100644 (file)
index 0000000..d0a86b6
--- /dev/null
@@ -0,0 +1,75 @@
+<%#
+LuCI - Lua Configuration Interface
+Copyright 2008-2009 Steven Barth <steven@midlink.org>
+Copyright 2008-2009 Jo-Philipp Wich <xm@subsignal.org>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+-%>
+
+<%-
+       require "luci.sys"
+       local style = true
+-%>
+
+<%+header%>
+
+<div class="cbi-map" id="cbi-conntrack">
+       <h2><a id="content" name="content"><%:a_n_conntrack%></a></h2>
+       <div class="cbi-map-descr"><%:a_n_conntrack_desc%></div>
+
+       <fieldset class="cbi-section" id="cbi-table-table">
+               <legend>ARP</legend>
+               <div class="cbi-section-node">
+                       <table class="cbi-section-table">
+                               <tr class="cbi-section-table-titles">
+                                       <th class="cbi-section-table-cell"><%:ipaddress%></th>
+                                       <th class="cbi-section-table-cell"><%:macaddress%></th>
+                                       <th class="cbi-section-table-cell"><%:interface%></th>
+                               </tr>
+
+                               <% luci.sys.net.arptable(function(e) %>
+                               <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>">
+                                       <td class="cbi-value-field"><%=e["IP address"]%></td>
+                                       <td class="cbi-value-field"><%=e["HW address"]%></td>
+                                       <td class="cbi-value-field"><%=e["Device"]%></td>
+                               </tr>
+                               <% style = not style; end) %>
+                       </table>
+               </div>
+       </fieldset>
+       <br />
+
+       <fieldset class="cbi-section" id="cbi-table-table">
+               <legend><%:a_n_conntrack%></legend>
+               <div class="cbi-section-node">
+                       <table class="cbi-section-table">
+                               <tr class="cbi-section-table-titles">
+                                       <th class="cbi-section-table-cell"><%:network%></th>
+                                       <th class="cbi-section-table-cell"><%:protocol%></th>
+                                       <th class="cbi-section-table-cell"><%:source%></th>
+                                       <th class="cbi-section-table-cell"><%:destination%></th>
+                               </tr>
+
+                               <% style = true; luci.sys.net.conntrack(function(c) %>
+                               <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>">
+                                       <td class="cbi-value-field"><%=c.layer3:upper()%></td>
+                                       <td class="cbi-value-field"><%=c.layer4:upper()%></td>
+                                       <td class="cbi-value-field"><%=c.src%></td>
+                                       <td class="cbi-value-field"><%=c.dst%></td>
+                               </tr>
+                               <% style = not style; end) %>
+                       </table>
+               </div>
+       </fieldset>
+       <br />
+</div>
+       
+<%+footer%>
+
index 5358cae..720ce9c 100644 (file)
@@ -15,15 +15,15 @@ $Id$
 
 <%-
 
-       require "luci.tools.webadmin"
-
-       local wba = luci.tools.webadmin
-       local uci = luci.model.uci.cursor_state()
+       local sys = require "luci.sys"
+       local wba = require "luci.tools.webadmin"
+       local uci = require "luci.model.uci".cursor_state()
+       local fs  = require "nixio.fs"
 
        local bridge_ifs = { }
        local single_ifs = { }
        local wifi_ifs   = { }
-       local devinfo    = luci.sys.net.deviceinfo()
+       local devinfo    = sys.net.deviceinfo()
 
        uci:foreach("network", "interface",
                function(s)
@@ -86,8 +86,8 @@ $Id$
 
        function get_switch_driver(i)
                local n, d = i:match("([a-z]+)(%d+)%.%d+$")
-               local hw = luci.fs.readfile("/proc/switch/%s%s/driver" %{ n, d })
-                       or luci.fs.readfile("/proc/switch/%s/driver" % d )
+               local hw = fs.readfile("/proc/switch/%s%s/driver" %{ n, d })
+                       or fs.readfile("/proc/switch/%s/driver" % d )
 
                return hw and hw:match("%S+")
        end
diff --git a/modules/admin-full/luasrc/view/admin_status/routes.htm b/modules/admin-full/luasrc/view/admin_status/routes.htm
new file mode 100644 (file)
index 0000000..cd62b80
--- /dev/null
@@ -0,0 +1,89 @@
+<%#
+LuCI - Lua Configuration Interface
+Copyright 2008-2009 Steven Barth <steven@midlink.org>
+Copyright 2008-2009 Jo-Philipp Wich <xm@subsignal.org>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+-%>
+
+<%-
+       require "bit"
+       require "luci.sys"
+       require "luci.tools.webadmin"
+       require "nixio.fs"
+
+       local style = true
+-%>
+
+<%+header%>
+
+<div class="cbi-map" id="cbi-network">
+       <h2><a id="content" name="content"><%:a_n_routes%></a></h2>
+       <div class="cbi-map-descr"><%:a_n_routes1%></div>
+
+       <fieldset class="cbi-section" id="cbi-table-table">
+               <legend><%:a_n_routes_kernel4%></legend>
+
+               <div class="cbi-section-node">
+                       <table class="cbi-section-table">
+                               <tr class="cbi-section-table-titles">
+                                       <th class="cbi-section-table-cell"><%:network%></th>
+                                       <th class="cbi-section-table-cell"><%:target%></th>
+                                       <th class="cbi-section-table-cell"><%:netmask%></th>
+                                       <th class="cbi-section-table-cell"><%:gateway%></th>
+                                       <th class="cbi-section-table-cell"><%:metric%></th>
+                               </tr>
+                               <% luci.sys.net.routes(function(rt) %>
+                               <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>">
+                                       <td class="cbi-value-field"><%=luci.tools.webadmin.iface_get_network(rt.device) or rt.device%></td>
+                                       <td class="cbi-value-field"><%=rt.dest:network():string()%></td>
+                                       <td class="cbi-value-field"><%=rt.dest:mask():string()%></td>
+                                       <td class="cbi-value-field"><%=rt.gateway:string()%></td>
+                                       <td class="cbi-value-field"><%=rt.metric%></td>
+                               </tr>
+                               <% style = not style; end) %>
+                       </table>
+               </div>
+       </fieldset>
+       <br />
+
+       <% if nixio.fs.access("/proc/net/ipv6_route") then style = true %>
+       <fieldset class="cbi-section" id="cbi-table-table">
+               <legend><%:a_n_routes_kernel6%></legend>
+
+               <div class="cbi-section-node">
+                       <table class="cbi-section-table">
+                               <tr class="cbi-section-table-titles">
+                                       <th class="cbi-section-table-cell"><%:network%></th>
+                                       <th class="cbi-section-table-cell"><%:target%></th>
+                                       <th class="cbi-section-table-cell"><%:gateway6%></th>
+                                       <th class="cbi-section-table-cell"><%:metric%></th>
+                               </tr>
+                               <% luci.sys.net.routes6(function(rt) %>
+                               <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>">
+                                       <td class="cbi-value-field"><%=luci.tools.webadmin.iface_get_network(rt.device) or rt.device%></td>
+                                       <td class="cbi-value-field"><%=rt.dest:string()%></td>
+                                       <td class="cbi-value-field"><%=rt.source:string()%></td>
+                                       <td class="cbi-value-field"><%- 
+                                               local metr   = rt.metric
+                                               local lower  = bit.band(metr, 0xffff)
+                                               local higher = bit.rshift(bit.band(metr, 0xffff0000), 16)
+                                               write(string.format("%04X%04X", higher, lower))
+                                       -%></td>
+                               </tr>
+                               <% style = not style; end) %>
+                       </table>
+               </div>
+       </fieldset>
+       <br />
+       <% end %>
+</div>
+
+<%+footer%>
index 589e83a..075f51e 100644 (file)
@@ -98,7 +98,7 @@ function action_upgrade()
        
        local function storage_size()
                local size = 0
-               if luci.fs.access("/proc/mtd") then
+               if nixio.fs.access("/proc/mtd") then
                        for l in io.lines("/proc/mtd") do
                                local d, s, e, n = l:match('^([^%s]+)%s+([^%s]+)%s+([^%s]+)%s+"([^%s]+)"')
                                if n == "linux" then
@@ -106,7 +106,7 @@ function action_upgrade()
                                        break
                                end
                        end
-               elseif luci.fs.access("/proc/partitions") then
+               elseif nixio.fs.access("/proc/partitions") then
                        for l in io.lines("/proc/partitions") do
                                local x, y, b, n = l:match('^%s*(%d+)%s+(%d+)%s+([^%s]+)%s+([^%s]+)')
                                if b and n and not n:match('[0-9]') then
@@ -123,7 +123,7 @@ function action_upgrade()
        local file
        luci.http.setfilehandler(
                function(meta, chunk, eof)
-                       if not luci.fs.access(tmpfile) and not file and chunk and #chunk > 0 then
+                       if not nixio.fs.access(tmpfile) and not file and chunk and #chunk > 0 then
                                file = io.open(tmpfile, "w")
                        end
                        if file and chunk then
@@ -139,9 +139,9 @@ function action_upgrade()
        -- Determine state
        local keep_avail   = true
        local step         = tonumber(luci.http.formvalue("step") or 1)
-       local has_image    = luci.fs.access(tmpfile)
+       local has_image    = nixio.fs.access(tmpfile)
        local has_support  = image_supported()
-       local has_platform = luci.fs.access("/lib/upgrade/platform.sh")
+       local has_platform = nixio.fs.access("/lib/upgrade/platform.sh")
        local has_upload   = luci.http.formvalue("image")
        
        -- This does the actual flashing which is invoked inside an iframe
@@ -182,7 +182,7 @@ function action_upgrade()
                -- If there is an image but user has requested step 1
                -- or type is not supported, then remove it.
                if has_image then
-                       luci.fs.unlink(tmpfile)
+                       nixio.fs.unlink(tmpfile)
                end
                        
                luci.template.render("admin_system/upgrade", {
@@ -197,7 +197,7 @@ function action_upgrade()
                luci.template.render("admin_system/upgrade", {
                        step=2,
                        checksum=image_checksum(),
-                       filesize=luci.fs.stat(tmpfile).size,
+                       filesize=nixio.fs.stat(tmpfile).size,
                        flashsize=storage_size(),
                        keepconfig=(keep_avail and luci.http.formvalue("keepcfg") == "1")
                } )
@@ -217,7 +217,7 @@ function _keep_pattern()
        if files then
                kpattern = ""
                for k, v in pairs(files) do
-                       if k:sub(1,1) ~= "." and luci.fs.glob(v) then
+                       if k:sub(1,1) ~= "." and nixio.fs.glob(v)() then
                                kpattern = kpattern .. " " ..  v
                        end
                end
index 2aadded..5817a93 100644 (file)
@@ -12,9 +12,11 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.model.uci")
-require("luci.sys")
-require("luci.tools.webadmin")
+
+local uci = require "luci.model.uci".cursor()
+local sys = require "luci.sys"
+local wa  = require "luci.tools.webadmin"
+local fs  = require "nixio.fs"
 
 m = Map("dhcp", "DHCP")
 
@@ -61,12 +63,12 @@ time.rmempty = true
 m2 = Map("luci_ethers", translate("dhcp_leases"))
 
 local leasefn, leasefp, leases
-luci.model.uci.cursor():foreach("dhcp", "dnsmasq",
+uci:foreach("dhcp", "dnsmasq",
  function(section)
        leasefn = section.leasefile
  end
 ) 
-local leasefp = leasefn and luci.fs.access(leasefn) and io.lines(leasefn)
+local leasefp = leasefn and fs.access(leasefn) and io.lines(leasefn)
 if leasefp then
        leases = {}
        for lease in leasefp do
@@ -83,9 +85,7 @@ if leases then
        ltime = v:option(DummyValue, 1, translate("dhcp_timeremain"))
        function ltime.cfgvalue(self, ...)
                local value = DummyValue.cfgvalue(self, ...)
-               return luci.tools.webadmin.date_format(
-                os.difftime(tonumber(value), os.time())
-               )
+               return wa.date_format(os.difftime(tonumber(value), os.time()))
        end
 end
 
@@ -96,10 +96,12 @@ s.template = "cbi/tblsection"
 
 mac = s:option(Value, "macaddr", translate("macaddress"))
 ip = s:option(Value, "ipaddr", translate("ipaddress"))
-for i, dataset in ipairs(luci.sys.net.arptable()) do
-       ip:value(dataset["IP address"])
-       mac:value(dataset["HW address"],
-        dataset["HW address"] .. " (" .. dataset["IP address"] .. ")")
-end
-
-return m, m2
\ No newline at end of file
+sys.net.arptable(function(entry)
+       ip:value(entry["IP address"])
+       mac:value(
+               entry["HW address"],
+               entry["HW address"] .. " (" .. entry["IP address"] .. ")"
+       )
+end)
+
+return m, m2
index 0a57b30..d358c8a 100644 (file)
@@ -12,13 +12,16 @@ You may obtain a copy of the License at
 
 $Id$
 ]]--
-require("luci.config")
+
+require "luci.config"
+local fs = require "nixio.fs"
+
 m = Map("luci", translate("webui"), translate("a_i_luci1"))
 
 -- force reload of global luci config namespace to reflect the changes
 function m.commit_handler(self)
        package.loaded["luci.config"] = nil
-       require("luci.config")
+       require "luci.config"
 end
 
 
@@ -31,8 +34,8 @@ local i18ndir = luci.i18n.i18ndir .. "default."
 for k, v in luci.util.kspairs(luci.config.languages) do
        local file = i18ndir .. k:gsub("_", "-")
        if k:sub(1, 1) ~= "." and (
-               luci.fs.access(file .. ".lua") or
-               luci.fs.access(file .. ".lua.gz")
+               fs.access(file .. ".lua") or
+               fs.access(file .. ".lua.gz")
        ) then
                l:value(k, v)
        end
index 508bac1..14414e9 100644 (file)
@@ -13,16 +13,16 @@ You may obtain a copy of the License at
 $Id$
 ]]--
 
-require("luci.tools.webadmin")
-require("luci.sys")
-require("luci.fs")
+local wa  = require "luci.tools.webadmin"
+local sys = require "luci.sys"
+local fs  = require "nixio.fs"
 
-local has_pptp  = luci.fs.mtime("/usr/sbin/pptp")
-local has_pppoe = luci.fs.glob("/usr/lib/pppd/*/rp-pppoe.so")
+local has_pptp  = fs.access("/usr/sbin/pptp")
+local has_pppoe = fs.glob("/usr/lib/pppd/*/rp-pppoe.so")()
 
 local network = luci.model.uci.cursor_state():get_all("network")
 
-local netstat = luci.sys.net.deviceinfo()
+local netstat = sys.net.deviceinfo()
 local ifaces = {}
 
 for k, v in pairs(network) do
@@ -41,7 +41,7 @@ hwaddr = s:option(DummyValue, "_hwaddr",
  translate("network_interface_hwaddr"), translate("network_interface_hwaddr_desc"))
 function hwaddr.cfgvalue(self, section)
        local ix = self.map:get(section, "ifname") or ""
-       return luci.fs.readfile("/sys/class/net/" .. ix .. "/address")
+       return fs.readfile("/sys/class/net/" .. ix .. "/address")
                or luci.util.exec("ifconfig " .. ix):match(" ([A-F0-9:]+)%s*\n")
                or "n/a"
 end
@@ -59,10 +59,10 @@ function txrx.cfgvalue(self, section)
        local ix = self.map:get(section, "ifname")
 
        local rx = netstat and netstat[ix] and netstat[ix][1]
-       rx = rx and luci.tools.webadmin.byte_format(tonumber(rx)) or "-"
+       rx = rx and wa.byte_format(tonumber(rx)) or "-"
 
        local tx = netstat and netstat[ix] and netstat[ix][9]
-       tx = tx and luci.tools.webadmin.byte_format(tonumber(tx)) or "-"
+       tx = tx and wa.byte_format(tonumber(tx)) or "-"
 
        return string.format("%s / %s", tx, rx)
 end
@@ -150,7 +150,7 @@ pwd:depends("proto", "pptp")
 
 -- Allow user to set MSS correction here if the UCI firewall is installed
 -- This cures some cancer for providers with pre-war routers
-if luci.fs.access("/etc/config/firewall") then
+if fs.access("/etc/config/firewall") then
        mssfix = s:option(Flag, "_mssfix",
                translate("m_n_mssfix"), translate("m_n_mssfix_desc"))
        mssfix.rmempty = false
index ee423f3..98f6697 100644 (file)
@@ -15,7 +15,10 @@ $Id$
 
 -- Data init --
 
-local uci = luci.model.uci.cursor()
+local fs  = require "nixio.fs"
+local sys = require "luci.sys"
+local uci = require "luci.model.uci".cursor()
+
 if not uci:get("network", "wan") then
        uci:section("network", "interface", "wan", {proto="none", ifname=" "})
        uci:save("network")
@@ -24,7 +27,7 @@ end
 
 local wlcursor = luci.model.uci.cursor_state()
 local wireless = wlcursor:get_all("wireless")
-local wifidata = luci.sys.wifi.getiwconfig()
+local wifidata = sys.wifi.getiwconfig()
 local wifidevs = {}
 local ifaces = {}
 
@@ -99,7 +102,7 @@ function scan.write(self, section)
        m.autoapply = false
        t2.render = t2._render
        local ifname = self.map:get(section, "ifname")
-       luci.util.update(t2.data, luci.sys.wifi.iwscan(ifname))
+       luci.util.update(t2.data, sys.wifi.iwscan(ifname))
 end
 
 t2._render = t2.render
@@ -218,8 +221,8 @@ encr:value("none", "No Encryption")
 encr:value("wep", "WEP")
 
 if hwtype == "atheros" or hwtype == "mac80211" then
-       local supplicant = luci.fs.mtime("/usr/sbin/wpa_supplicant")
-       local hostapd = luci.fs.mtime("/usr/sbin/hostapd")
+       local supplicant = fs.access("/usr/sbin/wpa_supplicant")
+       local hostapd    = fs.access("/usr/sbin/hostapd")
 
        if hostapd and supplicant then
                encr:value("psk", "WPA-PSK")
index 9769ea0..5efd50f 100644 (file)
@@ -56,7 +56,7 @@ function index()
 
        assign({"freifunk", "olsr"}, {"admin", "status", "olsr"}, "OLSR", 30)
 
-       if luci.fs.access("/etc/config/luci_statistics") then
+       if nixio.fs.access("/etc/config/luci_statistics") then
                assign({"freifunk", "graph"}, {"admin", "statistics", "graph"}, i18n("stat_statistics", "Statistiken"), 40)
        end
 
@@ -83,7 +83,7 @@ local function fetch_olsrd()
        local rawdata = sys.httpget("http://127.0.0.1:2006/")
 
        if #rawdata == 0 then
-               if luci.fs.access("/proc/net/ipv6_route", "r") then
+               if nixio.fs.access("/proc/net/ipv6_route", "r") then
                        rawdata = sys.httpget("http://[::1]:2006/")
                        if #rawdata == 0 then
                                return nil
index e0aeb3b..510a025 100644 (file)
@@ -117,7 +117,7 @@ end
 function rpc_fs()
        local util    = require "luci.util"
        local io      = require "io"
-       local fs2     = util.clone(require "luci.fs")
+       local fs2     = util.clone(require "nixio.fs")
        local jsonrpc = require "luci.jsonrpc"
        local http    = require "luci.http"
        local ltn12   = require "luci.ltn12"
index 4a1cc38..c719436 100644 (file)
@@ -3,8 +3,8 @@ msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2009-06-10 03:41+0200\n"
-"PO-Revision-Date: 2009-07-09 00:59+0200\n"
-"Last-Translator: Stefan Pirwitz <i18n@freifunk-bno.de>\n"
+"PO-Revision-Date: 2009-07-18 07:05+0200\n"
+"Last-Translator: Guillermo Javier Nardoni <guillermo@geryon.com.ar>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
@@ -19,7 +19,7 @@ msgstr "Los siguientes cambios se han aplicado"
 #. The following changes have been reverted
 #: i18n/english/luasrc/i18n/admin-core.en.lua:2
 msgid "uci_reverted"
-msgstr ""
+msgstr "Los siguientes cambios han sido revertidos"
 
 #. User Interface
 #: i18n/english/luasrc/i18n/admin-core.en.lua:3
@@ -30,2051 +30,2265 @@ msgstr "Interfaz de usuario"
 #: i18n/english/luasrc/i18n/admin-core.en.lua:4
 msgid "c_lucidesc"
 msgstr ""
+"<abbr title=\"Lua Configuration Interface\">LuCI</abbr> es una colección libre "
+"de software Lua incluyendo un <abbr title=\"Model-View-"
+"Controller\">MVC</abbr>-Webframework y una interfaz web para dispositivos "
+"embebidos.<abbr title=\"Lua Configuration Interface\">LuCI</abbr> se encuentra "
+"licenciado bajo la licencia Apache (Apache-License)."
 
 #. Project Homepage
 #: i18n/english/luasrc/i18n/admin-core.en.lua:5
 msgid "c_projecthome"
-msgstr ""
+msgstr "Página del proyecto "
 
 #. Lead Development
 #: i18n/english/luasrc/i18n/admin-core.en.lua:6
 msgid "c_leaddev"
-msgstr ""
+msgstr "Lider del desarrollo"
 
 #. Contributing Developers
 #: i18n/english/luasrc/i18n/admin-core.en.lua:7
 msgid "c_contributors"
-msgstr ""
+msgstr "Desarrolladores que contribuyen"
 
+# Thanks to --> Gracias a -> Agradecemientos --> Agregadecemos a
 #. Thanks To
 #: i18n/english/luasrc/i18n/admin-core.en.lua:8
 msgid "c_thanksto"
-msgstr ""
+msgstr "Agregadecemos a"
 
 #. Hello!
 #: i18n/english/luasrc/i18n/admin-core.en.lua:9
 msgid "a_i_i_hello"
-msgstr ""
+msgstr "Hola !"
 
 #. This is the administration area of <abbr title=\"Lua Configuration Interface\">LuCI</abbr>.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:10
 msgid "a_i_i_admin1"
 msgstr ""
+"Éste es el área de administración de <abbr title=\"Lua Configuration "
+"Interface\">LuCI</abbr>."
 
 #. <abbr title=\"Lua Configuration Interface\">LuCI</abbr> is a free, flexible, and user friendly graphical interface for configuring OpenWrt Kamikaze.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:11
 msgid "a_i_i_admin2"
 msgstr ""
+"<abbr title=\"Lua Configuration Interface\">LuCI</abbr> interfaz gráfica "
+"libre, flexible y amigable para configurar la distro OpenWrt (Kamikaze) y "
+"derivados."
 
 #. On the following pages you can adjust all important settings of your router.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:12
 msgid "a_i_i_admin3"
 msgstr ""
+"En las páginas siguientes puede realizar todos los ajustes importantes de su "
+"router."
 
 #. Notice: In <abbr title=\"Lua Configuration Interface\">LuCI</abbr> changes have to be confirmed by clicking Changes - Save &amp; Apply before being applied.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:13
 msgid "a_i_i_admin4"
 msgstr ""
+"Aviso: En <abbr title=\"Lua Configuration Interface\">LuCI</abbr> los cambios "
+"deben ser confirmados haciendo clic en \"Cambios\" y luego en \"Guardar "
+"&amp;amp; aplicar\" para que los cambios sean efectivos."
 
 #. As we always want to improve this interface we are looking forward to your feedback and suggestions.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:14
 msgid "a_i_i_admin5"
 msgstr ""
+"Como siempre queremos mejorar esta interfaz estamos esperando con interés "
+"sus comentarios y sugerencias. "
 
 #. And now have fun with your router!
 #: i18n/english/luasrc/i18n/admin-core.en.lua:15
 msgid "a_i_i_admin6"
-msgstr ""
+msgstr "Y ahora disfrute su router!"
 
 #. The <abbr title=\"Lua Configuration Interface\">LuCI</abbr> Team
 #: i18n/english/luasrc/i18n/admin-core.en.lua:16
 msgid "a_i_i_team"
-msgstr ""
+msgstr "El grupo de <abbr title=\"Lua Configuration Interface\">LuCI</abbr>"
 
 #. Here you can customize the settings and the functionality of <abbr title=\"Lua Configuration Interface\">LuCI</abbr>.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:17
 msgid "a_i_luci1"
 msgstr ""
+"Aquí puede personalizar las configuraciones y funcionalidad de <abbr "
+"title=\"Lua Configuration Interface\">LuCI</abbr>."
 
 #. Post-commit actions
 #: i18n/english/luasrc/i18n/admin-core.en.lua:18
 msgid "a_i_ucicommit"
-msgstr ""
+msgstr "Acciones luego de \"Post-commit\""
 
 #. These commands will be executed automatically when a given <abbr title=\"Unified Configuration Interface\">UCI</abbr> configuration is committed allowing changes to be applied instantly.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:19
 msgid "a_i_ucicommit1"
 msgstr ""
+"Estos comandos se ejecutan automáticamente cuando una determinada "
+"configuración de la <abbr title=\"Unified configuración Interface\"> UCI </ "
+"abbr> es aplicada permitiendo que los cambios sean efectivos inmediatamente."
 
 #. Files to be kept when flashing a new firmware
 #: i18n/english/luasrc/i18n/admin-core.en.lua:20
 msgid "a_i_keepflash"
-msgstr ""
+msgstr "Archivos que serán protegidos cuando un nuevo firmware es instalado"
 
 #. When flashing a new firmware with <abbr title=\"Lua Configuration Interface\">LuCI</abbr> these files will be added to the new firmware installation.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:21
 msgid "a_i_keepflash1"
 msgstr ""
+"Cuando un nuevo firmware ha sido instalado con <abbr title=\"Lua "
+"Configuration Interface\">LuCI</abbr> estos archivos serán agregados a la "
+"nueva instalación automáticamente."
 
 #. Here you can find information about the current system status like <abbr title=\"Central Processing Unit\">CPU</abbr> clock frequency, memory usage or network interface data.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:22
 msgid "a_st_i_status1"
 msgstr ""
+"Aquí pude encontrar información acerca del estado actual del sistema como la "
+"frecuencia del reloj de la <abbr title=\"Central Processing Unit\">CPU</abbr> "
+"clock frequency, uso de la memoria o datos de la interfaz de red."
 
 #. Also kernel or service logfiles can be viewed here to get an overview over their current state.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:23
 msgid "a_st_i_status2"
 msgstr ""
+"También los archivos de registro del núcleo (kernel) o servicio se pueden "
+"ver aquí para obtener una visión general sobre su estado actual."
 
 #. <abbr title=\"Wireless Local Area Network\">WLAN</abbr>-Scan
 #: i18n/english/luasrc/i18n/admin-core.en.lua:24
 msgid "iwscan"
-msgstr ""
+msgstr "<abbr title=\"Wireless Local Area Network\">WLAN</abbr>-Scan"
 
 #. Wifi networks in your local environment
 #: i18n/english/luasrc/i18n/admin-core.en.lua:25
 msgid "iwscan1"
-msgstr ""
+msgstr "Redes inalámbricas en un entorno local"
 
 #. <abbr title=\"Encrypted\">Encr.</abbr>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:26
 msgid "iwscan_encr"
-msgstr ""
+msgstr "<abbr title=\"Encrypted\">Encr.</abbr>"
 
 #. Link
 #: i18n/english/luasrc/i18n/admin-core.en.lua:27
 msgid "iwscan_link"
-msgstr ""
+msgstr "Enlace"
 
 #. Signal
 #: i18n/english/luasrc/i18n/admin-core.en.lua:28
 msgid "iwscan_signal"
-msgstr ""
+msgstr "Señal"
 
 #. Noise
 #: i18n/english/luasrc/i18n/admin-core.en.lua:29
 msgid "iwscan_noise"
-msgstr ""
+msgstr "Ruido"
 
 #. Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:30
 msgid "routes"
-msgstr ""
+msgstr "Rutas"
 
 #. Netmask
 #: i18n/english/luasrc/i18n/admin-core.en.lua:31
 msgid "routes_netmask"
-msgstr ""
+msgstr "Mascara de red"
 
 #. Gateway
 #: i18n/english/luasrc/i18n/admin-core.en.lua:32
 msgid "routes_gateway"
-msgstr ""
+msgstr "Puerta de enlace"
 
 #. Metric
 #: i18n/english/luasrc/i18n/admin-core.en.lua:33
 msgid "routes_metric"
-msgstr ""
+msgstr "Métrica"
 
 #. Here you can configure the basic aspects of your device like its hostname or the timezone.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:34
 msgid "a_s_desc"
 msgstr ""
+"Aquí puede configurar los aspectos básico de su dispositivo como su zona "
+"horaria o hombre de host."
 
 #. Software
 #: i18n/english/luasrc/i18n/admin-core.en.lua:35
 msgid "a_s_packages"
-msgstr ""
+msgstr "Software"
 
 #. Admin Password
 #: i18n/english/luasrc/i18n/admin-core.en.lua:36
 msgid "a_s_changepw"
-msgstr ""
+msgstr "Contraseña de Admin"
 
 #. OPKG-Configuration
 #: i18n/english/luasrc/i18n/admin-core.en.lua:37
 msgid "a_s_p_ipkg"
-msgstr ""
+msgstr "Configuración de OPKG"
 
 #. <abbr title=\"Secure Shell\">SSH</abbr>-Keys
 #: i18n/english/luasrc/i18n/admin-core.en.lua:38
 msgid "a_s_sshkeys"
-msgstr ""
+msgstr "<abbr title=\"Secure Shell\">SSH</abbr>-Keys"
 
 #. Mount Points
 #: i18n/english/luasrc/i18n/admin-core.en.lua:39
 msgid "a_s_fstab"
-msgstr ""
+msgstr "Puntos de montaje"
 
 #. Change settings related to the system itself, its identification, installed hard- and software, authentication or mount points.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:40
 msgid "a_s_i_system1"
 msgstr ""
+"Cambiar los ajustes relacionados con el sistema en sí, su identificación, "
+"hardware y software instalado, la autenticación o los puntos de montaje."
 
 #. These settings define the base of your system.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:41
 msgid "a_s_i_system2"
-msgstr ""
+msgstr "Estos valores definen la base de su sistema."
 
 #. Pay attention as any misconfiguration here may prevent your device from booting or may lock yourself out of it.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:42
 msgid "a_s_i_system3"
 msgstr ""
+"Preste atención ya que cualquier mala configuración aqui'puede evitar que su "
+"dispositivo se inicie o quede bloqueado permanentemente para su uso."
 
 #. Interfaces
 #: i18n/english/luasrc/i18n/admin-core.en.lua:43
 msgid "a_s_if"
-msgstr ""
+msgstr "Interfaces"
 
 #. Bridge
 #: i18n/english/luasrc/i18n/admin-core.en.lua:44
 msgid "a_s_if_bridge"
-msgstr ""
+msgstr "Puente"
 
 #. ID
 #: i18n/english/luasrc/i18n/admin-core.en.lua:45
 msgid "a_s_if_bridge_id"
-msgstr ""
+msgstr "ID"
 
 #. Bridge Port
 #: i18n/english/luasrc/i18n/admin-core.en.lua:46
 msgid "a_s_if_bridge_port"
-msgstr ""
+msgstr "Puerto del puente"
 
 #. STP
 #: i18n/english/luasrc/i18n/admin-core.en.lua:47
 msgid "a_s_if_bridge_stp"
-msgstr ""
+msgstr "STP"
 
 #. Device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:48
 msgid "a_s_if_device"
-msgstr ""
+msgstr "Dispositivo"
 
 #. Ethernet Bridge
 #: i18n/english/luasrc/i18n/admin-core.en.lua:49
 msgid "a_s_if_ethbridge"
-msgstr ""
+msgstr "Puente ethernet"
 
 #. Ethernet Adapter
 #: i18n/english/luasrc/i18n/admin-core.en.lua:50
 msgid "a_s_if_ethdev"
-msgstr ""
+msgstr "Adaptador ethernet"
 
 #. Ethernet Switch
 #: i18n/english/luasrc/i18n/admin-core.en.lua:51
 msgid "a_s_if_ethswitch"
-msgstr ""
+msgstr "Switch ethernet"
 
 #. Interface
 #: i18n/english/luasrc/i18n/admin-core.en.lua:52
 msgid "a_s_if_interface"
-msgstr ""
+msgstr "Interfaz"
 
 #. IP Configuration
 #: i18n/english/luasrc/i18n/admin-core.en.lua:53
 msgid "a_s_if_ipconfig"
-msgstr ""
+msgstr "Configuración IP"
 
 #. Alias
 #: i18n/english/luasrc/i18n/admin-core.en.lua:54
 msgid "a_s_if_ipconfig_alias"
-msgstr ""
+msgstr "Alias"
 
 #. DHCP assigned
 #: i18n/english/luasrc/i18n/admin-core.en.lua:55
 msgid "a_s_if_ipconfig_dhcp"
-msgstr ""
+msgstr "DHCP asignado"
 
 #. IPv6
 #: i18n/english/luasrc/i18n/admin-core.en.lua:56
 msgid "a_s_if_ipconfig_ipv6"
-msgstr ""
+msgstr "IPv6"
 
 #. Not configured
 #: i18n/english/luasrc/i18n/admin-core.en.lua:57
 msgid "a_s_if_ipconfig_none"
-msgstr ""
+msgstr "No configurado"
 
 #. Primary
 #: i18n/english/luasrc/i18n/admin-core.en.lua:58
 msgid "a_s_if_ipconfig_primary"
-msgstr ""
+msgstr "Primario"
 
 #. Channel
 #: i18n/english/luasrc/i18n/admin-core.en.lua:59
 msgid "a_s_if_iwchannel"
-msgstr ""
+msgstr "Canal"
 
 #. Mode
 #: i18n/english/luasrc/i18n/admin-core.en.lua:60
 msgid "a_s_if_iwmode"
-msgstr ""
+msgstr "Modo"
 
 #. Ad-Hoc
 #: i18n/english/luasrc/i18n/admin-core.en.lua:61
 msgid "a_s_if_iwmode_adhoc"
-msgstr ""
+msgstr "Ad-Hoc"
 
 #. Pseudo Ad-Hoc
 #: i18n/english/luasrc/i18n/admin-core.en.lua:62
 msgid "a_s_if_iwmode_ahdemo"
-msgstr ""
+msgstr "Pseudo Ad-Hoc"
 
 #. Master
 #: i18n/english/luasrc/i18n/admin-core.en.lua:63
 msgid "a_s_if_iwmode_ap"
-msgstr ""
+msgstr "Master"
 
 #. Master + WDS
 #: i18n/english/luasrc/i18n/admin-core.en.lua:64
 msgid "a_s_if_iwmode_apwds"
-msgstr ""
+msgstr "Master + WDS"
 
 #. Client
 #: i18n/english/luasrc/i18n/admin-core.en.lua:65
 msgid "a_s_if_iwmode_sta"
-msgstr ""
+msgstr "Cliente"
 
 #. Client + WDS
 #: i18n/english/luasrc/i18n/admin-core.en.lua:66
 msgid "a_s_if_iwmode_stawds"
-msgstr ""
+msgstr "Cliente + WDS"
 
 #. WDS
 #: i18n/english/luasrc/i18n/admin-core.en.lua:67
 msgid "a_s_if_iwmode_wds"
-msgstr ""
+msgstr "WDS"
 
 #. SSID
 #: i18n/english/luasrc/i18n/admin-core.en.lua:68
 msgid "a_s_if_iwssid"
-msgstr ""
+msgstr "SSID"
 
 #. MAC
 #: i18n/english/luasrc/i18n/admin-core.en.lua:69
 msgid "a_s_if_mac"
-msgstr ""
+msgstr "MAC"
 
 #. Pkts.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:70
 msgid "a_s_if_pkts"
-msgstr ""
+msgstr "Paquetes."
 
 #. Interface Status
 #: i18n/english/luasrc/i18n/admin-core.en.lua:71
 msgid "a_s_if_status"
-msgstr ""
+msgstr "Interfaz de Estado "
 
 #. Transfer
 #: i18n/english/luasrc/i18n/admin-core.en.lua:72
 msgid "a_s_if_transfer"
-msgstr ""
+msgstr "Transferencia"
 
 #. RX
 #: i18n/english/luasrc/i18n/admin-core.en.lua:73
 msgid "a_s_if_transfer_rx"
-msgstr ""
+msgstr "RX"
 
 #. TX
 #: i18n/english/luasrc/i18n/admin-core.en.lua:74
 msgid "a_s_if_transfer_tx"
-msgstr ""
+msgstr "TX"
 
 #. Type
 #: i18n/english/luasrc/i18n/admin-core.en.lua:75
 msgid "a_s_if_type"
-msgstr ""
+msgstr "Tipo"
 
 #. VLAN
 #: i18n/english/luasrc/i18n/admin-core.en.lua:76
 msgid "a_s_if_vlan"
-msgstr ""
+msgstr "VLAN"
 
 #. Ports
 #: i18n/english/luasrc/i18n/admin-core.en.lua:77
 msgid "a_s_if_vlanports"
-msgstr ""
+msgstr "Puertos"
 
 #. Wireless Adapter
 #: i18n/english/luasrc/i18n/admin-core.en.lua:78
 msgid "a_s_if_wifidev"
-msgstr ""
+msgstr "Adaptador inalámbrico"
 
 #. Firewall
 #: i18n/english/luasrc/i18n/admin-core.en.lua:79
 msgid "a_s_ipt"
-msgstr ""
+msgstr "Corta fuego"
 
 #. Actions
 #: i18n/english/luasrc/i18n/admin-core.en.lua:80
 msgid "a_s_ipt_actions"
-msgstr ""
+msgstr "Acciones"
 
 #. Traffic
 #: i18n/english/luasrc/i18n/admin-core.en.lua:81
 msgid "a_s_ipt_bytes"
-msgstr ""
+msgstr "Tráfico"
 
 #. Chain
 #: i18n/english/luasrc/i18n/admin-core.en.lua:82
 msgid "a_s_ipt_chain"
-msgstr ""
+msgstr "Cadena"
 
 #. Destination
 #: i18n/english/luasrc/i18n/admin-core.en.lua:83
 msgid "a_s_ipt_destination"
-msgstr ""
+msgstr "Destino"
 
 #. Flags
 #: i18n/english/luasrc/i18n/admin-core.en.lua:84
 msgid "a_s_ipt_flags"
-msgstr ""
+msgstr "Flags"
 
 #. In
 #: i18n/english/luasrc/i18n/admin-core.en.lua:85
 msgid "a_s_ipt_inputif"
-msgstr ""
+msgstr "Entrada"
 
 #. No chains in this table
 #: i18n/english/luasrc/i18n/admin-core.en.lua:86
 msgid "a_s_ipt_nochains"
-msgstr ""
+msgstr "No hay cadenas in esta tabla"
 
 #. No Rules in this chain
 #: i18n/english/luasrc/i18n/admin-core.en.lua:87
 msgid "a_s_ipt_norules"
-msgstr ""
+msgstr "No hay reglas en esta cadena"
 
 #. Options
 #: i18n/english/luasrc/i18n/admin-core.en.lua:88
 msgid "a_s_ipt_options"
-msgstr ""
+msgstr "Opciones"
 
 #. Out
 #: i18n/english/luasrc/i18n/admin-core.en.lua:89
 msgid "a_s_ipt_outputif"
-msgstr ""
+msgstr "Salida"
 
 #. Packets
 #: i18n/english/luasrc/i18n/admin-core.en.lua:90
 msgid "a_s_ipt_packets"
-msgstr ""
+msgstr "Paquetes"
 
 #. Pkts.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:91
 msgid "a_s_ipt_pkts"
-msgstr ""
+msgstr "Paquetes."
 
 #. Policy
 #: i18n/english/luasrc/i18n/admin-core.en.lua:92
 msgid "a_s_ipt_policy"
-msgstr ""
+msgstr "Política"
 
 #. Prot.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:93
 msgid "a_s_ipt_prot"
-msgstr ""
+msgstr "Protocolo"
 
 #. References
 #: i18n/english/luasrc/i18n/admin-core.en.lua:94
 msgid "a_s_ipt_references"
-msgstr ""
+msgstr "Referencias"
 
 #. Reset Counters
 #: i18n/english/luasrc/i18n/admin-core.en.lua:95
 msgid "a_s_ipt_reset"
-msgstr ""
+msgstr "Reiniciar contadores"
 
 #. Restart Firewall
 #: i18n/english/luasrc/i18n/admin-core.en.lua:96
 msgid "a_s_ipt_restart"
-msgstr ""
+msgstr "Reiniciar corta fuego"
 
 #. #
 #: i18n/english/luasrc/i18n/admin-core.en.lua:97
 msgid "a_s_ipt_rulenum"
-msgstr ""
+msgstr "#"
 
 #. Source
 #: i18n/english/luasrc/i18n/admin-core.en.lua:98
 msgid "a_s_ipt_source"
-msgstr ""
+msgstr "Origen"
 
 #. Firewall Status
 #: i18n/english/luasrc/i18n/admin-core.en.lua:99
 msgid "a_s_ipt_status"
-msgstr ""
+msgstr "Estado del corta fuego"
 
 #. Table
 #: i18n/english/luasrc/i18n/admin-core.en.lua:100
 msgid "a_s_ipt_table"
-msgstr ""
+msgstr "Tabla"
 
 #. Target
 #: i18n/english/luasrc/i18n/admin-core.en.lua:101
 msgid "a_s_ipt_target"
-msgstr ""
+msgstr "Objetivo"
 
 #. Perform Actions
 #: i18n/english/luasrc/i18n/admin-core.en.lua:102
 msgid "a_s_packages_do"
-msgstr ""
+msgstr "Ejectuar acciones"
 
 #. Install
 #: i18n/english/luasrc/i18n/admin-core.en.lua:103
 msgid "a_s_packages_install"
-msgstr ""
+msgstr "Instalar"
 
 #. Download and install package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:104
 msgid "a_s_packages_installurl"
-msgstr ""
+msgstr "Descargar e instalar paquete"
 
 #. Edit package lists and installation targets
 #: i18n/english/luasrc/i18n/admin-core.en.lua:105
 msgid "a_s_packages_ipkg"
-msgstr ""
+msgstr "Editar listas de paquetes de instalación y los objetivos "
 
 #. Package name
 #: i18n/english/luasrc/i18n/admin-core.en.lua:106
 msgid "a_s_packages_name"
-msgstr ""
+msgstr "Nombre del paquete"
 
 #. Remove
 #: i18n/english/luasrc/i18n/admin-core.en.lua:107
 msgid "a_s_packages_remove"
-msgstr ""
+msgstr "Desinstalar"
 
 #. Find package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:108
 msgid "a_s_packages_search"
-msgstr ""
+msgstr "Buscar paquete"
 
 #. Package lists updated
 #: i18n/english/luasrc/i18n/admin-core.en.lua:109
 msgid "a_s_packages_update"
-msgstr ""
+msgstr "Listas de paquetes actualizada"
 
 #. Update package lists
 #: i18n/english/luasrc/i18n/admin-core.en.lua:110
 msgid "a_s_packages_updatelist"
-msgstr ""
+msgstr "Acutlizar listas de paquetes"
 
 #. Upgrade installed packages
 #: i18n/english/luasrc/i18n/admin-core.en.lua:111
 msgid "a_s_packages_upgrade"
-msgstr ""
+msgstr "Actualizar los paquetes instalados"
 
 #. Could not set default destination
 #: i18n/english/luasrc/i18n/admin-core.en.lua:112
 msgid "a_s_packages_code1"
-msgstr ""
+msgstr "No es posible establecer el destino por defecto"
 
 #. Error parsing config file
 #: i18n/english/luasrc/i18n/admin-core.en.lua:113
 msgid "a_s_packages_code2"
-msgstr ""
+msgstr "Error al analizar el archivo de configuración"
 
 #. Could not create temporary directory (ran out of space?)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:114
 msgid "a_s_packages_code3"
-msgstr ""
+msgstr "No es posible crear el directorio temporal (se quedó sin espacio?) "
 
 #. Could not get adminstrative lock (ran out of space?)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:115
 msgid "a_s_packages_code4"
 msgstr ""
+"No es posible obtener de bloqueo administrativo (se quedó sin espacio?) "
 
 #. Unsatisfied Dependencies
 #: i18n/english/luasrc/i18n/admin-core.en.lua:116
 msgid "a_s_packages_code5"
-msgstr ""
+msgstr "Dependencias insatisfechas "
 
 #. Refused to remove essential package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:117
 msgid "a_s_packages_code6"
-msgstr ""
+msgstr "No se puede eliminar un paquete esencial "
 
 #. Package has dependents
 #: i18n/english/luasrc/i18n/admin-core.en.lua:118
 msgid "a_s_packages_code7"
-msgstr ""
+msgstr "Hay paquetes instalados que dependen de éste."
 
 #. Package has no installation candidate (wrong name?)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:119
 msgid "a_s_packages_code8"
 msgstr ""
+"La instalación del paquete no tiene ningún candidato (nombre equivocado?) "
 
 #. Package has no available architecture 
 #: i18n/english/luasrc/i18n/admin-core.en.lua:120
 msgid "a_s_packages_code9"
 msgstr ""
+"El paquete no tiene una arquitectura disponible <span class=\"translation-"
+"space\"> </ span> "
 
 #. Package is not trusted
 #: i18n/english/luasrc/i18n/admin-core.en.lua:121
 msgid "a_s_packages_code10"
-msgstr ""
+msgstr "El paquete no es de confianza "
 
 #. Error while downloading
 #: i18n/english/luasrc/i18n/admin-core.en.lua:122
 msgid "a_s_packages_code11"
-msgstr ""
+msgstr "Error al descargar "
 
 #. Conflicts with other packages
 #: i18n/english/luasrc/i18n/admin-core.en.lua:123
 msgid "a_s_packages_code12"
-msgstr ""
+msgstr "Se produjeron conflictos con otros paquetes"
 
 #. Package is already installed
 #: i18n/english/luasrc/i18n/admin-core.en.lua:124
 msgid "a_s_packages_code13"
-msgstr ""
+msgstr "El paquete ya se encuentra instalado"
 
 #. Package has unresolved dependencies
 #: i18n/english/luasrc/i18n/admin-core.en.lua:125
 msgid "a_s_packages_code14"
-msgstr ""
+msgstr "El paquete tien dependencias no resueltas"
 
 #. Refused to downgrade package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:126
 msgid "a_s_packages_code15"
-msgstr ""
+msgstr "Se negó a bajar (de versión) el paquete "
 
 #. Package manager ran out of space
 #: i18n/english/luasrc/i18n/admin-core.en.lua:127
 msgid "a_s_packages_code16"
-msgstr ""
+msgstr "Gestor de paquetes se quedó sin espacio "
 
 #. Bad signature while verifiying package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:128
 msgid "a_s_packages_code17"
-msgstr ""
+msgstr "Error en verificación del paquete, la firma no corresponde"
 
 #. MD5 error while verifiying package
 #: i18n/english/luasrc/i18n/admin-core.en.lua:129
 msgid "a_s_packages_code18"
-msgstr ""
+msgstr "Error MD5 al verificar el paquete "
 
 #. Internal error occured
 #: i18n/english/luasrc/i18n/admin-core.en.lua:130
 msgid "a_s_packages_code19"
-msgstr ""
+msgstr "Ha ocurrido un error interno"
 
 #. Package lists
 #: i18n/english/luasrc/i18n/admin-core.en.lua:131
 msgid "a_s_p_ipkg_pkglists"
-msgstr ""
+msgstr "Listas de paquetes"
 
 #. Installation targets
 #: i18n/english/luasrc/i18n/admin-core.en.lua:132
 msgid "a_s_p_ipkg_targets"
-msgstr ""
+msgstr "Destinos de instalación"
 
 #. Change the password of the system administrator (User <code>root</code>)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:133
 msgid "a_s_changepw1"
 msgstr ""
+"Cambiar la clave del administrador del sistema (Usuario <code>root</code>)"
 
 #. Password successfully changed
 #: i18n/english/luasrc/i18n/admin-core.en.lua:134
 msgid "a_s_changepw_changed"
-msgstr ""
+msgstr "Contraseña cambiada satisfactoriamente"
 
 #. Error: Passwords do not match
 #: i18n/english/luasrc/i18n/admin-core.en.lua:135
 msgid "a_s_changepw_nomatch"
-msgstr ""
+msgstr "Error: Las claves ingresadas no coinciden"
 
 #. Here you can paste public <abbr title=\"Secure Shell\">SSH</abbr>-Keys (one per line) for <abbr title=\"Secure Shell\">SSH</abbr> public-key authentication.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:136
 msgid "a_s_sshkeys1"
 msgstr ""
+"Aquí puede pegar las claves públicas de <abbr title=\"Secure "
+"Shell\">SSH</abbr> (una por línea) para la autenticación de claves públicas "
+"de <abbr title=\"Secure Shell\">SSH</abbr>."
 
 #. Mount Points
 #: i18n/english/luasrc/i18n/admin-core.en.lua:137
 msgid "a_s_fstab_mountpoints"
-msgstr ""
+msgstr "Puntos de montaje"
 
 #. Mount Points define at which point a memory device will be attached to the filesystem
 #: i18n/english/luasrc/i18n/admin-core.en.lua:138
 msgid "a_s_fstab_mountpoints1"
 msgstr ""
+"Los puntos de montaje definen donde un dispositivo de memoria será adjuntado "
+"al sistema de archivos"
 
 #. Mounted file systems
 #: i18n/english/luasrc/i18n/admin-core.en.lua:139
 msgid "a_s_fstab_active"
-msgstr ""
+msgstr "Sistemas de archivo montados"
 
 #. Used
 #: i18n/english/luasrc/i18n/admin-core.en.lua:140
 msgid "a_s_fstab_used"
-msgstr ""
+msgstr "Usado"
 
 #. Available
 #: i18n/english/luasrc/i18n/admin-core.en.lua:141
 msgid "a_s_fstab_avail"
-msgstr ""
+msgstr "Disponible"
 
 #. Mount Point
 #: i18n/english/luasrc/i18n/admin-core.en.lua:142
 msgid "a_s_fstab_mountpoint"
-msgstr ""
+msgstr "Punto de montaje"
 
 #. The device file of the memory or partition (<abbr title=\"for example\">e.g.</abbr> <code>/dev/sda1</code>)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:143
 msgid "a_s_fstab_device1"
 msgstr ""
+"El archivo de dispotivo de memoria o partición (<abbr title=\"Por "
+"ejemplo\">e.j.</abbr> <code>/dev/sda1</code>)"
 
 #. The filesystem that was used to format the memory (<abbr title=\"for example\">e.g.</abbr> <samp><abbr title=\"Third Extended Filesystem\">ext3</abbr></samp>)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:144
 msgid "a_s_fstab_fs1"
 msgstr ""
+"El sistema de archivo que fue utilizado para dar formato a la memoria (<abbr "
+"title=\"por ejemplo\">Ej.</abbr> <samp><abbr title=\"Third Extended "
+"Filesystem\">ext3</abbr></samp>)"
 
 #. If your physical memory is insufficient unused data can be temporarily swapped to a swap-device resulting in a higher amount of usable <abbr title=\"Random Access Memory\">RAM</abbr>. Be aware that swapping data is a very slow process as the swap-device cannot be accessed with the high datarates of the <abbr title=\"Random Access Memory\">RAM</abbr>.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:145
 msgid "a_s_fstab_swap1"
 msgstr ""
+"Si la memoria física es insuficiente, los datos no utilizados pueden ser "
+"intercambiado tempralmente en un dispositivo de intercambio (swap-device) "
+"conllevando a espacio de memoria <abbr title=\"Random Access "
+"Memory\">RAM</abbr> usable. Tenga en cuenta que el intercambio de datos is un "
+"proceso lento ya que los dispositivos de intercambio (swap-devices) no "
+"pueden transferir volumenes de informacińo a altas tazas como si la <abbr "
+"title=\"Random Access Memory\">RAM</abbr>."
 
 #. Reboots the operating system of your device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:146
 msgid "a_s_reboot1"
-msgstr ""
+msgstr "Reiniciar el sistema operativo de su dispositivo"
 
 #. Perform reboot
 #: i18n/english/luasrc/i18n/admin-core.en.lua:147
 msgid "a_s_reboot_do"
-msgstr ""
+msgstr "Reiniciar..."
 
 #. Please wait: Device rebooting...
 #: i18n/english/luasrc/i18n/admin-core.en.lua:148
 msgid "a_s_reboot_running"
-msgstr ""
+msgstr "Por favor espere. Reiniciando dispositivo ..."
 
 #. Warning: There are unsaved changes that will be lost while rebooting!
 #: i18n/english/luasrc/i18n/admin-core.en.lua:149
 msgid "a_s_reboot_u"
 msgstr ""
+"Advertencia: Hay cambios realizados que no han sido guardados, los mismos se "
+"perderán mientras se reinicia!"
 
 #. Changes applied.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:150
 msgid "a_s_applyreboot1"
-msgstr ""
+msgstr "Cambios aplicados."
 
 #. Backup / Restore
 #: i18n/english/luasrc/i18n/admin-core.en.lua:151
 msgid "a_s_backup"
-msgstr ""
+msgstr "Backup / Restore"
 
 #. Create backup
 #: i18n/english/luasrc/i18n/admin-core.en.lua:152
 msgid "a_s_backup_backup"
-msgstr ""
+msgstr "Crear copia de respaldo"
 
 #. Backup Archive
 #: i18n/english/luasrc/i18n/admin-core.en.lua:153
 msgid "a_s_backup_archive"
-msgstr ""
+msgstr "Archivo de copia de seguridad"
 
 #. Reset router to defaults
 #: i18n/english/luasrc/i18n/admin-core.en.lua:154
 msgid "a_s_backup_reset"
-msgstr ""
+msgstr "Reiniciar router a su configuración de fábrica"
 
 #. Proceed reverting all settings and resetting to firmware defaults?
 #: i18n/english/luasrc/i18n/admin-core.en.lua:155
 msgid "a_s_backup_reset1"
-msgstr ""
+msgstr "Proceder a configurar su router a los valores de fábrica?"
 
 #. Restore backup
 #: i18n/english/luasrc/i18n/admin-core.en.lua:156
 msgid "a_s_backup_restore"
-msgstr ""
+msgstr "Restaurar copia de seguridad"
 
 #. Here you can backup and restore your router configuration and - if possible - reset the router to the default settings.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:157
 msgid "a_s_backup1"
 msgstr ""
+"Aquí puede realizar una copia de respaldo o bien restaurar la configuración "
+"de su ruter y, si es posible, reiniciar el ruter a su configuración de "
+"fábrica."
 
 #. <abbr title=\"Hypertext Transfer Protocol\">HTTP</abbr>-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:158
 msgid "a_srv_http"
-msgstr ""
+msgstr "Servidor <abbr title=\"Hypertext Transfer Protocol\">HTTP</abbr>"
 
 #. <abbr title=\"Secure Shell\">SSH</abbr>-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:159
 msgid "a_srv_ssh"
-msgstr ""
+msgstr "Servidor <abbr title=\"Secure Shell\">SSH</abbr>"
 
 #. Services and daemons perform certain tasks on your device.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:160
 msgid "a_srv_services1"
-msgstr ""
+msgstr "Los servicios y demonios ejecutan ciertas tareas en su dispositivo."
 
 #. Most of them are network servers, that offer a certain service for your device or network like shell access, serving webpages like <abbr title=\"Lua Configuration Interface\">LuCI</abbr>, doing mesh routing, sending e-mails, ...
 #: i18n/english/luasrc/i18n/admin-core.en.lua:161
 msgid "a_srv_services2"
 msgstr ""
+"La mayoría de ellos son servidores de red, que ofrezcen un determinado "
+"servicio para el dispositivo o la red como el acceso shell, servicio de "
+"páginas web como <abbr title=\"Lua configuración Interface\"> LuCI </ abbr>, "
+"haciendo mesh-routing, el envío de mensajes de correo electrónico, ..."
 
 #. A small webserver which can be used to serve <abbr title=\"Lua Configuration Interface\">LuCI</abbr>.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:162
 msgid "a_srv_http1"
 msgstr ""
+"Un pequeño servidor web que puede ser usado para servir <abbr title=\"Lua "
+"configuración Interface\"> LuCI </ abbr>. "
 
 #. Authentication Realm
 #: i18n/english/luasrc/i18n/admin-core.en.lua:163
 msgid "a_srv_http_authrealm"
-msgstr ""
+msgstr "Autenticación Realm"
 
 #. The realm which will be displayed at the authentication prompt for protected pages.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:164
 msgid "a_srv_http_authrealm1"
 msgstr ""
+"El nombre Realm el cual será mostrado en el símbolo de autenticación para "
+"páginas protegidas. "
 
 #. defaults to <code>/etc/httpd.conf</code>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:165
 msgid "a_srv_http_config1"
-msgstr ""
+msgstr "por defecto a <code>/etc/httpd.conf</code>"
 
 #. Document root
 #: i18n/english/luasrc/i18n/admin-core.en.lua:166
 msgid "a_srv_http_root"
-msgstr ""
+msgstr "Raíz de documentos"
 
 #. Enable Keep-Alive
 #: i18n/english/luasrc/i18n/admin-core.en.lua:167
 msgid "a_srv_http_keepalive"
-msgstr ""
+msgstr "Habilitar Keep-Alive"
 
 #. Connection timeout
 #: i18n/english/luasrc/i18n/admin-core.en.lua:168
 msgid "a_srv_http_timeout"
-msgstr ""
+msgstr "Tiempo de conexión agotado"
 
 #. Plugin path
 #: i18n/english/luasrc/i18n/admin-core.en.lua:169
 msgid "a_srv_http_path"
-msgstr ""
+msgstr "Ruta del plugin"
 
 #. A lightweight HTTP/1.1 webserver written in C and Lua designed to serve LuCI
 #: i18n/english/luasrc/i18n/admin-core.en.lua:170
 msgid "a_srv_lucittpd"
 msgstr ""
+"Un servidor web HTTP/1.1 liviano escrito en C y Lua, diseñado para servir "
+"LUCI "
 
 #. Dropbear offers <abbr title=\"Secure Shell\">SSH</abbr> network shell access and an integrated <abbr title=\"Secure Copy\">SCP</abbr> server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:171
 msgid "a_srv_dropbear1"
 msgstr ""
+"Dropbear ofrece acceso de red via el <abbr title=\"Secure Shell\"> SSH </ "
+"abbr> y servidor de copia de archivos integrado <abbr title=\"Secure Copy\"> "
+"SCP </ abbr>."
 
 #. Password authentication
 #: i18n/english/luasrc/i18n/admin-core.en.lua:172
 msgid "a_srv_d_pwauth"
-msgstr ""
+msgstr "Autenticación de contraseña"
 
 #. Allow <abbr title=\"Secure Shell\">SSH</abbr> password authentication
 #: i18n/english/luasrc/i18n/admin-core.en.lua:173
 msgid "a_srv_d_pwauth1"
 msgstr ""
+"Permitir autenticación de conseña via <abbr title=\"Secure Shell\">SSH</abbr>"
 
 #. Channel
 #: i18n/english/luasrc/i18n/admin-core.en.lua:174
 msgid "a_w_channel"
-msgstr ""
+msgstr "Canal"
 
 #. On this pages you can find configuration options for <abbr title=\"Wireless Local Area Network\">WLAN</abbr> based wireless networks.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:175
 msgid "a_w_wifi1"
 msgstr ""
+"En esta página podrá encontrar opciones de configuración para su(s) red(es) "
+"inalámbrica(s) <abbr title=\"Wireless Local Area Network\">WLAN</abbr>"
 
 #. You can easily integrate your 802.11a/b/g/n-devices into your physical network and use the virtual adapter support to build wireless repeaters or offer several networks with one device.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:176
 msgid "a_w_wifi2"
 msgstr ""
+"Fácilmente puede integrar sus dispositivos 802.11a/b/g/n dentro de su red "
+"física y usar un adaptador virtual para crear repetidores u ofrecer redes "
+"con un mismo dispositivo."
 
 #. There is support for Managed, Client, Ad-Hoc and <abbr title=\"Wireless Distribution System\">WDS</abbr> operating modes as well as <abbr title=\"Wi-Fi Protected Access\">WPA</abbr> and <abbr title=\"Wi-Fi Protected Access 2\">WPA2</abbr> encryption for secure communnication.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:177
 msgid "a_w_wifi3"
 msgstr ""
+"Se brinda soporte para operar en modo Managed, Client, Ad-Hoc y <abbr "
+"title=\"Wireless Distribution System\">WDS</abbr> así también como "
+"encriptación usando <abbr title=\"Wi-Fi Protected Access\">WPA</abbr> y <abbr "
+"title=\"Wi-Fi Protected Access 2\">WPA2</abbr> para comunicaciones seguras."
 
 #. Here you can configure installed wifi devices.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:178
 msgid "a_w_devices1"
-msgstr ""
+msgstr "Aquí puede configurar los dispositivos Wi-Fi instalados."
 
 #. Transmit Antenna
 #: i18n/english/luasrc/i18n/admin-core.en.lua:179
 msgid "a_w_txantenna"
-msgstr ""
+msgstr "Antena transmisora"
 
 #. Receive Antenna
 #: i18n/english/luasrc/i18n/admin-core.en.lua:180
 msgid "a_w_rxantenna"
-msgstr ""
+msgstr "Antena receptora"
 
 #. Distance to furthest station (in meter)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:181
 msgid "a_w_distance1"
-msgstr ""
+msgstr "Distancia de la estación mas alejada (en metros)"
 
 #. Diversity
 #: i18n/english/luasrc/i18n/admin-core.en.lua:182
 msgid "a_w_diversity"
-msgstr ""
+msgstr "Diversidad"
 
 #. Country Code
 #: i18n/english/luasrc/i18n/admin-core.en.lua:183
 msgid "a_w_countrycode"
-msgstr ""
+msgstr "Código de País"
 
 #. Connection Limit
 #: i18n/english/luasrc/i18n/admin-core.en.lua:184
 msgid "a_w_connlimit"
-msgstr ""
+msgstr "Límite de conexión "
 
 #. You can run several wifi networks with one device. Be aware that there are certain hardware and driverspecific restrictions. Normally you can operate 1 Ad-Hoc or up to 3 Master-Mode and 1 Client-Mode network simultaneously.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:185
 msgid "a_w_networks1"
 msgstr ""
+"Puede correr varias redes Wi-Fi con un solo dispositivo. Tenga en cuenta que "
+"hay restricciones que se aplican al propio hardware y al driver "
+"específicamente. Normalmente puede operar 1 red Ad-Hoc o hasta 3 modo Master "
+"y un Cliente de forma simultanea."
 
 #. Network Name (<abbr title=\"Extended Service Set Identifier\">ESSID</abbr>)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:186
 msgid "a_w_netid"
 msgstr ""
+"Nombre de la red (<abbr title=\"Extended Service Set "
+"Identifier\">ESSID</abbr>)"
 
 #. Add the Wifi network to physical network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:187
 msgid "a_w_network1"
-msgstr ""
+msgstr "Añadir una red WiFi a la red física"
 
 #.  - Create new Network - 
 #: i18n/english/luasrc/i18n/admin-core.en.lua:188
 msgid "a_w_netmanual"
 msgstr ""
+"<span class=\"translation-space\"> </span>\n"
+"- Crear nueva red -<span class=\"translation-space\"> </span>\n"
 
 #. Transmit Power
 #: i18n/english/luasrc/i18n/admin-core.en.lua:189
 msgid "a_w_txpwr"
-msgstr ""
+msgstr "Potencia de transmisión"
 
 #. Broadcom Frameburst
 #: i18n/english/luasrc/i18n/admin-core.en.lua:190
 msgid "a_w_brcmburst"
-msgstr ""
+msgstr "Frameburst Broadcom"
 
+# Frameburst = Punto de ruptura
 #. Atheros Frameburst
 #: i18n/english/luasrc/i18n/admin-core.en.lua:191
 msgid "a_w_athburst"
-msgstr ""
+msgstr "Frameburst Atheros"
 
 #. RadiusServer
 #: i18n/english/luasrc/i18n/admin-core.en.lua:192
 msgid "a_w_radiussrv"
-msgstr ""
+msgstr "Servidor Radius"
 
 #. Radius-Port
 #: i18n/english/luasrc/i18n/admin-core.en.lua:193
 msgid "a_w_radiusport"
-msgstr ""
+msgstr "Puerto servidor Radius"
 
 #. AP-Isolation
 #: i18n/english/luasrc/i18n/admin-core.en.lua:194
 msgid "a_w_apisolation"
-msgstr ""
+msgstr "Aislamiento AP"
 
 #. Prevents Client to Client communication
 #: i18n/english/luasrc/i18n/admin-core.en.lua:195
 msgid "a_w_apisolation1"
-msgstr ""
+msgstr "Impide la comunicación de cliente a cliente "
 
 #. Hide <abbr title=\"Extended Service Set Identifier\">ESSID</abbr>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:196
 msgid "a_w_hideessid"
-msgstr ""
+msgstr "Ocultar <abbr title=\"Extended Service Set Identifier\">ESSID</abbr>"
 
 #. Access Point
 #: i18n/english/luasrc/i18n/admin-core.en.lua:197
 msgid "a_w_ap"
-msgstr ""
+msgstr "Punto de Acceso"
 
 #. Ad-Hoc
 #: i18n/english/luasrc/i18n/admin-core.en.lua:198
 msgid "a_w_adhoc"
-msgstr ""
+msgstr "Ad-Hoc"
 
 #. Pseudo Ad-Hoc (ahdemo)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:199
 msgid "a_w_ahdemo"
-msgstr ""
+msgstr "Pseudo Ad-Hoc (ahdemo)"
 
 #. Client
 #: i18n/english/luasrc/i18n/admin-core.en.lua:200
 msgid "a_w_client"
-msgstr ""
+msgstr "Cliente"
 
 #. WDS
 #: i18n/english/luasrc/i18n/admin-core.en.lua:201
 msgid "a_w_wds"
-msgstr ""
+msgstr "WDS"
 
 #. Monitor
 #: i18n/english/luasrc/i18n/admin-core.en.lua:202
 msgid "a_w_monitor"
-msgstr ""
+msgstr "Monitor"
 
 #. Dnsmasq is a combined <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>-Server and <abbr title=\"Domain Name System\">DNS</abbr>-Forwarder for <abbr title=\"Network Address Translation\">NAT</abbr> firewalls
 #: i18n/english/luasrc/i18n/admin-core.en.lua:203
 msgid "dhcp_dnsmasq_desc"
 msgstr ""
+"Dnsmasq es un software que combina un Servidor <abbr title=\"Dynamic Host "
+"Configuration Protocol\">DHCP</abbr> y Reenviador <abbr title=\"Domain Name "
+"System\">DNS</abbr> para corta fuego <abbr title=\"Network Address "
+"Translation\">NAT</abbr>"
 
 #. Domain required
 #: i18n/english/luasrc/i18n/admin-core.en.lua:204
 msgid "dhcp_dnsmasq_domainneeded"
-msgstr ""
+msgstr "Dominio requerido"
 
 #. Don&#39;t forward <abbr title=\"Domain Name System\">DNS</abbr>-Requests without <abbr title=\"Domain Name System\">DNS</abbr>-Name
 #: i18n/english/luasrc/i18n/admin-core.en.lua:205
 msgid "dhcp_dnsmasq_domainneeded_desc"
 msgstr ""
+"Hacer reenvío Don&amp;#39;t de peticiones de <abbr title=\"Domain Name "
+"System\">DNS</abbr> sin un nombre de <abbr title=\"Domain Name "
+"System\">DNS</abbr>"
 
 #. Authoritative
 #: i18n/english/luasrc/i18n/admin-core.en.lua:206
 msgid "dhcp_dnsmasq_authoritative"
-msgstr ""
+msgstr "Authoritative"
 
 #. This is the only <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> in the local network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:207
 msgid "dhcp_dnsmasq_authoritative_desc"
 msgstr ""
+"Este es el único servidor <abbr title=\"Dynamic Host Configuration "
+"Protocol\">DHCP</abbr> en la red de área local"
 
 #. Filter private
 #: i18n/english/luasrc/i18n/admin-core.en.lua:208
 msgid "dhcp_dnsmasq_boguspriv"
-msgstr ""
+msgstr "Filtro privado "
 
 #. Don&#39;t forward reverse lookups for local networks
 #: i18n/english/luasrc/i18n/admin-core.en.lua:209
 msgid "dhcp_dnsmasq_boguspriv_desc"
-msgstr ""
+msgstr "Hacer búqueda inversa para redes locales"
 
 #. Filter useless
 #: i18n/english/luasrc/i18n/admin-core.en.lua:210
 msgid "dhcp_dnsmasq_filterwin2k"
-msgstr ""
+msgstr "Filtro inútil "
 
 #. filter useless <abbr title=\"Domain Name System\">DNS</abbr>-queries of Windows-systems
 #: i18n/english/luasrc/i18n/admin-core.en.lua:211
 msgid "dhcp_dnsmasq_filterwin2k_desc"
 msgstr ""
+"filter useless <abbr title=\"Domain Name System\">DNS</abbr>-queries of "
+"Windows-systems"
 
 #. Localise queries
 #: i18n/english/luasrc/i18n/admin-core.en.lua:212
 msgid "dhcp_dnsmasq_localisequeries"
-msgstr ""
+msgstr "Localización de las consultas "
 
 #. localises the hostname depending on its subnet
 #: i18n/english/luasrc/i18n/admin-core.en.lua:213
 msgid "dhcp_dnsmasq_localisequeries_desc"
-msgstr ""
+msgstr "Localización de nombre de host dependiendo de su subred"
 
 #. Local Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:214
 msgid "dhcp_dnsmasq_local"
-msgstr ""
+msgstr "Servidor local"
 
 #. Local Domain
 #: i18n/english/luasrc/i18n/admin-core.en.lua:215
 msgid "dhcp_dnsmasq_domain"
-msgstr ""
+msgstr "Dominio local"
 
 #. Expand Hosts
 #: i18n/english/luasrc/i18n/admin-core.en.lua:216
 msgid "dhcp_dnsmasq_expandhosts"
-msgstr ""
+msgstr "Expandir hosts"
 
 #. adds domain names to hostentries in the resolv file
 #: i18n/english/luasrc/i18n/admin-core.en.lua:217
 msgid "dhcp_dnsmasq_expandhosts_desc"
-msgstr ""
+msgstr "añadir nombre de dominios a entradas de host en el archivo resolv"
 
 #. don&#39;t cache unknown
 #: i18n/english/luasrc/i18n/admin-core.en.lua:218
 msgid "dhcp_dnsmasq_nonegcache"
-msgstr ""
+msgstr "do cachear desconocido"
 
 #. prevents caching of negative <abbr title=\"Domain Name System\">DNS</abbr>-replies
 #: i18n/english/luasrc/i18n/admin-core.en.lua:219
 msgid "dhcp_dnsmasq_nonegcache_desc"
 msgstr ""
+"impedir cacheo de respuestas negativas de <abbr title=\"Domain Name "
+"System\">DNS</abbr>"
 
 #. Use <code>/etc/ethers</code>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:220
 msgid "dhcp_dnsmasq_readethers"
-msgstr ""
+msgstr "Usar <code>/etc/ethers</code>"
 
 #. Read <code>/etc/ethers</code> to configure the <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:221
 msgid "dhcp_dnsmasq_readethers_desc"
 msgstr ""
+"Leer <code>/etc/ethers</code> para configurar el Servidor <abbr "
+"title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>"
 
 #. Leasefile
 #: i18n/english/luasrc/i18n/admin-core.en.lua:222
 msgid "dhcp_dnsmasq_leasefile"
-msgstr ""
+msgstr "Archivo \"lease\""
 
 #. file where given <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>-leases will be stored
 #: i18n/english/luasrc/i18n/admin-core.en.lua:223
 msgid "dhcp_dnsmasq_leasefile_desc"
 msgstr ""
+"archivo donde las direcciones dadas por el servidor <abbr title=\"Dynamic "
+"Host Configuration Protocol\">DHCP</abbr> serán guardadas"
 
 #. Resolvfile
 #: i18n/english/luasrc/i18n/admin-core.en.lua:224
 msgid "dhcp_dnsmasq_resolvfile"
-msgstr ""
+msgstr "Archivo \"resolv\""
 
 #. local <abbr title=\"Domain Name System\">DNS</abbr> file
 #: i18n/english/luasrc/i18n/admin-core.en.lua:225
 msgid "dhcp_dnsmasq_resolvfile_desc"
-msgstr ""
+msgstr "Archvo <abbr title=\"Domain Name System\">DNS</abbr> local"
 
 #. Ignore <code>/etc/hosts</code>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:226
 msgid "dhcp_dnsmasq_nohosts"
-msgstr ""
+msgstr "Ignorar <code>/etc/hosts</code>"
 
 #. Strict order
 #: i18n/english/luasrc/i18n/admin-core.en.lua:227
 msgid "dhcp_dnsmasq_strictorder"
-msgstr ""
+msgstr "Strict order"
 
 #. <abbr title=\"Domain Name System\">DNS</abbr>-Server will be queried in the order of the resolvfile
 #: i18n/english/luasrc/i18n/admin-core.en.lua:228
 msgid "dhcp_dnsmasq_strictorder_desc"
 msgstr ""
+"El Servidor <abbr title=\"Domain Name System\">DNS</abbr> serán consultados de "
+"acuerdo al orden explicitado en el archivo \"resolv\""
 
 #. Log queries
 #: i18n/english/luasrc/i18n/admin-core.en.lua:229
 msgid "dhcp_dnsmasq_logqueries"
-msgstr ""
+msgstr "Registrar consultas (LOG)"
 
 #. Ignore resolve file
 #: i18n/english/luasrc/i18n/admin-core.en.lua:230
 msgid "dhcp_dnsmasq_noresolv"
-msgstr ""
+msgstr "Iganorar archivo \"resolv\""
 
 #. concurrent queries
 #: i18n/english/luasrc/i18n/admin-core.en.lua:231
 msgid "dhcp_dnsmasq_dnsforwardmax"
-msgstr ""
+msgstr "consultas simultaneas"
 
 #. <abbr title=\"Domain Name System\">DNS</abbr>-Port
 #: i18n/english/luasrc/i18n/admin-core.en.lua:232
 msgid "dhcp_dnsmasq_port"
-msgstr ""
+msgstr "Puerto <abbr title=\"Domain Name System\">DNS</abbr>"
 
 #. <abbr title=\"maximal\">max.</abbr> <abbr title=\"Extension Mechanisms for Domain Name System\">EDNS0</abbr> paket size
 #: i18n/english/luasrc/i18n/admin-core.en.lua:233
 msgid "dhcp_dnsmasq_ednspacket_max"
 msgstr ""
+"Tamaño <abbr title=\"máximo\">máx.</abbr> de paquete <abbr title=\"Extension "
+"Mechanisms for Domain Name System\">EDNS0</abbr>"
 
 #. <abbr title=\"maximal\">max.</abbr> <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>-Leases
 #: i18n/english/luasrc/i18n/admin-core.en.lua:234
 msgid "dhcp_dnsmasq_dhcpleasemax"
 msgstr ""
+"<abbr title=\"maximal\">max.</abbr> <abbr title=\"Dynamic Host Configuration "
+"Protocol\">DHCP</abbr>-Leases"
 
 #. additional hostfile
 #: i18n/english/luasrc/i18n/admin-core.en.lua:235
 msgid "dhcp_dnsmasq_addnhosts"
-msgstr ""
+msgstr "archivo de host adicional"
 
 #. query port
 #: i18n/english/luasrc/i18n/admin-core.en.lua:236
 msgid "dhcp_dnsmasq_queryport"
-msgstr ""
+msgstr "puerto de consulta"
 
 #. Enable TFTP-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:237
 msgid "dhcp_dnsmasq_enabletftp"
-msgstr ""
+msgstr "Activar Servidor TFTP"
 
 #. TFTP-Server Root
 #: i18n/english/luasrc/i18n/admin-core.en.lua:238
 msgid "dhcp_dnsmasq_tftproot"
-msgstr ""
+msgstr "Raíz del Servidor TFTP"
 
 #. Network Boot Image
 #: i18n/english/luasrc/i18n/admin-core.en.lua:239
 msgid "dhcp_dnsmasq_dhcpboot"
-msgstr ""
+msgstr "Imágen de inicio en red"
 
 #. Switch
 #: i18n/english/luasrc/i18n/admin-core.en.lua:240
 msgid "a_n_switch"
-msgstr ""
+msgstr "Switch"
 
 #. Active Connections
 #: i18n/english/luasrc/i18n/admin-core.en.lua:241
 msgid "a_n_conntrack"
-msgstr ""
+msgstr "Conexiones activas"
 
 #. This page gives an overview over currently active network connections.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:242
 msgid "a_n_conntrack_desc"
 msgstr ""
+"Esta brinda una descripción general acerca de la cantidad de conexiones "
+"activas de red."
 
 #. Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:243
 msgid "a_n_routes"
-msgstr ""
+msgstr "Rutas"
 
 #. IPv4 Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:244
 msgid "a_n_routes4"
-msgstr ""
+msgstr "Rutas IPv4"
 
 #. IPv6 Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:245
 msgid "a_n_routes6"
-msgstr ""
+msgstr "Rutas IPv6"
 
 #. In this area you find all network-related settings.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:246
 msgid "a_network1"
 msgstr ""
+"En este área encontrará todo lo relacionado a la configuración de la red"
 
 #. On most routers the network switch can be freely configured and splitted up into several <abbr title=\"Virtual Local Area Network\">VLAN</abbr>s.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:247
 msgid "a_network2"
 msgstr ""
+"en la mayoría de los ruteadores el switch de red puede configurarse "
+"libremente y divirse en varias <abbr title=\"Virtual Local Area "
+"Network\">VLAN</abbr>s."
 
 #. Interfaces and <abbr title=\"Point-to-Point Protocol over Ethernet\">PPPoE</abbr> / <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr>-Settings allow a custom organisation of the network and connections to other networks like the internet.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:248
 msgid "a_network3"
 msgstr ""
+"La configuración de los protocolos <abbr title=\"Point-to-Point Protocol over "
+"Ethernet\">PPPoE</abbr> / <abbr title=\"Point-to-Point Tunneling "
+"Protocol\">PPTP</abbr> permiten personalizar la conecciones para conectar a "
+"una organización a otras redes como ser internet."
 
 #. With <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> devices in your local network can be automatically configured for network communication.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:249
 msgid "a_network4"
 msgstr ""
+"Con el Servidor <abbr title=\"Dynamic Host Configuration "
+"Protocol\">DHCP</abbr> los dispositivos en su red de área local pueden ser "
+"configurados automáticamente para la comunicación en red."
 
 #. Firewall and portforwarding can be used to secure your network while providing services to external networks.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:250
 msgid "a_network5"
 msgstr ""
+"El corta fuego y el reenvío de puertos pueden ser configurados para asgurar "
+"su red mientras se provee de servicios externos a la red."
 
 #. The network ports on your router can be combined to several <abbr title=\"Virtual Local Area Network\">VLAN</abbr>s in which computers can communicate directly with each other. <abbr title=\"Virtual Local Area Network\">VLAN</abbr>s are often used to separate different network segments. Often there is by default one Uplink port for a connection to the next greater network like the internet and other ports for a local network.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:251
 msgid "a_n_switch1"
 msgstr ""
+"Los puertos de red de su router pueden ser combinados en diferentes <abbr "
+"title=\"Virtual Local Area Network\">VLAN</abbr>s donde las computadoras "
+"pueden comunicarse directamente con otras. Las <abbr title=\"Virtual Local "
+"Area Network\">VLAN</abbr>s a menu son usadas para separar diferentes "
+"segmentos de red. Además, usualmente hay un puerto de enlace de subida "
+"(Uplink) para conectar a una red mas grande, por ejemplo Internet y otro(s) "
+"puerto(s) para el acceso a la red local."
 
 #. Ports belonging to a <abbr title=\"Virtual Local Area Network\">VLAN</abbr> are separated with spaces. The port with the highest number (usually 5) is oftern the connection to the internal network interface of the router. On devices with 5 ports often the one with the lowest number (0) is the predefined Uplink port.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:252
 msgid "network_switch_desc"
 msgstr ""
+"Los puertos pertenecientes a una <abbr title=\"Virtual Local Area "
+"Network\">VLAN</abbr> son separados por espacios. El puerto con el número mas "
+"alto (usualmente 5) is a menudo la coneción a la interfaz de red interna "
+"del router. En dispositivos con 5 puertos usualmente el puerto con el número "
+"mas bajo (0) está preconfigurado para el enlace de subida (Uplink)."
 
 #. On this page you can configure the network interfaces. You can bridge several interfaces by ticking the &quot;bridge interfaces&quot; field and enter the names of several network interfaces separated by spaces. You can also use <abbr title=\"Virtual Local Area Network\">VLAN</abbr> notation <samp>INTERFACE.VLANNR</samp> (<abbr title=\"for example\">e.g.</abbr>: <samp>eth0.1</samp>).
 #: i18n/english/luasrc/i18n/admin-core.en.lua:253
 msgid "a_n_ifaces1"
 msgstr ""
+"En esta página podrá configurar las interfaces de red. Puede hacer puentes "
+"con diferentes interfaces, ingresando el nombre de las interfaces asociadas "
+"separada por espacios. También puede usar notación <abbr title=\"Virtual "
+"Local Area Network\">VLAN</abbr>, <samp>INTERFACE.VLANNR</samp> (<abbr "
+"title=\"por ejemplo\">Ej.</abbr>: <samp>eth0.1</samp>)."
 
 #. Bridge interfaces
 #: i18n/english/luasrc/i18n/admin-core.en.lua:254
 msgid "a_n_i_bridge"
-msgstr ""
+msgstr "Puentear interfaces"
 
 #. creates a bridge over specified interface(s)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:255
 msgid "a_n_i_bridge1"
-msgstr ""
+msgstr "crear un puente sobre la(s) interfaz/(ces) asociada(s)"
 
 #. Enable <abbr title=\"Spanning Tree Protocol\">STP</abbr>
 msgid "a_n_i_stp"
-msgstr ""
+msgstr "Activar <abbr title=\"Spanning Tree Protocol\">STP</abbr>"
 
 #. Enables the Spanning Tree Protocol on this bridge
 msgid "a_n_i_stp1"
-msgstr ""
+msgstr "Activa STP en este puente"
 
 #. With <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> network members can automatically receive their network settings (<abbr title=\"Internet Protocol\">IP</abbr>-address, netmask, <abbr title=\"Domain Name System\">DNS</abbr>-server, ...).
 #: i18n/english/luasrc/i18n/admin-core.en.lua:256
 msgid "dhcp_desc"
 msgstr ""
+"Con <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> miembros "
+"de la red pueden automáticamente recibir su configuración (<abbr "
+"title=\"Internet Protocol\">IP</abbr>-address, máscara de red, servidor <abbr "
+"title=\"Domain Name System\">DNS</abbr>, ...)."
 
 #. Leasetime
 #: i18n/english/luasrc/i18n/admin-core.en.lua:257
 msgid "dhcp_dhcp_leasetime"
-msgstr ""
+msgstr "Tiempo de \"lease\""
 
 #. Dynamic <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:258
 msgid "dhcp_dhcp_dynamicdhcp"
-msgstr ""
+msgstr "Dynamic <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr>"
 
 #. Ignore interface
 #: i18n/english/luasrc/i18n/admin-core.en.lua:259
 msgid "dhcp_dhcp_ignore"
-msgstr ""
+msgstr "Ignorar interfaz"
 
 #. disable <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> for this interface
 #: i18n/english/luasrc/i18n/admin-core.en.lua:260
 msgid "dhcp_dhcp_ignore_desc"
 msgstr ""
+"desactivar <abbr title=\"Dynamic Host Configuration Protocol\">DHCP</abbr> "
+"para esta interfaz"
 
 #. Force
 #: i18n/english/luasrc/i18n/admin-core.en.lua:261
 msgid "dhcp_dhcp_force"
-msgstr ""
+msgstr "Forzar"
 
 #. first address (last octet)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:262
 msgid "dhcp_dhcp_start_desc"
-msgstr ""
+msgstr "primer dirección (último octeto)"
 
 #. number of leased addresses -1
 #: i18n/english/luasrc/i18n/admin-core.en.lua:263
 msgid "dhcp_dhcp_limit_desc"
-msgstr ""
+msgstr "número de direcciones brindadas -1"
 
 #. DHCP-Options
 #: i18n/english/luasrc/i18n/admin-core.en.lua:264
 msgid "dhcp_dhcp_dhcpoption"
-msgstr ""
+msgstr "Opciones de DHCP"
 
 #. See &quot;dnsmasq --help dhcp&quot; for a list of available options.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:265
 msgid "dhcp_dhcp_dhcpoption_desc"
 msgstr ""
+"Ver la ayuda  &amp;quot;dnsmasq -- dhcp&amp;quot; para una lista de opciones "
+"disponibles."
 
 #. Leases
 #: i18n/english/luasrc/i18n/admin-core.en.lua:266
 msgid "dhcp_leases"
-msgstr ""
+msgstr "Brindadas"
 
 #. Static Leases
 #: i18n/english/luasrc/i18n/admin-core.en.lua:267
 msgid "luci_ethers"
-msgstr ""
+msgstr "Brindadas estáticamente"
 
 #. Leasetime remaining
 #: i18n/english/luasrc/i18n/admin-core.en.lua:268
 msgid "dhcp_timeremain"
-msgstr ""
+msgstr "Tiempo de \"lease\" restante"
 
 #. Active Leases
 #: i18n/english/luasrc/i18n/admin-core.en.lua:269
 msgid "dhcp_leases_active"
-msgstr ""
+msgstr "\"Leases\" activas"
 
 #. Point-to-Point Connections
 #: i18n/english/luasrc/i18n/admin-core.en.lua:270
 msgid "a_n_ptp"
-msgstr ""
+msgstr "Conexiones punto-a-punto"
 
 #. Point-to-Point connections with <abbr title=\"Point-to-Point Protocol over Ethernet\">PPPoE</abbr> or <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr> are often used to connect a device over <abbr title=\"Digital Subscriber Line\">DSL</abbr> or similar technologies to an internet access point.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:271
 msgid "a_n_ptp1"
 msgstr ""
+"Las conexiones punto-a-punto los protocolos <abbr title=\"Point-to-Point "
+"Protocol over Ethernet\">PPPoE</abbr> o <abbr title=\"Point-to-Point Tunneling "
+"Protocol\">PPTP</abbr> son a menudo utilizadas para conectar un dispositivo "
+"sobre una línea <abbr title=\"Digital Subscriber Line\">DSL</abbr> o "
+"tecnologías similiar a un punto de acceso a internet."
 
 #. You need to install &quot;comgt&quot; for UMTS/GPRS, &quot;ppp-mod-pppoe&quot; for PPPoE, &quot;ppp-mod-pppoa&quot; for PPPoA or &quot;pptp&quot; for PPtP support
 #: i18n/english/luasrc/i18n/admin-core.en.lua:272
 msgid "network_interface_prereq"
 msgstr ""
+"Es necesario instalar &amp;quot;comgt&amp;quot; para UMTS/GPRS, &amp;quot"
+";ppp-mod-pppoe&amp;quot; para PPPoE, &amp;quot;ppp-mod-pppoa&amp;quot; para "
+"PPPoA o &amp;quot;pptp&amp;quot; para porte PPtP"
 
 #. You need to install &quot;ppp-mod-pppoe&quot; for PPPoE or &quot;pptp&quot; for PPtP support
 #: i18n/english/luasrc/i18n/admin-core.en.lua:273
 msgid "network_interface_prereq_mini"
 msgstr ""
+"Es necesario instalar &amp;quot;ppp-mod-pppoe&amp;quot; para PPPoE o "
+"&amp;quot;pptp&amp;quot; para PPtP support"
 
 #. <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr>-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:274
 msgid "network_interface_server"
-msgstr ""
+msgstr "Servidor <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr>"
 
 #. Automatic Disconnect
 #: i18n/english/luasrc/i18n/admin-core.en.lua:275
 msgid "network_interface_demand"
-msgstr ""
+msgstr "Desconectar automáticamente"
 
 #. Time (in seconds) after which an unused connection will be closed
 #: i18n/english/luasrc/i18n/admin-core.en.lua:276
 msgid "network_interface_demand_desc"
-msgstr ""
+msgstr "Tiempo (en segundos) luego de que una conexión no usada será cerrada"
 
 #. Keep-Alive
 #: i18n/english/luasrc/i18n/admin-core.en.lua:277
 msgid "network_interface_keepalive"
-msgstr ""
+msgstr "Mantener conectada"
 
 #. Number of failed connection tests to initiate automatic reconnect
 #: i18n/english/luasrc/i18n/admin-core.en.lua:278
 msgid "network_interface_keepalive_desc"
 msgstr ""
+"Número de tests de conexión fallida para iniciar la reconexión automática"
 
 #. Modem device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:279
 msgid "network_interface_device"
-msgstr ""
+msgstr "Dispositivo de Modem"
 
 #. The device node of your modem, e.g. /dev/ttyUSB0
 #: i18n/english/luasrc/i18n/admin-core.en.lua:280
 msgid "network_interface_device_desc"
-msgstr ""
+msgstr "El nodo de dispositivo de su modem, ej. /dev/ttyUSB0"
 
 #. Replace default route
 #: i18n/english/luasrc/i18n/admin-core.en.lua:281
 msgid "network_interface_defaultroute"
-msgstr ""
+msgstr "Reemplazar la ruta por defecto"
 
 #. Let pppd replace the current default route to use the PPP interface after successful connect
 #: i18n/english/luasrc/i18n/admin-core.en.lua:282
 msgid "network_interface_defaultroute_desc"
 msgstr ""
+"Permite que pppd reemplace la ruta por defecto actual para usar la interfaz "
+"ppp como ruta por defecto luego de una conexión satisfactoria"
 
 #. Use peer DNS
 #: i18n/english/luasrc/i18n/admin-core.en.lua:283
 msgid "network_interface_peerdns"
-msgstr ""
+msgstr "Uso de pares de DNS "
 
 #. Configure the local DNS server to use the name servers adverticed by the PPP peer
 #: i18n/english/luasrc/i18n/admin-core.en.lua:284
 msgid "network_interface_peerdns_desc"
 msgstr ""
+"Configurar el servidor DNS local para usar servidores de nombre sugeridos "
+"por el par PPP"
 
 #. Enable IPv6 on PPP link
 #: i18n/english/luasrc/i18n/admin-core.en.lua:285
 msgid "network_interface_ipv6"
-msgstr ""
+msgstr "Ativar IPv6 sobre enlace PPP"
 
 #. Connect script
 #: i18n/english/luasrc/i18n/admin-core.en.lua:286
 msgid "network_interface_connect"
-msgstr ""
+msgstr "Script de conexión"
 
 #. Let pppd run this script after establishing the PPP link
 #: i18n/english/luasrc/i18n/admin-core.en.lua:287
 msgid "network_interface_connect_desc"
-msgstr ""
+msgstr "Permite a pppd ejecutar este script luego de establecer un enlace PPP"
 
 #. Disconnect script
 #: i18n/english/luasrc/i18n/admin-core.en.lua:288
 msgid "network_interface_disconnect"
-msgstr ""
+msgstr "Script de desconexión"
 
 #. Let pppd run this script before tearing down the PPP link
 #: i18n/english/luasrc/i18n/admin-core.en.lua:289
 msgid "network_interface_disconnect_desc"
-msgstr ""
+msgstr "Permite a pppd ejecutar este script antes de terminar el enlace PPP"
 
 #. Additional pppd options
 #: i18n/english/luasrc/i18n/admin-core.en.lua:290
 msgid "network_interface_pppd_options"
-msgstr ""
+msgstr "Opciones adicional de pppd"
 
 #. Specify additional command line arguments for pppd here
 #: i18n/english/luasrc/i18n/admin-core.en.lua:291
 msgid "network_interface_pppd_options_desc"
 msgstr ""
+"Especifique aquí argumentos adicionales para la línea de comando de pppd"
 
 #. Access point (APN)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:292
 msgid "network_interface_apn"
-msgstr ""
+msgstr "Punto de acceso (APN)"
 
 #. PIN code
 #: i18n/english/luasrc/i18n/admin-core.en.lua:293
 msgid "network_interface_pincode"
-msgstr ""
+msgstr "Código PIN"
 
 #. Make sure that you provide the correct pin code here or you might lock your sim card!
 #: i18n/english/luasrc/i18n/admin-core.en.lua:294
 msgid "network_interface_pincode_desc"
 msgstr ""
+"Asegurese de escribir correctamente el código pin aquí caso contrario "
+"bloqueará su tarjeta sim!"
 
 #. Service type
 #: i18n/english/luasrc/i18n/admin-core.en.lua:295
 msgid "network_interface_service"
-msgstr ""
+msgstr "Tipo de servicio"
 
 #. Setup wait time
 #: i18n/english/luasrc/i18n/admin-core.en.lua:296
 msgid "network_interface_maxwait"
-msgstr ""
+msgstr "Configurar tiempo de espera"
 
 #. Seconds to wait for the modem to become ready before attempting to connect
 #: i18n/english/luasrc/i18n/admin-core.en.lua:297
 msgid "network_interface_maxwait_desc"
-msgstr ""
+msgstr "Segundos a esperar al modem antes iniciar el intento de conexión"
 
 #. PPPoA Encapsulation
 #: i18n/english/luasrc/i18n/admin-core.en.lua:298
 msgid "network_interface_encaps"
-msgstr ""
+msgstr "Encapsulación PPPoA"
 
 #. Routes specify over which interface and gateway a certain host or network can be reached.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:299
 msgid "a_n_r_routes1"
 msgstr ""
+"Rutas a especificar sobre qué  interfaz y puerta de enlace cierto host o red "
+"a la que se puede llegar. "
 
 #. Static Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:300
 msgid "a_n_routes_static"
-msgstr ""
+msgstr "Rutas estáticas"
 
 #. Static IPv4 Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:301
 msgid "a_n_routes_static4"
-msgstr ""
+msgstr "Rutas estáticas IPv4"
 
 #. Static IPv6 Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:302
 msgid "a_n_routes_static6"
-msgstr ""
+msgstr "Rutas estáticas IPv6"
 
 #. Active <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>-Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:303
 msgid "a_n_routes_kernel4"
-msgstr ""
+msgstr "Rutas <abbr title=\"Internet Protocol Version 4\">IPv4</abbr> activas"
 
 #. Active <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>-Routes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:304
 msgid "a_n_routes_kernel6"
-msgstr ""
+msgstr "Rutas <abbr title=\"Internet Protocol Version 6\">IPv6</abbr> activas"
 
 #. Host-<abbr title=\"Internet Protocol Address\">IP</abbr> or Network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:305
 msgid "a_n_r_target1"
 msgstr ""
+"Dirección <abbr title=\"Internet Protocol Address\">IP</abbr> de host o red"
 
 #. <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>-Address or Network (CIDR)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:306
 msgid "a_n_r_target6"
 msgstr ""
+"Dirección <abbr title=\"Internet Protocol Version 6\">IPv6</abbr> o (CIDR) de "
+"red"
 
 #. if target is a network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:307
 msgid "a_n_r_netmask1"
-msgstr ""
+msgstr "si el destino es una red"
 
 #. Internet Connection
 #: i18n/english/luasrc/i18n/admin-core.en.lua:308
 msgid "m_n_inet"
-msgstr ""
+msgstr "Conexión a Internet "
 
 #. Local Network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:309
 msgid "m_n_local"
-msgstr ""
+msgstr "Red local"
 
 #. Route
 #: i18n/english/luasrc/i18n/admin-core.en.lua:310
 msgid "m_n_route"
-msgstr ""
+msgstr "Ruta"
 
 #. Bridge
 #: i18n/english/luasrc/i18n/admin-core.en.lua:311
 msgid "m_n_brdige"
-msgstr ""
+msgstr "Puente"
 
 #. Provide (Access Point)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:312
 msgid "m_w_ap"
-msgstr ""
+msgstr "Proporcionar (Punto de Acceso) "
 
 #. Independent (Ad-Hoc)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:313
 msgid "m_w_adhoc"
-msgstr ""
+msgstr "Independiente (ad hoc) "
 
 #. Join (Client)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:314
 msgid "m_w_client"
-msgstr ""
+msgstr "Únete (Cliente) "
 
 #. Distributed (<abbr title=\"Wireless Distribution System\">WDS</abbr>)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:315
 msgid "m_w_wds"
-msgstr ""
+msgstr "Distribuído (<abbr title=\"Wireless Distribution System\">WDS</abbr>)"
 
 #. Clientmode
 #: i18n/english/luasrc/i18n/admin-core.en.lua:316
 msgid "m_w_clientmode"
-msgstr ""
+msgstr "Modo cliente"
 
 #. System log buffer size
 #: i18n/english/luasrc/i18n/admin-core.en.lua:317
 msgid "system_system_logsize"
-msgstr ""
+msgstr "Tamaño del buffer del registro de sistema"
 
 #. External system log server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:318
 msgid "system_system_logip"
-msgstr ""
+msgstr "Servidor externo de registro de sistema"
 
 #. Log output level
 #: i18n/english/luasrc/i18n/admin-core.en.lua:319
 msgid "system_system_conloglevel"
-msgstr ""
+msgstr "Nivel de salida del registro"
 
 #. Level of log messages on the console
 #: i18n/english/luasrc/i18n/admin-core.en.lua:320
 msgid "system_system_conloglevel_desc"
-msgstr ""
+msgstr "Nivel de mensajes de registro en la consola "
 
 #. Processor
 #: i18n/english/luasrc/i18n/admin-core.en.lua:321
 msgid "m_i_processor"
-msgstr ""
+msgstr "Procesador"
 
 #. Memory
 #: i18n/english/luasrc/i18n/admin-core.en.lua:322
 msgid "m_i_memory"
-msgstr ""
+msgstr "Memoria"
 
 #. Local Time
 #: i18n/english/luasrc/i18n/admin-core.en.lua:323
 msgid "m_i_systemtime"
-msgstr ""
+msgstr "Hora local"
 
 #. Uptime
 #: i18n/english/luasrc/i18n/admin-core.en.lua:324
 msgid "m_i_uptime"
-msgstr ""
+msgstr "Tiempo de actividad "
 
 #. First leased address
 #: i18n/english/luasrc/i18n/admin-core.en.lua:325
 msgid "m_n_d_firstaddress"
-msgstr ""
+msgstr "Primer dirección otorgada"
 
 #. Number of leased addresses
 #: i18n/english/luasrc/i18n/admin-core.en.lua:326
 msgid "m_n_d_numleases"
-msgstr ""
+msgstr "Número de direcciones otorogada"
 
 #. Routing table
 #: i18n/english/luasrc/i18n/admin-core.en.lua:327
 msgid "routingtable"
-msgstr ""
+msgstr "Tabla de enrutamiento "
 
 #. Wifi scan
 #: i18n/english/luasrc/i18n/admin-core.en.lua:328
 msgid "wlanscan"
-msgstr ""
+msgstr "Wifi scan"
 
 #. Frequency
 #: i18n/english/luasrc/i18n/admin-core.en.lua:329
 msgid "frequency"
-msgstr ""
+msgstr "Frecuencia"
 
 #. Power
 #: i18n/english/luasrc/i18n/admin-core.en.lua:330
 msgid "power"
-msgstr ""
+msgstr "Potencia"
 
 #. Noise
 #: i18n/english/luasrc/i18n/admin-core.en.lua:331
 msgid "noise"
-msgstr ""
+msgstr "Ruído"
 
 #. Signal
 #: i18n/english/luasrc/i18n/admin-core.en.lua:332
 msgid "signal"
-msgstr ""
+msgstr "Señal"
 
 #. Link
 #: i18n/english/luasrc/i18n/admin-core.en.lua:333
 msgid "link"
-msgstr ""
+msgstr "Enlace"
 
 #. <abbr title=\"Fragmentation\">Frag.</abbr>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:334
 msgid "frag"
-msgstr ""
+msgstr "<abbr title=\"Fragmentación\">Frag.</abbr>"
 
 #. <abbr title=\"Request To Send\">RTS</abbr>
 #: i18n/english/luasrc/i18n/admin-core.en.lua:335
 msgid "rts"
-msgstr ""
+msgstr "<abbr title=\"Request To Send\">RTS</abbr>"
 
 #. Bitrate
 #: i18n/english/luasrc/i18n/admin-core.en.lua:336
 msgid "bitrate"
-msgstr ""
+msgstr "Bitrate"
 
 #. automatically reconnect
 #: i18n/english/luasrc/i18n/admin-core.en.lua:337
 msgid "m_n_keepalive"
-msgstr ""
+msgstr "reconectar automáticamente"
 
 #. disconnect when idle for
 #: i18n/english/luasrc/i18n/admin-core.en.lua:338
 msgid "m_n_dialondemand"
-msgstr ""
+msgstr "desconecte cuando esté inactivo durante "
 
 #. <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr>-Server
 #: i18n/english/luasrc/i18n/admin-core.en.lua:339
 msgid "m_n_pptp_server"
-msgstr ""
+msgstr "Servidor <abbr title=\"Point-to-Point Tunneling Protocol\">PPTP</abbr>"
 
 #. <abbr title=\"Light Emitting Diode\">LED</abbr> Configuration
 #: i18n/english/luasrc/i18n/admin-core.en.lua:340
 msgid "leds"
-msgstr ""
+msgstr "Configuración de <abbr title=\"Light Emitting Diode\">LED</abbr>s"
 
 #. Customizes the behaviour of the device <abbr title=\"Light Emitting Diode\">LED</abbr>s if possible.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:341
 msgid "leds_desc"
 msgstr ""
+"Personaliza el comportamiento de los <abbr title=\"Light Emitting "
+"Diode\">LED</abbr>s del dispositivo, si es posible."
 
 #. <abbr title=\"Light Emitting Diode\">LED</abbr> Name
 #: i18n/english/luasrc/i18n/admin-core.en.lua:342
 msgid "system_led_name"
-msgstr ""
+msgstr "Nombre del <abbr title=\"Light Emitting Diode\">LED</abbr>"
 
 #. <abbr title=\"Light Emitting Diode\">LED</abbr> Device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:343
 msgid "system_led_sysfs"
-msgstr ""
+msgstr "Disposito del <abbr title=\"Light Emitting Diode\">LED</abbr>"
 
 #. Default state
 #: i18n/english/luasrc/i18n/admin-core.en.lua:344
 msgid "system_led_default"
-msgstr ""
+msgstr "Estado por defecto"
 
 #. ticked = on
 #: i18n/english/luasrc/i18n/admin-core.en.lua:345
 msgid "system_led_default_desc"
-msgstr ""
+msgstr "marcado = encendido"
 
 #. Trigger
 #: i18n/english/luasrc/i18n/admin-core.en.lua:346
 msgid "system_led_trigger"
-msgstr ""
+msgstr "Desencadenar "
 
 #. None
 #: i18n/english/luasrc/i18n/admin-core.en.lua:347
 msgid "system_led_trigger_none"
-msgstr ""
+msgstr "Ninguno"
 
 #. Default On
 #: i18n/english/luasrc/i18n/admin-core.en.lua:348
 msgid "system_led_trigger_defaulton"
-msgstr ""
+msgstr "Encendido por defecto"
 
 #. Timer
 #: i18n/english/luasrc/i18n/admin-core.en.lua:349
 msgid "system_led_trigger_timer"
-msgstr ""
+msgstr "Temporizador "
 
 #. Heartbeat (Load Average)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:350
 msgid "system_led_trigger_heartbeat"
-msgstr ""
+msgstr "Latido del corazón (carga media) "
 
 #. Network Device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:351
 msgid "system_led_trigger_netdev"
-msgstr ""
+msgstr "Dispositivo de red"
 
 #. Off-State Delay
 #: i18n/english/luasrc/i18n/admin-core.en.lua:352
 msgid "system_led_delayoff"
-msgstr ""
+msgstr "Retardo de Off-State"
 
 #. Time (in ms) the <abbr title=\"Light Emitting Diode\">LED</abbr> is off
 #: i18n/english/luasrc/i18n/admin-core.en.lua:353
 msgid "system_led_delayoff_desc"
 msgstr ""
+"Tiempo (en ms) en el cual el <abbr title=\"Light Emitting Diode\">LED</abbr> "
+"permanece apagado"
 
 #. On-State Delay
 #: i18n/english/luasrc/i18n/admin-core.en.lua:354
 msgid "system_led_delayon"
-msgstr ""
+msgstr "Retardo de On-State"
 
 #. Time (in ms) the <abbr title=\"Light Emitting Diode\">LED</abbr> is on
 #: i18n/english/luasrc/i18n/admin-core.en.lua:355
 msgid "system_led_delayon_desc"
 msgstr ""
+"Tiempo (en ms) en el cual el <abbr title=\"Light Emitting Diode\">LED</abbr> "
+"permanece encendido"
 
 #. Device
 #: i18n/english/luasrc/i18n/admin-core.en.lua:356
 msgid "system_led_dev"
-msgstr ""
+msgstr "Dispositivo"
 
 #. Trigger Mode
 #: i18n/english/luasrc/i18n/admin-core.en.lua:357
 msgid "system_led_mode"
-msgstr ""
+msgstr "Modo de activación "
 
 #. Link On
 #: i18n/english/luasrc/i18n/admin-core.en.lua:358
 msgid "system_led_mode_link"
-msgstr ""
+msgstr "Link On"
 
 #. Transmit
 #: i18n/english/luasrc/i18n/admin-core.en.lua:359
 msgid "system_led_mode_tx"
-msgstr ""
+msgstr "Transmitir"
 
 #. Receive
 #: i18n/english/luasrc/i18n/admin-core.en.lua:360
 msgid "system_led_mode_rx"
-msgstr ""
+msgstr "Recibir "
 
 #. Active
 #: i18n/english/luasrc/i18n/admin-core.en.lua:361
 msgid "network_interface_up"
-msgstr ""
+msgstr "Activo"
 
 #. <abbr title=\"Media Access Control\">MAC</abbr>-Address
 #: i18n/english/luasrc/i18n/admin-core.en.lua:362
 msgid "network_interface_hwaddr"
-msgstr ""
+msgstr "Dirección <abbr title=\"Media Access Control\">MAC</abbr>"
 
 #. Hardware Address
 #: i18n/english/luasrc/i18n/admin-core.en.lua:363
 msgid "network_interface_hwaddr_desc"
-msgstr ""
+msgstr "Dirección de Hardware"
 
 #. Traffic
 #: i18n/english/luasrc/i18n/admin-core.en.lua:364
 msgid "network_interface_txrx"
-msgstr ""
+msgstr "Tráfico"
 
 #. transmitted / received
 #: i18n/english/luasrc/i18n/admin-core.en.lua:365
 msgid "network_interface_txrx_desc"
-msgstr ""
+msgstr "transmitido / recibido"
 
 #. Errors
 #: i18n/english/luasrc/i18n/admin-core.en.lua:366
 msgid "network_interface_err"
-msgstr ""
+msgstr "Errores"
 
 #. TX / RX
 #: i18n/english/luasrc/i18n/admin-core.en.lua:367
 msgid "network_interface_err_desc"
-msgstr ""
+msgstr "Tx / Rx"
 
 #. Create / Assign firewall-zone
 #: i18n/english/luasrc/i18n/admin-core.en.lua:368
 msgid "network_interface_fwzone"
-msgstr ""
+msgstr "Crear / Asignar zona de seguridad "
 
 #. This interface does not belong to any firewall zone yet.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:369
 msgid "network_interface_fwzone_desc"
-msgstr ""
+msgstr "Esta interfaz no pertenece a ninguna zona del corta fuego aún."
 
 #. Processes
 #: i18n/english/luasrc/i18n/admin-core.en.lua:370
 msgid "process_head"
-msgstr ""
+msgstr "Procesos"
 
 #. This list gives an overview over currently running system processes and their status.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:371
 msgid "process_descr"
 msgstr ""
+"Esta lista brinda un pantallaso general acerca de los procesos de sistema "
+"que se encuentra ejecutando actualmente y su estado relacionado."
 
 #. PID
 #: i18n/english/luasrc/i18n/admin-core.en.lua:372
 msgid "process_pid"
-msgstr ""
+msgstr "PID"
 
 #. Owner
 #: i18n/english/luasrc/i18n/admin-core.en.lua:373
 msgid "process_owner"
-msgstr ""
+msgstr "Dueño"
 
 #. Command
 #: i18n/english/luasrc/i18n/admin-core.en.lua:374
 msgid "process_command"
-msgstr ""
+msgstr "Comando"
 
 #. CPU usage (%)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:375
 msgid "process_cpu"
-msgstr ""
+msgstr "Uso de la CPU (%)"
 
 #. Memory usage (%)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:376
 msgid "process_mem"
-msgstr ""
+msgstr "Uso de la Memoria (%)"
 
 #. Hang Up
 #: i18n/english/luasrc/i18n/admin-core.en.lua:377
 msgid "process_hup"
-msgstr ""
+msgstr "Colgar"
 
 #. Terminate
 #: i18n/english/luasrc/i18n/admin-core.en.lua:378
 msgid "process_term"
-msgstr ""
+msgstr "Terminar"
 
 #. Kill
 #: i18n/english/luasrc/i18n/admin-core.en.lua:379
 msgid "process_kill"
-msgstr ""
+msgstr "Matar"
 
 #. cached
 #: i18n/english/luasrc/i18n/admin-core.en.lua:380
 msgid "mem_cached"
-msgstr ""
+msgstr "en caché "
 
 #. buffered
 #: i18n/english/luasrc/i18n/admin-core.en.lua:381
 msgid "mem_buffered"
-msgstr ""
+msgstr "buffered"
 
 #. free
 #: i18n/english/luasrc/i18n/admin-core.en.lua:382
 msgid "mem_free"
-msgstr ""
+msgstr "libre"
 
 #. Scheduled Tasks
 #: i18n/english/luasrc/i18n/admin-core.en.lua:383
 msgid "a_s_crontab"
-msgstr ""
+msgstr "Tareas programadas"
 
 #. This is the system crontab in which scheduled tasks can be defined.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:384
 msgid "a_s_crontab1"
 msgstr ""
+"Este es el crontab del sistema en el que las tareas programadas son "
+"definidas"
 
 #. NAS ID
 #: i18n/english/luasrc/i18n/admin-core.en.lua:385
 msgid "a_w_nasid"
-msgstr ""
+msgstr "NAS ID"
 
 #. Path to CA-Certificate
 #: i18n/english/luasrc/i18n/admin-core.en.lua:386
 msgid "a_w_cacert"
-msgstr ""
+msgstr "Ruta al Certificado CA"
 
 #. EAP-Method
 #: i18n/english/luasrc/i18n/admin-core.en.lua:387
 msgid "a_w_eaptype"
-msgstr ""
+msgstr "Método EAP"
 
 #. Path to Private Key
 #: i18n/english/luasrc/i18n/admin-core.en.lua:388
 msgid "a_w_tlsprivkey"
-msgstr ""
+msgstr "Ruta a la Clave Privada"
 
 #. Password of Private Key
 #: i18n/english/luasrc/i18n/admin-core.en.lua:389
 msgid "a_w_tlsprivkeypwd"
-msgstr ""
+msgstr "Contraseña de la Clave Privada"
 
 #. Authentication
 #: i18n/english/luasrc/i18n/admin-core.en.lua:390
 msgid "a_w_peapauth"
-msgstr ""
+msgstr "Autenticación"
 
 #. Identity
 #: i18n/english/luasrc/i18n/admin-core.en.lua:391
 msgid "a_w_peapidentity"
-msgstr ""
+msgstr "Identidad"
 
 #. Password
 #: i18n/english/luasrc/i18n/admin-core.en.lua:392
 msgid "a_w_peappassword"
-msgstr ""
+msgstr "Contraseña"
 
 #. Create Network
 #: i18n/english/luasrc/i18n/admin-core.en.lua:393
 msgid "a_w_create"
-msgstr ""
+msgstr "Crear red"
 
 #. Hostnames
 #: i18n/english/luasrc/i18n/admin-core.en.lua:394
 msgid "hostnames"
-msgstr ""
+msgstr "Nombres de host"
 
 #. Host entries
 #: i18n/english/luasrc/i18n/admin-core.en.lua:395
 msgid "hostnames_entries"
-msgstr ""
+msgstr "Entradas de host"
 
 #. Hostname
 #: i18n/english/luasrc/i18n/admin-core.en.lua:396
 msgid "hostnames_hostname"
-msgstr ""
+msgstr "Nombre de host"
 
 #. IP address
 #: i18n/english/luasrc/i18n/admin-core.en.lua:397
 msgid "hostnames_address"
-msgstr ""
+msgstr "Dirección IP"
 
 #. Clamp Segment Size
 #: i18n/english/luasrc/i18n/admin-core.en.lua:398
 msgid "m_n_mssfix"
-msgstr ""
+msgstr "Tamaño del segmento de la abrazadera"
 
 #. Fixes problems with unreachable websites, submitting forms or other unexpected behaviour for some ISPs.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:399
 msgid "m_n_mssfix_desc"
 msgstr ""
+"Correge problemas con los sitios web inaccesibles, envío de formularios o "
+"una conducta inesperada para algunos proveedores de servicios de Internet."
 
 #. Flash Firmware
 #: i18n/english/luasrc/i18n/admin-core.en.lua:400
 msgid "admin_upgrade"
-msgstr ""
+msgstr "Flash Firmware"
 
 #. The uploaded image file does not contain a supported format. Make sure that you choose the generic image format for your platform.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:401
 msgid "admin_upgrade_badimage"
 msgstr ""
+"El archivo con la imágen del firmware subido, presenta un formato de archivo "
+"no soportado. Asegurese de haber elegido una imágen genérica para su "
+"plataforma."
 
 #. Checksum
 #: i18n/english/luasrc/i18n/admin-core.en.lua:402
 msgid "admin_upgrade_checksum"
-msgstr ""
+msgstr "Checksum"
 
 #. Upload an OpenWrt image file to reflash the device.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:403
 msgid "admin_upgrade_desc"
 msgstr ""
+"Subir un archivo de imágen de OpenWrt o derivado para re-flashear el "
+"dispositivo."
 
 #. Size
 #: i18n/english/luasrc/i18n/admin-core.en.lua:404
 msgid "admin_upgrade_filesize"
-msgstr ""
+msgstr "Tamaño"
 
 #. Firmware image
 #: i18n/english/luasrc/i18n/admin-core.en.lua:405
 msgid "admin_upgrade_fwimage"
-msgstr ""
+msgstr "Imágen del firmware"
 
 #. Keep configuration files
 #: i18n/english/luasrc/i18n/admin-core.en.lua:406
 msgid "admin_upgrade_keepcfg"
-msgstr ""
+msgstr "Mantener archivos de configuración"
 
 #. Sorry. OpenWrt does not support a system upgrade on this platform.<br /> You need to manually flash your device.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:407
 msgid "admin_upgrade_nosupport"
 msgstr ""
+"Lo lamento. OpenWrt y derivados no permite la actualización de esta "
+"plataforma. <br /> Para poder flashear este dispositivo deberá hacerlo en "
+"forma manual."
 
 #. The system is flashing now.<br /> DO NOT POWER OFF THE DEVICE!<br /> Wait a few minutes until you try to reconnect. It might be necessary to renew the address of your computer to reach the device again, depending on your settings.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:408
 msgid "admin_upgrade_running"
 msgstr ""
+"El sistema está siendo flasheado.<br /> NO APAGUE EL DISPOSITIVO!<br /> "
+"Espere unos minutos antes de intentar reconectarse. Posiblemente sea "
+"necesario que vuelva a renovar la dirección de su computadora para poder "
+"acceder al dispositivo nuevamente, dependiendo de su configuración."
 
 #.  (%s available)
 #: i18n/english/luasrc/i18n/admin-core.en.lua:409
 msgid "admin_upgrade_spaceavail"
 msgstr ""
+"<span class=\"translation-space\"> </span>\n"
+"(%s disponible)"
 
 #. It appears that you try to flash an image that does not fit into the flash memory, please verify the image file!
 #: i18n/english/luasrc/i18n/admin-core.en.lua:410
 msgid "admin_upgrade_toolarge"
 msgstr ""
+"Aparentemente está intentando flashear con una imágen de firmware que no "
+"entra en la memoria flash de su equipo, por favor verifique el archivo!"
 
 #. Upload image
 #: i18n/english/luasrc/i18n/admin-core.en.lua:411
 msgid "admin_upgrade_upload"
-msgstr ""
+msgstr "Subir imágen"
 
 #. The flash image was uploaded. Below is the checksum and file size listed, compare them with the original file to ensure data integrity.<br /> Click \"Proceed\" below to start the flash procedure.
 #: i18n/english/luasrc/i18n/admin-core.en.lua:412
 msgid "admin_upgrade_uploaded"
 msgstr ""
+"El archivo con la ímagen del firmware ha sido subida. Abajo se encuentra "
+"listado el checksum y el tamaño de archivo, comparelos con el tamaño "
+"original del archivo para asugurarse de la integridad de datos <br /> Haga "
+"clic en \"Proceder\" para iniciar el proceso de flash."
index fd514be..ca0f922 100644 (file)
@@ -3,7 +3,7 @@ msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2009-06-10 03:41+0200\n"
-"PO-Revision-Date: 2009-07-16 03:31+0200\n"
+"PO-Revision-Date: 2009-07-18 07:37+0200\n"
 "Last-Translator: Guillermo Javier Nardoni <guillermo@geryon.com.ar>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "MIME-Version: 1.0\n"
@@ -146,12 +146,12 @@ msgstr "Destino"
 #. Device
 #: i18n/english/luasrc/i18n/default.en.lua:27
 msgid "device"
-msgstr ""
+msgstr "Dispositivo"
 
 #. Devices
 #: i18n/english/luasrc/i18n/default.en.lua:28
 msgid "devices"
-msgstr ""
+msgstr "Dispositivos"
 
 #. disable
 #: i18n/english/luasrc/i18n/default.en.lua:29
@@ -171,7 +171,7 @@ msgstr "Log Kernel"
 #. <abbr title=\"Domain Name System\">DNS</abbr>-Server
 #: i18n/english/luasrc/i18n/default.en.lua:32
 msgid "dnsserver"
-msgstr ""
+msgstr "Servidor <abbr title=\"Domain Name System\">DNS</abbr>"
 
 #. Edit
 #: i18n/english/luasrc/i18n/default.en.lua:33
@@ -206,12 +206,12 @@ msgstr "Filtro"
 #. <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>-Gateway
 #: i18n/english/luasrc/i18n/default.en.lua:39
 msgid "gateway"
-msgstr ""
+msgstr "Puerta de enlace <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>"
 
 #. <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>-Gateway
 #: i18n/english/luasrc/i18n/default.en.lua:40
 msgid "gateway6"
-msgstr ""
+msgstr "Puerta de enlace <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>"
 
 #. General
 #: i18n/english/luasrc/i18n/default.en.lua:41
@@ -221,7 +221,7 @@ msgstr "General"
 #. Hostname
 #: i18n/english/luasrc/i18n/default.en.lua:42
 msgid "hostname"
-msgstr ""
+msgstr "Nombre de host"
 
 #. Install
 #: i18n/english/luasrc/i18n/default.en.lua:43
@@ -241,262 +241,263 @@ msgstr "Interfaz"
 #. Interfaces
 #: i18n/english/luasrc/i18n/default.en.lua:46
 msgid "interfaces"
-msgstr ""
+msgstr "Interfaces"
 
 #. <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>-Address
 #: i18n/english/luasrc/i18n/default.en.lua:47
 msgid "ipaddress"
-msgstr ""
+msgstr "Dirección <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>"
 
 #. <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>-Address
 #: i18n/english/luasrc/i18n/default.en.lua:48
 msgid "ip6address"
-msgstr ""
+msgstr "Dirección <abbr title=\"Internet Protocol Version 6\">IPv6</abbr>"
 
 #. Legend
 #: i18n/english/luasrc/i18n/default.en.lua:49
 msgid "legend"
-msgstr ""
+msgstr "Leyenda"
 
 #. Library
 #: i18n/english/luasrc/i18n/default.en.lua:50
 msgid "library"
-msgstr ""
+msgstr "Biblioteca"
 
 #. Logout
 #: i18n/english/luasrc/i18n/default.en.lua:51
 msgid "logout"
-msgstr ""
+msgstr "Cerrar sesión"
 
 #. Key
 #: i18n/english/luasrc/i18n/default.en.lua:52
 msgid "key"
-msgstr ""
+msgstr "Llave"
 
 #. Language
 #: i18n/english/luasrc/i18n/default.en.lua:53
 msgid "language"
-msgstr ""
+msgstr "Lenguaje"
 
 #. Limit
 #: i18n/english/luasrc/i18n/default.en.lua:54
 msgid "limit"
-msgstr ""
+msgstr "Límite"
 
 #. Load
 #: i18n/english/luasrc/i18n/default.en.lua:55
 msgid "load"
-msgstr ""
+msgstr "Carga"
 
 #. Login
 #: i18n/english/luasrc/i18n/default.en.lua:56
 msgid "login"
-msgstr ""
+msgstr "Iniciar sesión"
 
 #. <abbr title=\"Media Access Control\">MAC</abbr>-Address
 #: i18n/english/luasrc/i18n/default.en.lua:57
 msgid "macaddress"
-msgstr ""
+msgstr "Dirección <abbr title=\"Media Access Control\">MAC</abbr>"
 
 #. see &#39;%s&#39; manpage
 #: i18n/english/luasrc/i18n/default.en.lua:58
 msgid "manpage"
-msgstr ""
+msgstr "ver las páginas de man de &amp;#39;%s&amp;#39;"
 
 #. Metric
 #: i18n/english/luasrc/i18n/default.en.lua:59
 msgid "metric"
-msgstr ""
+msgstr "Métrica"
 
 #. Mode
 #: i18n/english/luasrc/i18n/default.en.lua:60
 msgid "mode"
-msgstr ""
+msgstr "Modo"
 
 #. Name
 #: i18n/english/luasrc/i18n/default.en.lua:61
 msgid "name"
-msgstr ""
+msgstr "Nombre"
 
 #. <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>-Netmask
 #: i18n/english/luasrc/i18n/default.en.lua:62
 msgid "netmask"
-msgstr ""
+msgstr "Máscara de red <abbr title=\"Internet Protocol Version 4\">IPv4</abbr>"
 
 #. Network
 #: i18n/english/luasrc/i18n/default.en.lua:63
 msgid "network"
-msgstr ""
+msgstr "Red"
 
 #. Networks
 #: i18n/english/luasrc/i18n/default.en.lua:64
 msgid "networks"
-msgstr ""
+msgstr "Redes"
 
 #. none
 #: i18n/english/luasrc/i18n/default.en.lua:65
 msgid "none"
-msgstr ""
+msgstr "ninguno"
 
 #. not installed
 #: i18n/english/luasrc/i18n/default.en.lua:66
 msgid "notinstalled"
-msgstr ""
+msgstr "no instalado"
 
 #. OK
 #: i18n/english/luasrc/i18n/default.en.lua:67
 msgid "ok"
-msgstr ""
+msgstr "Aceptar"
 
 #. Options
 #: i18n/english/luasrc/i18n/default.en.lua:68
 msgid "options"
-msgstr ""
+msgstr "Opciones"
 
 #. Overview
 #: i18n/english/luasrc/i18n/default.en.lua:69
 msgid "overview"
-msgstr ""
+msgstr "Descripción general"
 
 #. Package Manager
 #: i18n/english/luasrc/i18n/default.en.lua:70
 msgid "packagemanager"
-msgstr ""
+msgstr "Gestor de Paquetes"
 
 #. Password
 #: i18n/english/luasrc/i18n/default.en.lua:71
 msgid "password"
-msgstr ""
+msgstr "Contraseña"
 
 #. Path
 #: i18n/english/luasrc/i18n/default.en.lua:72
 msgid "path"
-msgstr ""
+msgstr "Ruta (path)"
 
 #. Port
 #: i18n/english/luasrc/i18n/default.en.lua:73
 msgid "port"
-msgstr ""
+msgstr "Puerto"
 
 #. Ports
 #: i18n/english/luasrc/i18n/default.en.lua:74
 msgid "ports"
-msgstr ""
+msgstr "Puertos"
 
 #. Proceed
 #: i18n/english/luasrc/i18n/default.en.lua:75
 msgid "proceed"
-msgstr ""
+msgstr "Proceda"
 
 #. Protocol
 #: i18n/english/luasrc/i18n/default.en.lua:76
 msgid "protocol"
-msgstr ""
+msgstr "Protocolo"
 
 #. Reboot
 #: i18n/english/luasrc/i18n/default.en.lua:77
 msgid "reboot"
-msgstr ""
+msgstr "Reiniciar"
 
 #. Reset
 #: i18n/english/luasrc/i18n/default.en.lua:78
 msgid "reset"
-msgstr ""
+msgstr "Resetear"
 
 #. Revert
 #: i18n/english/luasrc/i18n/default.en.lua:79
 msgid "revert"
-msgstr ""
+msgstr "Revertir"
 
 #. Save
 #: i18n/english/luasrc/i18n/default.en.lua:80
 msgid "save"
-msgstr ""
+msgstr "Guardar"
 
 #. Save &amp; Apply
 #: i18n/english/luasrc/i18n/default.en.lua:81
 msgid "saveapply"
-msgstr ""
+msgstr "Guardar &amp;amp; Aplicar"
 
 #. Scan
 #: i18n/english/luasrc/i18n/default.en.lua:82
 msgid "scan"
-msgstr ""
+msgstr "Escanear"
 
 #. Service
 #: i18n/english/luasrc/i18n/default.en.lua:83
 msgid "service"
-msgstr ""
+msgstr "Servicio"
 
 #. Services
 #: i18n/english/luasrc/i18n/default.en.lua:84
 msgid "services"
-msgstr ""
+msgstr "Servicios"
 
 #. Settings
 #: i18n/english/luasrc/i18n/default.en.lua:85
 msgid "settings"
-msgstr ""
+msgstr "Configuraciones"
 
 #. Size
 #: i18n/english/luasrc/i18n/default.en.lua:86
 msgid "size"
-msgstr ""
+msgstr "Tamaño"
 
 #. Source
 #: i18n/english/luasrc/i18n/default.en.lua:87
 msgid "source"
-msgstr ""
+msgstr "Origen"
 
 #. Start
 #: i18n/english/luasrc/i18n/default.en.lua:88
 msgid "start"
-msgstr ""
+msgstr "Iniciar"
 
 #. static
 #: i18n/english/luasrc/i18n/default.en.lua:89
 msgid "static"
-msgstr ""
+msgstr "estático"
 
 #. Status
 #: i18n/english/luasrc/i18n/default.en.lua:90
 msgid "status"
-msgstr ""
+msgstr "Estado"
 
 #. Statistics
 #: i18n/english/luasrc/i18n/default.en.lua:91
 msgid "statistics"
-msgstr ""
+msgstr "Estadísticas"
 
 #. Submit
 #: i18n/english/luasrc/i18n/default.en.lua:92
 msgid "submit"
-msgstr ""
+msgstr "Enviar"
 
 #. System Log
 #: i18n/english/luasrc/i18n/default.en.lua:93
 msgid "syslog"
-msgstr ""
+msgstr "Registro del Sistema"
 
 #. System
 #: i18n/english/luasrc/i18n/default.en.lua:94
 msgid "system"
-msgstr ""
+msgstr "Sistema"
 
+# Target = Meta --> Objetivo --> Destino?
 #. Target
 #: i18n/english/luasrc/i18n/default.en.lua:95
 msgid "target"
-msgstr ""
+msgstr "Destino"
 
 #. Timezone
 #: i18n/english/luasrc/i18n/default.en.lua:96
 msgid "timezone"
-msgstr ""
+msgstr "Zona horaria"
 
 #. Type
 #: i18n/english/luasrc/i18n/default.en.lua:97
 msgid "type"
-msgstr ""
+msgstr "Tipo"
 
 #. Unknown Error
 #: i18n/english/luasrc/i18n/default.en.lua:98
index 1cdf15b..e985616 100644 (file)
@@ -3,8 +3,8 @@ msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2009-06-10 03:41+0200\n"
-"PO-Revision-Date: 2009-07-09 01:09+0200\n"
-"Last-Translator: Stefan Pirwitz <i18n@freifunk-bno.de>\n"
+"PO-Revision-Date: 2009-07-18 07:15+0200\n"
+"Last-Translator: Guillermo Javier Nardoni <guillermo@geryon.com.ar>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
@@ -20,6 +20,8 @@ msgstr "Hola y bienvenido a la red de"
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:2
 msgid "ff_public1"
 msgstr ""
+"Somos una iniciativa que pretende crear red libre, independiente y abierta "
+"utilizando tecnología de conexión inalámbrica."
 
 #. This is the access point
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:3
@@ -34,7 +36,7 @@ msgstr "Se encuentra administrado por"
 #. You can find further information about the global Freifunk initiative at
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:5
 msgid "ff_public4"
-msgstr ""
+msgstr "Puede obtener información acrca de la iniciativaglobal Freifunk en"
 
 #. If you are interested in our project then contact the local community
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:6
@@ -47,6 +49,8 @@ msgstr ""
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:7
 msgid "ff_public6"
 msgstr ""
+"El acceso a Internet depende de condiciones técnicas y organizacionales y "
+"puede o no funcionar para usted."
 
 #. Location
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:8
@@ -61,7 +65,7 @@ msgstr "E-Mail"
 #. You really should provide your address here!
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:10
 msgid "ff_mail1"
-msgstr ""
+msgstr "Usted realmente debe proporcionar su dirección aquí!"
 
 #. Nickname
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:11
@@ -76,12 +80,12 @@ msgstr "Nombre completo"
 #. Node
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:13
 msgid "ff_node"
-msgstr ""
+msgstr "Nodo"
 
 #. Notice
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:14
 msgid "ff_note"
-msgstr ""
+msgstr "Aviso"
 
 #. Phone
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:15
@@ -91,22 +95,22 @@ msgstr "Teléfono"
 #. Memory
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:16
 msgid "ff_ram"
-msgstr ""
+msgstr "Memoria"
 
 #. Free
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:17
 msgid "ff_free"
-msgstr ""
+msgstr "Libre"
 
 #. Buffers
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:18
 msgid "ff_buffers"
-msgstr ""
+msgstr "Buffers"
 
 #. Cached
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:19
 msgid "ff_cached"
-msgstr ""
+msgstr "En caché"
 
 #. Total
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:20
@@ -116,23 +120,23 @@ msgstr "Total"
 #. Coordinates
 #: modules/freifunk/luasrc/i18n/freifunk.en.lua:21
 msgid "ff_geocoord"
-msgstr "Coodenadas"
+msgstr "Coordenadas"
 
 #. Client-Splash
 msgid "ff_splash"
-msgstr ""
+msgstr "Client-Splash"
 
 #. Active Clients
 msgid "ff_splash_clients"
-msgstr ""
+msgstr "Clientes activos"
 
 #. Hostname
 msgid "ff_splash_hostname"
-msgstr ""
+msgstr "Nombre de host"
 
 #. IP Address
 msgid "ff_splash_ip"
-msgstr ""
+msgstr "Dirección IP"
 
 #. MAC Address
 msgid "ff_splash_mac"
@@ -140,11 +144,11 @@ msgstr "Dirección MAC"
 
 #. Time remaining
 msgid "ff_splash_timeleft"
-msgstr ""
+msgstr "Tiempo restante"
 
 #. Outgoing traffic
 msgid "ff_splash_traffic"
-msgstr ""
+msgstr "Tráfico saliente"
 
 #. Policy
 msgid "ff_splash_policy"
@@ -152,7 +156,7 @@ msgstr "Política"
 
 #. unknown
 msgid "ff_splash_unknown"
-msgstr ""
+msgstr "desconocido"
 
 #. expired
 msgid "ff_splash_expired"
@@ -160,19 +164,19 @@ msgstr "expirado"
 
 #. whitelisted
 msgid "ff_splash_whitelisted"
-msgstr ""
+msgstr "en lista blanca"
 
 #. splashed
 msgid "ff_splash_splashed"
-msgstr ""
+msgstr "salpicado"
 
 #. blacklisted
 msgid "ff_splash_blacklisted"
-msgstr ""
+msgstr "en lista negra"
 
 #. temporarily blocked
 msgid "ff_splash_tempblock"
-msgstr "Tiempo de bloqueo"
+msgstr "bloqueado temporalmente"
 
 #. No clients connected
 msgid "ff_splash_noclients"
@@ -185,18 +189,21 @@ msgstr "Bloqueo de P2P"
 #. P2P-Block is a greylisting mechanism to block various peer-to-peer protocols for non-whitelisted clients.
 msgid "ff_p2pblock_desc"
 msgstr ""
+"El Bloqueo de P2P es un mecanismo que implementa una lista gris "
+"(greylisting) para bloquear varios protocolos peer-to-peer para los clientes "
+"que no se encuentren en la lista blanca (whitelisted)"
 
 #. Enable P2P-Block
 msgid "ff_p2pblock_enabled"
-msgstr ""
+msgstr "Activar bloqueo P2P"
 
 #. Portrange
 msgid "ff_p2pblock_portrange"
-msgstr ""
+msgstr "Rango de puertos"
 
 #. Block Time
 msgid "ff_p2pblock_blocktime"
-msgstr ""
+msgstr "Tiempo de bloqueo"
 
 #. seconds
 msgid "ff_p2pblock_blocktime_desc"
@@ -204,7 +211,7 @@ msgstr "segundos"
 
 #. Whitelisted IPs
 msgid "ff_p2pblock_whitelist"
-msgstr ""
+msgstr "IPs en la lista blanca"
 
 #. Layer7-Protokolle
 msgid "ff_p2pblock_layer7"
@@ -212,4 +219,4 @@ msgstr "Protocolo Layer7"
 
 #. IP-P2P
 msgid "ff_p2pblock_ipp2p"
-msgstr ""
+msgstr "IP-P2P"
index b303f0f..ea0bea9 100644 (file)
-#, fuzzy
 msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2009-06-10 03:41+0200\n"
-"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
-"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"PO-Revision-Date: 2009-07-20 07:14+0200\n"
+"Last-Translator: Guillermo Javier Nardoni <guillermo@geryon.com.ar>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Translate Toolkit 1.1.1\n"
+"X-Generator: Pootle 1.1.0\n"
 
 #. Port forwarding
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:1
 msgid "fw_portfw"
-msgstr ""
+msgstr "Reenvío de puerto"
 
 #. Traffic Redirection
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:2
 msgid "fw_redirect"
-msgstr ""
+msgstr "Redirección de tráfico"
 
 #. Traffic redirection allows you to change the destination address of forwarded packets.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:3
 msgid "fw_redirect_desc"
 msgstr ""
+"La redirección de tráfico permite cambiar la dirección de destino de los "
+"paquetes reenviados."
 
 #. Zone-to-Zone traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:4
 msgid "fw_forwarding"
-msgstr ""
+msgstr "Tráfico Zona-a-Zona"
 
 #. Firewall
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:5
 msgid "fw_fw"
-msgstr ""
+msgstr "Corta fuego"
 
 #. Zone
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:6
 msgid "fw_zone"
-msgstr ""
+msgstr "Zona"
 
 #. Zones
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:7
 msgid "fw_zones"
-msgstr ""
+msgstr "Zonas"
 
 #. Custom forwarding
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:8
 msgid "fw_custfwd"
-msgstr ""
+msgstr "Renvío personalizado"
 
 #. The firewall creates zones over your network interfaces to control network traffic flow.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:9
 msgid "fw_fw1"
 msgstr ""
+"El corta fuego crea zonas sobre sus interfaces de red para controlar el "
+"flujo del tráfico."
 
 #. Advanced Rules
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:10
 msgid "firewall_rule"
-msgstr ""
+msgstr "Reglas avanzadas"
 
 #. Advanced rules let you customize the firewall to your needs. Only new connections will be matched. Packets belonging to already open connections are automatically allowed to pass the firewall.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:11
 msgid "firewall_rule_desc"
 msgstr ""
+"Las reglas avanzadas le permite personalizar el corta fuego según sus "
+"necesidades. Sólamente las nuevas conexiones serán afectadas por las reglas. "
+"Los paquetes pertenecientes a conexiones ya abierta, se les permite el "
+"libre paso por el corta fuego."
 
 #. Input Zone
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:12
 msgid "firewall_rule_src"
-msgstr ""
+msgstr "Zona de entrada"
 
 #. Output Zone
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:13
 msgid "firewall_rule_dest"
-msgstr ""
+msgstr "Zona de salida"
 
 #. Source address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:14
 msgid "firewall_rule_srcip"
-msgstr ""
+msgstr "Dirección de origen"
 
 #. Destination address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:15
 msgid "firewall_rule_destip"
-msgstr ""
+msgstr "Dirección de destino"
 
 #. Source MAC-Address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:16
 msgid "firewall_rule_srcmac"
-msgstr ""
+msgstr "Dirección MAC de origen"
 
 #. Source port
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:17
 msgid "firewall_rule_srcport"
-msgstr ""
+msgstr "Puerto de origen"
 
 #. Destination port
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:18
 msgid "firewall_rule_destport"
-msgstr ""
+msgstr "Puerto de destino"
 
 #. Action
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:19
 msgid "firewall_rule_target"
-msgstr ""
+msgstr "Acción"
 
 #. accept
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:20
 msgid "fw_accept"
-msgstr ""
+msgstr "aceptar"
 
 #. reject
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:21
 msgid "fw_reject"
-msgstr ""
+msgstr "desechar"
 
 #. drop
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:22
 msgid "fw_drop"
-msgstr ""
+msgstr "rechazar"
 
 #. Source
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:23
 msgid "fw_src"
-msgstr ""
+msgstr "Origen"
 
 #. Destination
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:24
 msgid "fw_dest"
-msgstr ""
+msgstr "Destino"
 
 #. Traffic Control
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:25
 msgid "fw_traffic"
-msgstr ""
+msgstr "Control de tráfico"
 
 #. MSS Clamping
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:26
 msgid "fw_mtufix"
-msgstr ""
+msgstr "MSS Clamping"
 
 #. Drop invalid packets
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:27
 msgid "fw_dropinvalid"
-msgstr ""
+msgstr "Rechazar paquetes inválidos"
 
 #. Port forwarding allows to provide network services in the internal network to an external network.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:28
 msgid "fw_portfw1"
 msgstr ""
+"El reenvío de puerto permite proveer servicios de red en una red interna a "
+"una red externa (por ejemplo Internet)"
 
 #. External Zone
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:29
 msgid "firewall_redirect_src_desc"
-msgstr ""
+msgstr "Zona Externa"
 
 #. External port
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:30
 msgid "firewall_redirect_srcdport"
-msgstr ""
+msgstr "Puerto externo"
 
 #. port or range as first-last
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:31
 msgid "firewall_redirect_srcdport_desc"
-msgstr ""
+msgstr "puerto o rango de puertos (primero-último)"
 
 #. Source address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:32
 msgid "firewall_redirect_srcip"
-msgstr ""
+msgstr "Dirección de Origen"
 
 #. Source MAC
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:33
 msgid "firewall_redirect_srcmac"
-msgstr ""
+msgstr "MAC de Origen"
 
 #. Internal address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:34
 msgid "firewall_redirect_destip"
-msgstr ""
+msgstr "Dirección interna"
 
 #. IP-Address
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:35
 msgid "firewall_redirect_destip_desc"
-msgstr ""
+msgstr "Dirección IP"
 
 #. Internal port (optional)
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:36
 msgid "firewall_redirect_destport"
-msgstr ""
+msgstr "Puerto interno (opcional)"
 
 #. port or range as first-last
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:37
 msgid "firewall_redirect_destport_desc"
-msgstr ""
+msgstr "puerto o rango de puertos (primero-último)"
 
 #. Here you can specify which network traffic is allowed to flow between network zones. Only new connections will be matched. Packets belonging to already open connections are automatically allowed to pass the firewall. If you experience occasional connection problems try enabling MSS Clamping otherwise disable it for performance reasons.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:38
 msgid "fw_forwarding1"
 msgstr ""
+"Aquí puede especificar qué tráfico de red is permitido, discho tráfico "
+"fluirá entre las zonas de red definidas. Sólamente las nuevas conexiones "
+"serán aplicadas por las reglas. Los paquetes pertenecientes a conexiones ya "
+"abierta se les permitirá el paso sobre el corta fuego. Si experimenta "
+"ocacionalmente problemas de conexión, intente activar MSS Clamping de otra "
+"forma, deshabilitelo para mejorar considerablemente la performance."
 
 #. Input
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:39
 msgid "firewall_forwarding_src"
-msgstr ""
+msgstr "Entrada"
 
 #. Output
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:40
 msgid "firewall_forwarding_dest"
-msgstr ""
+msgstr "Salida"
 
 #. Defaults
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:41
 msgid "firewall_defaults"
-msgstr ""
+msgstr "De fábrica"
 
 #. These are the default settings that are used if no other rules match.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:42
 msgid "firewall_defaults_desc"
 msgstr ""
+"Estos son los valores por defecto que son usados si no hay otra regla a "
+"aplicar."
 
 #. SYN-flood protection
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:43
 msgid "firewall_defaults_synflood"
-msgstr ""
+msgstr "Protección por exceso de SYN"
 
 #. Incoming Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:44
 msgid "firewall_defaults_input"
-msgstr ""
+msgstr "Tráfico entrante"
 
 #. Outgoing Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:45
 msgid "firewall_defaults_output"
-msgstr ""
+msgstr "Tráfico saliente"
 
 #. Forwarded Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:46
 msgid "firewall_defaults_forward"
-msgstr ""
+msgstr "Tráfico reenviado"
 
 #. Zones part the network interfaces into certain isolated areas to separate network traffic. One or more networks can belong to a zone. The MASQ-flag enables NAT masquerading for all outgoing traffic on this zone.
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:47
 msgid "firewall_zone_desc"
 msgstr ""
+"Las zonas dividen las interfaces de red en varias partes aisladas para "
+"separar el tráfico de red. Una o mas redes pueden pertenecer a una zona. La "
+"bandera MASQ activa el enmascaramiento NAT para todo el tráfico saliente "
+"sobre esa zona."
 
 #. Incoming Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:48
 msgid "firewall_zone_input"
-msgstr ""
+msgstr "Tráfico entrante"
 
 #. Default Policy
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:49
 msgid "firewall_zone_input_desc"
-msgstr ""
+msgstr "Poítica por defecto"
 
 #. Outgoing Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:50
 msgid "firewall_zone_output"
-msgstr ""
+msgstr "Tráfico saliente"
 
 #. Default Policy
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:51
 msgid "firewall_zone_output_desc"
-msgstr ""
+msgstr "Política por defecto"
 
 #. Forwarded Traffic
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:52
 msgid "firewall_zone_forward"
-msgstr ""
+msgstr "Tráfico reenviado"
 
 #. Default Policy
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:53
 msgid "firewall_zone_forward_desc"
-msgstr ""
+msgstr "Política por defecto"
 
 #. MASQ
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:54
 msgid "firewall_zone_masq"
-msgstr ""
+msgstr "MASQ"
 
 #. Networks
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:55
 msgid "firewall_zone_network"
-msgstr ""
+msgstr "Redes"
 
 #. contained networks
 #: applications/luci-fw/luasrc/i18n/luci-fw.en.lua:56
 msgid "firewall_zone_network_desc"
-msgstr ""
+msgstr "redes contenidas"
index 5b63a85..c2577af 100644 (file)
-#, fuzzy
 msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2009-06-10 03:41+0200\n"
-"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
-"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"PO-Revision-Date: 2009-07-20 03:42+0200\n"
+"Last-Translator: Guillermo Javier Nardoni <guillermo@geryon.com.ar>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Translate Toolkit 1.1.1\n"
+"X-Generator: Pootle 1.1.0\n"
 
 #. OLSR Daemon
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:1
 msgid "olsrd"
-msgstr ""
+msgstr "Demonio OLSR"
 
 #. Neighbour IP
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:2
 msgid "olsrd_neighbour_ip"
-msgstr ""
+msgstr "Neighbour IP"
 
 #. Local interface IP
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:3
 msgid "olsrd_local_ip"
-msgstr ""
+msgstr "IP de la interfaz local"
 
 #. Announced network
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:4
 msgid "olsrd_network"
-msgstr ""
+msgstr "Red a anunciar"
 
 #. OLSR gateway
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:5
 msgid "olsrd_gateway"
-msgstr ""
+msgstr "Puerta de enlace OLSR"
 
 #. OLSR node
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:6
 msgid "olsrd_node"
-msgstr ""
+msgstr "Nodo OLSR"
 
 #. Unable to connect to the OLSR daemon!
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:7
 msgid "olsrd_error"
-msgstr ""
+msgstr "No es posible conectar con el demonio de OLSR! "
 
 #. Make sure that OLSRd is running, the &quot;txtinfo&quot; plugin is loaded, configured on port 2006 and accepts connections from &quot;127.0.0.1&quot;.
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:8
 msgid "olsrd_error_desc"
 msgstr ""
+"Asegúrese de que olsrd se está ejecutando, qué el plugin \"txtinfo\" esté "
+"cargado, configurado en el puerto 2006, y acepta conexiones desde 127.0.0.1."
 
 #. OLSR - HNA-Announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:9
 msgid "olsrd_hna"
-msgstr ""
+msgstr "Anuncios HNA de OLSR"
 
 #. OLSR - Plugins
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:10
 msgid "olsrd_plugins"
-msgstr ""
+msgstr "Plugins OLSR"
 
 #. OLSR connections
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:11
 msgid "olsrd_links"
-msgstr ""
+msgstr "Conexiones OLSR"
 
 #. Overview of currently established OLSR connections
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:12
 msgid "olsrd_links_desc"
 msgstr ""
+"Detalle general acerca de las conexiones de OLSR establecidas actualmente."
 
 #. Expected retransmission count
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:13
 msgid "olsrd_links_etx_desc"
-msgstr ""
+msgstr "Contador de retransmisión esperado"
 
 #. Success rate of sent packages
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:14
 msgid "olsrd_links_lq_desc"
-msgstr ""
+msgstr "Tasa de éxito de los paquetes enviados "
 
 #. Success rate of received packages
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:15
 msgid "olsrd_links_nlq_desc"
-msgstr ""
+msgstr "Tasa de éxito de los paquetes recibidos"
 
 #. Known OLSR routes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:16
 msgid "olsrd_routes"
-msgstr ""
+msgstr "Rutas OLSR conocidas"
 
 #. Overview of currently known routes to other OLSR nodes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:17
 msgid "olsrd_routes_desc"
-msgstr ""
+msgstr "Listado de las rutas conocidas en la actualidad a otros nodos de OLSR "
 
 #. Active OLSR nodes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:18
 msgid "olsrd_topology"
-msgstr ""
+msgstr "Nodos OLSR activos"
 
 #. Overview of currently known OLSR nodes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:19
 msgid "olsrd_topology_desc"
-msgstr ""
+msgstr "Listado de nodos actualmente conocido OLSR "
 
 #. Last hop
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:20
 msgid "olsrd_topology_lasthop"
-msgstr ""
+msgstr "Último salto"
 
 #. Active host net announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:21
 msgid "olsrd_hna2"
-msgstr ""
+msgstr "Anuncios activos del host de red"
 
 #. Overview of currently active OLSR host net announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:22
 msgid "olsrd_hna_desc"
-msgstr ""
+msgstr "Listado de los anuncios activos actuales de host de red de OLSR"
 
 #. Active MID announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:23
 msgid "olsrd_mid"
-msgstr ""
+msgstr "Anuncios MID activos"
 
 #. Overview of known multiple interface announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:24
 msgid "olsrd_mid_desc"
-msgstr ""
+msgstr "Listados múltiples de anuncios sobre las internfaces"
 
 #. Secondary OLSR interfaces
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:25
 msgid "olsrd_mid_aliases"
-msgstr ""
+msgstr "Interfaces OLSR secundarias"
 
 #. Freifunk
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:26
 msgid "olsrd_etx_ff"
-msgstr ""
+msgstr "Freifunk"
 
 #. floating point
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:27
 msgid "olsrd_etx_float"
-msgstr ""
+msgstr "punto flotante"
 
 #. fixed point math
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:28
 msgid "olsrd_etx_fpm"
-msgstr ""
+msgstr "punto fijo matemático"
 
 #. General settings
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:29
 msgid "olsrd_olsrd"
-msgstr ""
+msgstr "Configuración general"
 
 #. Start without network
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:30
 msgid "olsrd_olsrd_allownoint"
-msgstr ""
+msgstr "Iniciar sin red activa"
 
 #. Clear screen
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:31
 msgid "olsrd_olsrd_clearscreen"
-msgstr ""
+msgstr "Limpiar pantalla"
 
 #. Debugmode
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:32
 msgid "olsrd_olsrd_debuglevel"
-msgstr ""
+msgstr "Modo Depuración"
 
 #. FIB metric
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:33
 msgid "olsrd_olsrd_fibmetric"
-msgstr ""
+msgstr "FIB metric"
 
 #. Internet protocol
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:34
 msgid "olsrd_olsrd_ipversion"
-msgstr ""
+msgstr "Protocolo de Internet"
 
 #. LQ aging
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:35
 msgid "olsrd_olsrd_linkqualityaging"
-msgstr ""
+msgstr "LQ aging"
 
 #. LQ algorithm
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:36
 msgid "olsrd_olsrd_linkqualityalgorithm"
-msgstr ""
+msgstr "LQ algorithm"
 
 #. LQ Dijkstra limit
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:37
 msgid "olsrd_olsrd_linkqualitydijkstralimit"
-msgstr ""
+msgstr "LQ Dijkstra limit"
 
 #. LQ fisheye
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:38
 msgid "olsrd_olsrd_linkqualityfisheye"
-msgstr ""
+msgstr "LQ fisheye"
 
 #. LQ level
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:39
 msgid "olsrd_olsrd_linkqualitylevel"
-msgstr ""
+msgstr "LQ level"
 
 #. MPR selection
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:40
 msgid "olsrd_olsrd_linkqualitylevel_1"
-msgstr ""
+msgstr "Selección del MPR"
 
 #. MPR selection and routing
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:41
 msgid "olsrd_olsrd_linkqualitylevel_2"
-msgstr ""
+msgstr "Selección del MPR y ruteo"
 
 #. LQ window size
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:42
 msgid "olsrd_olsrd_linkqualitywinsize"
-msgstr ""
+msgstr "Tamaño de la venta del LQ"
 
 #. MPR coverage
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:43
 msgid "olsrd_olsrd_mprcoverage"
-msgstr ""
+msgstr "Cobertura MPR"
 
 #. Pollrate
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:44
 msgid "olsrd_olsrd_pollrate"
-msgstr ""
+msgstr "Pollrate"
 
 #. TC redundancy
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:45
 msgid "olsrd_olsrd_tcredundancy"
 msgstr ""
+"Redundancia <abbr title=\"Topology Control - Control de la "
+"topología\">TC</abbr>"
 
 #. MPR selectors
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:46
 msgid "olsrd_olsrd_tcredundancy_0"
-msgstr ""
+msgstr "Selectores MPR"
 
 #. MPR selectors and MPR
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:47
 msgid "olsrd_olsrd_tcredundancy_1"
-msgstr ""
+msgstr "Selectores MPR y MPR"
 
 #. all neighbours
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:48
 msgid "olsrd_olsrd_tcredundancy_2"
-msgstr ""
+msgstr "todos los vecinos"
 
 #. Use hysteresis
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:49
 msgid "olsrd_olsrd_usehysteresis"
-msgstr ""
+msgstr "Uso de histéresis"
 
 #. Willingness
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:50
 msgid "olsrd_olsrd_willingness"
-msgstr ""
+msgstr "<abbr title=\"Willingness\">Voluntad</abbr>"
 
 #. Hello interval
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:51
 msgid "olsrd_interface_hellointerval"
-msgstr ""
+msgstr "Intervalo de \"Hola\""
 
 #. Hello validity time
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:52
 msgid "olsrd_interface_hellovaliditytime"
-msgstr ""
+msgstr "Tiempo de validez de \"Hola\""
 
 #. HNA interval
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:53
 msgid "olsrd_interface_hnainterval"
-msgstr ""
+msgstr "Intervalo HNA"
 
 #. HNA validity time
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:54
 msgid "olsrd_interface_hnavaliditytime"
-msgstr ""
+msgstr "Timpo de validez de HNA"
 
 #. IPv4 broadcast
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:55
 msgid "olsrd_interface_ip4broadcast"
-msgstr ""
+msgstr "Dirección de transmisión IPv4"
 
 #. MID interval
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:56
 msgid "olsrd_interface_midinterval"
-msgstr ""
+msgstr "Intervalo de MID"
 
 #. MID validity time
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:57
 msgid "olsrd_interface_midvaliditytime"
-msgstr ""
+msgstr "Tiempo de validez de MID"
 
 #. TC interval
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:58
 msgid "olsrd_interface_tcinterval"
-msgstr ""
+msgstr "Intervalo TC"
 
 #. TC validity time
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:59
 msgid "olsrd_interface_tcvaliditytime"
-msgstr ""
+msgstr "Timpo de validez de TC"
 
 #. IPv6 address type
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:60
 msgid "olsrd_interface_ip6addrtype"
-msgstr ""
+msgstr "Tipo de dirección IPv6"
 
 #. IPC settings
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:61
 msgid "olsrd_ipcconnect"
-msgstr ""
+msgstr "Configuraciónes del IPC"
 
 #. IPC connections enable you to remote-control the local OLSRd instance using external programs
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:62
 msgid "olsrd_ipcconnect_desc"
 msgstr ""
+"Las conexión de IPC le permite controlar de forma remota la instancia de "
+"OLSR (OLSRd) utilizando herramientas y programas externos"
 
 #. Allowed host addresses
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:63
 msgid "olsrd_ipcconnect_host"
-msgstr ""
+msgstr "Direcciones de host permitidas"
 
 #. Multiple separated by spaces
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:64
 msgid "olsrd_ipcconnect_host_desc"
-msgstr ""
+msgstr "Separar con espacios en caso de ser múltiples"
 
 #. Maxmimum connection count
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:65
 msgid "olsrd_ipcconnect_maxconnections"
-msgstr ""
+msgstr "Cuenta máxima de conexión"
 
 #. Set to 0 to disable IPC
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:66
 msgid "olsrd_ipcconnect_maxconnections_desc"
-msgstr ""
+msgstr "Especifique \"0\" para desactivar IPC"
 
 #. Allowed subnets
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:67
 msgid "olsrd_ipcconnect_net"
-msgstr ""
+msgstr "Subredes permitidas"
 
 #. Address Mask; multiple separated by space
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:68
 msgid "olsrd_ipcconnect_net_desc"
 msgstr ""
+"Dirección de máscara de red, en caso de ser mas de una, sepárelas mediante "
+"un espacio"
 
 #. IPv4 HNA announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:69
 msgid "olsrd_hna4"
-msgstr ""
+msgstr "Anuncios IPv4 de HNA"
 
 #. Hna4 entries allow you to propagate local IPv4 host- and network-routes into the mesh network
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:70
 msgid "olsrd_hna4_desc"
 msgstr ""
+"Las entradas de Hna4 permite propagar las rutas locales de host y red dentro "
+"de la red en malla."
 
 #. Network address
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:71
 msgid "olsrd_hna4_netaddr"
-msgstr ""
+msgstr "Direccíon de red"
 
 #. IPv4 address
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:72
 msgid "olsrd_hna4_netaddr_desc"
-msgstr ""
+msgstr "Dirección IPv4"
 
 #. Netmask
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:73
 msgid "olsrd_hna4_netmask"
-msgstr ""
+msgstr "Máscara de red"
 
 #. IPv4 address
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:74
 msgid "olsrd_hna4_netmask_desc"
-msgstr ""
+msgstr "Dirección IPv4"
 
 #. IPv6 HNA announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:75
 msgid "olsrd_hna6"
-msgstr ""
+msgstr "Anuncios IPV6 de HNA"
 
 #. Hna6 entries allow you to propagate local IPv6 host- and network-routes into the mesh network
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:76
 msgid "olsrd_hna6_desc"
 msgstr ""
+"Las entradas de Hna6 permite propagar las rutas locales de host y red dentro "
+"de la red en malla."
 
 #. Network address
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:77
 msgid "olsrd_hna6_netaddr"
-msgstr ""
+msgstr "Dirección de Red"
 
 #. IPv6 address
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:78
 msgid "olsrd_hna6_netaddr_desc"
-msgstr ""
+msgstr "Dirección IPv6"
 
 #. Prefix
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:79
 msgid "olsrd_hna6_prefix"
-msgstr ""
+msgstr "Prefijo"
 
 #. IPv6 prefix
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:80
 msgid "olsrd_hna6_prefix_desc"
-msgstr ""
+msgstr "Prefijo IPv6"
 
 #. Plugin configuration
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:81
 msgid "olsrd_loadplugin"
-msgstr ""
+msgstr "Configuración del plugin"
 
 #. Enable plugin
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:82
 msgid "olsrd_loadplugin_ignore"
-msgstr ""
+msgstr "Activar plugin"
 
 #. Library
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:83
 msgid "olsrd_loadplugin_library"
-msgstr ""
+msgstr "Librería"
 
 #. Allow connections from this hosts
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:84
 msgid "olsrd_loadplugin_accept"
-msgstr ""
+msgstr "Permitir conexiones desde este host"
 
 #. Ping test addresses
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:85
 msgid "olsrd_loadplugin_ping"
-msgstr ""
+msgstr "Direcciones para el testeo con \"ping\""
 
 #. Interval
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:86
 msgid "olsrd_loadplugin_interval"
-msgstr ""
+msgstr "Intervalo"
 
 #. HNA announcements
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:87
 msgid "olsrd_loadplugin_hna"
-msgstr ""
+msgstr "Anuncios HNA"
 
 #. Format: IP-Address Netmask / OLSR will announce this network once it is reachable
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:88
 msgid "olsrd_loadplugin_hna_desc"
 msgstr ""
+"Formato: Dirección IP - Máscara de Red / OLSR anunciará esta red una vez que "
+"sea alcanzada"
 
 #. Alternative \"hosts\" file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:89
 msgid "olsrd_loadplugin_addhosts"
-msgstr ""
+msgstr "Archivo alternativo de \"hosts\""
 
 #. The contents of this file will be appended to the autogenerated \"hosts\" file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:90
 msgid "olsrd_loadplugin_addhosts_desc"
 msgstr ""
+"El contenido de este archivo será agregado al archivo de \"hosts\" "
+"autogenerado"
 
 #. DNS server
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:91
 msgid "olsrd_loadplugin_dnsserver"
-msgstr ""
+msgstr "Servidor DNS"
 
 #. Alternative hostnames
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:92
 msgid "olsrd_loadplugin_hosts"
-msgstr ""
+msgstr "Nombres de host alternativo"
 
 #. Format: Interface-IP Hostname
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:93
 msgid "olsrd_loadplugin_hosts_desc"
-msgstr ""
+msgstr "Formato: Interfaz-IP nombre de host"
 
 #. Path to the \"hosts\" file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:94
 msgid "olsrd_loadplugin_hostsfile"
-msgstr ""
+msgstr "Ruta al archivo de \"hosts\""
 
 #. Latitude
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:95
 msgid "olsrd_loadplugin_lat"
-msgstr ""
+msgstr "Latitud"
 
 #. Output file for coordinates
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:96
 msgid "olsrd_loadplugin_latlonfile"
-msgstr ""
+msgstr "Archivo de salida para las coordenadas"
 
 #. OLSR will write received coordinates of other nodes to this file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:97
 msgid "olsrd_loadplugin_latlonfile_desc"
-msgstr ""
+msgstr "OLSR escribirá las coordenadas recibidas de otros nodos a este archivo"
 
 #. Input file for coordinates
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:98
 msgid "olsrd_loadplugin_latloninfile"
-msgstr ""
+msgstr "Archivo de entrada para las coordenadas"
 
 #. OLSR periodically checks this file for new coordinates and propagates them
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:99
 msgid "olsrd_loadplugin_latloninfile_desc"
 msgstr ""
+"OLSR periodicamente chquea este archivo en búsqueda de nuevas coordenadas "
+"para luego propagarlas"
 
 #. Longitude
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:100
 msgid "olsrd_loadplugin_lon"
-msgstr ""
+msgstr "Longitud"
 
 #. Hostnames
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:101
 msgid "olsrd_loadplugin_name"
-msgstr ""
+msgstr "Nombres de host"
 
 #. Command for name changes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:102
 msgid "olsrd_loadplugin_namechangescript"
-msgstr ""
+msgstr "Comando para los cambios de nombre"
 
 #. OLSR executes this command once entries in the \"hosts\" are changed
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:103
 msgid "olsrd_loadplugin_namechangescript_desc"
 msgstr ""
+"OLSR ejecuta este comando una vez que las entradas en el archivo de \"hosts\" "
+"hayan cambiado"
 
 #. Path to the \"resolv\" file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:104
 msgid "olsrd_loadplugin_resolvfile"
-msgstr ""
+msgstr "Ruta al archivo \"resolv\""
 
 #. Command for service changes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:105
 msgid "olsrd_loadplugin_serviceschangescript"
-msgstr ""
+msgstr "Comando para los cambios de servicio"
 
 #. OLSR excutes this command once new service announcements are received
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:106
 msgid "olsrd_loadplugin_serviceschangescript_desc"
 msgstr ""
+"OLSR ejecuta este comando una vez que son recibidos los anuncios de un nuevo "
+"servicio"
 
 #. PID file for SIGHUP signals
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:107
 msgid "olsrd_loadplugin_sighuppidfile"
-msgstr ""
+msgstr "Archivo PID para las señales de SIGHUP"
 
 #. OLSR sends a HUP signal to this PID once the \"hosts\" oder \"resolv\" file is changed
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:108
 msgid "olsrd_loadplugin_sighuppidfile_desc"
 msgstr ""
+"OLSR envía una señal de HUP a este archivo PID cada vez que el archivo "
+"\"hosts\" o \"resolv\" es actualizado"
 
 #. Domain suffix
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:109
 msgid "olsrd_loadplugin_suffix"
-msgstr ""
+msgstr "Sufijo de dominio"
 
 #. Timeout
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:110
 msgid "olsrd_loadplugin_timeout"
-msgstr ""
+msgstr "Tiempo agotado"
 
 #. Name of the BMF interface
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:111
 msgid "olsrd_loadplugin_bmfinterface"
-msgstr ""
+msgstr "Nombre de la interfaz BMF"
 
 #. IP address of the BMF interface
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:112
 msgid "olsrd_loadplugin_bmfinterfaceid"
-msgstr ""
+msgstr "Dirección IP de la interfaz BMF"
 
 #. Redirect local broadcasts
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:113
 msgid "olsrd_loadplugin_dolocalbroadcast"
-msgstr ""
+msgstr "Redireccionar direcciones de transmisiones local"
 
 #. Also redirect broadcasts from OLSR interfaces
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:114
 msgid "olsrd_loadplugin_capturepacketsonolsrinterfaces"
 msgstr ""
+"También redireccionar direcciones de transmisión de las interfaces de OLSR"
 
 #. Propagation mechanism
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:115
 msgid "olsrd_loadplugin_bmfmechanism"
-msgstr ""
+msgstr "Mecanismo de propagación"
 
 #. Number of retransmissions per package
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:116
 msgid "olsrd_loadplugin_broadcastretransmitcount"
-msgstr ""
+msgstr "Número de retransmisión por paquete"
 
 #. Minimum number of neighbours for broadcast redirection
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:117
 msgid "olsrd_loadplugin_fanoutlimit"
-msgstr ""
+msgstr "Número mínimo de vecinos para la redireccionar la transmisión"
 
 #. Non-OLSR interfaces
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:118
 msgid "olsrd_loadplugin_nonolsrif"
-msgstr ""
+msgstr "Interfaces NO OLSR"
 
 #. Used port
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:119
 msgid "olsrd_loadplugin_port"
-msgstr ""
+msgstr "Puerto usado"
 
 #. Allow connections from hosts
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:120
 msgid "olsrd_loadplugin_host"
-msgstr ""
+msgstr "Permitir conexiones desde los host"
 
 #. Allow connections from subnets
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:121
 msgid "olsrd_loadplugin_net"
-msgstr ""
+msgstr "Permitir conexiones desde las subredes"
 
 #. Format: IP-AddresseNetmask
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:122
 msgid "olsrd_loadplugin_net_desc"
-msgstr ""
+msgstr "Formato: Dirección IP-Máscara de red"
 
 #. Used protocols
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:123
 msgid "olsrd_loadplugin_redistribute"
-msgstr ""
+msgstr "Protocolos utilizado"
 
 #. Only export routes to Quagga or to kernel too
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:124
 msgid "olsrd_loadplugin_exportroutes"
-msgstr ""
+msgstr "Only export routes to Quagga or to kernel too"
 
 #. Always prefer local routes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:125
 msgid "olsrd_loadplugin_localpref"
-msgstr ""
+msgstr "Siempre preferir rutas locales"
 
 #. Distance of exported routes
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:126
 msgid "olsrd_loadplugin_distance"
-msgstr ""
+msgstr "Distancia de las rutas exportadas"
 
 #. Key file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:127
 msgid "olsrd_loadplugin_keyfile"
-msgstr ""
+msgstr "Archivo de clave"
 
 #. Watchdog timestamp file
 #: applications/luci-olsr/luasrc/i18n/olsr.en.lua:128
 msgid "olsrd_loadplugin_file"
-msgstr ""
+msgstr "Archivo para el \"sello de tiempo\" de Watchdog"