Commit Graph

893 Commits

Author SHA1 Message Date
Tim Wilkinson 610cde651c
Lua userpages (#190)
* Lua Services

* Lua versions of user page (non-admin)

* Support multiple antenna chains

* Improved led detection

* Fix logging

* Add manager.log files to support tool

* Lua versions of user page (non-admin)

* Dont count default route

* Fix board id for older nodes

* Handle missing node.history

* Check /tmp/snrlog exists

* Per discussion, make the Lua pages the defaults and Perl the backups
2022-01-19 07:42:31 -06:00
Tim Wilkinson fa6c2da4fe
Lua Services (#189)
* Lua Services

* Support multiple antenna chains

* Improved led detection

* Fix logging

* Add manager.log files to support tool
2022-01-17 18:54:44 -06:00
dman776 d7bc61ed6a
bugfix: remove filename checks for firmware uploads (#201)
* bugfix: remove filename checks for firmware uploads

* remove extra variable that are no longer needed
2022-01-15 21:56:48 -06:00
Tim Wilkinson 54589ff775 Fix missing location 2022-01-03 15:03:40 -08:00
dman776 488247753c
remove 'trunk' from snapshots path (#194) 2021-12-18 10:42:13 -06:00
Tim Wilkinson ee2791c621
Dmz mode migrate fix (#169)
* Migrate /etc/config/dmz-mode to /etc/dmz-mode

* Migrate dmz_mode into /etc/config/aredn

* Use cmd append

* Changes should be in /etc/config.mesh

* Add commit
2021-11-19 15:48:45 -06:00
dman776 f0c556941c
undo the renaming of output files that previously removed the -squashfs- portion to accomodate the OFS tool (#180) 2021-11-16 14:25:47 -06:00
dman776 7163819bf2
moved uci actions and file actions under file exists test (#173) 2021-11-12 08:34:31 -06:00
Tim Wilkinson f1b949134d
Stop creating 'config alerts' on every reboot. (#172)
Co-authored-by: Tim Wilkinson <tim@aredn-build.home>
2021-11-11 12:08:49 -06:00
battlehax 2c331fdd6f
Add files via upload (#174)
prevent unauthenticated remote code execution as root in the 'traceroute' function
2021-11-11 11:32:30 -06:00
dman776 90d9ac94bc
fix: duplicate to the config.mesh structure after saving. (#170) 2021-11-09 23:16:25 -06:00
dman776 f0c62fc2a7
enhancement: migrate location info to uci (#168)
* add uci migration script

* removed debug lines

* added newline to end

* include gridsquare values

* migrate lat/lon/gridsquare to uci format

* remove from sysupgrade kept files list
2021-11-09 17:03:20 -06:00
Tim Wilkinson 8ea58e4949 Revert failed olsrd fix 2021-11-08 19:40:47 -08:00
Tim Wilkinson ce296c94d4 Make sure wifi is up before letting OLSRD run 2021-11-07 11:09:34 -08:00
Phil Crump 837a3c602c
admin page: Fix validateFirmwareFilename() for underscore in ath79 filenames (#161) 2021-11-04 15:32:04 -05:00
Tim Wilkinson 1fd909b18d
Meshoween: Better way to add new uci meshstatus section (#159) 2021-11-03 21:26:56 -05:00
Tim Wilkinson 9cac3db003
aredn: Meshoween - Bug fixes (#158)
Create meshstatus section if missing
2021-11-03 13:25:06 -07:00
Tim Wilkinson 134532ab2a
aredn: Meshoween Mesh status page optimizations (#157)
* Memory and cpu performance improvements
* Fix bandwidth reporting
* Discard large arrays once we're done with them
* Fixup whitespace
* Improve string constructions
* Use available mem
* Print the Remote Nodes as we go (can be big)
* Local variables
* Stop re-reading arp/mac files
* Reduce calls to system 'cat'
* Simply lat/lon read
* Only read route30 once
* Whitespace
* Make meshstatus limits configurable
* and => &&, or => ||
* gzip content if we can

fixes #155
2021-11-02 21:35:39 -07:00
Phil Crump 7d6dfcb37d
aredn: Load leaflet assets asynchronously on setup page. (#151) 2021-10-25 20:43:55 -05:00
Phil Crump a6669cc53e
aredn: Fix validateFirmwareFilename() on admin page (#150)
Co-authored-by: Phil Crump <phil.crump@goonhilly.org>
2021-10-22 16:02:15 -05:00
Joe AE6XE 304540d0e1 aredn: add new ubnt Rocket M with USB device
new boardid 0xe112
2021-09-15 02:20:33 +01:00
dman776 c179ce40b7
Api add tactical name (#139) 2021-09-09 08:32:24 -05:00
Steve AB7PA 7908c3e2d4
api: fix remote nodes list (#138) 2021-09-09 08:31:20 -05:00
dman776 abb3b4ae79
enhancement: add freifunk repo to advancedconfig. fixes #143 (#144) 2021-08-31 13:10:00 -05:00
Eric 785161e932
aredn: fix long node names for tunnels. (#137)
fixes #11
also fixes: https://www.arednmesh.org/comment/7412#comment-7412
(which has been hanging around for um... _years_!!)
2021-07-20 09:07:10 -05:00
Steve AB7PA a3e33a2f9b
api: show version in info table (#135)
Include the api_version in the info table so it can be displayed in 
System card on newui.
2021-07-18 21:21:12 -05:00
Steve AB7PA db61c1181d
api: sort remote nodes (#134)
* api: sort remote nodes

one-liner to sort remoteNodes by ETX value for newui.

* api: sort remote nodes

ensure sort by floating point numbers
2021-07-18 21:20:48 -05:00
Eric 87ea92da2a
aredn: update the API version numbers (#132) 2021-07-13 21:29:32 -05:00
Steve AB7PA 8ff4156d37
fix snrlogging issue (#131)
Add default values to snr variables to avoid fatal errors that prevent 
snr.dat and snrlog/files from being written.
2021-07-10 12:40:28 -05:00
Eric 8f1d23e565
aredn: 20MHz wide channel fix for adjust_rate function in utils.lua (#129) 2021-07-10 12:40:01 -05:00
Steve AB7PA a7ab2c6a46
api: revise localhost function (#128)
* api: revise localhost function

Revise getLocalHosts() so it doesn't report unwanted hosts.  
getLocalCnxType() is no longer needed.

* include new iplookup function too

* incorporate Eric r1de values for getCurrentNeighbors

* use alternative for mac2host()

* get actual wlan interface for arp query

* tested on dualband radio

Tested on dualband radios with active clients on both Mesh RF and Wifi 
AP.

* add more error checking

* fix iplookup match

It is possible to have 2-digit "mid" prefixes. Fixes match to account 
for 2 possible digits.

* tighten up code

* add extra info values for Eric r1de
2021-07-10 12:39:25 -05:00
Eric 7fa6b57e1c
aredn: added network topology to mesh info API "page" (#125) 2021-07-10 12:38:11 -05:00
Steve AB7PA 49017f4cbf
add invalid link handling to api (#115) 2021-06-17 14:49:11 -05:00
Steve AB7PA e93987fe06
api: add RF IP for non-RF links (#124)
* api: add RF IP for non-RF links

Add the RF IP address for non-RF linked devices. This allows the 
services to be displayed for non-RF Current Neighbors.

* remove case manipulation
2021-06-17 14:48:19 -05:00
dman776 d595b9cf3d
add traceroute and remotenodes to api (#114) 2021-06-06 07:33:43 -05:00
Steve AB7PA 06bce04df1
fix MHz on status display (#118) 2021-06-05 10:37:53 -05:00
dman776 79aa11db40
Api use libiwinfo frequency (#112) 2021-05-26 09:57:47 -05:00
Steve AB7PA 10ff6f512f
Fix regex for current neighbor midxx.hostname (#110) 2021-05-22 23:45:00 -05:00
Steve AB7PA 79a57a0021
Add LocalHost Connection Type (#109)
Add a connection type field to info.lua so the api can provide it to the 
newui Local Hosts display.
2021-05-21 11:12:43 -05:00
Steve AB7PA 1c76248765
Remove local.mesh suffix from Local Hosts hostname in newui (#108) 2021-05-20 20:46:29 -05:00
Steve AB7PA 7633d10382
Remove local.mesh suffix from CurrentNeighbor hostname (#106)
* Remove local.mesh suffix from CurrentNeighbor hostname

* Uppercase hostname for consistency

* Make hostname lowercase for consistency with Local Hosts display in newui
2021-05-20 16:56:50 -05:00
AbortRetryFail 9fd900f631
Add build target for Meraki MR16 devices. (#104)
closes #103
closes #104
2021-05-16 15:29:40 -07:00
Steve AB7PA 780b696398
fix: Local Alert File Read All (#102)
* fix: Local Alert File Read All

Read the entire local_message file rather than just the first line.

* fix: Local Alert File Read All

Also fix the issue with empty alert files showing empty newui alert 
dialogs.
2021-05-11 21:27:05 -05:00
dman776 232d7bf6b2
api enhancement: convert getFreq to use lib-iwinfo (#101) 2021-05-06 00:05:57 -05:00
Steve AB7PA 8ef6e56925
Format Uptime as String (#100)
* Format Uptime as String

Format uptime as a string with values for days, hours, minutes, and 
seconds.

* Format uptime as String

Change code to use the secondsToClock function in utils.lua
2021-05-05 22:20:29 -05:00
dman776 209f9dc3f9
bugfix: fix api when meshrf is disabled (#99) 2021-05-05 12:53:19 -05:00
dman776 8117fcc74f
Lua info gateway (#95)
* api updates: alerts, targettype, api_version

* added filesystem and memory totals

* bugfix: correct error in api ip when there is no gateway
2021-04-23 10:10:40 -05:00
Paul K3PGM 3ddb7a0bb2
feature: runtime-configurable tunnel limits (#84) 2021-04-23 09:46:09 -05:00
Steve AB7PA d5c9e33e68
bug: Fix spike to zero in SNR Chart (#90)
Fix spike to zero in SNR Chart.
2021-04-06 21:18:00 -05:00
Steve AB7PA 6cc379d647
bug: fix nill typo (#88)
* bug: fix nill typo

Fix typo (nill to nil) in pidfile test.

* bug: fix nill typo

Fix typo (nill to nil).
2021-04-06 21:15:50 -05:00
Steve AB7PA 77ebea85c2
Execute Button Description (#86) 2021-03-27 11:28:17 -05:00
kc8ufv fa4c9c36ea Update perlfunc.pm
Added new hardware model strings for the Mikrotik Routerboard 911 & 912, since Mikrotik now puts them as RB911/RB912
2021-03-26 17:46:16 -07:00
dman776 c98126f812
feature: add "none" type advanced config options to simplify the UI (#81) 2021-03-21 19:14:29 -05:00
Paul K3PGM 130119f163
Tunnel servers limited to 9 - same fix as vtundsrv in f4a1e73 (#82) 2021-03-21 19:13:34 -05:00
dman776 38b5e01fee
feature: add mesh gateway setting to sysinfo.json (#77) 2021-03-15 09:39:27 -05:00
K3PGM 1381cf3868
Fix for uci_set_indexed_option() inserting multiple empty sections (#78) 2021-03-14 20:35:10 -05:00
dman776 cdf8057f65
bugfix: re-submit path reset2 (previously approved) (#75) 2021-03-12 20:02:08 -06:00
dman776 4b86b4f02a
feature: add advanced config option to purge AREDN Alert (and local alert) messages (#76) 2021-03-12 16:28:14 -06:00
ab7pa 89f110866f Update alert banner background color
Update the alert banner background color to distinguish it from the 
"supported hardware" messages. This makes it look more like a standard 
sticky note.
2021-03-07 00:32:58 -08:00
dman776 7c6c1e4636
bugfix: reset download paths upon upgrade to default (#69)
* bugfix: reset download paths upon upgrade to default, if standard paths are used.

* correct aredn_base path default
2021-02-23 21:23:06 -06:00
Joe AE6XE 011eab0895
aredn: add new Mikrotik model string for SXTsq5nD (#62) 2021-01-22 23:10:14 -06:00
Joe Ayers bf944dface AREDN: add new Mikrotik RBLHG-2nD model string
fixes #582
2020-10-18 16:11:36 -07:00
Joe Ayers 29a56b8850 aredn: add new mikrotik model string for LHG based devices
new model string: MikroTik RouterBOARD RBLHG-5HPnD
2020-10-07 22:42:15 -07:00
Eric e4a0c996ff bugfix: custom download paths during firmware upgrade
Fixes #575
2020-10-07 16:23:46 -07:00
Eric 2c1bd9ce0e
aredn: enhancement: Nat mode aliases
Aliases in NAT mode allows the node admin to create alias names for hosts on the LAN and then use those for creating port forwarding rules.  The aliases DO NOT effect the rest of the mesh network and are not propagated via OLSR.

NAT Mode aliases are only usable on the local LAN where the IP addresses are known and routable only on the subnet.   Since the NAT hides these IP addresses or the node masquerades, other mesh nodes and devices by definition only know about the node’s hostname.  Thus aliases on the LAN in NAT mode are not propagated by OLSR across the mesh.  You _CANNOT_ use an alias name in a service listing.

You _will_ be able to set an alternate hostname for any host on the nodes' LAN however.
A host named `CBY45-DELLLAPTOP` can also be known as `wxc-shack-laptop`. It may make remembering which host is which a bit easier.

Since OLSR does not propagate the alias,  the "Do Not Propagate" checkbox while in NAT Mode is hidden.
2020-10-07 16:20:59 -07:00
Eric 5948946de6
aredn: visualize non-propagated and aliased hosts (#569)
* enhancement: show the "non propagated" hosts as a grey color in the mesh list on the localnode.
This allows for the node admin to see, at a glance, which of the hosts are "hidden" or not.

* changed colors a little bit for the black background styles.
also assed in the aliases so now they will show up as a different color too.
this only effects the mesh listing on the localnode to where the aliases and/or non propagated hosts are.
the rest of the network does not see this.

* add a tooltip to the aliased/non propagated hostnames to help explain what they mean
2020-09-10 07:39:55 -05:00
Eric e13dd2cb04
aredn: allow aliased hostnames on the mesh
Allows for aliased hostnames on the mesh. One IP/Host can be assigned to multiple hostnames.
This is useful for many things including virtual hosts, virtual machines, virtual email addresses, etc.
The possibilities are actually _endless_.

Fixes #516
2020-09-08 16:39:49 -05:00
Joe Ayers f4a1e73189 aredn: bugfix max tunnel limited to 9 instead of 10
fixes #564
2020-09-08 14:39:23 -05:00
Steve Lewis AB7PA ad578d8944 Add file size tests to arednMsg
Add tests for file content to aredn_message.sh
2020-09-02 20:38:12 -05:00
Steve Lewis AB7PA afb18b3a52 Tweak aredn_message display
Tweak the node id on the AREDN message display.
2020-08-30 13:35:37 -05:00
Eric eadc184f3e fixed some formatting 2020-08-29 09:06:21 -05:00
Eric 8810e0eaaf Stop certain hostname/IP's from propagating over the mesh
Allows for the node admin to choose to have DHCP leased hostnames/IP's propagated over the rest of the mesh network or not.
Defaults to allowing the hostname/IP to propagate.

The hostname/IP will *still* be resolvable from the localnode and will show up in the list of hosts on the localnode only.
This allows for selected local mesh devices to be not available over the rest of the mesh network.
ie: switches, routers, cameras, etc.

This will work immediately for *new* DHCP leases when the checkbox is selected.
For *existing* DHCP leases, it may take a while for the network to update, if ever.
To speed up the process of full network OLSR "DNS" updating, reboot all the nearest neighbor device(s) to the node you made these changes to.
That seems to get the changes "out" to the rest of the network faster than normal.

Fixes #508
2020-08-29 09:06:21 -05:00
dman776 c0605cb306
enhancement: change advancedconfig boolean control (#560) 2020-08-26 18:34:30 -05:00
Steve Lewis AB7PA 5c14719e0b Add CSS fontfamily list
Add fontfamily list in CSS files to help browsers render sans-serif 
correctly. Add text color so alert messages display correctly on all 
themes.
2020-08-25 17:56:52 -05:00
Joe Ayers 8bf19db3a4 aredn: add settings for new model string RBSXTsq5HPnD 2020-08-24 19:01:24 -05:00
Steve Lewis AB7PA b29ecbdbe2 Change AdvConfig Warning Banner
Change the Advanced Configuration warning banner: slightly wider to 
distinguish from Alerts banner, add WARNING and make text color pure 
white for contrast.
2020-08-24 19:00:59 -05:00
dman776 8ec57de248
bugfix: correct lower-case translation for hostname (#555) 2020-08-22 09:50:58 -05:00
dman776 5e572ff66a
aredn: add aredn local alerts capability (#552) 2020-08-18 16:17:03 -05:00
Joe Ayers 6e579d4d6e aredn: extend 5GHz channel options from 133 down to 131
In the US, part 97 ham radio lower band edge is 5650.
Channel 131 @ 10MHz channel width is the lowest channel
setting that stays within allocation.

fixes #550
2020-08-18 16:08:04 -05:00
Joe Ayers 1adcfd77a5 aredn: remove config files no longer in use consuming flash
clean up 176k of flash space.  Config files include modes
forA P, Client, Mesh_Ap, and ROuter.  Files are no longer
referenced or used.
2020-06-29 08:11:44 -05:00
Joe AE6XE 7b3f205ffb
aredn: allow wan ping (#544)
fixes: #509
2020-06-24 21:08:06 -05:00
Joe Ayers c98916ad1a aredn: remove node mode configuration notation
in the past nodes could be configured uniquely for
a given mode:  ap, wifi client, mesh. Current behavior
in basic setup no longer has unique modes, rather wireless
cards can be configured in different modes in basic setup
and devices with multiple wireless interfaces can
be setup to use multiple modes at the same time.

fixes #533
fixes #535
2020-06-22 22:00:01 -05:00
Joe Ayers 5ccb4c3486 aredn: remove olsr status in help, no longer in UI
fixes #537
2020-06-20 20:32:11 -05:00
Eric 31492676dc
update: Change the nodes default map tile server URL away from MapBox (#527) 2020-06-20 19:54:12 -05:00
Joe Ayers 79f3b518d0 aredn: supporttool: change format of firewall reporting
use iptable -L -v options to see chain order and enable
improved ability to troubleshoot firewall issues
2020-05-28 23:07:06 -05:00
Joe Ayers cecca6854d aredn: add Mode ether to tunnel interfaces
This reduces message forwarding by OLSR. Without this mode
olsr will forward a message backout the same interface it
was received on, presumably due to hidden 802.11n nodes.
2020-05-28 23:06:42 -05:00
Joe Ayers 16e33b5306 aredn: add new Mikrotik model strings for RBLHG-5nD and RBLHG-2nD-XL 2020-05-27 19:33:56 -05:00
apcameron 80619b73a9
ath79: Migrate the TP-LINK WBS Devices to the ath79 Branch (#525) 2020-05-01 09:30:39 -05:00
Joe AE6XE b53ce1e817
bugfix: aredn firewall blocking traffic when using tunnel feature (#524)
fixes #522
tested by: Matthew KB9OIV <Matthew.annen@gmail.com>
tested by: Chris K3ADA <sutehk.cs@gmail.com>

Resolves 2 issues with tunnel iptable rules.  A rule needed to be
shifted down by 1 position in chain given upgrade to openwrt 19.07.
Reload of rules was not correctly retaining chain order and creating
duplicate entries, inadvertantly blocking intended traffic.
2020-04-29 20:54:29 -05:00
apcameron 62adfa9eb8
ath79: Migrate CPE210 v1/v1.1, CPE510v1/v1.1 to the ATH79 Branch (#523)
Installation:

Flash factory image through stock firmware WEB UI
or through TFTP:
To get to TFTP recovery just hold reset button while powering on for
around 4-5 seconds and release.
Rename factory image to recovery.bin
Stock TFTP server IP:192.168.0.100
Stock device TFTP address:192.168.0.254
2020-04-28 22:29:37 -05:00
Eric 1ace91aae2 bugfix: encode special characters in tunnel comment field
catch the tunnel comment field in perlfunc's read_post_data function where certain characters are changed to the html character entity in order to not interfere with the config files.
Tested with all kinds of crazy charcters such as: zdsfkh? <!@#$%^&*()> "quote"

Fixes #515
2020-04-23 17:33:44 -07:00
apcameron 31c6669c2f ath79: add support for TP-Link CPE220 v2
Specifications:

    * SoC: Qualcomm Atheros AR9344 (560 MHz)
    * RAM: 64MB
    * Storage: 8 MB
    * Wireless: 2.4GHz N based built into SoC 2x2
    * Ethernet: 2x 100/10 Mbps, integrated into SoC, 24V POE IN

Installation:

Flash factory image through stock firmware WEB UI
or through TFTP:
To get to TFTP recovery just hold reset button while powering on for
around 4-5 seconds and release.
Rename factory image to recovery.bin
Stock TFTP server IP:192.168.0.100
Stock device TFTP address:192.168.0.254
2020-04-20 19:20:57 -07:00
apcameron 831df9af23 ath79: Add Support for the TP-Link CPE610-v2
TP-Link CPE610-v2 is an outdoor wireless CPE for 5 GHz with
one Ethernet port based on Atheros AR9344
Specifications:
Based on the same underlying hardware as the TP-Link CPE510
Power, LAN0, WLAN green LEDs
23dBi high-gain directional 2×2 MIMO antenna and a dedicated metal reflector
Flashing instructions:
Flash factory image through stock firmware WEB UI
or through TFTP
To get to TFTP recovery just hold reset button while powering on for
around 4-5 seconds and release.
Rename factory image to recovery.bin
Stock TFTP server IP:192.168.0.100
Stock device TFTP adress:192.168.0.254
Signed-off-by: Andrew Cameron apcameron@softhome.net
2020-04-15 05:53:06 -07:00
apcameron b452af4c05 bugfix: migrate the TP-LINK CPE610 v1 device to the ath79 branch 2020-04-10 17:54:51 -07:00
dman776 3298de7fb8
feature: add aam_refresh method to advanced config page (#511) 2020-04-09 19:52:39 -05:00
apcameron 3b4ac70028 bugfix: Migrate the TP-LINK CPE510 v2/v3 to the ath79 branch 2020-04-09 06:13:28 -07:00
dman776 c3f94bd0d5
feature: add "aredn alerts" feature in header (#505)
* feature: add "aredn alerts" feature in header

* optimize conditional logic

* additional fixes

* improve presentation display
2020-04-08 21:31:01 -05:00
Eric 5142710e20
bugfix: fix variables in perlfunc (#506) 2020-04-07 18:42:29 -05:00
Eric 3f1646682e
bug: leaflet css and js files from mesh hosts (#501)
correct issue with the map on the setup page in PR #490
2020-04-04 09:31:07 -05:00
dman776 cdd1f8e96c
feature: add target type info (ar71xx/ath79) to admin page (#500)
* feature: add target type info (ar71xx/ath79) to admin page

* changed order of info
2020-04-03 17:50:55 -05:00