Jo-Philipp Wich [Mon, 9 Jan 2012 00:04:54 +0000 (00:04 +0000)]
[PATCH] Explicit Cache-Control for lucid.http static content
The Chrome web browser revalidates every resource if no explicit Cache-Control or Expires HTTP/1.1 header is sent. This makes the page loads appear to take a long time on pages with a few external resources, adding 300-500ms
per item. This includes the XHR json responses that set page images, like wireless signal indicators and the like-- the images are revalidated on every XHR response. As an example, the Network -> Interfaces page generates 16
requests to the lucid http server:
Main HTML
cascade.css
xhr.js
tabbg.png
cbi.js
loading.gif
ethernet_disabled.png
reload.png
reset.gif
edit.gif
remove.gif
add.gif
bridge.png
vlan.png
wifi.png
iface_status
Of those, 14 should be pulled from cache but they are all valdiated. The lucid server returns the correct 304 (Not Modified) responses but it delays the apparent page load time because of the backlog it creates at the http
server.
I would suggest setting explicit cache control on all files returned by the lucid http directory dispatcher. The "Expires" header is reportedly more widely supported, however this relies on the clock on the OpenWrt? system
being accurate, which may not be the case. The "Cache-Control: max-age=" allows the server to set a timeout in seconds. I've included a patch that sets revalidate interval to 1 year, which is the value recommended by google.
Reference: http://code.google.com/speed/page-speed/docs/caching.html
Note this could create an issue if there are luci application which are generating files which change that are being served by the lucid http DirectoryPublisher?. I'm not sure if there is anyone doing that. If needed, this can
probably be created as an option to the DirectoryPublisher? config stanza for each vhost.
Finally, this only affects the Google Chrome browser, as both IE9 and Firefox seem to have their own revalidation interval in the absence of explicit cache control which may be based on the last modified time of the resource.
Even in Chrome, this change doesn't take effect until the item is re-served with a 200 HTTP response so Chrome's cache should be cleared after this patch is applied. The patch can be extended to include cache control on 304
responses, but I'd not worry about cluttering the code with it because the problem will solve itself once chrome redownloads the resource.
Jo-Philipp Wich [Sun, 8 Jan 2012 23:39:29 +0000 (23:39 +0000)]
libs/web: remove debugging code
Jo-Philipp Wich [Sun, 8 Jan 2012 23:36:35 +0000 (23:36 +0000)]
libs/web: allow zero-length string literals when parsing datatypes
Jo-Philipp Wich [Sun, 8 Jan 2012 23:33:47 +0000 (23:33 +0000)]
libs/web: introduce recursive expression support for datatypes, introduce "or" and "and" datatypes
The commit adds a recursive parser for datatype expressions which allows nesting of validators,
this allows for complex expressions like "list(or(range(0,65535),'infinite'))" to allow a list of
values which are either integers between 0 and 65535 or the literal string "inifinite".
That change also deprecates combined datatypes like "ipaddr" ["or(ip4addr,ip6addr)"] or
"host" ["or(hostname,ip4addr,ip6addr)"]
Jo-Philipp Wich [Sat, 7 Jan 2012 22:06:02 +0000 (22:06 +0000)]
libs/web: remove neg_ipaddr, neg_ip4addr and neg_network_ip4addr datatypes, can be represented with neg(type)
Jo-Philipp Wich [Sat, 7 Jan 2012 21:55:52 +0000 (21:55 +0000)]
applications/luci-firewall: fix datatype validation for masq src/dest; allow list of negated ucinames, hostnames, ip-ranges or -addresses
Jo-Philipp Wich [Fri, 6 Jan 2012 16:42:02 +0000 (16:42 +0000)]
modules/admin-full: set password of logged in user instead of unconditionally using root, thanks Viktar Palstsiuk <viktar.palstsiuk@promwad.com>
Jo-Philipp Wich [Fri, 6 Jan 2012 16:28:54 +0000 (16:28 +0000)]
modules/admin-full: fix wireless interface removal if not network was assigned to the iface, thanks Viktar Palstsiuk <viktar.palstsiuk@promwad.com>
Translation System [Fri, 6 Jan 2012 13:32:48 +0000 (13:32 +0000)]
Commit from LuCI Translation Portal by user jow.: 74 of 154 messages translated (0 fuzzy).
Translation System [Fri, 6 Jan 2012 13:32:45 +0000 (13:32 +0000)]
Commit from LuCI Translation Portal by user jow.: 6 of 812 messages translated (0 fuzzy).
Jo-Philipp Wich [Thu, 5 Jan 2012 19:21:07 +0000 (19:21 +0000)]
build: only consider directories containing a Makefile, fixes compilation crashes if a file or empty directory exists in modules/, applications/ etc.
Translation System [Sun, 1 Jan 2012 17:33:55 +0000 (17:33 +0000)]
Commit from LuCI Translation Portal by user jow.: 117 of 154 messages translated (0 fuzzy).
Translation System [Sun, 1 Jan 2012 17:33:52 +0000 (17:33 +0000)]
Commit from LuCI Translation Portal by user jow.: 788 of 812 messages translated (0 fuzzy).
Jo-Philipp Wich [Sun, 1 Jan 2012 17:20:16 +0000 (17:20 +0000)]
modules/admin-full: make luci-bwc dlopen() libiwinfo.so instead of lua/iwinfo.so
Jo-Philipp Wich [Sun, 1 Jan 2012 15:51:37 +0000 (15:51 +0000)]
libs/core: remove various uses of global vars in luci.ip
Jo-Philipp Wich [Sun, 1 Jan 2012 15:41:16 +0000 (15:41 +0000)]
themes/openwrt: fix input placeholder color for firefox, add css for internet explorer
Jo-Philipp Wich [Sun, 1 Jan 2012 15:31:25 +0000 (15:31 +0000)]
applications/luci-firewall: fix crash in rule formatting helper when a rule with an /128 ipv6 prefix is encountered
Jo-Philipp Wich [Sun, 1 Jan 2012 14:43:56 +0000 (14:43 +0000)]
modules/admin-full: allow space separated lists of macs in static lease form (#319)
Jo-Philipp Wich [Mon, 26 Dec 2011 16:11:15 +0000 (16:11 +0000)]
protocols/6x4: fix turning off 6ro4 advertising on all interfaces
Translation System [Thu, 22 Dec 2011 19:05:30 +0000 (19:05 +0000)]
Commit from LuCI Translation Portal by user jow.: 116 of 154 messages translated (0 fuzzy).
Jo-Philipp Wich [Wed, 21 Dec 2011 22:41:44 +0000 (22:41 +0000)]
modules/admin-full: fix crypto depends for ad-hoc and static wds modes (#271)
Jo-Philipp Wich [Tue, 20 Dec 2011 19:04:04 +0000 (19:04 +0000)]
modules/admin-core: use luci.model.uci.apply() in service control to restart dependencies of the current config as well
Jo-Philipp Wich [Tue, 20 Dec 2011 19:02:14 +0000 (19:02 +0000)]
libs/core: rework luci.model.uci.apply() to return the commandline as table, suitable for passing to nixio.exec()
Jo-Philipp Wich [Tue, 20 Dec 2011 18:31:47 +0000 (18:31 +0000)]
modules/admin-core: fix apply actions for configs with hyphens or underscore in the name
Jo-Philipp Wich [Tue, 20 Dec 2011 17:52:10 +0000 (17:52 +0000)]
[PATCH] Naive fix for bug #208
For SimpleSection, use the section name (always "1") instead of the
section type in the CBI-like string used to identify the upload. This
allows upload fields to be placed in SimpleSections. The fix changes a
minimal number of lines, but does introduce some unnecessary confusion,
it may or may not be better than a more thorough/invasive fix.
Set the enctype for the form element in the simpleform view to be
multipart/form-data because the default
application/x-www-form-urlencoded does not support input files.
Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
Jo-Philipp Wich [Tue, 20 Dec 2011 17:51:44 +0000 (17:51 +0000)]
libs/web: show input/forward hints in zonelist widget only if bnoth allowany and allowlocal are enabled
Jo-Philipp Wich [Tue, 20 Dec 2011 17:35:50 +0000 (17:35 +0000)]
modules/admin-full: reuse sysupgrade facilities to create backup archive
Jo-Philipp Wich [Tue, 20 Dec 2011 15:24:14 +0000 (15:24 +0000)]
themes: add essential CSS class to other themes as well
Jo-Philipp Wich [Tue, 20 Dec 2011 15:09:38 +0000 (15:09 +0000)]
applications/luci-firewall: fix wrong location of cbi templates
Jo-Philipp Wich [Tue, 20 Dec 2011 03:57:40 +0000 (03:57 +0000)]
libs/web: prevent break between action buttons in tblsection template
Jo-Philipp Wich [Tue, 20 Dec 2011 03:19:13 +0000 (03:19 +0000)]
po: resync firewall translation
Jo-Philipp Wich [Tue, 20 Dec 2011 03:14:54 +0000 (03:14 +0000)]
applications/luci-firewall: use option "name" instead of deprecated "_name", expose "extra" option, add enable/disable toggles for portforwards, snats and rules
Jo-Philipp Wich [Tue, 20 Dec 2011 03:00:17 +0000 (03:00 +0000)]
libs/web: fix placeholder attribute for DynList
Jo-Philipp Wich [Tue, 20 Dec 2011 02:56:03 +0000 (02:56 +0000)]
libs/web: fix undesired autofocus of DynamicList widget
Jo-Philipp Wich [Tue, 20 Dec 2011 02:44:32 +0000 (02:44 +0000)]
libs/web: improve ip6addr datype validation, accept both CIDR and IP/Mask notation
Jo-Philipp Wich [Tue, 20 Dec 2011 00:16:32 +0000 (00:16 +0000)]
po: update firewall translations
Jo-Philipp Wich [Tue, 20 Dec 2011 00:08:07 +0000 (00:08 +0000)]
applications/luci-firewall: make rule descriptions fully translateable
Translation System [Mon, 19 Dec 2011 21:53:30 +0000 (21:53 +0000)]
Commit from LuCI Translation Portal by user jow.: 10 of 222 messages translated (0 fuzzy).
Jo-Philipp Wich [Mon, 19 Dec 2011 21:20:57 +0000 (21:20 +0000)]
themes/openwrt: add some new CSS classes used by firewall ui
Jo-Philipp Wich [Mon, 19 Dec 2011 21:17:33 +0000 (21:17 +0000)]
po: resync firewall translation
Jo-Philipp Wich [Mon, 19 Dec 2011 21:16:31 +0000 (21:16 +0000)]
applications/luci-firewall: complete rework firewall ui
- split zone setup, port forwards, traffic rules and firewall.user
- add quickadd forms for various common rules like port forwards
- add tool class for textual formatting and descriptions of rules
- simplify controller, remove old mini admin remainders
Jo-Philipp Wich [Mon, 19 Dec 2011 20:09:20 +0000 (20:09 +0000)]
libs/web: add "any" option to firewall_zonelist widget
Jo-Philipp Wich [Mon, 19 Dec 2011 18:55:59 +0000 (18:55 +0000)]
libs/web: rework DynamicList widget to support dynamic lists composed of comboboxes
Jo-Philipp Wich [Fri, 16 Dec 2011 06:05:51 +0000 (06:05 +0000)]
libs/web: rework hostname match to not allow arbritary sequences of numbers and dots
Jo-Philipp Wich [Fri, 16 Dec 2011 05:52:24 +0000 (05:52 +0000)]
libs/web: add list(...) datatype for space separated lists of arbritary datatypes
Jo-Philipp Wich [Fri, 16 Dec 2011 02:10:37 +0000 (02:10 +0000)]
[PATCH] Abstract address UNIX sockets not binding properly (by capnbry@gmail.com, #366)
In #274, I stated abstract namespace and autobound abstract namespace datagram UNIX domain sockets work perfectly with nixio. However, I may have jumped the gun on that conclusion. Turns out they work perfectly for only one
concurrent connection.
The problem is that when binding to an abstract address socket, which begins with a NULL byte, nixio strncpy's the name into the sockaddr_un structure, which effectively copies nothing. It then binds to an address of 180 NULLs,
which is completely legal, but obviously you run into problems when a second client tries to bind to the same address.
The rules are as follows ( http://linux.die.net/man/7/unix) for the names:
* If the name is blank, bind() should pass that the addrlen of sizeof(sa_family_t) and Linux will autobind a name that begins with null and is followed by 5 digits.
* If the first character of the name is non-null, the name is a pathname and is null-terminated. addrlen should be sizeof(sockaddr_un), but the length can also be the pathname len + sizeof(sa_family_t) as the value will be
null-terminated by the kernel unix socket driver
* If the first character is null, the address is abstract and the value should not be null-terminated and addrlen is pathname + sizeof(sa_family_t)
The attached patch fixes bind/connect/sendto by shortening the addrlen passed to be pathname len + sizeof(sa_family_t), which generates the correct socket names for all 3 cases above.
It also fixes the address returned by recvfrom, which currently returns a blank string for any abstract address socket (as they begin with a null).
Jo-Philipp Wich [Fri, 16 Dec 2011 01:25:07 +0000 (01:25 +0000)]
applications/luci-firewall: allow negated uci identifiers, hostnames and ip addresses in zone masq src/dest fields
Jo-Philipp Wich [Fri, 16 Dec 2011 01:18:34 +0000 (01:18 +0000)]
libs/web: add missing parts of previous commit
Jo-Philipp Wich [Fri, 16 Dec 2011 01:18:15 +0000 (01:18 +0000)]
libs/web: implement "network" cbi datatype
Translation System [Wed, 14 Dec 2011 15:59:26 +0000 (15:59 +0000)]
Commit from LuCI Translation Portal by user jow.: 60 of 108 messages translated (0 fuzzy).
Translation System [Wed, 14 Dec 2011 15:58:50 +0000 (15:58 +0000)]
Commit from LuCI Translation Portal by user jow.: 8 of 222 messages translated (0 fuzzy).
Jo-Philipp Wich [Wed, 14 Dec 2011 15:48:59 +0000 (15:48 +0000)]
applications/luci-statistics: add iwinfo config
Jo-Philipp Wich [Wed, 14 Dec 2011 15:01:54 +0000 (15:01 +0000)]
libs/web: allow one-character hostnames
Jo-Philipp Wich [Tue, 13 Dec 2011 15:57:32 +0000 (15:57 +0000)]
modules/admin-full: probe for EAP support in wpad/hostapd/wpa_supplicant and offer wpa/wpa2 only if it is present
Jo-Philipp Wich [Tue, 13 Dec 2011 14:06:02 +0000 (14:06 +0000)]
applications/luci-statistics: add iwinfo support to stat-genconfig
Translation System [Mon, 12 Dec 2011 14:43:13 +0000 (14:43 +0000)]
Commit from LuCI Translation Portal by user jow.: 787 of 812 messages translated (0 fuzzy).
Jo-Philipp Wich [Mon, 12 Dec 2011 14:36:25 +0000 (14:36 +0000)]
po: fix swapped german translation of HT40+ and HT40-, thanks Daniel Golle
Jo-Philipp Wich [Mon, 12 Dec 2011 14:13:07 +0000 (14:13 +0000)]
applications/luci-statistics: fix controller (#7344)
Translation System [Sun, 11 Dec 2011 16:25:14 +0000 (16:25 +0000)]
Commit from LuCI Translation Portal by user jow.: 2 of 2 messages translated (0 fuzzy).
Translation System [Sun, 11 Dec 2011 16:25:03 +0000 (16:25 +0000)]
Commit from LuCI Translation Portal by user jow.: 3 of 59 messages translated (0 fuzzy).
Translation System [Sun, 11 Dec 2011 16:25:01 +0000 (16:25 +0000)]
Commit from LuCI Translation Portal by user jow.: 9 of 9 messages translated (0 fuzzy).
Translation System [Sun, 11 Dec 2011 16:24:51 +0000 (16:24 +0000)]
Commit from LuCI Translation Portal by user jow.: 76 of 77 messages translated (0 fuzzy).
Translation System [Sun, 11 Dec 2011 16:21:18 +0000 (16:21 +0000)]
Commit from LuCI Translation Portal by user jow.: 812 of 812 messages translated (0 fuzzy).
Translation System [Fri, 9 Dec 2011 18:43:03 +0000 (18:43 +0000)]
Commit from LuCI Translation Portal by user jow.: 3 of 222 messages translated (0 fuzzy).
Jo-Philipp Wich [Fri, 9 Dec 2011 18:06:38 +0000 (18:06 +0000)]
contrib/package: make luci-app-statistics depend on collectd-mod-iwinfo
Jo-Philipp Wich [Thu, 8 Dec 2011 16:52:45 +0000 (16:52 +0000)]
protocols/core: change vendorclass option to vendorid to match actual OpenWrt implementation
Jo-Philipp Wich [Thu, 8 Dec 2011 03:35:27 +0000 (03:35 +0000)]
modules/admin-full: fix System -> Administration menu if dropbear is not installed
Translation System [Thu, 8 Dec 2011 02:51:11 +0000 (02:51 +0000)]
Commit from LuCI Translation Portal by user jow.: 1 of 222 messages translated (0 fuzzy).
Translation System [Thu, 8 Dec 2011 02:49:22 +0000 (02:49 +0000)]
Commit from LuCI Translation Portal by user jow.: 43 of 64 messages translated (0 fuzzy).
Jo-Philipp Wich [Thu, 8 Dec 2011 02:05:49 +0000 (02:05 +0000)]
po: fix charset in some ukrainian language files
Jo-Philipp Wich [Thu, 8 Dec 2011 02:02:54 +0000 (02:02 +0000)]
po: sync statistics translations
Jo-Philipp Wich [Thu, 8 Dec 2011 00:58:48 +0000 (00:58 +0000)]
po: add pbx-voicemail translation template
Jo-Philipp Wich [Thu, 8 Dec 2011 00:58:26 +0000 (00:58 +0000)]
po: initialize pbx-voicemail translations
Jo-Philipp Wich [Wed, 7 Dec 2011 21:08:49 +0000 (21:08 +0000)]
applications/luci-statistics: drop support for wireless plugin, add iwinfo replacement
Jo-Philipp Wich [Wed, 7 Dec 2011 21:00:40 +0000 (21:00 +0000)]
applications/luci-statistics: remove plugin overview pages, jump to first plugin of each category instead
Iordan Iordanov [Wed, 7 Dec 2011 07:35:40 +0000 (07:35 +0000)]
1) Changed "express" to "priority" when inserting the QoS rules.
Jo-Philipp Wich [Tue, 6 Dec 2011 11:00:33 +0000 (11:00 +0000)]
modules/admin-full, po: s/libiwinfo/libiwinfo-lua/
Jo-Philipp Wich [Mon, 5 Dec 2011 19:36:50 +0000 (19:36 +0000)]
libs/core: fix undefined tostring() in network model
Jo-Philipp Wich [Mon, 5 Dec 2011 19:34:47 +0000 (19:34 +0000)]
modules/admin-full: fix removal of wireless networks if radio is disabled
Jo-Philipp Wich [Mon, 5 Dec 2011 18:35:00 +0000 (18:35 +0000)]
modules/admin-core: expose txpower offset in wifi json status
Jo-Philipp Wich [Mon, 5 Dec 2011 18:34:22 +0000 (18:34 +0000)]
libs/core: expose txpower offset values in network model
Jo-Philipp Wich [Mon, 5 Dec 2011 18:29:04 +0000 (18:29 +0000)]
modules/admin-full: use new iwinfo capabilities to display shifted tx power values
Jo-Philipp Wich [Mon, 5 Dec 2011 16:38:54 +0000 (16:38 +0000)]
From
c63e369d57cb6862a8890c7b2ee1b6b449b2c42d Mon Sep 17 00:00:00 2001
From: Gabor Juhos <juhosg@openwrt.org>
Date: Mon, 5 Dec 2011 14:36:34 +0100
Subject: [PATCH] libs/sys: read model name from /tmp/sysinfo/model if present
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Jo-Philipp Wich [Mon, 5 Dec 2011 14:09:24 +0000 (14:09 +0000)]
applications/luci-statistics: rework handling of index and detail graphs
Instead of coding the display logic into the graph models, simply annotate
graph models with .detail = true/false and let the renderer decide which
to pick when.
Jo-Philipp Wich [Sat, 3 Dec 2011 14:10:49 +0000 (14:10 +0000)]
contrib: drop libiwinfo, moved to OpenWrt trunk
Jo-Philipp Wich [Sat, 3 Dec 2011 00:22:25 +0000 (00:22 +0000)]
libiwinfo: reimplement iwinfo.lua in C and package it as "iwinfo"
Jo-Philipp Wich [Fri, 2 Dec 2011 20:57:09 +0000 (20:57 +0000)]
contrib/package: depend on libiwinfo-lua
Jo-Philipp Wich [Fri, 2 Dec 2011 20:53:11 +0000 (20:53 +0000)]
libiwinfo: rename liblua files to lua
Jo-Philipp Wich [Fri, 2 Dec 2011 20:48:08 +0000 (20:48 +0000)]
libiwinfo: major changes
- move own headers to include/iwinfo/ and shipped ones to include/iwinfo/api/
- split into libiwinfo and libiwinfo-lua which contains only the binding
- provide a public api for libiwinfo
- install development headers and shared objects
Iordan Iordanov [Thu, 1 Dec 2011 22:26:48 +0000 (22:26 +0000)]
1) Added a couple more sounds.
Iordan Iordanov [Thu, 1 Dec 2011 22:14:14 +0000 (22:14 +0000)]
1) Added sounds needed for authentication app.
2) Added license and attribution for sounds
3) Added linking sounds into the asterisk sounds directory.
Jo-Philipp Wich [Thu, 1 Dec 2011 16:18:37 +0000 (16:18 +0000)]
libiwinfo: clear buffer in nl80211_ifname2phy(), prevents running operations against the wrong phy
Iordan Iordanov [Wed, 30 Nov 2011 23:12:42 +0000 (23:12 +0000)]
1) Now loading the func_timeout.so module used to set DISA timeouts.
Iordan Iordanov [Wed, 30 Nov 2011 22:56:53 +0000 (22:56 +0000)]
1) Fixed a couple of directories which were different from Debian.
Jo-Philipp Wich [Wed, 30 Nov 2011 15:11:15 +0000 (15:11 +0000)]
i18n: remove empty directories
Jo-Philipp Wich [Wed, 30 Nov 2011 15:10:55 +0000 (15:10 +0000)]
i18n, contrib: package ukrainian language support
Iordan Iordanov [Wed, 30 Nov 2011 14:31:21 +0000 (14:31 +0000)]
1) Removed tls certificates file, as it is not present on OpenWRT
2) Added a config option asking msmtp to not verify the identity of the SMTP server (CA certs missing)
Translation System [Wed, 30 Nov 2011 12:59:32 +0000 (12:59 +0000)]
Commit from LuCI Translation Portal by user jow.: 11 of 11 messages translated (0 fuzzy).
Translation System [Wed, 30 Nov 2011 12:59:31 +0000 (12:59 +0000)]
Commit from LuCI Translation Portal by user jow.: 1 of 4 messages translated (0 fuzzy).
Translation System [Wed, 30 Nov 2011 12:59:30 +0000 (12:59 +0000)]
Commit from LuCI Translation Portal by user jow.: 1 of 2 messages translated (0 fuzzy).