Commit Graph

1730 Commits

Author SHA1 Message Date
Tata
6742584e12 gluon-config-mode-geo-location: allow to set location independently from sharing it (#1537)
also properly delete location data when a user disables
the location option after re-entering config-mode.
2019-09-24 09:56:40 +02:00
Christof Schulze
6aee8e95e8 gluon-mmfd: add package (#1802) 2019-09-23 21:34:53 +02:00
Linus Lüssing
302a795189 Revert "gluon-mesh-batman-adv: reenable batman-adv multicast optimizations"
This reverts commit 9b1eb40fe7.

With the batman-adv v2019.2 upgrade reverted (c1a7733956), the batman-adv
multicast-to-multi-unicast feature is not available yet. Without that it is
going to be very unlikely of the batman-adv multicast optimizations to
take effect. E.g. some outdated nodes would disable it.

To avoid confusion and diversion with a few communities having it enabled
and most implicitly deactivated, just deactivate it for all for now
until batman-adv is updated to v2019.2 or greater again.
2019-09-21 23:28:12 +02:00
Christof Schulze
a3fd203e13 gluon-mesh-babel: add dependency: gluon-l3roamd
gluon-mesh-babel conigures babeld and thus the mesh. This mesh is only usable
with routes to the clients which are discovered by l3roamd.
2019-09-14 00:32:55 +02:00
Christof Schulze
d5a4f4fd8c gluon-mesh-babel: distribute routes to 2000::/3 2019-09-14 00:32:55 +02:00
Christof Schulze
59b7625e54 gluon-l3roamd: utilize node_client_prefix6 from site, add checks
* add check_site.lua to validate required field from site
* make use of node_client_prefix6 if defined in site
2019-09-14 00:32:55 +02:00
Matthias Schiffer
b2f5f71c43
gluon-web-wifi-config: fix incorrect UCI call
Fixes #1809

Fixes: bf55249159 ("gluon-core: add outdoor support for 5 ghz radios")
2019-09-06 20:37:37 +02:00
Christof Schulze
bd543db86b gluon-core: enhance mac_to_ip() beyond RFC 4291 (#1798)
mac_to_ip() calculates an ipv6 address from a mac address according to
RFC 4291. For wireguard we have to use specially crafted addresses that
must be unique. This allows calculating such unique mac-based addresses
by allowing to optionally specifying the bytes to be inserted into the
address.
2019-08-23 20:42:23 +02:00
Linus Lüssing
cb899874dc
gluon-mesh-batman-adv: allow installing mesh-batman-adv-14 and -15 at the same time
The new routing_algo site.conf value BATMAN_IV_LEGACY is introduced. With
these changes, the routing_algo setting becomes mandatory.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2019-08-22 20:09:10 +02:00
Linus Lüssing
f9e68be4e0
gluon-mesh-batman-adv: respondd: determine compat version from release version
We cannot add the same file (here: /lib/gluon/mesh-batman-adv/compat) to
two, installed packages. Therefore, instead of determining the compat
version number from this file, infer it from the batman-adv release
version number instead.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2019-08-22 20:09:10 +02:00
Matthias Schiffer
dcb18e6efe
features: include gluon-radvd by default
Fixes #1775
2019-08-21 19:34:12 +02:00
Chrissi^
dc8149abc4
gluon-mesh-vpn-core: Add dependency for KERNEL_NET_ACT_POLICE
This is a fix for the broken ingress traffic-shaping in gluon v2018.2.2
and possibly earlier.

For ingress traffic shaping the kernel option NET_ACT_POLICE is needed.
Before this patch there was no dependency to this. Neither in
gluon_core, gluon-mesh-vpn-core nor in the package.

This patch adds this dependency.

[Matthias Schiffer: move dependency from GLUON_CORE to gluon-mesh-vpn-core]

Fixes #1790
2019-08-21 18:37:53 +02:00
Martin Weinelt
eeb745d717 gluon-web-network: fix variable shadowing
package/gluon-web-network/luasrc/lib/gluon/config-mode/model/admin/network.lua:122:16: (W431) shadowing upvalue f on line 19

Fixes: bab4af01e ("gluon-web-network: improve PoE GPIO name translation
handling")
2019-08-13 17:49:02 +02:00
Simon Terzenbach
c124f6f410 mcp85xx-p1020: add support for Aerohive HiveAP 330 2019-08-13 13:25:20 +02:00
Simon Terzenbach
c37644e004
ar71xx-nand: add support for Aerohive HiveAP 121 2019-08-02 00:37:26 +02:00
Matthias Schiffer
bab4af01eb
gluon-web-network: improve PoE GPIO name translation handling
- Replace string concat for i18n key with an explicit list to make the code
  compatible with i18n-scan.pl
- Improve fallback string
2019-07-20 20:56:58 +02:00
Sven Eckelmann
2eb15bac0e gluon-authorized-keys: Force installation of gluon-lock-password
The gluon-authorized-keys is usually installed to use SSH keys to
authenticate a user against the device. To make this useful, it is also
required to disable passwordless SSH access to the device.

This new dependency is only required when the user doesn't have
gluon-setup-mode enabled already.

Fixes: #1777
Reported-by: yanosz <github@yanosz.net>
Fixes: a753fa79e3 ("gluon-authorized-keys: add keys from site.conf")
Signed-off-by: Sven Eckelmann <sven@narfation.org>
2019-07-02 12:34:55 +02:00
Jan-Tarek Butt
90baebc2b7 add gluon-hoodselector: Integrate geolocation mode
This MR includs only the VPN MODE of the hoodselector whitch simply set
hoods base on their geopositions.

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

check_site.lua: fix language syntax

muss -> must
rage -> range
at lease -> at least
coordiantes -> coordinates
realaise -> realised

gluon-hoodselector: fix language syntax in hoodselector

can not -> can't
routers -> router's
continure -> continue
to next -> to the next
TMP -> temporary
for current -> for the current
continure -> continue
with next -> with the next
thier -> there
provides -> provide
possition -> position
therfore -> therefore

gluon-hoodselector: fix language syntax in util.lua

realaise -> realised

gluon-hoodselector: fix language syntax and use autoupdate lock mechanism.

gluon-hoodselector: fix spelling/grammar

gluon-hoodselector: automatically set SECTION and CATEGORY for Gluon packages

gluon-hoodselector-add-VPN-MODE: add micrond & libjson-c dependency

gluon-hoodselector-add-VPN-MODE: check running hoodselector before loading lua

gluon-hoodselector-add-VPN-MODE: remove nixio dependency from hoodselector util

Revert "gluon-hoodselector-add-VPN-MODE: check running hoodselector before loading lua"

This reverts commit 535b0a1b2fb73e563bf6a44b568a796440bd307f.

add luaposix and luabitop to pakage dependency

sbin/hoodselector: remove nixio requiemend

sbin/hoodselector: load hoods only if necessary

gluon-hoodselector: use VPN abstraction layer. the hoodselectore does
not need to know about all individual VPN protocols.

gluon-hoodselector: Makefile add gluon-mesh-vpn-core as dependency

gluon-hoodselector: apply changes of mesh vpn lib

gluon-hoodselector: remove outdated comments

package/gluon-hoodselector: check_site.lua rm domain seed check thus its already checked by gluon-core

package/gluon-hoodselector: util.lua code cleanup and refactoring

package/gluon-hoodselector: hoodselector code cleanup and refactoring

gluon-hoodselector: util.lua, use taps instead of spaces. Use posix.unistd.access instead of io.open

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

gluon-hoodselector: hoodselector, use taps instead of spaces.

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

gluon-hoodselector: check_site.lua: replace hood with domain

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

gluon-hoodselector: drop VPN mode and rename hood to domain. Furthermore implement geolocator mode as neorayder way

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: rm duplicated print output

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector util: fix wrong function signature

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

small typo fixes

small typo fixes

Update util.lua

processes are really restarted now. new (old) problem: nodes will not forget their former ipv6-addresses. watchdog could here with that.

gluon-hoodselector util.lua: replace i iterator with _

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

Update util.lua

now polygons with holes are recognized correctly. also a mix of nested polygons and boxes should be possible as shapes[]

package/gluon-hoodselector: hoodselector use gluon-reload for daemon restarts/reloads

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: util.lua use math-polygon lib and rm restart_services function. Rectengles will be converted into polygons now

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: Makefile rewrite description update depends list

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: check_site.lua reduce complexity

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: use : for gluon_version Val

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: fix if equal syntax

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

luasrc/usr/lib/lua/hoodselector/util.lua: check_site.lua simplify checksite script and fix if logic

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: set space after comma, rm unnecessary error handling

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: use only brackes on require function no mixup

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: check_site.lua rm unuse variables and fix non std global function

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: util.lua rm unuse include

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: rm comment return nil in function get_geolocation()

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>

package/gluon-hoodselector: Makefile refactor pkg description

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>
2019-06-29 02:43:01 +02:00
Martin Weinelt
10d05d268c
gluon-core: fix primary mac selection on tp-link archer c25 v1
Fixes #1771
2019-06-27 13:35:35 +02:00
Ruben Barkow
2bda2ea028 gluon-web-mesh-vpn-fastd: update comment after luacheck fixes (#1751)
Fixes: 4249d65af7 ("treewide: fix luacheck warnings")
2019-06-19 22:40:05 +02:00
Matthias Schiffer
a6a25c9431
Merge pull request #1724 from freifunk-gluon/pr/tc-mbits
gluon-config-mode-mesh-vpn: display tc limits in Mbit/s
2019-06-19 19:35:59 +02:00
Matthias Schiffer
a2ba3efe8b
Merge pull request #1743 from freifunk-gluon/mesh-vpn-fix-limits
gluon-mesh-vpn-core: move common VPN config to gluon UCI package
2019-06-19 19:34:28 +02:00
Matthias Schiffer
ecc8ebc8ed
treewide: move ebtables filter definitions from files to luasrc 2019-06-18 19:52:33 +02:00
Matthias Schiffer
95e7d41563
gluon-ebtables-source-filter: another luacheck fix 2019-06-17 20:12:47 +02:00
Martin Weinelt
cd9f1a0f0c gluon-core: fix and complete list of outdoor board names 2019-06-17 16:27:19 +02:00
Martin Weinelt
3d4fb37351
gluon-mesh-vpn-tunneldigger: move watchdog script into luasrc directory
This allows the script to be minified as well as being checked by
luacheck.
2019-06-17 00:48:08 +02:00
bobcanthelpyou
266e0aed38 gluon-mesh-vpn-tunneldigger: fix luacheck warnings 2019-06-17 00:41:20 +02:00
Matthias Schiffer
f67522bef3
Merge pull request #1748 from bobcanthelpyou/luacheck_warnings
treewide: fix luacheck warnings
2019-06-16 23:17:43 +02:00
bobcanthelpyou
f2305faea8 gluon-web-model: fix return value of resolve_depends() 2019-06-16 22:51:53 +02:00
bobcanthelpyou
4249d65af7 treewide: fix luacheck warnings 2019-06-16 22:51:53 +02:00
Matthias P. Walther
8e176354f8
gluon-mesh-vpn-tunneldigger add watchdog script
The logic is based on the previously used shell script implementation.

Co-Authored-By: Robin Weiligmann <admin@robwei.me>
2019-06-16 20:56:35 +02:00
Martin Weinelt
ada723a0df
gluon-config-mode-mesh-vpn: display tc limits in Mbit/s 2019-06-16 19:32:57 +02:00
Matthias Schiffer
fc7c8cb086
gluon-mesh-vpn-core: remove obsolete migration code
/etc/config/gluon-simple-tc was removed with Gluon 2016.1.
2019-06-16 18:40:10 +02:00
Matthias Schiffer
818c31afdd
gluon-mesh-vpn-core: move common VPN config to gluon UCI package
We now keep the VPN enable state, bandwidth limit enable and actual limits
in the core config to avoid having to recover "user intent" from different
config files when the used VPN packages change.

Fixes #1736
2019-06-16 18:40:10 +02:00
Matthias Schiffer
f6df3b0541
gluon-mesh-vpn-core: don't consider tunneldigger when fastd is installed
None of our scripts can handle fastd and tunneldigger running at the same
time. When both are installed, ignore tunneldigger.
2019-06-16 17:56:18 +02:00
Matthias Schiffer
80b6e7f18f
Merge pull request #1742 from bobcanthelpyou/luacheck_gluon-mesh-vpn-core
gluon-mesh-vpn-core: fix luacheck warnings
2019-06-16 17:39:24 +02:00
bobcanthelpyou
9f4c393295 gluon-mesh-vpn-core: fix luacheck warnings
./gluon-wan:25:1: (W122) setting read-only field ? of global arg
./gluon-wan:29:1: (W311) value assigned to variable ok is unused
2019-06-16 17:31:53 +02:00
Matthias Schiffer
da45bd5987
treewide: do not use Lua module() 2019-06-16 15:51:43 +02:00
Matthias Schiffer
3ec108aacc
gluon-web: fix Http:getcookie()
None of our code uses cookies, so this issue went unnoticed.
2019-06-16 14:55:23 +02:00
Matthias Schiffer
071cf7b20f
Switch to Lua for target definitions
The old bash-based parsing code was way too complex. Replace it with Lua.
2019-06-15 23:34:07 +02:00
Martin Weinelt
709c1b1b91 gluon-config-mode-outdoor: fix reference mess for real this time 2019-06-10 11:20:53 +02:00
Martin Weinelt
718696e11d gluon-config-mode-outdoor: fix default value readout 2019-06-09 21:54:52 +02:00
Matthias Schiffer
7be7064432
gluon-ebtables-filter-multicast: fix comment char in Lua code
It seems this mistake didn't cause an error because of Lua's support for
shebang lines.
2019-06-09 15:27:08 +02:00
Linus Lüssing
9b1eb40fe7 gluon-mesh-batman-adv: reenable batman-adv multicast optimizations
Several fixes and enhancements related to multicast were added upstream
in batman-adv. So let's give the batman-adv multicast optimizations
another go.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2019-06-07 15:16:40 +02:00
Christof Schulze
08a8815815 gluon-l3roamd: add missing uc dependency
uc is used in the initscript. It must be set as dependency
2019-05-25 15:43:25 +02:00
David Bauer
5f19706756 gluon-core: fix mesh radios not being created
This commit fixes a bug where on first setup, mesh interfaces won't be
created for 2.4GHz radios.
2019-05-21 13:42:22 +02:00
David Bauer
1aa4ffc514 gluon-config-mode gluon-core: fix incorrect gluon.platform reference
The is_outdoor function is placed inside the gluon.platform module, not
the platform_info module. Currently, the outdoor-mode wizard component
and the upgrade script fail due to nil-value calls.
2019-05-21 13:42:22 +02:00
Martin Weinelt
ad1a1906ab
gluon-core: fix reference to outdoors config site variable 2019-04-29 16:08:10 +02:00
Martin Weinelt
501c3b38bb add gluon-config-mode-outdoor package
adds a section to the wizard for outdoor capable devices
that informs the user of of the regulatory situation and
allows a quick toggle of the outdoor mode.
2019-04-28 18:19:43 +02:00
Martin Weinelt
e20d5b0a3e gluon-core: allow presetting the outdoor mode for new installations 2019-04-28 18:19:43 +02:00
Martin Weinelt
423aafbd29 gluon-core: improve channel and add chanlist validation 2019-04-28 18:17:40 +02:00
Martin Weinelt
bf55249159 gluon-core: add outdoor support for 5 ghz radios
Add the `wifi5.outdoor_chanlist` site configuration that
allows specifying an outdoor channel range that can be
switched to for regulatory compliance.

Upon enabling the outdoor option the device will
 - configure the `outdoor_chanlist` on all 5 GHz radios
 - which may enable DFS/TPC, based on the regulatory domain
 - disable ibss/mesh on the 5 GHz radio, as DFS *will*
   break mesh connections
 - allow for htmode reconfiguration on 5 GHz radios

The outdoor option can be toggled from
 - Advanced Settings
   - W-LAN
     - Outdoor Installation

The `preserve_channel` flag overrules the outdoor channel
selection.
2019-04-28 18:17:11 +02:00
Martin Weinelt
4f60f6dbc6 gluon-core: disable legacy_rates by default, drop support for supported and basic rates (#1716) 2019-04-28 16:47:29 +02:00
Matthias Schiffer
09916f6e35
gluon-mesh-batman-adv: drop packets from mesh with next-node source or destination address (#1714)
Fixes #1659
2019-04-28 14:56:09 +02:00
bobcanthelpyou
fe521db441 build: add site check for obsolete settings (#1702) 2019-04-28 14:38:08 +02:00
Tata
e81d1a390f Add mechanism to reload domain related services (#1710) 2019-04-23 17:34:49 +02:00
Matthias Schiffer
59a44274cb
gluon-respondd: do not join link-local multicast group on br-client
Fixes #1701
2019-04-21 19:31:32 +02:00
Matthias Schiffer
a5614a5019
gluon-neighbour-info: fix outgoing interface for non-link-local multicast addresses 2019-04-21 19:19:02 +02:00
Matthias Schiffer
e9e1e2d18a
gluon-neighbour-info: exit on unknown parameters 2019-04-21 19:19:02 +02:00
Matthias Schiffer
7dec8ebf87
gluon-neighbour-info: fix mixed tab/space indentation 2019-04-21 19:19:02 +02:00
Matthias Schiffer
fc5f93604e
gluon-neighbour-info: fix inet_pton() error message
inet_pton() doesn't set errno on regular parse errors, so using perror()
doesn't make sense (and we avoid a confusing "Success" message).
2019-04-21 19:19:02 +02:00
Linus Lüssing
8e04679be6 gluon-mesh-batman-adv: add batctl dependency to gluon-mesh-batman-adv-14
The batctl v2013.4 build was removed from the batman-adv-legacy package
as the current, upstream batctl releases work with batman-adv-legacy,
too.

As a replacement we need to add the upstream batctl dependency to
gluon-mesh-batman-adv-14 to have a batctl available again here.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2019-04-16 12:03:20 +02:00
bobcanthelpyou
149b55526f gluon.mk: fix reference to LuaSrcDiet binary 2019-04-14 11:21:31 +02:00
Tata
d4c066a0f8 gluon-config-mode-mesh-vpn: 0300-mesh-vpn.lua fix limit_ingress default value (#1682)
in case of default disabled simple-tc for tunneldigger

Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>
2019-04-11 08:50:48 +02:00
Sven Eckelmann
e13a614420 gluon-status-page-mesh-batman-adv: Save if metrics chose neighbor as own best nexthop
The commit a080049735 ("gluon-status-page-mesh-batman-adv: Retrieve TQ of
neighbors with non-best direct link") removed the check whether a neighbor
has the BATADV_ATTR_FLAG_BEST set. But consumers may still want to filter
out or mark neighbors which don't have this flag set. To assist with such a
feature, enhance the neighbor object with an extra boolean "best" attribute
which stores whether the BATADV_ATTR_FLAG_BEST was found or not.

Reported-by: Vincent Wiemann <webmaster@codefetch.de>
2019-04-09 01:31:51 +02:00
Sven Eckelmann
cef21e584a gluon-mesh-batman-adv: Save if metrics chose neighbor as own best nexthop
The commit ee63ed42fe ("gluon-mesh-batman-adv: List neighbors with
non-best direct link") removed the check whether a neighbor has the
BATADV_ATTR_FLAG_BEST set. But consumers may still want to filter out or
mark neighbors which don't have this flag set. To assist with such a
feature, enhance the neighbor object with an extra boolean "best" attribute
which stores whether the BATADV_ATTR_FLAG_BEST was found or not.

Reported-by: Vincent Wiemann <webmaster@codefetch.de>
2019-04-09 01:31:51 +02:00
Sven Eckelmann
d0df47d943 gluon-status-page-mesh-batman-adv: Retrieve TQ of neighbors with non-best direct link
Links between two direct neighbors are not always the best route between
these devices. The flag BATADV_ATTR_FLAG_BEST would not be set for these
originator entries and the respondd module would just ignore this entry.

If these neighbors are not accepted and returned to the status page then
some of the neighbor entries will show a name, (acceptable) signal strength
and mac address but no TQ value.

Fixes: 28668c8c52 ("gluon-status-page: API")
2019-04-09 01:31:51 +02:00
Sven Eckelmann
ec72d30b8f gluon-mesh-batman-adv: List neighbors with non-best direct link
Links between two direct neighbors are not always the best route between
these devices. The flag BATADV_ATTR_FLAG_BEST would not be set for these
originator entries and the respondd module would just ignore this entry.

This causes missing links in meshviewer and similar tools. And when the
link quality is nearly equal and but fluctuates slightly, these links will
from time to time appear and disappear on the map.

Fixes: 2e0e24a992 ("announce neighbours using alfred/gluon-announce")
2019-04-09 01:31:51 +02:00
Manu.WTF
3b0e5fab71 ramips-mt7620: add support for Xiaomi MiWifi Mini (#1638) 2019-03-29 12:43:05 +01:00
David Bauer
a9a4abb637 ipq806x: add support for NETGEAR R7800 (#1669)
The device is broken until the next release. The LEDs are currently not
working (fixed in current OpenWRT master).

Also give a brief explanation about the BROKEN status being dependent on
the WiFi chip used and not the SoC family in general.
2019-03-28 14:49:17 +01:00
Matthias Schiffer
c208fc4fd9
gluon-site: add better error message for domain name conflicts
When two domains alias the same name (or one aliases another), display a
meaningful error message like:

    Failed to alias domain 'foo' as 'bar', name already taken by
    domain 'baz'.
2019-03-22 20:15:25 +01:00
bobcanthelpyou
3b55cbc1f3 gluon-web: fix typos 2019-03-18 21:49:54 +01:00
Sven Eckelmann
b850fff7e4 gluon-mesh-batman-adv: Only use local TT to count non-wifi clients (#1676)
The amount of local wifi clients is currently counted by two different
ways:

* asking the kernel wifi layer for the number of of clients on 2.4GHz and
  5GHz band
* asking batman-adv for the number of non-timed out entries in the local
  translation table with WiFi flag

The number of wifi24+wifi5 and the number of TT wifi client counts are
reported via respondd to various consumers. The ffrgb meshviewer is
displaying these values as:

* 2,4 GHz: wifi24
* 5 GHz: wifi5
* other: (TT local wifi+non-wifi clients) - (wifi24 + wifi5)

But the local translation table is holding entries much longer than the
wifi layer. It can therefore easily happen that a wifi client disappears in
the kernel wifi layer and batman-adv still has the entry stored in the
local TT.

The ffrgb meshviewer would then show this count in the category "other".
This often results in confusions because "other" is usually for ethernet
clients. And nodes with a frequently disappearing larger group of clients
(near bus stations or larger intersections) often show most clients under
the group "other" even when this devices doesn't have a LAN ethernet port.

It is better for presentation to calculate the number of total wifi clients
by summing up wifi24 + wifi5. And getting the number of total clients (non
wifi + wifi) by adding the result of the previous calculation to the sum of
non-wifi client in the local batman-adv translation table.

Fixes: 89a9d8138c ("gluon-mesh-batman-adv-core: Announce client count by frequency")
Reported-by: Pascal Wettin <p.wettin@gmx.de>
2019-03-16 13:37:49 +01:00
bobcanthelpyou
dcf5f192a0 gluon-web-node-role: Update i18n role translation (#1655) 2019-02-25 21:24:08 +01:00
David Bauer
f52bd99e71 gluon-mesh-batman-adv: use libnl-tiny to get IPv6 addresses (#1616) 2019-02-17 19:53:24 +01:00
bobcanthelpyou
5cdb6e86c7 package: update urls to https 2019-02-16 19:25:49 +01:00
David Bauer
c1b9ea2d9c gluon-scheduled-domain-switch: add package (#1555)
This package allows to automatically switch to another domain, either
at a given point in time or after the node was offline long enough.
2019-02-12 11:00:29 +01:00
David Bauer
387a9b4fe4 gluon-core: assert WiFi driver provides 4 MAC-addresses (#1626)
Gluon has multiple ways to obtain unique MAC-addresses. They are either
provided by the WiFi driver or derived from the primary MAC-address.

Quoting the same file:

> It's necessary that the first 45 bits of the MAC address don't
> vary on a single hardware interface, since some chips are using
> a hardware MAC filter. (e.g 'rt305x')

This currently fails in case the rt35xx based chips mac address differs
from the primary MAC. In this case, the MAC address for the client0 radio
(vif 1) comes from the WiFi driver. As there is only a single
MAC-address provided by '/sys/class/ieee80211/phyX/addresses' but the
MAC-address for mesh 0 (vif 2) is derived from the Node-ID, resulting in
different first 45 bits. The WiFi won't come up altogether in this case.

This commit verifies at least 4 MAC-Addresses are provided by the WiFi
driver. If this is not the case, all MAC-addresses are derived from the
primary MAC. This way, affected radios are working correctly.
2019-02-11 21:22:46 +01:00
Martin Weinelt
9153b38117 gluon-core: fix unifiac-{lite,pro} primary mac selection
fixes #1629
2019-01-25 01:50:53 +01:00
Martin Weinelt
c4d435c9c7 gluon-core: sort 010-primary-mac by target and board_name 2019-01-25 01:50:53 +01:00
Martin Weinelt
86148bdfc3 gluon-status-page: rebuild status-page.js after 02dfc66
The original commit only applied its changes to the source file and did
not rebuild the minified file, therefore the change never went live.
2019-01-17 23:25:31 +01:00
Matthias Schiffer
2aa324ecf7
gluon-config-mode-geo-location: fix source/i18n mismatch
The text was changed in the i18n files, but the corresponding change in the
Lua sources seemingly got lost during a rebase.

Closes #1611
2019-01-03 03:16:11 +01:00
David Bauer
888cddb662 gluon-core: distribute dualband radios (#1606)
This commit distributes dualband radios evenly on 2.4 GHz and 5GHz with
2.4 GHz being prioritised higher than 5 GHz. This means in case a device
has only a single radio and this radio supports operation in both bands,
it will be set to 2.4 GHz.

Tested-by: Martin Weinelt <martin@darmstadt.freifunk.net>
Signed-off-by: David Bauer <mail@david-bauer.net>
2018-12-29 21:48:12 +01:00
Martin Weinelt
76f591995e gluon-client-bridge: set ra_holdoff interval to 30 seconds (#1597)
Allow odhcp6c to fork the script to handle router
advertisments in 30 seconds intervals. This is the value
that was previously used in Gluon v2018.1 / LEDE 17.01.

The default value is 3 seconds and while it is RFC compliant
it can put alot of pressure on even moderately sized devices.

Signed-off-by: Martin Weinelt <martin@darmstadt.freifunk.net>
2018-12-07 21:40:13 +01:00
Christof Schulze
8c058af89d gluon-mesh-babel: remove broken log-file option from config
log-file /dev/stderr is broken for babeld as it eats log messages for debug log.
This commit gets rid of the option. This allows -d N to be used as babeld command
line option.
2018-12-05 00:21:33 +01:00
Julian
68ee1db91e gluon-core: fix pattern %v in opkg URLs (#1594)
$VERSION_ID is a lowercase value
2018-12-02 16:59:06 +01:00
bobcanthelpyou
f3fa17d0f7 gluon-mesh-babel: Variable 'uret' is reassigned a value before the old one has been used. 2018-11-29 23:57:06 +01:00
bobcanthelpyou
62f06c1b16 gluon-mesh-babel: Unsigned variable 'total' can't be negative 2018-11-29 23:57:06 +01:00
bobcanthelpyou
083b7ef675 gluon-mesh-babel: 'buf' nulled but not freed upon failure 2018-11-29 23:57:06 +01:00
Martin Weinelt
bcf4d076e1 gluon-status-page: display position and link it with geo uri scheme (#1587)
Fixes: #659
Signed-off-by: Martin Weinelt <martin@darmstadt.freifunk.net>
2018-11-27 23:16:32 +01:00
Andreas Ziegler
1d2e36dab5 Revert "gluon-config-mode-geo-location: allow to store coordinates without sharing"
This reverts commit 104d7455fa.
in its current form it requires you to enter coordinates, which we don't want to enforce by default.
2018-11-27 02:07:04 +01:00
Andreas Ziegler
f5dc9601c3
Merge pull request #1577 from freifunk-ffm/wireguard-prep
Prepare existing babel stack for wireguard
2018-11-26 01:22:14 +01:00
Christof Schulze
62406509fc gluon-core: enable ECN 2018-11-26 01:20:31 +01:00
Christof Schulze
e5b238e04a gluon-mesh-babel: exit with error if unable to connect to babeld 2018-11-26 01:20:31 +01:00
Christof Schulze
89b7612fdb gluon-l3roamd: init: dynamically configure mesh interfaces gracefully during reload
This patch makes use of the new feature in l3roamd to gracefully
add, remove and list the mesh interfaces that are currently in use. This
helps when changing mesh interfaces often - a characteristic of the
wireguard protocol implementation as in the previous behavior all local
clients are dropped when adjusting mesh interfaces.
2018-11-26 01:20:31 +01:00
Jan-Tarek Butt
104d7455fa gluon-config-mode-geo-location: allow to store coordinates without sharing 2018-11-24 15:02:49 +01:00
Christof Schulze
171c293ebe gluon-core, gluon-mesh-babel: move lua functions that generate ll-addresses from a mac into gluon-core 2018-11-21 20:56:35 +01:00
Christof Schulze
c23e6e4b53 gluon-mesh-babel: babel-respond: stop relying on mac addresses and instead obtain ll-address from nic 2018-11-21 20:56:35 +01:00
Christof Schulze
bd96bd4024 gluon-mesh-babel: explicitly specify the use of the busybox netcat 2018-11-21 20:56:35 +01:00
Christof Schulze
b90d214da9 gluon-iptables-clamp-mss-to-pmtu: clamp mss on all mesh interfaces for all destinations to pmtu 2018-11-21 20:47:39 +01:00
Matthias Schiffer
eda3aa3333
gluon-mesh-vpn-core: add gluon-wan exec wrapper
gluon-wan is a sudo-like exec wrapper that switches the process group to
gluon-mesh-vpn, making it use the WAN dnsmasq rather than resolving over
the mesh.

Note that this only affects DNS at the moment. Processes running under
gluon-wan will still use the regular mesh IPv6 routing table, and not the
WAN routing table. This is not a problem for IPv4, as there is only one
IPv4 routing table.

Fixes #1575
2018-11-21 12:09:10 +01:00
Matthias Schiffer
6d4d4792d5
gluon-mesh-*: do not count wifi clients/neighbours inactive for more than 60s 2018-11-18 11:45:16 +01:00
Matthias Schiffer
f61d252361
gluon-mesh-batman-adv: respondd: do not count batadv clients inactive for more than 60s 2018-11-17 20:07:00 +01:00
Matthias Schiffer
af9c1f7e9f
gluon-mesh-babel: fix respondd provider build/install
Rename to respondd.c / respondd.so, gluon.mk expects these names. This way
we can remove the install code. The installed filename is changed to
gluon-mesh-babel.so, bringing it in line with out common naming scheme.
2018-11-17 19:45:18 +01:00
T-X
cb35b0d10a gluon-ebtables: build kernel with ebt_dnat and ebt_redirect (#1472)
The redirect and dnat target are needed for gluon-alt-esc-client to
forward frames to the selected, alternative gateways.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2018-11-16 21:33:59 +01:00
David Bauer
665cc49d67 ar71xx: add support for Archer C7 v5 2018-10-15 00:38:18 +02:00
Andreas Ziegler
849f72b0a6 gluon-status-page: don't cache index meta redirect 2018-10-11 03:23:29 +02:00
Andreas Ziegler
1628f2d49e gluon-config-mode-core: don't cache index meta redirect 2018-10-11 03:23:29 +02:00
David Bauer
246a617d71 ar71xx: add support for TL-WR902AC v1 (#1546)
This adds support for the TP-Link TL-WR902Ac v1 travel router.

The device is marked as broken due to 64MB which might be insufficient
in certain environments.
2018-10-11 03:21:51 +02:00
Matthias Schiffer
c584d81952
gluon-config-mode-hostname: fix site check for prefill
Do not require this setting in site.conf.
2018-09-29 14:09:28 +02:00
David Bauer
9de78e27b6 gluon-config-mode-hostname: add option to use default hostname (#1529)
Before 7827f89, mandatory hostname field in config mode was
pre-filled with the default hostname.

This commit adds the config_mode.hostname.prefill option for
controlling the default value.
2018-09-15 22:36:07 +02:00
Tata
1a690d2fd6 package/features: add gluon-ebtables-limit-arp to batman feature (#1516)
this activates the package by default when using the batman feature
while still allowing to explicitly remove it like this:

GLUON_SITE_PACKAGES := \
  -gluon-ebtables-limit-arp
2018-09-05 04:45:41 +02:00
Matthias Schiffer
a8d736ac7b
gluon-config-mode-geo-location-osm: add OSM-based location picker
gluon-config-mode-geo-location-osm extends the
gluon-config-mode-geo-location with a location picker based on
OpenStreetMaps.

Based-on-patch-by: Jan-Tarek Butt <tarek@ring0.de>
2018-09-01 11:35:39 +02:00
Matthias Schiffer
0d4188d40b
gluon-web-osm: base on OpenLayers 5, add model class
The new code is shorter and uses more readable variable names. It does not
depend on specifically named input fields anymore (allowing to use multiple
maps on the same page), and only uses well-defined interfaces to trigger
revalidation of input fields.

The Map model class allows to add OSM maps to gluon-web forms.
2018-09-01 11:35:33 +02:00
Matthias Schiffer
ba1df47dba
gluon-web-model: add custom events for form elements 2018-09-01 11:28:12 +02:00
Matthias Schiffer
a3a1d217f2
gluon-web-model, gluon-config-mode-theme: replace old gluon-map class, fix Form id 2018-09-01 11:28:12 +02:00
Matthias Schiffer
9a732f30dd
gluon-web-model: reorder Node arguments so Section:option() can just pass them through 2018-09-01 11:28:12 +02:00
Matthias Schiffer
653c132013
gluon-web-model: remove unused Section attribute "fields" 2018-09-01 11:28:12 +02:00
Matthias Schiffer
a2be178ce8
gluon-web: add view helper for JSON-encoded values
Can be used for inserting Lua values into inline JS code.
2018-09-01 11:28:12 +02:00
Matthias Schiffer
897ee73d14
gluon-mesh-batman-adv: respondd: remove incorrect field width limits
At least the ifindex and the flags fields can be larger than 0xff.

Fixes #1523
2018-09-01 11:12:22 +02:00
Matthias Schiffer
d3d6637c7f
Merge pull request #1517 from blocktrron/pr-memory-calculation 2018-08-25 01:55:01 +02:00
David Bauer
02dfc66438 gluon-status-page: update memory usage estimation
Let gluon-respondd expose "MemAvailable" from /proc/meminfo to allow for
a more realistic memory-usage estimation.

Information on MemAvailable can be found here:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
commit/?id=34e431b0ae398fc54ea69ff85ec700722c9da773
2018-08-25 00:57:44 +02:00
David Bauer
44c70ca4d6 gluon-respondd: expose MemAvailable 2018-08-25 00:57:44 +02:00
Tata
20d22f66dd gluon-mesh-vpn-core: add abstraction layer for VPN interface name (#1518) 2018-08-24 23:21:43 +02:00
Matthias Schiffer
6ebe2ccd1b
gluon-config-mode-geo-location: fix typo 2018-08-23 23:01:43 +02:00
Matthias Schiffer
a72cf0b86b
gluon-config-mode-geo-location: revise altitude label overrides
As already done with other config mode texts, the altitude field now has
default texts that are used when they are not set in the site i18n files.
The altitude-help text has been removed from site i18n; instead, the
geo-location-help text now overrides the whole section description
including the part that mentions the altitude.
2018-08-19 20:58:26 +02:00
Matthias Schiffer
b4346ff9e6
gluon-config-mode-geo-location: make altitude show behaviour match docs
Do not show by default, delete old altitude value when a form without
altitude shown is saved.

Fixes #1493
2018-08-19 20:20:31 +02:00
Ruben Barkow
2b16257896 gluon-web-mesh-vpn-fastd: clarify config of default crypto method (#1502) 2018-08-06 21:36:05 +02:00
Andreas Ziegler
78ed75ee28 Revert "gluon-core: make sure dns traffic leaves the correct interface when there is ipv6 wan uplink"
This reverts commit b3d7011130.

with this change, DNS in batman-adv based networks is broken.
although the revert breaks babel based networks, this is not as big of a problem.
2018-08-03 15:04:26 +02:00
Christof Schulze
a304814c80 gluon-l3roamd: set gc_thresh for ipv4 and ipv6 to obtain DELNEIGH messages 2018-08-02 00:58:51 +02:00
Christof Schulze
d17cef06a2 gluon-l3roamd: obtain uci cursor 2018-08-02 00:58:51 +02:00
Christof Schulze
b3d7011130 gluon-core: make sure dns traffic leaves the correct interface when there is ipv6 wan uplink 2018-08-02 00:58:51 +02:00
Christof Schulze
0f9ab5e306 gluon-mesh-babel: add new package 2018-08-02 00:58:51 +02:00
Christof Schulze
6241ba5435 gluon-iptables-clamp-mss-to-pmtu: add new package 2018-08-02 00:58:51 +02:00
Tata
cf9b6e34ff gluon-web-osm: add javascript static osm source (#1483)
Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>
2018-07-29 16:07:39 +02:00
Felix Kaechele
d87c4b521b gluon-mesh-vpn: support ingress bandwidth shaping with tunneldigger (#1460)
Signed-off-by: Felix Kaechele <felix@kaechele.ca>
2018-07-26 01:26:00 +02:00
Ruben Barkow
b9b61ed79c gluon-config-mode-theme: background grey of clicked buttons (#1492) 2018-07-25 22:36:48 +02:00
Ruben Barkow
ca2929a61f gluon-web-admin: add site-commit to info page (#1482) 2018-07-25 22:30:29 +02:00
Sven Eckelmann
b9ec173ffb ipq40xx: add support for OpenMesh A62
This device is a dual 5GHz device. It is recommended to manually change the
radio of the first device to the lower 5GHz channels and the second radio
to the upper 5GHz channels.
2018-07-25 22:27:16 +02:00
Sven Eckelmann
36a5604dfe ipq40xx: add support for OpenMesh A42 2018-07-25 22:27:16 +02:00
Sven Eckelmann
3ef28a4684 gluon-client-bridge: Revert "move IPv4 local subnet route to br-client (#1312)"
The commit b3762fc61c ("gluon-client-bridge: move IPv4 local subnet route
to br-client (#1312)") moves the IPv4 prefix from the local-port interface
to br-client. A client requesting an IPv4 connection to the IPv4 anycast
address of the node (the device running gluon) will create following
packets:

1. ARP packet from client to get the MAC of the mac address of the anycast
   IPv4 address
2. ARP reply from node to client with the anycast MAC address for the IPv4
   anycast address
3. IPv4 packet from client which requires reply (for example ICMP echo
   request)
4. ARP request for the client MAC address for its IPv4 address in prefix4
   (done with the mac address of br-client and transmitted over br-client)
5. IPv4 packet from node (transmitted over br-client with br-client MAC
   address) as reply for the client IPv4 packet (for example ICMP echo
   reply)

The step 4 and 5 are problematic here because packets use the node specific
MAC addresses from br-client instead of the anycast MAC address. The client
will receive the ARP packet with the node specific MAC address and change
their own neighbor IP (translation) table. This will for example break the
access to the status page to the connected device or the anycast DNS
forwarder implementation when the client roams to a different node.

This reverts commit b3762fc61c and adds an
upgrade code to remove local_node_route on on existing installations.
2018-07-22 16:42:41 +02:00
Sven Eckelmann
fc59d5208d gluon-mesh-batman-adv: Drop IPv4 anycast related packets from/to bat0
The commit b3762fc61c ("gluon-client-bridge: move IPv4 local subnet route
to br-client (#1312)") moves the IPv4 prefix from the local-port interface
to br-client. A client requesting an IPv4 connection to the IPv4 anycast
address of the node (the device running gluon) will create following
packets:

1. ARP packet from client to get the MAC of the mac address of the anycast
   IPv4 address
2. ARP reply from node to client with the anycast MAC address for the IPv4
   anycast address
3. IPv4 packet from client which requires reply (for example ICMP echo
   request)
4. ARP request for the client MAC address for its IPv4 address in prefix4
   (done with the mac address of br-client and transmitted over br-client)
5. IPv4 packet from node (transmitted over br-client with br-client MAC
   address) as reply for the client IPv4 packet (for example ICMP echo
   reply)

The step 4 is extremely problematic here. ARP replies with the anycast IPv4
address must not be submitted or received via bat0 - expecially not when it
contains an node specific MAC address as source. When it is still done then
the wrong MAC address is stored in the batadv DAT cache and ARP packet is
maybe even forwarded to clients. This latter is especially true for ARP
requests which are broadcast and will be flooded to the complete mesh.

Clients will see these ARP packets and change their own neighbor IP
(translation) table. They will then try to submit the packets for IPv4
anycast addresses to the complete wrong device in the mesh. This will for
example break the access to the status page to the connected device or the
anycast DNS forwarder implementation. Especially the latter causes extreme
latency when clients try to connect to server using a domain name or even
breaks the connection setup process completely. Both are caused by the
unanswered DNS requests which at first glance look like packet loss.

An node must therefore take care of:

* not transmitting ARP packets related to the anycast IPv4 address over
  bat0
* drop ARP packets related to the anycast IPv4 when they are received on
  bat0 from a still broken node
* don't accept ARP packets related to the anycast IPv4 replies on local
  node when it comes from bat0

Fixes: b3762fc61c ("gluon-client-bridge: move IPv4 local subnet route to br-client (#1312)")
2018-07-22 16:42:41 +02:00
Adorfer
65d172f835
gluon-config-mode-mesh-vpn: i18n/de: fix missing comma 2018-07-19 19:28:48 +02:00
Matthias Schiffer
017bcd43ce
gluon-core: remove nixio dependency 2018-07-17 20:08:16 +02:00
Matthias Schiffer
06a9d61523
gluon-web-*: replace nixio with luaposix 2018-07-17 20:08:16 +02:00
Matthias Schiffer
92d90cdfb7
gluon-config-mode-*: replace nixio with gluon.util 2018-07-17 20:08:16 +02:00
Matthias Schiffer
90031ba97a
gluon-status-page: replace nixio with luaposix 2018-07-17 20:08:16 +02:00
Matthias Schiffer
5fc04fb34a
gluon-wan-dnsmasq: replace nixio with luaposix 2018-07-17 20:08:15 +02:00
Matthias Schiffer
32394dc694
gluon-mesh-vpn-core: replace nixio with luaposix 2018-07-17 20:08:15 +02:00
Matthias Schiffer
fd10d7cbb0
gluon-core: replace nixio with luaposix and luabitops 2018-07-17 20:08:15 +02:00
Matthias Schiffer
60a0e78a4a
gluon-core: gluon.util: remove unused function readline() 2018-07-17 20:08:15 +02:00
David Bauer
c4b1febd31 ipq40xx: add target
This commit adds support for the new ipq40xx target.
2018-07-16 01:39:36 +02:00
Matthias Schiffer
7e4bfee3c9
gluon-core: upgrade: remove unused variables 2018-07-14 13:35:28 +02:00
Matthias Schiffer
f1f2bae94f
gluon-core: remove obsolete gluon.site_config library 2018-07-13 23:16:33 +02:00
David Bauer
52bc028e6b ar71xx: add support for OCEDO Koala (#1475) 2018-07-13 01:25:58 +02:00
Matthias Schiffer
210d97c53e
Switch to OpenWrt 18.06 branch 2018-07-10 22:57:40 +02:00
Matthias Schiffer
da058c5ef9
gluon-status-page: move neighbours-batadv wrapper to batadv-specific package 2018-06-30 16:03:13 +02:00
Andreas Ziegler
5cf7c53e69
gluon-config-mode-geo-location: allow overriding geo location description text 2018-06-29 21:01:24 +02:00
Andreas Ziegler
533ea986ad
gluon-config-mode-hostname: allow overriding hostname description text 2018-06-29 20:55:32 +02:00
Ralf Jung
1649635be4
gluon-config-mode-contact-info: allow overriding contact field help and note in site 2018-06-24 19:47:52 +02:00
J0WI
ee97fe8b9e gluon-web-admin: show sha256sum to verify upgrade (#1441) 2018-06-19 19:24:27 +02:00
Sven Eckelmann
ef819cc196 ar71xx: add support for OpenMesh OM2P(-HS)v4 (#1426) 2018-06-09 13:55:38 +02:00
Sven Eckelmann
9d719a2e57 ar71xx: add support for OpenMesh A40/A60 (#1424) 2018-06-08 20:18:30 +02:00
Jan-Philipp Litza
e909d45ab0 gluon-radv-filterd: Invalidate originators cache after some time (#1343) 2018-06-05 21:55:30 +02:00
Matthias Schiffer
603912dd0d
gluon-config-mode-contact-info: restore datatype definition
optional = true does not make sense without a datatype. When no datatype is
set, the empty string will be a valid value, so data is never unset in the
write function. Restore the minlength(1) datatype so the contact setting is
deleted as intended when no value is provided.
2018-06-04 23:37:32 +02:00
Matthias Schiffer
b8fa1b2a99
gluon-config-mode-contact-info: remove useless description
The first half was just the package title, the second was outdated.
2018-06-04 23:15:59 +02:00
Matthias Schiffer
f51eac7582
gluon-status-page: add contact information again
The field was accidentally removed during the status-page rewrite.

Fixes #1401
2018-05-22 22:48:27 +02:00
Christof Schulze
ab7f1acd0c gluon-config-mode-contact-info: provide enhancements for german, english and french translation to comply with DSGVO (#1394)
* do not allow to obligatorily require contact information
* add remark that the data is provided voluntarily
* mention how to delete the data
* be very clear about the fact that the data being entered is public and
  can be downloaded and processed by anyone.
2018-05-19 19:26:33 +02:00
David Bauer
ed7d68490d gluon-config-mode: add platform on config-mode reboot (#1397)
This commit adds the ability to show information about the platform on
config-mode reboot.
2018-05-17 02:30:29 +02:00
lemoer
73c30b0916 gluon-respondd: fix whitespace after "if" 2018-05-05 15:09:30 +02:00
lemoer
dde708692c gluon-respondd: use %SCNu64 instead of %llu for uint64_t 2018-05-05 15:09:30 +02:00
lemoer
6ac7e97fae gluon-respondd: add information from /proc/stat to "statistics"
This commit adds information about:
- how cpu time is spent since boot in jiffies (1/100*sek) (cpu)
    - the value is summed for all cores, so in 10 seconds the
      summed values will increase by 4000, if the cpu has
      4 cores
- context switches since boot (ctxt)
- interrupt counters since boot (intr, softirq)
- forks since boot (processes)

    { "stat": {
       "cpu": {
         "user": 219403,
         "nice": 1714,
         "system": 75159,
         "idle": 2727739,
         "iowait": 2943,
         "irq": 0,
         "softirq": 571
       },
       "intr": 8426340,
       "ctxt": 50992590,
       "processes": 10549,
       "softirq": 5161884
    } }
2018-05-05 15:09:30 +02:00
Matthias Schiffer
1f7ed28b76
gluon-core: set VXLAN/legacy mode in site config
In multidomain setups, VXLAN is enabled by default, but can be disabled in
domain configs using the mesh/vxlan option. In single domain setups, the
mesh/vxlan option is mandatory.

The UCI option for legacy mode is removed.

Fixes #1364
2018-04-27 18:05:50 +02:00
Matthias Schiffer
5d92f125cd
gluon-web-network: remove legacy option for wired mesh 2018-04-27 17:48:36 +02:00
Matthias Schiffer
3519f4e61b
gluon-radv-filterd: correct call to ebtables-tiny
Fixes: 8e5abf02ae ("treewide: switch to ebtables-tiny")
2018-04-27 14:38:01 +02:00
Christof Schulze
2465a103f6
gluon-status-page: when prettifying undefined numbers, show - instead of NaN 2018-04-16 10:23:15 +02:00
Matthias Schiffer
62943f9ca1
gluon-mesh-vpn-tunneldigger: fix typo in description 2018-04-15 22:48:23 +02:00
Matthias Schiffer
6304a317e4
gluon-l3roamd: fix interface checks in initscript
The local_node ifstatus must be checked for local-node, not client. While
we're at it, also clean up the syntax a bit.
2018-04-15 12:49:52 +02:00
Christof Schulze
8959d8c3ea
gluon-status-page: make status page mesh protocol agnostic
batman-adv-specific parts are moved to a new package
gluon-status-page-mesh-batman-adv.
2018-04-15 12:46:01 +02:00
Christof Schulze
b70d4ce20a
gluon-core, gluon-l3roamd: introduce script gluon-list-mesh-interfaces that lists all currently active mesh interfaces 2018-04-15 12:41:01 +02:00
Christof Schulze
6dff120e3c
gluon-status-page: reduce usage of absolute paths in cgi-bin scripts neighbours-nodeinfo and stations 2018-04-15 12:39:36 +02:00
Matthias Schiffer
35ade80f1c
gluon-status-page: move mesh protocol specific definitions into a separate file 2018-04-15 11:36:37 +02:00
Matthias Schiffer
3282a63ea7
gluon-status-page: remove "lastseen" field from neighbours-batadv output
The field is unused.
2018-04-15 10:09:36 +02:00
Matthias Schiffer
433af56f99
gluon-status-page: fix code indentation 2018-04-15 10:01:25 +02:00
Matthias Schiffer
994c94918a
treewide: automatically set SECTION and CATEGORY for Gluon packages 2018-04-14 00:01:04 +02:00
Matthias Schiffer
6f0d9f1e2d
gluon-status-page: fix typo in comment 2018-04-13 22:50:37 +02:00
Matthias Schiffer
74f4119c1b
treewide: add support for building kernel modules used by Gluon into the kernel 2018-04-13 17:32:20 +02:00
Matthias Schiffer
8e5abf02ae
treewide: switch to ebtables-tiny 2018-04-13 16:00:58 +02:00
Matthias Schiffer
543eb17882
gluon-core: remove DNS cache feature
dnsmasq's caching is severly broken and does not handle all answer records
equally. In particular, its cached answers are missing DNSKEY and DS
records, breaking DNSSEC validation on clients.

Remove the cache for now. It may return if dnsmasq is fixed or we switch to
a different resolver.
2018-04-13 15:15:40 +02:00
Matthias Schiffer
395266e404
gluon-core: remove obsolete dnsmasq upgrade script
The script cleaned up an old setting that was removed in 2014.
2018-04-13 15:01:43 +02:00
Matthias Schiffer
ba9fc94e85
gluon-core: get rid of old sysctl settings 2018-04-13 14:41:01 +02:00
Matthias Schiffer
9b937a8c64
gluon-core: remove unused gluon.sysctl Lua module 2018-04-13 14:41:01 +02:00
Matthias Schiffer
25b32ec2fe
treewide: move sysctl settings to /etc/sysctl.d
net.ipv6.conf.br-client.forwarding is moved from gluon-client-bridge to
gluon-mesh-batman-adv, as the setting is not useful with non-bridged
protocols.
2018-04-13 14:41:01 +02:00
Matthias Schiffer
46c5effae3
gluon-core: reduce mac80211 fq_codel memory limit to 256KB on devices with 32MB RAM 2018-04-11 08:33:30 +02:00
Linus Lüssing
951b6632bc gluon-ebtables-limit-arp: do not add multicast addresses to filter
With the batman-adv multicast support compiled back in again we end up
with multicast addresses in the batman-adv translation table.

Currently we wrongly interpret multicast addresses returned by TT as a
unique host, too, which adds them with a source address filter to
ebtables as well. However, the source address of an ethernet frames is
never supposed to be a multicat one.

This leads to unnecessary entries in ebtables. Fixing this by ignoring
those MAC addreses returned by TT which have the multicast bit set.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2018-04-01 03:26:50 +02:00
Jan-Tarek Butt
d5ef9b67c9
gluon-mesh-vpn-tunneldigger: only allow in domain config
Signed-off-by: Jan-Tarek Butt <tarek@ring0.de>
2018-03-28 18:38:01 +02:00
Matthias Schiffer
f17bb94ad7
gluon-config-mode-theme: fix styling of select elements
* Use correct width
* Don't display focus outline (Webkit)
* Don't let option elements inherit error colors (Webkit)
2018-03-27 20:38:26 +02:00
Matthias Schiffer
6dc9369715
gluon-status-page: suppress "broken pipe" syslog message
Some HTTP endpoints were writing annoying "broken pipe" messages to stderr.
2018-03-27 19:48:04 +02:00
Martin Weinelt
946b42e234
gluon-config-mode-domain-select: allow hiding of individual domain codes 2018-03-20 18:05:38 +01:00
Matthias Schiffer
532b57011f
gluon-core, gluon-client-bridge: allow 0-character ESSIDs/mesh IDs 2018-03-17 15:38:24 +01:00
Jan-Tarek Butt
dda1b2a127
gluon-client-bridge: check AP SSID length to be in range of 1-32 characters 2018-03-17 15:33:40 +01:00
Jan-Tarek Butt
9a9024843b
gluon-core: check mesh ID and IBSS SSID length to be in range of 1-32 characters 2018-03-17 15:33:12 +01:00
Matthias Schiffer
7827f8960f
gluon-config-mode-hostname: add config_mode.hostname.optional site option
This setting allows to enforce manually setting a hostname.

In the initial configuration, the hostname field is now left empty; when
setting the hostname is not enforced, the default hostname is shown as the
field placeholder.

Fixes #1139
2018-03-17 12:51:14 +01:00
Matthias Schiffer
486c2e4821
gluon-config-mode-contact-info: change "mandatory" site option to "optional"
Also add documentation about config mode settings.
2018-03-17 12:27:57 +01:00
Matthias Schiffer
87ded4c3d8
gluon-config-mode-hostname: improve English node name explanation 2018-03-17 11:48:25 +01:00
Matthias Schiffer
9f86bf3155
gluon-core: add default_hostname helper 2018-03-17 11:44:33 +01:00
Matthias Schiffer
d87a798ac3
gluon-core: disable VXLAN checksums
Our VXLAN setup was changed to accept VXLAN packets without checksum almost
2 months ago, so we can disable sending the checksums now as well. Slightly
improves performance.
2018-03-16 20:17:03 +01:00
Matthias Schiffer
7f812e8754
package/features: never implicitly enable gluon-web-mesh-vpn-fastd
This package only provides the choice between "security" and "performance
mode". It should only be enabled when specified in site.mk.
2018-03-12 13:57:57 +01:00
Matthias Schiffer
c80c294b3f
gluon-mesh-batman-adv: increase bridge multicast querier robustness to 9
The RFC standard multicast querier interval is 120s. Our querier uses in
interval of 20s for better support of roaming clients, but our robustness
setting of 3 leads to external queriers using the standard interval to be
timeout after only 60s, leading to frequent "querier appeared/disappeared"
messages. Increase robustness so that external queriers with any interval
<180s are supported.
2018-03-11 12:36:54 +01:00
Matthias Schiffer
68a706a948
gluon.mk: remove GLUON_PKG_MAKE option 2018-03-09 10:05:44 +01:00
Matthias Schiffer
5e086da608
gluon-respondd: remove Gluon-specific provider directory
Our provider modules are prefixed with gluon- now, and the log message
about a missing provider dir was confusing users.
2018-03-08 21:46:05 +01:00
Matthias Schiffer
60522ee253
treewide: move package Makefile boilerplate to gluon.mk 2018-03-08 19:49:41 +01:00
Ruben Barkow
ee14a03e70 treewide: french translation: WLAN -> Wi-Fi (#1342) 2018-03-08 11:26:10 +01:00
Matthias Schiffer
ca43e9058f
gluon-radv-filterd: add missing build dependency on respondd 2018-03-07 21:26:11 +01:00
Matthias Schiffer
934221b86f
treewide: remove redundant definitions from package Makefiles 2018-03-07 21:23:41 +01:00
Matthias Schiffer
17370d8462
gluon-ebtables: unconditionally segment IGMP/MLD
We must ensure that each node becomes IGMP/MLD querier for its local
clients; having only a single querier for the whole mesh is generally
unreliable, leading to frequent "IGMP/MLD querier appeared/disappeared"
messages from batman-adv and unreliable snooping.

In smaller meshes it might be interesting only segment querier domains, but
allow membership reports to pass through the mesh, in order to support
snooping switches outside the mesh without special configuration. A
site.conf switch is provided to control this behaviour.

Fixes #1320
2018-03-07 08:12:30 +01:00
rubo77
d4bfa6c4e0 gluon-config-mode-hostname: clarify the use of the nodename 2018-03-02 02:57:59 +01:00
Matthias Schiffer
208cd4d98c
gluon-client-bridge: allow WLAN configs without ap section again
Fixes: 7ccdacd294 ("treewide: rework check_site_lib.lua")
2018-03-01 01:18:39 +01:00
Matthias Schiffer
3e88331137
gluon-status-page: add dependency on libubus-lua 2018-02-26 18:55:51 +01:00
Matthias Schiffer
27f7ce444f
gluon-status-page: when visiting via a next-node address, redirect to a unique address
A downside of this behaviour is that the page does not work for IPv4-only
clients, as the redirect will always point at an IPv6 address.

Still, it seems like a good idea to enforce the redirect even from the IPv4
next-node address, as switching nodes while being connected to the status
page would lead to unexpected behaviour.
2018-02-26 03:25:01 +01:00
Matthias Schiffer
fdf823a3a2
gluon-status-page-api: merge back into gluon-status-page
All Access-Control-Allow-Origin are removed to improve users' privacy. As
the status page API is thus not useful without the status page anymore,
merge them back into a single package.

The status-page-api respondd provider is removed as well.

Fixes #1194
2018-02-26 02:20:38 +01:00
Matthias Schiffer
88906f238b
gluon-status-page: reimplement based on gluon-web
This new status page is significantly smaller than the old one. It always
loads its resources from the same host as the page itself, not requiring
cross-origin requests anymore.

It also uses the common i18n infrastructure of gluon-web.

Fixes #914
2018-02-26 02:20:38 +01:00
Matthias Schiffer
b1aa5390a7
gluon-config-mode-core: move gluon-web base path to /lib/gluon/config-mode
- CGI script and index.html are moved from gluon-web to
  gluon-config-mode-core, the script is renamed to 'config'
- gluon-web and gluon-web-model base views and i18n files are symlinked
  into the new path
- gluon-web-theme is renamed to gluon-config-mode-theme and installs
  directly into the new path
- all gluon-web-* models, controllers and views are moved into the new
  path
2018-02-26 00:07:13 +01:00
Matthias Schiffer
3925344292
gluon-setup-mode: move HTTP server support to gluon-config-mode-core, add gluon-lock-password 2018-02-26 00:07:12 +01:00
Matthias Schiffer
9648489a01
gluon-web: reorganize layout handling
Also bring back gluon-web-theme's i18n strings.
2018-02-26 00:07:12 +01:00
Matthias Schiffer
c3e4ceed28
gluon-web: split out model support into a separate package 2018-02-26 00:07:08 +01:00
Matthias Schiffer
83a6847fbd
gluon-web: remove unneeded functions from gluon.web.util
exec() is moved to gluon.util.
2018-02-25 17:13:30 +01:00
Matthias Schiffer
5dcb784308
gluon-core: remove unused lock and exec functions 2018-02-25 17:13:30 +01:00
Matthias Schiffer
987eef011a
gluon-core: remove unused user/group management functions, call lock command directly 2018-02-25 17:13:30 +01:00
Matthias Schiffer
6ae1af9694
gluon-mesh-vpn-core: use OpenWrt's user/group management 2018-02-25 17:13:30 +01:00
Matthias Schiffer
218de7e0ae
gluon-web: pass base path from CGI script 2018-02-25 17:13:30 +01:00
Matthias Schiffer
661e4dee9f
gluon-config-mode-core, gluon-web-*: do not access dispatcher directly 2018-02-25 17:13:30 +01:00
Matthias Schiffer
4a8283b5ab
gluon-web: remove unused files 2018-02-25 17:13:30 +01:00
Matthias Schiffer
93c1d77e07
gluon-web-theme: add missing dependencies 2018-02-25 17:13:30 +01:00
Matthias Schiffer
37cdea9733
gluon-web-*: consistently use <%| tag 2018-02-23 20:05:07 +01:00
Matthias Schiffer
dd23a805c2
gluon-web: add new <%| tag for escaped expressions 2018-02-23 19:45:28 +01:00
Matthias Schiffer
961c9db81f
gluon-web-mesh-vpn-fastd: remove "gluon" from view paths
These files are already located in /lib/gluon, no need to add it a second
time.
2018-02-23 18:55:04 +01:00
Matthias Schiffer
b2b489854e
gluon-config-mode-core: remove "gluon" from view paths
These files are already located in /lib/gluon, no need to add it a second
time.
2018-02-23 18:53:41 +01:00
Matthias Schiffer
88789b1536
gluon-web: update i18n strings 2018-02-23 13:39:56 +01:00
Matthias Schiffer
172a02e2dc
gluon-config-mode-domain-select: remove i18n build commands
gluon-config-mode-domain-select does not have any i18n files of its own.
2018-02-23 13:39:56 +01:00
Matthias Schiffer
557565e189
gluon-web: add i18n package namespaces 2018-02-23 13:39:56 +01:00
Matthias Schiffer
1a426c3bb9
gluon-web: make pcdata() prototype match lmo_translate() 2018-02-23 02:08:25 +01:00
Matthias Schiffer
93d3393993
gluon-web: make buf_length() argument const 2018-02-23 02:08:11 +01:00
Matthias Schiffer
2681622018
gluon-web: build with -fvisibility=hidden 2018-02-23 01:05:27 +01:00
Matthias Schiffer
43e70f351f
gluon-web: handle translation and escaping in generated Lua code
By emitting Lua code to call translate() and pcdata(), we are more
flexible than when doing this internally in the parser. The performance
penalty should be negligible.
2018-02-23 00:57:03 +01:00
Matthias Schiffer
933cc3d7d9
gluon-web: use ' instead of " for strings in generated Lua code
We need a bit less escaping this way.
2018-02-23 00:34:06 +01:00
Matthias Schiffer
3e292ba06f
gluon-web: close FDs after mmap() 2018-02-23 00:03:57 +01:00
Matthias Schiffer
99b4d2eaf0
gluon-web: clean up LMO code 2018-02-22 22:47:27 +01:00
Matthias Schiffer
3203970969
gluon-web: clean up parser 2018-02-22 21:13:24 +01:00
Matthias Schiffer
5a20f9794c
gluon-web: clean up buffer handling 2018-02-22 21:13:24 +01:00
Matthias Schiffer
624d969c52
gluon-web: compile with -std=c99 -Wall -Wextra
Also fix all warnings.
2018-02-22 21:13:23 +01:00
Matthias Schiffer
56a10e03b3
gluon-web: update copyright 2018-02-22 21:13:23 +01:00
Matthias Schiffer
7e5f0fe1d5
gluon-web: clean up opening files
Open with O_CLOEXEC, use fstat() instead of stat().
2018-02-22 21:13:23 +01:00
Matthias Schiffer
94f22e50e6
gluon-web: clean up malloc() calls 2018-02-22 21:13:23 +01:00
Matthias Schiffer
f957593f26
gluon-web: template_lmo: clean up sfh_hash() 2018-02-22 21:13:23 +01:00
Matthias Schiffer
9e8a6ec2b5
gluon-web: remove lmo_canon_hash()
Our strings can be looked up verbatim.
2018-02-22 13:58:20 +01:00
Matthias Schiffer
b5817f5523
gluon-web: replace custom strfind() function with memmem() 2018-02-22 13:37:57 +01:00
Matthias Schiffer
0ff4761a57
gluon-web: remove unnecessary template_lualib.h 2018-02-22 13:34:32 +01:00
Matthias Schiffer
91ae553c93
gluon-web-node-role: don't mention "Freifunk" in the labels 2018-02-22 03:27:29 +01:00
Christof Schulze
9711afaf69
gluon-core: allow multiple domain names for next_node-feature
* change type of next_node.name
* create domain entry for each entry and add to dnsmasq configuration

[Matthias Schiffer: reword documentation]
2018-02-16 15:15:31 +01:00
T-X
b3762fc61c gluon-client-bridge: move IPv4 local subnet route to br-client (#1312)
This patch moves the prefix4 subnet route from the local-node veth
device to br-client (while keeping the next node ipv4 address on the
local node device).

This is in preparation to allow routing over the br-client interface
later.
2018-02-16 00:00:12 +01:00
Christof Schulze
f94a410738 gluon-l3roamd: let l3roam0 interface and routes be set up by l3roamd 2018-02-15 23:54:06 +01:00
Christof Schulze
e724fec260 gluon-l3roamd: adjust l3roamd startup parameters
* use local socket
* use main routing table,
* pass client-bridge
2018-02-15 23:54:06 +01:00
Linus Lüssing
84a6f65f02 gluon-ebtables-limit-arp: a package for ARP rate-limiting
This package adds filters to limit the amount of ARP Requests
devices are allowed to send into the mesh. The limits are 6 packets
per minute per client device, by MAC address, and 1 per second per
node in total.

A burst of up to 50 ARP Requests is allowed until the rate-limiting
takes effect (see --limit-burst in the ebtables manpage).

Furthermore, ARP Requests with a target IP already present in the
batman-adv DAT Cache are excluded from the rate-limiting,
both regarding counting and filtering, as batman-adv will respond
locally with no burden for the mesh. Therefore, this limiter
should not affect popular target IPs, like gateways.

However it should mitigate the problem of curious people or
smart devices scanning the whole IP range. Which could create
a significant amount of overhead for all participants so far.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2018-02-15 23:21:11 +01:00
kb-light
b98956e47e
gluon-config-mode-domain-select: new package
[Matthias Schiffer: slightly clean up code]
2018-02-15 20:57:53 +01:00
Matthias Schiffer
0dd03597a6
gluon-config-mode-core: allow returning functions from wizard modules
Allow returning functions in addition to the names of UCI packages to
commit. Functions are run after all packages have been committed.
2018-02-15 20:57:53 +01:00
Matthias Schiffer
345a5de861
gluon-core: add newline to the end of sysconfig files
Both gluon.sysconfig and libgluonutil already remove the trailing newline
if it exists. It's nicer to avoid files without a trailing newline, e.g.
for printing the file contents in a terminal.
2018-02-15 20:57:53 +01:00
Martin Weinelt
427c83754b gluon-core: 200-wireless: upgrade 11ac radios to VHT20 (#1328)
Patch originally authored by @oleeander.

Fixes #424
2018-02-15 20:29:19 +01:00
Matthias Schiffer
d61f6a1e85
gluon-core: rename iterate_radios() to foreach_radio(), pass whole radio section
Allows to remove some redundant UCI lookups.
2018-02-15 14:04:37 +01:00
Karsten
f69fbf7d05 gluon-core: don't disable legacy mesh on mesh_lan on reconfigure (#1323)
Fixes #1322
2018-02-07 07:33:25 +01:00
Martin Weinelt
42763d21dc
gluon-mesh-vpn-core: add public key to nodeinfo response
This is currently only implemented in the gluon-mesh-vpn-fastd
package.

Advertising the public key may be deemed problematic when
your threat-model involves protecting the nodes privacy
from tunnel traffic correlation by onlink observers.

It can be enabled by setting site.mesh_vpn.fastd.pubkey_privacy
to `false`.
2018-02-04 20:47:53 +01:00
Matthias Schiffer
623faf794a
gluon-web: fix access to undefined in checkvalue()
Fixes: cfe1bba8 "gluon-web: fix radio button view of ListValues"
2018-02-04 18:57:27 +01:00
Matthias Schiffer
9ece0daa76
gluon-web: ListValue: convert keys to strings before adding to key list
Fixes validation of ListValues.

Fixes: ec532b95 "gluon-web: extend ListValue with optional and unset
values"
2018-02-04 18:57:27 +01:00
Matthias Schiffer
c479d9160d
gluon-core: don't request a prefix via DHCPv6 on WAN
The prefix is not used, and requesting it leads to odhcp6c log spam with
certain DHCPv6 servers.
2018-02-03 03:02:56 +01:00
Matthias Schiffer
09c2e60cd4
gluon-core: upgrade/110-network: fix formatting 2018-02-03 03:02:20 +01:00
Matthias Schiffer
ec532b95cf
gluon-web: extend ListValue with optional and unset values
If a value is unset or optional, an empty choice is added to the selection.
This empty choice will be marked as invalid if the value is not optional.

This is properly supported for the 'select' widget only for now, and not
for 'radio'.
2018-01-31 17:08:21 +01:00
Matthias Schiffer
cfe1bba8ae
gluon-web: fix radio button view of ListValues
Pretty much everything about this was broken:
* Fix dependency tracking
* Fix vertical orientation
* Fix paddings
* Add theming
2018-01-31 15:47:45 +01:00
Matthias Schiffer
dbfd22d651
gluon-web: simplify DynamicList data attributes, respect size option 2018-01-30 23:55:08 +01:00
Matthias Schiffer
bc75ce5c86
gluon-site: remove dependency of GLUON_MULTIDOMAIN on gluon-site
Solves a recursive dependency problem.

While we're at it, also fix the description string.
2018-01-28 11:24:42 +01:00
Matthias Schiffer
6ae067cb37
gluon-core: add domain aliases and pretty name
Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-26 12:32:47 +01:00
lemoer
2ef0af5fe8
gluon-respondd: add system.domain_code to respondd provider "nodeinfo"
[Matthias Schiffer: rebase]
2018-01-26 12:32:47 +01:00
lemoer
146787fa5c
libgluonutil: merge domain and site configs
[Matthias Schiffer: rebase and simplify]
2018-01-26 12:32:47 +01:00
Matthias Schiffer
a2f45d0d32
gluon-core: store default domain in UCI 2018-01-26 12:32:46 +01:00
Matthias Schiffer
24a085a542
gluon-site: add default domain and check for it
This does not do anything yet, as this_domain() is not implemented yet.

Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-26 12:32:46 +01:00
Matthias Schiffer
07dbfea617
gluon-site: disable multidomain support by default 2018-01-26 12:32:46 +01:00
Jan-Philipp Litza
cf329daaf0
Add package gluon-radv-filterd
This package drops all incoming router advertisements except for the
default router with the best metric according to B.A.T.M.A.N. advanced.

Note that advertisements originating from the node itself (for example
via gluon-radvd) are not affected.
2018-01-25 23:02:49 +01:00
Matthias Schiffer
7ae8a51126
gluon-core: allow zero VXLAN UDP checksum on RX
Also disabling TX checksums and not only allowing incoming packets without
checksum will provide another small speedup. As doing so would break wired
meshing with VXLAN-enabled nodes that require non-zero checksums, we will
wait a few days before this step.
2018-01-24 22:41:29 +01:00
Matthias Schiffer
e54b37d835
gluon-core: firewall: move VXLAN rules to the top
Evaluating these rules before all the ICMPv6 rules improves wired mesh
throughput measurably.
2018-01-24 22:41:29 +01:00
Matthias Schiffer
2950cc3f59
gluon-core: only use a bridge for wired meshing when necessary
On most devices, there is only a single LAN interface connected to all LAN
ports, so no bridge is necessary.
2018-01-24 22:16:09 +01:00
Matthias Schiffer
c84820cb08
package/gluon.mk: add to PKG_FILE_DEPENDS
Ensure packages get rebuilt when gluon.mk changes.
2018-01-19 13:22:26 +01:00
Matthias Schiffer
775028475b
check_site: move site loading logic to check_site_lib (which is renamed to check_site.lua) 2018-01-19 12:33:52 +01:00
Matthias Schiffer
7ccdacd294
treewide: rework check_site_lib.lua
In addition to significant internal differences in check_site_lib.lua (in
particular unifying error handling to a single place for the upcoming
multi-domain support), this changes the way fields are addressed in site
check scripts: rather than providing a string like 'next_node.ip6', the
path is passed as an array {'next_node', 'ip6'}.

Other changes in site check scripts:
* need_array and need_table now pass the full path to the sub fields to the
subcheck instead of the key and value
* Any check referring to a field inside a table implies that all higher
levels must be tables if they exist: a check for {'next_node', 'ip6'} adds
an implicit (optional) check for {'next_node'}, which allows to remove many
explicit checks for such tables
2018-01-19 10:12:43 +01:00
Matthias Schiffer
414dfa8155
libgluonutil: simplify CMakeLists.txt
libgluonutil is not usable outside the OpenWrt/LEDE environment anyways, so
it doesn't make much sense to make the CMakeLists.txt overly generic.
2018-01-19 06:23:29 +01:00
Matthias Schiffer
020afc856f
gluon-site: install domain configs
The domain configs are not checked yet, and not used for anything.

Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-19 05:44:25 +01:00
lemoer
50812b162c
treewide: forbid use of selected site variables in domain specific or site configs
[Matthias schiffer: rebase, add a few more restrictions]
2018-01-19 04:05:27 +01:00
lemoer
b520bf5c50
gluon-core: rename site_seed to domain_seed
[Matthias Schiffer: rebase]
2018-01-19 03:30:06 +01:00
Matthias Schiffer
1dd9845db1
package/gluon.mk: use nicer escaping in GluonCheckSite 2018-01-19 01:38:56 +01:00
lemoer
adcd5b7311
gluon-core: add gluon-reconfigure script
Not useful by itself except for testing; will be used for multi-domain
support.

[Matthias Schiffer: rename script, use for initial configuration]
2018-01-19 01:10:39 +01:00
lemoer
0f5d932c4f
gluon-core: add util gluon-show-site to print merged site config
This should not convert JSON to a Lua table and back, as this loses the
distinction between arrays and objects, but as our site.conf is defined in
Lua anyways (for now), this can be fixed in a later revision.

[Matthias Schiffer: rename to gluon-show-site, rebase]
2018-01-19 01:07:44 +01:00
lemoer
5817170821
gluon-core: introduce "gluon" uci package
[Matthias Schiffer: change section name and commit message]
2018-01-19 00:41:25 +01:00
Matthias Schiffer
0b80f1b5ce
gluon-core: reimplement gluon.site module in C
By basing the Lua gluon.site module on gluonutil_load_site_config(), the
config load implementation needs to changed only in a single place for
multi-domain support.
2018-01-18 16:29:00 +01:00
Matthias Schiffer
6cf88c3b03
Replace luci-lib-jsonc with our own lua-jsonc 2018-01-18 16:28:59 +01:00
Matthias Schiffer
12103d9638
gluon-web: remove useless serialize_json alias 2018-01-18 07:49:00 +01:00
Matthias Schiffer
01336f70ec
gluon-core: firewall: make the default input policy REJECT
Fixes #1311
2018-01-17 09:51:10 +01:00
Matthias Schiffer
a32fddf38c
gluon-core: firewall: accept inbound VXLAN traffic on wired mesh interfaces
Fixes #1308
2018-01-17 09:51:10 +01:00
Matthias Schiffer
454555a030
gluon-alfred: firewall: allow alfred server announces from mesh 2018-01-17 08:06:42 +01:00
Matthias Schiffer
18feb29b29
gluon-autoupdater: don't reference old autoupdater util library
Fixes #1310
2018-01-17 01:06:15 +01:00
David Bauer
99b02701cc ar71xx: add support for TP-Link Archer C58/C59/C60 (#1281) 2018-01-16 18:51:12 +01:00
Matthias Schiffer
18b9174d03
Use 'disabled' attribute instead of 'auto' to disable wired mesh interfaces
The 'auto' attribute still allows enabling the interface using ifup, which
is not intended when wired mesh is disabled.
2018-01-11 23:06:36 +01:00
Linus Lüssing
4911da56e1
gluon-ebtables: Enable concurrent ebtables updates
This enables the ebtables internal locking mechanism which
will avoid race conditions between multiple, concurrent
ebtables calls.

This is a preparation for the upcoming gluon-arp-limiter
daemon, to avoid issues if upon restarting gluon-ebtables
the gluon-arp-limiter daemon tries to modify the tables.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2018-01-03 19:58:53 +01:00
David Bauer
9273e56c63 ar71xx: add support for TP-Link Archer C7 v4 (#1289) 2018-01-03 16:50:23 +01:00
Christof Schulze
bc2fb8cc69 gluon-respondd: firewall should allow access for devices in zone local_client (#1291) 2017-12-31 19:57:57 +01:00
Christof Schulze
910a6c8bb3 gluon-respondd: add current unix time to statistics (#1287) 2017-12-29 23:49:28 +01:00
Matthias Schiffer
245e0f9ecc
Merge pull request #1280 from FreifunkVogtland/libbatadv
libbatadv: Add common batman-adv helper functions library
2017-12-28 14:50:13 +01:00
Christof Schulze
41ab551518
libgluonutil: add function that retrieves the node prefix from site.conf 2017-12-27 23:50:31 +01:00
Sven Eckelmann
6701aa81a5 gluon-status-page-api: Use genl helpers from libbatadv
Signed-off-by: Sven Eckelmann <sven@narfation.org>
2017-12-27 17:40:41 +01:00
Sven Eckelmann
a267cc7ee7 gluon-mesh-batman-adv: Use genl helpers from libbatadv
Signed-off-by: Sven Eckelmann <sven@narfation.org>
2017-12-27 17:40:35 +01:00
Sven Eckelmann
624cffc744 libbatadv: Add library for common batman-adv helpers
Interacting with batman-adv's genl interface requires some code and
definitions which could be shared between different packages. libbatadv is
trying to do this without providing any guarantee for ABI or API stability.
It is only useful in very controlled environments like gluon.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
2017-12-27 17:40:30 +01:00
Matthias Schiffer
f799518194
gluon-ebtables-filter-multicast: do not filter out Bridge Loop Avoidance
batman-adv uses gratuitous ARP packets with certain target addresses for
BLA.

Fixes #1198
2017-12-27 17:22:37 +01:00
Karsten
35237c2ca1 gluon-web-network: make 'PoE Power Port[0-9]' translatable (#1173) 2017-12-27 03:11:49 +01:00
Matthias Schiffer
2b1ffb3034
gluon-core, gluon-client-bridge: create local_client zone in core
As core defines basic rules for this zone, it makes sense to create it
there.
2017-12-27 02:43:34 +01:00
Matthias Schiffer
8ea5810bda
gluon-core: firewall: allow inbound ICMPv4 ping on local_node 2017-12-27 02:43:34 +01:00
Matthias Schiffer
39284f00d0
gluon-core: firewall: allow Multicast Listener Discovery on mesh/local_client
Based-on-patch-by: Christof Schulze <christof.schulze@gmx.net>
2017-12-27 02:43:33 +01:00
Matthias Schiffer
a252383918
gluon-core: firewall: remove redundant ICMPv6 output rules
OUTPUT is always accepted, no need to allow ICMPv6 explicitly.
2017-12-27 02:43:33 +01:00
Matthias Schiffer
fe2048e4df
gluon-core: firewall: coding style
Wrap long lines.
2017-12-27 02:43:33 +01:00
Ralf Jung
4bae0a429f docs: dns-cache: explain setting dns.servers a bit more (#1268) 2017-12-27 00:21:08 +01:00
Christof Schulze
c544846bc5
gluon-neighbour-info: allow respondd replies on mesh and wan interface 2017-11-25 23:31:23 +01:00
Christof Schulze
e5b4d25451
gluon-respondd: allow access to respondd from mesh-internal addresses 2017-11-25 23:31:08 +01:00
Christof Schulze
1c1c9f8fc7
gluon-core: firewall rework, make base policy more restrictive
* gluon-core, gluon-client-bridge: introduce new firewall zone: local_client
 * gluon-core: put clients in local_client zone, introduce drop-zone,
   set dns-rules and zones
 * gluon-respondd: allow respondd on mesh
 * gluon-status-page-api: allow http input on mesh and client
2017-11-25 23:19:08 +01:00
Matthias Schiffer
7351fb5d4a
gluon-web-network: fix reading "legacy" mode settings from UCI
Fixes #1269
2017-11-25 22:08:58 +01:00
kb-light
f7f659c254
gluon-web-network: make poe_passthrough more generic 2017-11-15 22:45:22 +01:00
Christof Schulze
94e7827ac8
gluon-status-page: improve localization (#1241) 2017-10-31 19:25:27 +01:00
Ruben Barkow
99c405756f gluon-web-theme: allow more width in style for input fields and selectboxes (#1229) 2017-10-14 13:42:24 +02:00
Matthias Schiffer
9324d18fee
gluon-mesh-batman-adv: filter out all packages between bat0 and local-port
Filtering by MAC address won't filter out multicast packages like router
solicitations, causing uradvd to send out router advertisements with
maximum frequency (every 3 seconds) in active meshes, even when no local
client is actually interested in the advertisements.

Fixes #1230
2017-10-03 17:07:42 +02:00
Christof Schulze
86e89a86d1 gluon-mesh-vpn-fastd: make respondd module compile again (#1228)
by moving the declaration of ret to the top of get_fastd()
2017-09-24 23:49:00 +02:00
lemoer
4899dda4af treewide: check for NULL after uci_alloc_context() (#1224) 2017-09-21 20:56:40 +02:00
Matthias Schiffer
9ab93992d1
gluon-autoupdater: mirror URLs must start with http://
The older busybox-based wget erroneously accepted URLs without protocol.
Add validator to avoid building firmwares with broken autoupdates.
2017-09-05 19:04:27 +02:00
Matthias Schiffer
fda2d10b6f
gluon-web-admin: simplify info.html template 2017-08-11 22:09:08 +02:00
Matthias Schiffer
13b325355d
gluon-core: make old site_config library reference new one, not the other way around 2017-08-11 22:07:35 +02:00
Matthias Schiffer
ee6afaced9
treewide: use new gluon.site Lua library
Some files have received some additional refactoring.
2017-08-11 22:07:34 +02:00
Matthias Schiffer
fd36bcce07
gluon-web-admin: fix info.html template indentation 2017-08-11 21:25:46 +02:00
Matthias Schiffer
8dbf3ea568
gluon-mesh-batman-adv: fix radvd start with dns.servers, but without next_node.ip config 2017-08-11 20:56:06 +02:00
Matthias Schiffer
8a41ed05f1
gluon-core: more coding style fixes 2017-08-11 20:28:59 +02:00
kb-light
90305761ce
gluon-core: update lib/gluon/upgrade/150-poe-passthrough for naming within lede 2017-08-11 20:27:51 +02:00
kb-light
949f4b7dd5
gluon-core: lib/gluon/upgrade/150-poe-passthrough: fix indentation 2017-08-11 20:26:08 +02:00
Matthias Schiffer
3df9fcecb0
gluon-core: explicitly disable radios without configuration in site.conf 2017-08-08 14:08:35 +02:00
Matthias Schiffer
293a45456b
gluon-core, gluon-client-bridge: use new gluon.site library in gluon.util
In particular, this affects users of gluon.util.iterate_radios.
2017-08-08 14:07:09 +02:00
Matthias Schiffer
53b6065500
gluon-ebtables-source-filter: use new gluon.site library to avoid 'or {}' syntax 2017-08-08 13:53:20 +02:00
Matthias Schiffer
12ec6ab2bc
gluon-mesh-batman-adv: use new gluon.site library to avoid 'or {}' syntax 2017-08-08 13:53:20 +02:00
Matthias Schiffer
951f62ac85
gluon-config-mode-*, gluon-web-admin: use new gluon.site library to avoid 'or {}' syntax 2017-08-08 13:53:16 +02:00
Matthias Schiffer
eef3bba123
gluon-client-bridge: use new gluon.site library to avoid 'or {}' syntax 2017-08-08 13:53:09 +02:00
Matthias Schiffer
1d6e6726d7
gluon-core: use new gluon.site library to avoid 'or {}' syntax 2017-08-08 13:53:02 +02:00
Matthias Schiffer
57adb49de2
gluon-core: add new gluon.site library for convenient access to optional values
The new gluon.site lua library will eventually replace gluon.site_config
(which is hereby deprecated, but will continue to be supported for a
while).

The new gluon.site library will wrap all values to allow traversing
non-existing tables without errors.

    site = require 'gluon.site'
    c = site.a.b.c -- doesn't fail even if a or a.b don't exist

The wrapped values must be unwrapped using call syntax:

    site_name = site.site_name()

Using the call syntax on a non-existing value will return nil. An
alternative default value may be passed instead:

    mac = site.next_node.mac('16:41:95:40:f7:dc')
2017-08-08 13:20:38 +02:00
Matthias Schiffer
73ad23936e
gluon-web-wifi-config: make the code a bit nicer
simple-uci will now delete an option when nil is passed.
2017-08-08 04:31:53 +02:00
Matthias Schiffer
0fee6cc707
gluon-web-logging: remove uci:set() nil check
simple-uci will now delete an option when nil is passed.
2017-08-08 04:31:53 +02:00
Matthias Schiffer
6884aad788
gluon-core: simplify 820-dns-config code 2017-08-08 04:31:53 +02:00
Matthias Schiffer
cd9ee858b8
gluon-config-mode-geo-location: remove uci:set() nil check
simple-uci will now delete an option when nil is passed.
2017-08-08 04:31:53 +02:00
Matthias Schiffer
4f51439167
gluon-config-mode-contact-info: remove uci:set() nil check
simple-uci will now delete an option when nil is passed.
2017-08-08 04:31:52 +02:00
Matthias Schiffer
31721a61f5
gluonc-core: 200-wireless: remove unneeded nil checks for uci:set_list()
uci:set_list() will delete the list when nil is passed, so there is no need
to differentiate between the cases.
2017-08-08 04:31:52 +02:00
Matthias Schiffer
06d0c0f211
gluon-core: fix 200-wireless coding style 2017-08-08 04:31:52 +02:00
Matthias Schiffer
2b9dd54f00
gluon-client-bridge: fix 320-gluon-client-bridge-wireless coding style 2017-08-08 04:31:52 +02:00
Matthias Schiffer
952439885e
gluon-mesh-vpn: fix fastd <-> tunneldigger migration
The generic upgrade script is moved to run after the more specific scripts.
In addition, the script will now remove the configuration sections of
uninstalled VPN packages, so both positive and negative changes of the
default enable state can be migrated correctly.

Based-on-patch-by: Cyrus Fox <cyrus@lambdacore.de>
Fixes: #1187
2017-08-08 01:39:29 +02:00
Matthias Schiffer
a76eaa5c45
gluon-mesh-batman-adv: preserve gw_mode on upgrades
When a Gluon node is used to connect to an uplink router/DHCP server (for
example in deployments without VPN tunnels), the gw_mode must be set to
server; this should be preserved on upgrades.

Fixes #1196
2017-07-25 23:49:11 +02:00
Steffen Förster
582d09615b
gluon-mesh-batman-adv: enable routing algorithm configuration through site.conf
[Matthias Schiffer: move to proto_gluon_bat0_setup() and default to BATMAN_IV]
2017-07-19 17:58:07 +02:00
kb-light
46126de792 Add new package gluon-web-logging (#1153) 2017-07-11 02:58:45 +02:00
Matthias Schiffer
3fd4ee99c3
gluon-l3roamd: fix incorrect dependency
gluon-mesh-babel is not merged yet, and once it is, this would lead to a
circular dependency.
2017-07-09 13:12:58 +02:00
Matthias Schiffer
6ca841bad5
build: introduce GLUON_FEATURES
To reduce the number of packages that need to be listed in
GLUON_SITE_PACKAGES, this adds a new variable GLUON_FEATURES. Sets of
packages are enabled automatically based on the combination of listed
feature flags.

Site-specified package feeds can provide their own feature flag
definitions.
2017-07-09 02:31:38 +02:00
Matthias Schiffer
818705280e
gluon-ebtables-*: add dependency on gluon-mesh-batman-adv
These packages don't work or don't make sense without batman-adv.
2017-07-08 21:23:00 +02:00
Matthias Schiffer
2cd30d644b
Remove redundant virtual packages
As PROVIDES can be used to replace real packages now, we don't need the
virtual packages as workaround anymore. This also means that the providing
packages don't need to be added to site.mk explicitly anymore when the
default provider is used.
2017-07-08 16:34:40 +02:00
Ruben Barkow
84d117ff73
gluon-web-admin: add option to show/hide password-login and add minimum password length 2017-07-07 02:15:52 +02:00
Sunz3r
b5a8959f59 gluon-config-mode-mesh-vpn: add tunneldigger to reboot page (#1172) 2017-07-06 13:24:15 +02:00
Ruben Barkow
0441c7d91f gluon-web-admin: typo "your node" (#1169) 2017-06-29 22:15:18 +02:00
Tata
5dcbbe93dc gluon-node-info: use GluonSrcDiet (#1168) 2017-06-29 11:59:22 +02:00
Matthias Schiffer
27f35e56b4
gluon-core: add interfaces having proto = gluon_mesh to mesh firewall zone
Based-on-patch-by: Christof Schulze <christof.schulze@gmx.net>
2017-06-27 23:49:56 +02:00
Christof Schulze
e432dd4d9f
gluon-core: gluon_mesh.sh: whitespace cleanup 2017-06-27 23:45:58 +02:00
Matthias Schiffer
ae593d8439
gluon-core: convert site seed to lowercase
While we use the hexadecimal representation as a hash input for simplicity,
it should not be interpreted as case-sensitive.
2017-06-27 23:28:23 +02:00
Matthias Schiffer
0ceb25e3e7
gluon-web-network: allow switching wired mesh legacy mode on and off 2017-06-27 23:04:50 +02:00
Matthias Schiffer
a2711065c8
gluon-core: add VXLAN support for gluon_wired protocol 2017-06-27 23:04:50 +02:00
Matthias Schiffer
0d6f957196
gluon-core: introduce new gluon_wired netifd proto for wired meshing
The new proto will simplify the switch to VXLAN encapsulation.
2017-06-27 23:00:17 +02:00
Matthias Schiffer
8bcd0975af
gluon-core: add a "site seed" to site.conf to seed site-specific random values 2017-06-27 23:00:17 +02:00
Matthias Schiffer
08e667ba2e
gluon-client-bridge: add default next-node MAC address
The next-node MAC address doesn't need to be unique in different
communities, so we can as well add a default value.
2017-06-26 22:48:45 +02:00
Ruben Barkow
822cfecbf5 gluon-config-mode-autoupdater: autoupdater disabled message (#1137) 2017-06-23 14:55:38 +02:00
Ruben Barkow
b44373efaf gluon-web-*: remove unused Section variables (#1150) 2017-06-23 13:00:52 +02:00
Matthias Schiffer
acfc3cc1a2
gluon-core: upgrade/210-interface-wan: whitespace cleanup 2017-06-21 17:16:41 +02:00
Matthias Schiffer
0db63008cd
gluon-core: upgrade/220-interface-lan: whitespace cleanup 2017-06-21 02:56:23 +02:00
Ruben Barkow
f3d763f509 gluon-web: improve menu order in Advanced Settings (#1146) 2017-06-19 20:16:18 +02:00
Matthias Schiffer
9dae2ebbfd
gluon-mesh-vpn-fastd: respondd: adjust for new site.conf mesh VPN structure
Fixes #1130
2017-06-01 16:23:51 +02:00
Matthias Schiffer
1ed87c6df4
gluon-mesh-batman-adv: enable bridge learning on bat0 again
Reverts d5829d87be ("gluon-mesh-batman-adv-core: disable bridge port
learning on bat0").

Fixes #1121
2017-05-12 15:43:31 +02:00
Christof Schulze
5bf3c895d0 gluon-mesh-batman-adv: announce dns server if dns cache was configured (#1105) 2017-04-27 21:11:23 +02:00
Linus Lüssing
c519ec4596 gluon-core: reenable multicast snooping for wan zone
LEDE recently disabled multicast snooping by default:

https://git.lede-project.org/?p=project/netifd.git;a=commitdiff;h=52541140f8138e31958cdc3d7e42a4029fa6bbc9

Reenable it for Gluon as there have been no confirmed issues for
LEDE and no negative reports concerning Gluon v2016.2.x so far.

Closes #1025.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2017-04-13 22:31:47 +02:00
Linus Lüssing
66ead88dcb gluon-client-bridge: reenable multicast snooping for client zone
LEDE recently disabled multicast snooping by default:

https://git.lede-project.org/?p=project/netifd.git;a=commitdiff;h=52541140f8138e31958cdc3d7e42a4029fa6bbc9

Reenable it for Gluon as there have been no confirmed issues for
LEDE and no negative reports concerning Gluon v2016.2.x so far.

Closes #1025.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2017-04-13 22:31:31 +02:00
Matthias Schiffer
e45c30330d
gluon-mesh-batman-adv: refactor interface management
We now create bat0 and primary0 independently of the lower mesh interfaces,
making the whole setup a lot more robust. In particular:

- we can't accidentially destroy primary0 because of concurrent setup and
  teardown runs of different interfaces
- bat0 will always exist, even when no mesh interfaces are up (e.g. no link
  on wired mesh)
- interfaces going down and up again will never tear down the whole of
  batman-adv
- we can enable and disable bat0 independently of the lower interface
  states
2017-04-12 19:23:08 +02:00
Matthias Schiffer
4ca67dcca5
gluon-mesh-batman-adv-*: unify into a single source package
For simplicity, we don't use different MTUs for compat 14 and 15 anymore,
there's no harm in using 1532 for batman-adv-legacy as well.
2017-04-12 04:22:45 +02:00
Matthias Schiffer
a502295eaf
gluon-core: gluon_mesh: make transitive and fixed_mtu available as interface data, add post-setup.d
In addition, transitive and fixed_mtu now default to 0 instead of an empty string.
2017-04-12 03:44:45 +02:00
Matthias Schiffer
c4641d47fd
gluon-mesh-batman-adv-core: dont' call 'ip' to check if primary0 exists 2017-04-11 02:01:38 +02:00
Matthias Schiffer
02f2d8796c
gluon-core: don't call 'ip' to check if an interface exists 2017-04-11 02:01:21 +02:00
Matthias Schiffer
c4613c4e8d
gluon-core: gluon.util: pass UCI cursor to get_wlan_mac(), get rid of local UCI context 2017-04-11 01:48:11 +02:00
Matthias Schiffer
f48d10bdde
gluon-core: gluon.util: pass UCI cursor as argument to iterate_radios() instead of using local context 2017-04-11 01:48:11 +02:00
Julian Labus
901b122d83
gluon-web-wifi-config: use find_phy from gluon.util 2017-04-11 01:48:11 +02:00
Julian Labus
734d1925de
gluon-core: gluon.util: fix PHY detection for radios addressed by PCIe address 2017-04-11 01:48:10 +02:00
Matthias Schiffer
da22c5cf8e
gluon-core: gluon.util: change find_phy argument to config table and make public 2017-04-11 01:48:10 +02:00
Matthias Schiffer
6499658b52
gluon-mesh-batman-adv-core: don't print error message when no_rebroadcast is not supported
batman-adv 2017.0 doesn't need (or support) no_rebroadcast anymore. Don't
fail when the file doesn't exist.
2017-04-10 01:32:30 +02:00
kb-light
eefd2ef8db Add package gluon-ebtables-source-filter (#1015) 2017-04-09 18:18:51 +02:00
Julian
13c61d9394 gluon-core: fix pattern %v in opkg URLs (#1087) 2017-04-07 14:24:13 +02:00
Cyrus
6a0ca58fc3 gluon-core: Fixed bug which kept legacy VLAN interface definitions (#1085) 2017-04-03 20:48:42 +02:00
Cyrus
540d0ff0a3 gluon-mesh-vpn-core: Fixed conditions for migration code (#1080)
VPN daemons were always disabled
2017-03-26 10:26:33 +02:00
Cyrus Fox
aa17e3e86e
gluon-mesh-vpn-tunneldigger: ignore default config when checking for legacy configs 2017-03-23 12:51:41 +01:00
Matthias Schiffer
da19961188
gluon-web: javascript: don't use global RegExp.$x matches, fix "this" for parameterized validators
Doing so caused broken validations, as different validators were affecting
each other.
2017-03-10 22:25:00 +01:00
Matthias Schiffer
b016cf18b4
gluon-mesh-vpn-core: add code for migration of enabled state between fastd and tunneldigger
Based-on-patch-by: Cyrus Fox <cyrus@lambdacore.de>
2017-03-10 19:45:35 +01:00
Matthias Schiffer
a49ef70c53
gluon-config-mode-mesh-vpn: add tunneldigger support
Based-on-patch-by: Cyrus Fox <cyrus@lambdacore.de>
2017-03-10 19:45:34 +01:00
Cyrus Fox
ad7a36fdce
gluon-mesh-vpn-tunneldigger: add package for tunneldigger L2TP support 2017-03-10 19:45:34 +01:00
Matthias Schiffer
be88eba07f
Refactor common parts of gluon-mesh-vpn-fastd into a gluon-mesh-vpn-core package
The fastd_mesh_vpn site.conf section is renamed to mesh_vpn.fastd.
2017-03-10 19:45:34 +01:00
Matthias Schiffer
41a9f9b06c
gluon-mesh-batman-adv-core: fix ARP resolution of next-node IPv4 address
The ebtables rules were not adjusted when switching from macvlan to veth.
2017-03-08 22:52:25 +01:00
Matthias Schiffer
7222fc07d1
gluon-web-private-wifi: fix default value of "enabled" setting 2017-03-02 15:09:49 +01:00
Matthias Schiffer
8245e77218
gluon-status-page: fix browser compatiblity of language selection 2017-02-26 20:55:31 +01:00
Matthias Schiffer
959c8ae7f8
gluon-status-page: use unique filenames for dependencies, switch to SHA256 checksums 2017-02-26 19:46:33 +01:00
Christof Schulze
b7651ee96f gluon-core: limit fq_codel memory to 1MB per AP with less than 48MB RAM (#1046) 2017-02-24 19:43:32 +01:00
Christof Schulze
946d873c14 gluon-status-page-api: limit uhttp max_requests to 16 on devices with <48MB RAM (#1045) 2017-02-24 19:38:40 +01:00
Matthias Schiffer
28f42b24a8
gluon-setup-mode, gluon-status-page-api: remove references to rpcd
rpcd is not included in our images anymore since switching to gluon-web, so
we don't need to disable it anymore.
2017-02-24 00:44:03 +01:00
Jan-Tarek Butt
c9f62fc278
gluon-mesh-batman-adv-core: Move lua file into luasrc dir 2017-02-23 20:27:23 +01:00
Matthias Schiffer
b45585a109
Switch LAN and WAN port of Ubiquiti AirGateway
This makes the LAN port the PoE master, so the AirGateway can be used to
supply power to another node connected via mesh-on-LAN.

Fixes #608
2017-02-23 19:49:39 +01:00
Matthias Schiffer
f0b919e89c
gluon-client-bridge: add next-node IPv6 address as deprecated
We always want to prefer the unique node address for outgoing traffic. Note
that this doesn't have an effect with batman-adv, as usually br-client will
be the outgoing interface, so the unique address would be chosen anyways.
2017-02-23 17:58:44 +01:00
Christof Schulze
b994ad4fdc gluon-l3roamd: add package containing basic l3roamd configuration (#1042) 2017-02-23 15:49:32 +01:00
rubo77
da7f69142f
gluon-config-mode-mesh-vpn: add extra message if mesh-VPN was not selected
This was introduced in ffhh-packages at https://github.com/freifunkhamburg/ffhh-packages/tree/master/gluon-config-mode-reboot-ffhh
2017-02-22 19:28:25 +01:00
Matthias Schiffer
f458d788c8
gluon-config-mode-core: make welcome and reboot message optional
Make use of our new _translate() function.
2017-02-22 19:28:25 +01:00
Matthias Schiffer
1d7b4482b7
gluon-web: add renderer._translate()
_translate() will return nil when no match is found.
2017-02-22 19:28:22 +01:00
Matthias Schiffer
31d3f08f25
treewide: convert all LuCI-based packages to gluon-web 2017-02-22 01:31:25 +01:00
Matthias Schiffer
e4b74be506
gluon-web: add package
The gluon-web package is basically a stripped-down and refactored version
of the LuCI base.
2017-02-22 01:30:58 +01:00
Matthias Schiffer
a06541623e
gluon-luci-admin: remove redundant Compound 2017-02-21 20:55:08 +01:00
Matthias Schiffer
78d8645e19
gluon-luci-autoupdater: avoid use of CBI Maps
As convenient as the Map is, the underlying code is very complex and will
be removed.
2017-02-21 20:55:08 +01:00
Matthias Schiffer
b5a3b9115b
gluon-luci-admin: get rid of an unneeded model 2017-02-21 20:55:08 +01:00
Matthias Schiffer
90fa69d7dd
gluon-config-mode-core: remove bogus comments from pofiles 2017-02-21 20:55:08 +01:00
kb-light
558e98ae42 gluon-mesh-vpn-fastd: improve check_site 2017-02-21 11:19:44 +01:00
kb-light
c9563cdebd scripts: check_site_lib: introduce need_string_array_match() (#1016) 2017-02-21 09:45:33 +01:00
Andrey Perliev
26a0cbd1cc gluon-status-page: JS translations (#1044)
Add translation support to gluon-status-page, including English, German and Russian translations.
2017-02-21 09:40:09 +01:00
Matthias Schiffer
43f32e3c3b
gluon-autoupdater: fix incomplete comment in upgrade script
Fixes #1043
2017-02-16 08:46:41 +01:00
Christof Schulze
6a5a7a7131 gluon-mesh-vpn-fastd: do not depend on gluon-mesh-batman-adv (#1041)
In preparation for Babel support.
2017-02-13 21:00:54 +01:00
Matthias Schiffer
afdae86a5e
gluon-respondd: allow platforminfo_get_model() to return NULL 2017-02-12 06:04:22 +01:00
Christof Schulze
b38bd942b9 gluon-status-page-api: fix indentation of luasrc/lib/gluon/status-page/www/cgi-bin/interfaces 2017-02-11 23:31:28 +01:00
Christof Schulze
8b63ac792a gluon-statuspage-api: make lib/gluon/status-page/www/cgi-bin/interfaces mesh-protocol agnostic 2017-02-11 23:31:28 +01:00
Christof Schulze
b3e609dca9
gluon-radvd: improve coding style in initscript 2017-02-11 22:40:51 +01:00
Christof Schulze
25f1b64934
gluon-radvd: remove netdev from initscript
uradvd will tolerate devices appearing and disappearing during runtime.
2017-02-11 22:40:41 +01:00
Matthias Schiffer
184cb1010d
gluon-core: add single_as_lan option to configure a single ethernet port as LAN instead of WAN 2017-02-10 22:48:23 +01:00
Matthias Schiffer
e39cbcbda1
gluon-core: gluon.util: make exec() replace all stdio files with /dev/null 2017-02-10 22:09:59 +01:00
Matthias Schiffer
ea12cb770d
gluon-core: nicer indentation of /lib/gluon/upgrade/020-interfaces 2017-02-10 22:08:51 +01:00
Matthias Schiffer
e5cb125737
Move wifi24/5 and mesh_on_wan/lan site validators from gluon-mesh-batman-adv-core to gluon-core
These values have been in use in gluon-core for some time, the validators
need to be moved as well.
2017-02-10 21:19:34 +01:00
Matthias Schiffer
f238b01173
gluon-client-bridge: use a veth pair instead of macvlan to connect local-node to br-client
macvlan interfaces never directly exchange traffic with the underlying
interface, but only with other hosts behind the interface. In consequence,
router advertisements from the uradvd running on br-client could never
reach local-node, preventing it from getting an IPv6 address without RAs
from an external radvd. Fix this be replacing the macvlan interface with
a veth pair (with the peer interface in br-client).

As a side effect, this saves about 5KB of flash, as the veth module is
simpler than macvlan.
2017-02-10 10:21:38 +01:00
Matthias Schiffer
57f8b9bc6a
Switch back roles of br-client and local-node interfaces
When preparing the migration from macvlan to veth for local-node, MAC
address conflicts occurred as some ports of br-client had the same address
as local-node. Reverting the roles of both interfaces fixes this.

By default, br-client is left as an interface without addresses and
firewall rules that drop everything, so the bridge is used to connect its
ports only. gluon-mesh-batman-adv-core changes this to the usual set
of addresses and firewall rules.
2017-02-10 09:58:23 +01:00
Matthias Schiffer
b92dfcb966
Move creation of local-node device from gluon-mesh-batman-adv-core to gluon-client-bridge
Prepare reverting the roles of br-client and local-node to their state
before 8c4403ba11.
2017-02-10 09:42:16 +01:00
Matthias Schiffer
eb350aba34
gluon-client-bridge, gluon-mesh-batman-adv-core: nicer indentation of uci:section calls
Also simplify the local_node.peerdns setting.
2017-02-10 08:16:27 +01:00
Matthias Schiffer
f9a52fd54f
Move luci-base dependency from gluon-core to gluon-setup-mode
Nothing outside the config mode depends on luci-base anymore.
2017-02-10 02:10:02 +01:00
Matthias Schiffer
5f922cf3ef
gluon-status-page-api: upgrade: don't throw error messages without rpcd 2017-02-10 02:10:02 +01:00
Matthias Schiffer
efb8475f45
build: get rid of some redundant build dependencies 2017-02-10 02:10:01 +01:00
Matthias Schiffer
80de4a69e3
gluon-client-bridge: don't depend on luci.ip 2017-02-10 02:10:01 +01:00
Matthias Schiffer
e665bfe64a
gluon-core: don't depend on luci.ltn12 2017-02-10 02:10:01 +01:00
Matthias Schiffer
c83b5b3cab
treewide: get rid of luci.util outside of config mode/advanced settings 2017-02-10 02:10:01 +01:00
Matthias Schiffer
6cf03bab37
treewide: replace normal uses of luci.model.uci with simple-uci to reduce LuCI dependencies
We also make use of the boolean support of simple-uci to make scripts
clearer.
2017-02-10 02:10:01 +01:00
Matthias Schiffer
6f48fc428f
gluon-legacy: remove package
The maintenance overhead doesn't justify keeping this old stuff anymore.
2017-02-10 02:10:01 +01:00
Christof Schulze
718758f0e5 gluon-respondd: have respondd join ff05::... in addition to ff02::... (#1030)
Rework init script to additionally join a ff05::... multicast group on the mesh-wide interface.
2017-02-10 02:03:04 +01:00
Matthias Schiffer
6b62e2fc78
gluon-core: check_site.lua: only accept /64 as prefix6
A lot of our code does not actually work with other prefix lengths.

Fixes #1014
2017-01-26 18:59:38 +01:00
Matthias Schiffer
3e7434bca1 Merge pull request #1000 from freifunk-ffm/christf_dns-config
Add gluon-dns-config: a package that enables the node to be used as DNS cache
2017-01-25 00:00:29 +01:00
Christof Schulze
8b083d4986 gluon-core: check_site.lua: fix indentation 2017-01-24 23:21:10 +01:00
Christof Schulze
e2e910fb41 gluon-core: add configuration that enables the next_node to be used as dns cache 2017-01-24 23:20:40 +01:00
Matthias Schiffer
01512419f4
gluon-luci-admin: fix firmware upgrade confirmation code
Fix an exception breaking the page.
2017-01-21 18:08:53 +01:00
Matthias Schiffer
e7b434ef34
gluon-luci-admin: fix password setting 2017-01-20 17:00:36 +01:00
Matthias Schiffer
0a8e028e8f
gluon-core: upgrade: don't print an error message on systems without opkg 2017-01-19 13:10:57 +01:00
Matthias Schiffer
78b2775eec
Use LEDE as base for Gluon 2017-01-18 17:21:43 +01:00
Matthias Schiffer
04818c170b
package: refactor add_to_set/remove_to_set to get rid of last LuCI patch 2017-01-18 16:28:54 +01:00
Matthias Schiffer
a0efa9f3fd
odhcp6c: update to use upstreamed solution to ignore default lifetime for RDNSS 2017-01-18 16:28:54 +01:00
Matthias Schiffer
7736f53dc4
Update LuCI to master branch 2017-01-18 16:28:48 +01:00
Matthias Schiffer
2dd8a700ca
package: avoid use of GLUONDIR variable 2017-01-17 21:22:58 +01:00
Matthias Schiffer
99471f8d5d
ar71xx-generic: add support for TP-Link WBS210/510 (untested)
Closes #844
2017-01-06 12:02:32 +01:00
Christof Schulze
d09351c97c gluon-luci-portconfig: portconfig.lua: change spaces to tabs (#998) 2017-01-02 19:22:05 +01:00
Matthias Schiffer
2ddf77fc81 Merge pull request #990 from freifunk-ffm/christf_get_mesh_interfaces
gluon-core: add function to gluon.util that returns all active mesh-devices
2016-12-23 00:56:42 +01:00
Matthias Schiffer
cd4753aaa5
gluon-respondd: add /usr/lib/respondd to provider directories 2016-12-23 00:44:20 +01:00
Christof Schulze
e41e5cb8d9 gluon-core: add get_mesh_devices(uconn) to gluon.util which will return all devices being up and having proto = gluon_mesh 2016-12-21 23:51:48 +01:00
Christof Schulze
0abe350782 gluon-core: replace blanks by tabs in gluon.util 2016-12-21 23:47:03 +01:00
Matthias Schiffer
2796f66fcb Merge pull request #976 from FreifunkVogtland/batadv-netlink
Switch from batman-adv v14/v15 debugfs to netlink
2016-12-13 01:20:27 +01:00
Matthias Schiffer
182c21eddc
gluon-site: convert site.conf to JSON in compile instead of install step 2016-12-11 15:19:09 +01:00
Sven Eckelmann
22946b14b6 gluon-mesh-batman-adv-core: Switch from debugfs to batadv netlink
The batadv debugfs requires large memory blocks to write the text debug
tables. This is inefficient for large tables like the global translation
table or the originators table.

The memory requirement can be reduced by using netlink. It copies smaller
packets in a binary format to the userspace program. The respondd module of
gluon-mesh-batman-adv-core can therefore parse larger originator tables
without causing an OOM on systems which are tight on memory.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
2016-12-11 12:03:12 +01:00
Sven Eckelmann
6ac5b9cbc8 gluon-status-page-api: Switch from debugfs to batadv netlink
The batadv debugfs requires large memory blocks to write the text debug
tables. This is inefficient for large tables like the global translation
table or the originators table.

The memory requirement can be reduced by using netlink. It copies smaller
packets in a binary format to the userspace program. gluon-status-page-api
can therefore parse larger originator tables without causing an OOM on
systems which are tight on memory.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
2016-12-11 12:03:12 +01:00
Ruben Barkow
ff0ad20752 gluon-config-mode-core: hand over more info to the reboot screen (#930) 2016-12-11 03:13:28 +01:00
Matthias Schiffer
9a06a98651
gluon-respondd: add delay to mesh-wide multicast requests
Mesh-wide multicast requests are answered with a random delay of up to 10s.
2016-12-11 00:42:41 +01:00
Matthias Schiffer
8c4403ba11
gluon-client-bridge, gluon-mesh-batman-adv-core: switch roles of br-client and local-node interfaces
MAC and IP addresses are switched. This makes the gluon-client-bridge
package more useful for different routing protocols that don't need a
unique address on the client bridge.

As a side effect, gluon-radvd is now using the next-node address, which had
been considered before, but was dismissed to avoid having gluon-radvd
depend on gluon-next-node and gluon-mesh-batman-adv. This will be useful
for announcing default routes via gluon-radvd.

One downside is that this introduces a minor dependency on batman-adv in
gluon-respondd: the hotplug script that checked for the client interface
before will now check for local-node. This doesn't really matter: for mesh
protocols without a local-node interface, the check will do nothing (which
makes sense, as there is no interface to bind to for mesh-wide respondd).
2016-12-10 23:43:44 +01:00
Matthias Schiffer
d2373590e0
gluon-core: add support for removing sysctl settings 2016-12-10 23:43:44 +01:00
Matthias Schiffer
3fc9154d1d
gluon-batman-adv-core: merge gluon-next-node into gluon-batman-adv-core 2016-12-10 23:43:44 +01:00
Matthias Schiffer
fb85d96d5e
gluon-next-node: don't require next_node.ip6
The next-node interface may be useful with IPv4 only or even just a MAC
address. This prepares merging gluon-next-node into gluon-batman-adv-core.
2016-12-10 23:43:23 +01:00
Jan-Philipp Litza
fcf3abd9c4 gluon-respondd: restart on state change of client iface
Because we unconditionally appended `-i br-client` to the command line of
respondd, it wasn't restarted when br-client changed state. Now, we use a
jsonfilter expression on the network.interface dump data, similar to how the
other interface names are generated, and only add the interface to the argument
list if it is up.
2016-12-09 10:43:24 +01:00
Jan-Philipp Litza
d8bb97831b gluon-respondd: Use procd in initscript and to restart on network changes 2016-12-08 23:30:57 +01:00
Matthias Schiffer
cb86fce29f
gluon-respondd: make setup.d script executable 2016-12-08 23:02:23 +01:00
Christof Schulze
ca57cdfe77 gluon-respondd: make initialisation mesh protocol agnostic (#946) 2016-12-08 17:44:29 +01:00
rubo77
2a101ddd56
gluon-core: add dirty flag to gluon-version, add site-version 2016-12-06 20:05:34 +01:00
Matthias Schiffer
b32ed384c7 gluon-mesh-batman-adv-core: respondd: correctly detect lower interface types (#954)
Fixes #941
2016-12-03 13:22:22 +01:00
Matthias Schiffer
1f3e789463
gluon-next-node: fix ebtables rules without next_node.ip4 2016-11-30 15:27:06 +01:00
Ruben Barkow
34deeac380 gluon-config-mode-geo-location: make the label for altitude definable in the site folder (#883) 2016-11-30 13:13:59 +01:00
Matthias Schiffer
20fc162b38
gluon-core, gluon-setup-mode: fix WAN/LAN assignment on CPE210
The interfaces were accidentially switched when the CPE210 was separated
from the CPE510 code.
2016-11-22 20:01:13 +01:00
viisauksena
539081d315 gluon-mesh-vpn-fastd: make fastd syslog level configurable (#915) 2016-11-06 00:01:49 +01:00
Brother-Lal
740c60c7e4 gluon-status-page: add hint to enable JavaScript if it is disabled (#913) 2016-10-24 14:43:12 +02:00
Brother-Lal
e80f751a85 fix error in statuspage if cookies are disabled (#912)
If cookies are disabled, the Statuspage only displays an empty ("Not connected")
This checks if the localStorage API is available and working and only uses it in this case
Also allows better backwards compatibility.
2016-10-24 14:18:01 +02:00
Jan-Tarek Butt
85c66b3bf8
gluon-autoupdater: double quote $1 to prevent globbing and word splitting 2016-10-10 05:44:27 +02:00
Matthias Schiffer
4e2888f7a2
gluon-wan-dnsmasq: fix handling of static DNS servers
Fixes #886
2016-09-18 22:39:22 +02:00
Matthias Schiffer
b902ddd8df
gluon-next-node: make IPv4 next-node address optional
If next_node.ip4 is not set or gluon-next-node is not used, prefix4 will
now be optional as well.
2016-09-10 17:15:16 +02:00
Ruben Barkow
d03c88afb4 gluon-config-mode-contact-info: define an "obligatory" option in site.conf (#843) 2016-09-07 06:44:57 +02:00
J0WI
d2fb547a3f gluon-status-page: removed obsolete css prefixes (#877)
None of them are used by modern browsers anymore, so it's safe to remove them.
2016-09-07 06:03:57 +02:00
Matthias Schiffer
d05cee5b55
gluon-mesh-batman-adv-core: explicitly set primary MAC address using a dummy interface
Fixes #834
2016-09-07 02:14:43 +02:00
Matthias Schiffer
6cddaedfc7
Reorganize MAC addresses, always explicitly set address for private WLAN
Fixes #842
2016-09-07 02:14:42 +02:00
Matthias Schiffer
4f39be09c9
gluon-core: migrate custom batadv interfaces to gluon_mesh proto
Users may have defined additional mesh interfaces. Properly migrate these
to avoid subtly breaking the network config (and make them ready for new
mesh protocols).
2016-09-07 02:14:42 +02:00
Matthias Schiffer
9a5a8e0ab0
gluon-client-bridge: add LAN interfaces to client bridge by default (instead of doing this in the batman-adv-specific scripts)
This allows to weaken the gluon-mesh-batman-adv-core dependency of
gluon-luci-portconfig to gluon-client-bridge.
2016-09-07 02:14:42 +02:00
Matthias Schiffer
8434896014
gluon-mesh-batman-adv-core: move config not specific to batman-adv to gluon-core 2016-09-07 02:14:42 +02:00
Matthias Schiffer
d1e6dfb7e3
gluon-mesh-batman-adv-*, gluon-mesh-vpn-fastd: configure batman-adv through gluon_mesh proto 2016-09-07 02:14:42 +02:00
Matthias Schiffer
b7380decc2
gluon-mesh-batman-adv-*: add gluon_mesh protocol handlers 2016-09-07 02:14:42 +02:00
Matthias Schiffer
5cd6295265
gluon-core: add gluon_mesh netifd proto
This new protocol will allow configuring mesh interfaces independently of
the used mesh protocol.
2016-09-07 02:14:42 +02:00
Matthias Schiffer
d70788adbc
gluon-status-page-api: hide warning in upgrade script 2016-08-30 22:09:40 +02:00
Matthias Schiffer
2331cb194e
gluon-mesh-batman-adv-core, gluon-mesh-vpn-fastd: switch MAC address assignment
Switch to:

1. WAN
2. LAN
3. Mesh VPN

As WAN and LAN are setup in gluon-mesh-batman-adv-core (and will be moved
to gluon-core), while the mesh VPN has its own package, giving WAN and LAN
the first indices is preferable.
2016-08-30 21:25:40 +02:00
Matthias Schiffer
051fd926ef
gluon-wan-dnsmasq: add interface name to link-local addresses
Fixes #854
2016-08-28 22:04:47 +02:00
Matthias Schiffer
e0ed7dde85
gluon-config-mode-mesh-vpn: fix indentation 2016-08-27 16:39:30 +02:00
Matthias Schiffer
7e0075584d
Use a "pretty" hostname where possible
Fixes #414
2016-08-27 16:33:37 +02:00
Matthias Schiffer
819c7d59f1
gluon-config-mode-*, gluon-luci-*: add escaping for many user- or site-defined strings
Allows weird release numbers, models and site names, and prepares support
for pretty hostnames.
2016-08-27 15:18:13 +02:00
Matthias Schiffer
79a49a1515
gluon-luci-theme: add HTML and URL escaping utility functions 2016-08-27 13:19:42 +02:00
kb-light
81280d8e18 gluon-mesh-batman-adv-core: use need_one_of() to check for valid mcast_rate 2016-08-27 07:12:07 +02:00
kb-light
6ff94aca35 gluon-core: make wifi rates configurable by site.conf
and add documentation
2016-08-27 07:11:58 +02:00
Matthias Schiffer
c84bb17915
Merge branch 'enable-multicast-snooping' of https://github.com/T-X/gluon 2016-08-26 21:05:30 +02:00
Matthias Schiffer
e5acba5fbc
gluon-radvd: fix init script
Fixes #862
2016-08-24 13:07:29 +02:00
Linus Lüssing
6594ba314c gluon-core: reenable multicast snooping on WAN side
Just like we enabled multicast snooping on the batman-adv client bridge
again, let's do the same for the WAN side.

With one exception: The IGMP/MLD querier is kept disabled to avoid
becoming too "bossy"/"noisy" on a foreign network. The main router on
the WAN side should perform querying and by that enable
IGMP/MLD/snooping if it considers this appropriate there.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2016-08-23 00:21:26 +02:00
Linus Lüssing
2a51d94fbb gluon-mesh-batman-adv-core: reenable multicast snooping
A few issues with the bridge snooping were identified and fixed
upstream in OpenWRT:

* "firewall: Allow IGMP and MLD input on WAN" (r45613)
* "kernel: bridge: backport two snooping related patches" (r45783)
* netifd: "bridge: Fix multicast_to_unicast feature by hairpin+isolate"
  (OW: "netifd: update to the latest version, adds multicast-to-unicast fixes" (r46719))
* "kernel: bridge, multicast-to-unicast: assign src after pskb_may_pull()" (r46721)
* "kernel: bridge, multicast-to-unicast: fix echoes on STA" (46765)

These have very likely caused issues with the bridge snooping before,
which led to disabling it in the past. Let's reenable the multicast
snooping now that they were fixed for reduced multicast overhead on the
wifi.

Advantages are the following:

This mildly reduces overhead on the mesh layer. And significantly reduces
overhead on the AP interface and therefore significantly increases
available airtime (the currently most significant scalability bottleneck).

Secondly removes an easy, often accidental node-local Denial-of-Service
vector based on multicast flooding / streaming.

Thirdly, makes node-local multicast streaming feasible.

Finally should noticably increase battery life of mobile devices.

Note: bridge querier is disabled for br-wan. We want to avoid becoming
too "bossy"/"noisy" on a foreign network.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2016-08-23 00:15:27 +02:00
T-X
d5829d87be gluon-mesh-batman-adv-core: disable bridge port learning on bat0 (#780)
The mesh side has become fairly huge in many communities. Up to
a few thousand entries can currently be found in the forwarding
database (fdb) of a bridge for its bridge port bat0.

The bridge fdb is kind of redundant to the batman-adv global translation
table here. Therefore this patch tries to reduce memory footprint by
following an approach similar to the IGMP/MLD split patchset approach:

Make the bridge oblivious not only regarding multicast listeners towards
the mesh but with this patch unicast hosts on the mesh, too.

If the destination of an ethernet frame is known by the bridge to be a
local one, then the frame is forwarded to the according port. If it is
unknown, then the frame is forwarded to the wifi AP interface and bat0.

mac80211 and batman-adv then know whether to drop or forward a frame
further through their own book-keeping.

Note that unicast-flood is not disabled for the wifi AP bridge port, nor
is learning disabled on the wifi AP. This is mainly to keep the
configuration in UCI and according setup scripts simple ;). However, not
disalbling unicast-flood on the wifi AP interface might also give a
minor latency improvement for newly joining wifi clients.

Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
2016-08-22 23:26:07 +02:00
kb-light
2789aebcb2 gluon-luci-private-wifi: limit ssid to 32 characters (#848)
Fixes #845
2016-08-08 11:38:57 +02:00
Jan-Philipp Litza
d445cb772d gluon-radvd: Use procd in init script
The main advantage is that procd is capable of logging stderr to logd,
making errors easier to debug.
2016-07-30 20:27:20 +02:00
Matthias Schiffer
f3cb6d7b36
gluon-luci-portconfig: add setting for PoE passthrough
Fixes #328
2016-07-30 00:04:17 +02:00
Matthias Schiffer
b1a753e1c5
gluon-core: allow setting PoE passthrough default setting from site.conf 2016-07-30 00:00:39 +02:00
Matthias Schiffer
b241373640
gluon-luci-private-wifi: set MAC address if the driver provides one 2016-07-28 00:27:47 +02:00
Matthias Schiffer
279a409198
gluon-core: split get_wlan_mac_from_driver() out of get_wlan_mac() 2016-07-27 17:25:05 +02:00
Matthias Schiffer
806af27083
gluon-client-bridge, gluon-mesh-batman-adv-core: make macaddr variable local in upgrade script 2016-07-27 17:25:05 +02:00
Matthias Schiffer
7565839fc4 Merge pull request #674 from T-X/filter-igmp-mld
Filter IGMP+MLD
2016-07-27 17:24:43 +02:00
Matthias Schiffer
85674a5557
gluon-luci-admin: rename "Expert Mode" to "Advanced settings"
Use the common term; the "Expert Mode" never was a distinct mode of
operation anyways.
2016-07-27 02:38:39 +02:00
Matthias Schiffer
5e3b1f80b0
gluon-luci-admin: regenerate fr.po 2016-07-27 02:35:06 +02:00
Christof Schulze
65ee128c37
gluon-radvd: externalize arguments
The arguments are now provided by gluon-mesh-batman-adv-core, so
gluon-radvd can be used with other mesh protocols.

[Matthias Schiffer: removed PROVIDES dependency]
2016-07-27 01:24:33 +02:00
Matthias Schiffer
55d6f71cff
gluon-setup-mode: remove unneeded require 2016-07-26 01:11:03 +02:00
lemoer
8e8f794c24 gluon-neighbour-info: improve verbosity on wrong cli parameters (#829)
gluon-neighbour-info: improve verbosity on wrong cli parameters
2016-07-25 15:52:27 +02:00
Matthias Schiffer
2afe34efec
Use MAC addresses provided by WLAN drivers by default
Some drivers (mt76) don't support arbitrary MAC addresses. Use the
addresses provided by the driver (avoiding the primary address) by default,
but fall back to our has-based scheme when the driver doesn't provide
(enough) addresses.
2016-07-20 18:42:56 +02:00
Matthias Schiffer
c8bc4620d1
gluon-core: unify indentation in gluon/util.lua 2016-07-20 17:51:09 +02:00
Matthias Schiffer
849af9ade0
gluon-client-bridge, gluon-mesh-batman-adv-core: simplify VIF config functions 2016-07-20 15:44:36 +02:00
Matthias Schiffer
64fdc0d7ba
gluon-mesh-batman-adv-core: add sleep to autoupdater network stop script
Accidentially forgot to commit this. The sleep is necessary so netifd can
actually stop the WLAN interfaces after `wifi down`.
2016-07-19 15:49:07 +02:00
Jan-Tarek Butt
8f5a7c9001
gluon-mesh-batman-adv-core: stop WLAN and batman-adv before autoupdater upgrades
[Matthias Schiffer:
  - improve commit message
  - add pidof check
  - also call `wifi down`
]
2016-07-19 03:41:21 +02:00
Jan-Tarek Butt
1c1f490527
Minify all Lua code 2016-07-10 20:14:25 +02:00
Matthias Schiffer
42910c0606
ramips-mt7621: use phy1 MAC address as primary on DIR-860L B1 2016-07-10 15:51:07 +02:00
Matthias Schiffer
c913957e01
gluon-luci-wifi-config: fix to work with legacy configs using macaddr instead of path to identify radios 2016-07-09 23:32:46 +02:00
Matthias Schiffer
bae721a9bb
Add target ar71xx-mikrotik
Fixes #121

Based-on-patch-by: Tobias Hachmer <tobias@hachmer.de>
2016-06-23 00:29:28 +02:00
Matthias Schiffer
dc485f7356
gluon-core: make gluon.platform.match() match all boards when no boards are given 2016-06-23 00:07:25 +02:00
Sven Eckelmann
fa04fff88d ar71xx-generic: Add support for OpenMesh MR1750v2
The new MR1750v2 device support is only available in LEDE master. The
relevant patches have to backported to add support for them in Gluon

Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
2016-06-17 20:04:00 +02:00