librecmc/librecmc.git
3 years agolibrecmc: bump to v1.5.5
RISCi_ATOM [Tue, 30 Mar 2021 14:26:10 +0000 (10:26 -0400)]
librecmc: bump to v1.5.5

3 years agoluci: Add luci-app-unbound to base
RISCi_ATOM [Tue, 30 Mar 2021 02:56:42 +0000 (22:56 -0400)]
luci: Add luci-app-unbound to base

3 years agotools: mklibs Add HOST_CPPFLAGS to fix compilation w/ GCC11
RISCi_ATOM [Mon, 29 Mar 2021 18:19:08 +0000 (14:19 -0400)]
tools: mklibs Add HOST_CPPFLAGS to fix compilation w/ GCC11

3 years agombedtls: update to 2.16.10
Magnus Kroken [Sun, 14 Mar 2021 18:42:33 +0000 (19:42 +0100)]
mbedtls: update to 2.16.10

This release of Mbed TLS provides bug fixes and minor enhancements. This
release includes fixes for security issues.

Security fixes:
* Fix a buffer overflow in mbedtls_mpi_sub_abs()
* Fix an errorneous estimation for an internal buffer in
mbedtls_pk_write_key_pem()
* Fix a stack buffer overflow with mbedtls_net_poll() and
mbedtls_net_recv_timeout()
* Guard against strong local side channel attack against base64 tables
by making access aceess to them use constant flow code

Full release announcement:
https://github.com/ARMmbed/mbedtls/releases/tag/v2.16.10

Signed-off-by: Magnus Kroken <mkroken@gmail.com>
(cherry picked from commit dbde2bcf60b5d5f54501a4b440f25fe7d02fbe5d)

3 years agoopenssl: bump to 1.1.1k
Eneas U de Queiroz [Fri, 26 Mar 2021 17:46:29 +0000 (14:46 -0300)]
openssl: bump to 1.1.1k

This version fixes 2 security vulnerabilities, among other changes:

 - CVE-2021-3450: problem with verifying a certificate chain when using
   the X509_V_FLAG_X509_STRICT flag.

 - CVE-2021-3449: OpenSSL TLS server may crash if sent a maliciously
   crafted renegotiation ClientHello message from a client.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
(cherry picked from commit 0bd0de7d43b3846ad0d7006294e1daaadfa7b532)

3 years agouboot-envtools: Add tpe-r1300
RISCi_ATOM [Wed, 17 Mar 2021 17:04:44 +0000 (13:04 -0400)]
uboot-envtools: Add tpe-r1300

3 years agohostapd: P2P: Fix a corner case in peer addition based on PD Request
Stefan Lippers-Hollmann [Sat, 27 Feb 2021 22:55:08 +0000 (23:55 +0100)]
hostapd: P2P: Fix a corner case in peer addition based on PD Request

p2p_add_device() may remove the oldest entry if there is no room in the
peer table for a new peer. This would result in any pointer to that
removed entry becoming stale. A corner case with an invalid PD Request
frame could result in such a case ending up using (read+write) freed
memory. This could only by triggered when the peer table has reached its
maximum size and the PD Request frame is received from the P2P Device
Address of the oldest remaining entry and the frame has incorrect P2P
Device Address in the payload.

Fix this by fetching the dev pointer again after having called
p2p_add_device() so that the stale pointer cannot be used.

This fixes the following security vulnerabilities/bugs:

- CVE-2021-27803 - A vulnerability was discovered in how p2p/p2p_pd.c
  in wpa_supplicant before 2.10 processes P2P (Wi-Fi Direct) provision
  discovery requests. It could result in denial of service or other
  impact (potentially execution of arbitrary code), for an attacker
  within radio range.

Fixes: 17bef1e97a50 ("P2P: Add peer entry based on Provision Discovery Request")
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
(cherry picked from commit 1ca5de13a153061feae260864d73d96f7c463785)

3 years agohostapd: backport ignoring 4addr mode enabling error
Raphaël Mélotte [Wed, 17 Feb 2021 14:58:16 +0000 (15:58 +0100)]
hostapd: backport ignoring 4addr mode enabling error

This is a backport of the upstream commit 58bbbb598144 ("nl80211: Ignore
4addr mode enabling error if it was already enabled").

 nl80211_set_4addr_mode() could fail when trying to enable 4addr mode on
 an interface that is in a bridge and has 4addr mode already enabled.
 This operation would not have been necessary in the first place and this
 failure results in disconnecting, e.g., when roaming from one backhaul
 BSS to another BSS with Multi AP.

 Avoid this issue by ignoring the nl80211 command failure in the case
 where 4addr mode is being enabled while it has already been enabled.

Signed-off-by: Raphaël Mélotte <raphael.melotte@mind.be>
[bump PKG_RELEASE, more verbose commit description]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit fb860b4e418c28a0f388f215e5acce103dcee1bf)

3 years agowolfssl: bump to v4.7.0-stable
Eneas U de Queiroz [Sun, 21 Feb 2021 21:33:30 +0000 (18:33 -0300)]
wolfssl: bump to v4.7.0-stable

Biggest fix for this version is CVE-2021-3336, which has already been
applied here.  There are a couple of low severity security bug fixes as
well.

Three patches are no longer needed, and were removed; the one remaining
was refreshed.

This tool shows no ABI changes:
https://abi-laboratory.pro/index.php?view=objects_report&l=wolfssl&v1=4.6.0&v2=4.7.0

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
(cherry picked from commit d1dfb577f1c0d5b1f1fa35000c9ad7abdb7d10ed)

3 years agobuild: fix checks for GCC11
Petr Štetiar [Mon, 1 Mar 2021 12:29:19 +0000 (13:29 +0100)]
build: fix checks for GCC11

Fedora 34 already uses GCC11.

Reported-by: Marcin Juszkiewicz <marcin-openwrt@juszkiewicz.com.pl>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit cae69d558135456976b8fc6cb08530d1358cf6d5)

3 years agoopenssl: bump to 1.1.1j
Eneas U de Queiroz [Wed, 17 Feb 2021 02:21:36 +0000 (23:21 -0300)]
openssl: bump to 1.1.1j

This fixes 4 security vulnerabilities/bugs:

- CVE-2021-2839 - SSLv2 vulnerability. Openssl 1.1.1 does not support
  SSLv2, but the affected functions still exist. Considered just a bug.

- CVE-2021-2840 - calls EVP_CipherUpdate, EVP_EncryptUpdate and
  EVP_DecryptUpdate may overflow the output length argument in some
  cases where the input length is close to the maximum permissable
  length for an integer on the platform. In such cases the return value
  from the function call will be 1 (indicating success), but the output
  length value will be negative.

- CVE-2021-2841 - The X509_issuer_and_serial_hash() function attempts to
  create a unique hash value based on the issuer and serial number data
  contained within an X509 certificate. However it was failing to
  correctly handle any errors that may occur while parsing the issuer
  field (which might occur if the issuer field is maliciously
  constructed). This may subsequently result in a NULL pointer deref and
  a crash leading to a potential denial of service attack.

- Fixed SRP_Calc_client_key so that it runs in constant time. This could
  be exploited in a side channel attack to recover the password.

The 3 CVEs above are currently awaiting analysis.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
(cherry picked from commit 482c9ff289c65480c8e7340e1740db24c62f91df)

3 years agowolfssl: Backport fix for CVE-2021-3336
Hauke Mehrtens [Mon, 8 Feb 2021 23:53:09 +0000 (00:53 +0100)]
wolfssl: Backport fix for CVE-2021-3336

This should fix CVE-2021-3336:
DoTls13CertificateVerify in tls13.c in wolfSSL through 4.6.0 does not
cease processing for certain anomalous peer behavior (sending an
ED22519, ED448, ECC, or RSA signature without the corresponding
certificate).

The patch is backported from the upstream wolfssl development branch.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 1f559cafe5cc1193a5962d40a2d938c66c783171)

3 years agohostapd: fix P2P group information processing vulnerability
Daniel Golle [Thu, 4 Feb 2021 01:01:36 +0000 (01:01 +0000)]
hostapd: fix P2P group information processing vulnerability

A vulnerability was discovered in how wpa_supplicant processing P2P
(Wi-Fi Direct) group information from active group owners.
This issue was discovered by fuzz testing of wpa_supplicant by Google's
OSS-Fuzz.

https://w1.fi/security/2020-2/wpa_supplicant-p2p-group-info-processing-vulnerability.txt

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
[added the missing patch]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry-picked from commit 7c8c4f1be648aff9f1072ee27a2cc8f6a4a788ef)

3 years agoopkg: update to latest git HEAD of branch openwrt-19.07
Baptiste Jonglez [Sun, 31 Jan 2021 15:40:40 +0000 (16:40 +0100)]
opkg: update to latest git HEAD of branch openwrt-19.07

c5dccea libopkg: fix md5sum calculation
7cad0c0 opkg_verify_integrity: better logging and error conditions
14d6480 download: purge cached packages that have incorrect checksum
456efac download: factor out the logic for building cache filenames
b145030 libopkg: factor out checksum and size verification
74bac7a download: remove compatibility with old cache naming scheme

Fixes: FS#2690

Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org>
3 years agowolfssl: enable HAVE_SECRET_CALLBACK
Felix Fietkau [Sat, 2 Jan 2021 13:36:03 +0000 (14:36 +0100)]
wolfssl: enable HAVE_SECRET_CALLBACK

Fixes wpad-wolfssl build

Signed-off-by: Felix Fietkau <nbd@nbd.name>
(cherry picked from commit 55e23f2c02ae95e84613ed7d1cbf8aba557b8682)

3 years agowolfssl: Fix hostapd build with wolfssl 4.6.0
Hauke Mehrtens [Fri, 1 Jan 2021 21:04:18 +0000 (22:04 +0100)]
wolfssl: Fix hostapd build with wolfssl 4.6.0

This fixes the following build problem in hostapd:
mipsel-openwrt-linux-musl/bin/ld: /builder/shared-workdir/build/tmp/ccN4Wwer.ltrans7.ltrans.o: in function `crypto_ec_point_add':
<artificial>:(.text.crypto_ec_point_add+0x170): undefined reference to `ecc_projective_add_point'
mipsel-openwrt-linux-musl/bin/ld: <artificial>:(.text.crypto_ec_point_add+0x18c): undefined reference to `ecc_map'
mipsel-openwrt-linux-musl/bin/ld: /builder/shared-workdir/build/tmp/ccN4Wwer.ltrans7.ltrans.o: in function `crypto_ec_point_to_bin':
<artificial>:(.text.crypto_ec_point_to_bin+0x40): undefined reference to `ecc_map'

Fixes: ba40da9045f7 ("wolfssl: Update to v4.6.0-stable")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit e7d0d2e9dcaa0ff1197fb7beee139b6a5bd35c79)

3 years agowolfssl: Update to v4.6.0-stable
Eneas U de Queiroz [Tue, 29 Dec 2020 17:49:20 +0000 (14:49 -0300)]
wolfssl: Update to v4.6.0-stable

This version fixes a large number of bugs and fixes CVE-2020-36177.

Full changelog at:
https://www.wolfssl.com/docs/wolfssl-changelog/
or, as part of the version's README.md:
https://github.com/wolfSSL/wolfssl/blob/v4.6.0-stable/README.md

Due a number of API additions, size increases from 374.7K to 408.8K for
arm_cortex_a9_vfpv3-d16.  The ABI does not change from previous version.

Backported patches were removed; remaining patch was refreshed.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
[added reference to CVE]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit ba40da9045f77feb04abe63eb8a92f13f9efe471)

3 years agodnsmasq: backport fixes v1.5.4a-20210124
Kevin Darbyshire-Bryant [Sun, 24 Jan 2021 10:24:29 +0000 (10:24 +0000)]
dnsmasq: backport fixes

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
3 years agonetifd: fix IPv6 routing loop on point-to-point links
Hans Dedecker [Thu, 21 Jan 2021 20:02:41 +0000 (21:02 +0100)]
netifd: fix IPv6 routing loop on point-to-point links

753c351 interface-ip: add unreachable route if address is offlink

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
3 years agoodhcp6c: fix IPv6 routing loop on point-to-point links
Hans Dedecker [Thu, 21 Jan 2021 19:57:56 +0000 (20:57 +0100)]
odhcp6c: fix IPv6 routing loop on point-to-point links

64e1b4e ra: fix routing loop on point to point links
f16afb7 ra: align ifindex resolving

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
3 years agoBump version to v1.5.4a
RISCi_ATOM [Fri, 22 Jan 2021 17:37:15 +0000 (12:37 -0500)]
Bump version to v1.5.4a

3 years agokernel: bump to 4.14.216
RISCi_ATOM [Fri, 22 Jan 2021 17:35:54 +0000 (12:35 -0500)]
kernel: bump to 4.14.216

3 years agombedtls: update to 2.16.9
Rosen Penev [Mon, 4 Jan 2021 00:28:43 +0000 (16:28 -0800)]
mbedtls: update to 2.16.9

Signed-off-by: Rosen Penev <rosenp@gmail.com>
(cherry picked from commit f13b623f5e53a72b65f45cbaf56c73df35e70ed2)

3 years agodnsmasq: Backport some security updates v1.5.4-20210122
Hauke Mehrtens [Mon, 11 Jan 2021 00:03:03 +0000 (01:03 +0100)]
dnsmasq: Backport some security updates

This fixes the following security problems in dnsmasq:
* CVE-2020-25681:
  Dnsmasq versions before 2.83 is susceptible to a heap-based buffer
  overflow in sort_rrset() when DNSSEC is used. This can allow a remote
  attacker to write arbitrary data into target device's memory that can
  lead to memory corruption and other unexpected behaviors on the target
  device.
* CVE-2020-25682:
  Dnsmasq versions before 2.83 is susceptible to buffer overflow in
  extract_name() function due to missing length check, when DNSSEC is
  enabled. This can allow a remote attacker to cause memory corruption
  on the target device.
* CVE-2020-25683:
  Dnsmasq version before 2.83 is susceptible to a heap-based buffer
  overflow when DNSSEC is enabled. A remote attacker, who can create
  valid DNS replies, could use this flaw to cause an overflow in a heap-
  allocated memory. This flaw is caused by the lack of length checks in
  rtc1035.c:extract_name(), which could be abused to make the code
  execute memcpy() with a negative size in get_rdata() and cause a crash
  in Dnsmasq, resulting in a Denial of Service.
* CVE-2020-25684:
  A lack of proper address/port check implemented in Dnsmasq version <
  2.83 reply_query function makes forging replies easier to an off-path
  attacker.
* CVE-2020-25685:
  A lack of query resource name (RRNAME) checks implemented in Dnsmasq's
  versions before 2.83 reply_query function allows remote attackers to
  spoof DNS traffic that can lead to DNS cache poisoning.
* CVE-2020-25686:
  Multiple DNS query requests for the same resource name (RRNAME) by
  Dnsmasq versions before 2.83 allows for remote attackers to spoof DNS
  traffic, using a birthday attack (RFC 5452), that can lead to DNS
  cache poisoning.
* CVE-2020-25687:
  Dnsmasq versions before 2.83 is vulnerable to a heap-based buffer
  overflow with large memcpy in sort_rrset() when DNSSEC is enabled. A
  remote attacker, who can create valid DNS replies, could use this flaw
  to cause an overflow in a heap-allocated memory. This flaw is caused
  by the lack of length checks in rtc1035.c:extract_name(), which could
  be abused to make the code execute memcpy() with a negative size in
  sort_rrset() and cause a crash in dnsmasq, resulting in a Denial of
  Service.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 years agoglibc: update to latest 2.27 commit
Hauke Mehrtens [Thu, 31 Dec 2020 17:22:49 +0000 (18:22 +0100)]
glibc: update to latest 2.27 commit

daf88b1dd1 Add NEWS entry for CVE-2020-6096 (bug 25620)
b29853702e arm: CVE-2020-6096: Fix multiarch memcpy for negative length [BZ #25620]
bad8d5ff60 arm: CVE-2020-6096: fix memcpy and memmove for negative length [BZ #25620]
d64ad0a517 Fix use-after-free in glob when expanding ~user (bug 25414)
34ce87638c Fix array overflow in backtrace on PowerPC (bug 25423)
0df8ecff9e misc/test-errno-linux: Handle EINVAL from quotactl
26f5442ec1 <string.h>: Define __CORRECT_ISO_CPP_STRING_H_PROTO for Clang [BZ #25232]
4b64a4245c intl/tst-gettext: fix failure with newest msgfmt
dc7f51bda9 aarch64: Fix DT_AARCH64_VARIANT_PCS handling [BZ #26798]
8edc96aa33 aarch64: add HWCAP_ATOMICS to HWCAP_IMPORTANT
599ebfacc0 aarch64: Remove HWCAP_CPUID from HWCAP_IMPORTANT

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 years agohostapd: add wpad-basic-wolfssl variant v1.5.4 v1.5.4-20201231
RISCi_ATOM [Thu, 31 Dec 2020 14:46:19 +0000 (09:46 -0500)]
hostapd: add wpad-basic-wolfssl variant

Add package which provides size optimized wpad with support for just
WPA-PSK, SAE (WPA3-Personal), 802.11r and 802.11w.

3 years agowireguard: Bump to v1.0.20201221
RISCi_ATOM [Tue, 29 Dec 2020 04:36:28 +0000 (23:36 -0500)]
wireguard: Bump to v1.0.20201221

3 years agoopenvpn: Bump to 2.4.10
RISCi_ATOM [Tue, 29 Dec 2020 03:21:56 +0000 (22:21 -0500)]
openvpn: Bump to 2.4.10

OpenVPN in the upstream 19.07 branch is no longer being
maintained; in master, openvpn has been removed from base and
was bump'ed to 2.5.x.

This moves openvpn forward with the last patches from 2.4.x
(excluding hotplug patches).

3 years agokernel: bump 4.14 to 4.14.212
RISCi_ATOM [Mon, 28 Dec 2020 18:22:36 +0000 (13:22 -0500)]
kernel: bump 4.14 to 4.14.212

Refreshed all patches.

Removed patches because included in upstream:
- 315-v5.10-usbnet-ipeth-fix-connectivity-with-ios-14.patch

3 years agowireless-regdb: Update to version 2020.11.20
Hauke Mehrtens [Wed, 16 Dec 2020 16:23:59 +0000 (17:23 +0100)]
wireless-regdb: Update to version 2020.11.20

9efa1da wireless-regdb: update regulatory rules for Egypt (EG)
ede87f5 wireless-regdb: restore channel 12 & 13 limitation in the US
5bcafa3 wireless-regdb: Update regulatory rules for Croatia (HR)
4e052f1 wireless-regdb: Update regulatory rules for Pakistan (PK) on 5GHz
f9dfc58 wireless-regdb: update 5.8 GHz regulatory rule for GB
c19aad0 wireless-regdb: Update regulatory rules for Kazakhstan (KZ)
07057d3 wireless-regdb: update regulatory database based on preceding changes

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 94d1b2508c38e21a5d1a45a4d80db2905bf1537c)

3 years agowireless-regdb: bump to latest release 2020-04-29
Petr Štetiar [Wed, 29 Apr 2020 21:11:05 +0000 (23:11 +0200)]
wireless-regdb: bump to latest release 2020-04-29

Update to latest release.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 493eef5b279a0455b76bfacabdec3af8bf642385)

3 years agomac80211: Update to version 4.19.161-1
Hauke Mehrtens [Sat, 5 Dec 2020 23:17:59 +0000 (00:17 +0100)]
mac80211: Update to version 4.19.161-1

The removed patches were applied upstream.

The changes to 357-mac80211-optimize-skb-resizing.patch are more
complex. I think the patch already took care of the new changes done
upstream.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 years agobase: Remove libtirpc from base v1.5.4-20201214
RISCi_ATOM [Sun, 13 Dec 2020 20:58:22 +0000 (15:58 -0500)]
base: Remove libtirpc from base

nfs-kernel-server was moved back to the package feeed a while ago
and libtirpc is in the package feed.

3 years agovpnc : Pull package from libreCMC src mirror vpnc svn repostiory is broken
RISCi_ATOM [Sat, 12 Dec 2020 23:46:33 +0000 (18:46 -0500)]
vpnc : Pull package from libreCMC src mirror vpnc svn repostiory is broken

3 years agoluci : Remove rpcd-mod-rad2-enc
RISCi_ATOM [Sat, 12 Dec 2020 23:45:04 +0000 (18:45 -0500)]
luci : Remove rpcd-mod-rad2-enc

3 years agotor: update to version 0.4.4.6
RISCi_ATOM [Sat, 12 Dec 2020 01:58:59 +0000 (20:58 -0500)]
tor: update to version 0.4.4.6

3 years agoopenssl: update to 1.1.1i
RISCi_ATOM [Fri, 11 Dec 2020 15:40:59 +0000 (10:40 -0500)]
openssl: update to 1.1.1i

Fixes: CVE-2020-1971, defined as high severity, summarized as:
NULL pointer deref in GENERAL_NAME_cmp function can lead to a DOS
attack.

Upstream commit : 882ca13d923796438fd06badeb00dc95b7eb1467

3 years agogeneric: ipeth: fix iOS 14 tethering
David Bauer [Sun, 29 Nov 2020 18:14:05 +0000 (19:14 +0100)]
generic: ipeth: fix iOS 14 tethering

This fixes tethering with devices using iOS 14. Prior to this patch,
connections to remote endpoints were not possible while data transfers
between the OpenWrt device and the iOS endpoints worked fine.

Signed-off-by: David Bauer <mail@david-bauer.net>
(cherry picked from commit f64496f30f2ef97124dc4e13a48ee0de9d51832e)

3 years agotools: always create $STAGING_DIR/usr/{include,lib}
Andre Heider [Thu, 20 Aug 2020 06:06:37 +0000 (08:06 +0200)]
tools: always create $STAGING_DIR/usr/{include,lib}

rules.mk always passes these as -I/-L to the toolchain.

Fixes rare errors like:
cc1: error: staging_dir/target-aarch64_cortex-a53_musl/usr/include: No such file or directory [-Werror=missing-include-dirs]

Signed-off-by: Andre Heider <a.heider@gmail.com>
Acked-by: Paul Spooren <mail@aparcar.org>
Acked-by: Rosen Penev <rosenp@gmail.com>
[fixed merge conflict]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit b0cb305236524095bfd899449b0ad8eb821cb3bb)

3 years agodownload.pl: properly cleanup intermediate .hash file
Petr Štetiar [Fri, 27 Nov 2020 20:56:30 +0000 (21:56 +0100)]
download.pl: properly cleanup intermediate .hash file

It seems like after a build the /dl dir seems to now contain a .hash
file for each source file due to inproper cleanup so fix it by removing
those intermediate files before leaving the download action.

Fixes: 4e19cbc55335 ("download: handle possibly invalid local tarballs")
Reported-by: Hannu Nyman <hannu.nyman@iki.fi>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 52a5d0d27f2557db99fc5435fbd7783b649cb9b2)

3 years agodownload: handle possibly invalid local tarballs
Petr Štetiar [Thu, 19 Nov 2020 15:32:46 +0000 (16:32 +0100)]
download: handle possibly invalid local tarballs

Currently it's assumed, that already downloaded tarballs are always
fine, so no checksum checking is performed and the tarball is used even
if it might be corrupted.

From now on, we're going to always check the downloaded tarballs before
considering them valid.

Steps to reproduce:

 1. Remove cached tarball

   rm dl/libubox-2020-08-06-9e52171d.tar.xz

 2. Download valid tarball again

   make package/libubox/download

 3. Invalidate the tarball

   sed -i 's/PKG_MIRROR_HASH:=../PKG_MIRROR_HASH:=ff/' package/libs/libubox/Makefile

 4. Now compile with corrupt tarball source

   make package/libubox/{clean,compile}

Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 4e19cbc553350b8146985367ba46514cf50e3393)

3 years agocmake.mk,rules.mk: fix host builds using CMake and ccache
Petr Štetiar [Fri, 27 Nov 2020 21:50:32 +0000 (22:50 +0100)]
cmake.mk,rules.mk: fix host builds using CMake and ccache

Commit f98878e4c17d ("cmake.mk: set C/CXX compiler for host builds as
well") has introduced regression as it didn't taken usage of ccache into
the account so fix it by handling ccache use cases as well.

In order to get this working we need to export HOSTCXX_NOCACHE in
rules.mk as well.

Fixes: f98878e4c17d ("cmake.mk: set C/CXX compiler for host builds as well")
Reported-by: Ansuel Smith <ansuelsmth@gmail.com>
Tested-by: Ansuel Smith <ansuelsmth@gmail.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 524fb5646eec6147aadfdd508219f39bcf8ba8fc)

3 years agocmake.mk: set C/CXX compiler for host builds as well
Rosen Penev [Thu, 26 Nov 2020 00:08:57 +0000 (16:08 -0800)]
cmake.mk: set C/CXX compiler for host builds as well

Without this, cmake will use whatever CC/CXX is set to, which could be
clang. In that case, at least libjson-c/host will fail to compile.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
(cherry picked from commit f98878e4c17d5f11e78994b4fc456e6b60b2660f)

3 years agomvebu: fixup Turris Omnia U-Boot environment
Klaus Kudielka [Fri, 27 Dec 2019 13:26:37 +0000 (14:26 +0100)]
mvebu: fixup Turris Omnia U-Boot environment

Fixup dfa357a3de "mvebu: base-files: Update Turris Omnia U-Boot
environment" which should have included this file as well.

By rebasing the initial patch this file somehow disappeared.

Signed-off-by: Klaus Kudielka <klaus.kudielka@gmail.com>
Reviewed-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Tested-by: W. Michael Petullo <mike@flyn.org> (Turris Omnia "2020")
Tested-by: Klaus Kudielka <klaus.kudielka@gmail.com> (Turris Omnia)
[explain fixup in commit message]
Signed-off-by: Paul Spooren <mail@aparcar.org>
(backported from commit 485ce5bbe5cc33526e56817694a79a7d94160e01)
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agomvebu: base-files: Update Turris Omnia U-Boot environment
Klaus Kudielka [Fri, 27 Dec 2019 13:26:37 +0000 (14:26 +0100)]
mvebu: base-files: Update Turris Omnia U-Boot environment

Move the update procedure from sysupgrade to first boot, which is much
more convenient in the sysupgrade case (otherwise the environment is
always one generation behind).

Check whether we have an old U-Boot release installed, and update the
environment only if necessary.

Some notes on the U-Boot environment:

The first 9 lines are a copy of the default environment of the old U-Boot
release - only modified, to run "distro_bootcmd", in case "mmcboot" fails
to boot the factory OS.

The remaining 16 lines are a backport of the default environment of the
new U-Boot release (shipped with CZ11NIC23). The main entry point is
"distro_bootcmd", which eventually sources boot.scr. This way, we have
a unified boot protocol for all Turris Omnia revisions so far.

This commit also fixes a shortcoming of previous Turris Omnia support:

Users may install OpenWrt with the Turris Omnia in factory state
(i.e. invalid environment store). In that case, neither fw_setenv, nor
U-Boot itself, would import the default environment from the image -
screwing up the rescue system, at least!

Signed-off-by: Klaus Kudielka <klaus.kudielka@gmail.com>
Reviewed-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Tested-by: W. Michael Petullo <mike@flyn.org> (Turris Omnia "2020")
Tested-by: Klaus Kudielka <klaus.kudielka@gmail.com> (Turris Omnia)
(cherry picked from commit dfa357a3def512c13f22371d24138b6e8093be18)

3 years agomvebu: Add turris-omnia.bootscript
Klaus Kudielka [Mon, 23 Dec 2019 07:34:49 +0000 (08:34 +0100)]
mvebu: Add turris-omnia.bootscript

In contrast to the U-Boot version shipped with older versions of Turris
Omnia (CZ11NIC13, CZ11NIC20), the version shipped with Turris Omnia 2019
(CZ11NIC23) relies on the existence of /boot.scr.

Consequently, add a suitable boot script to the sysupgrade image.

Flash instructions for Turris Omnia 2019:
- Download openwrt-...-sysupgrade.img.gz, gunzip it, and copy the resulting
  .img file to the root of a USB flash drive (FAT32 or ext2/3/4).
- Enter a rescue shell: Either via 5-LED reset and ssh root@192.168.1.1
  on LAN port 4, or via 7-LED reset and the serial console.
- Insert the USB drive and mount it:
  mkdir /mnt; mount /dev/sda1 /mnt
- Flash the OpenWrt image to eMMC:
  dd if=/mnt/openwrt-...-sysupgrade.img of=/dev/mmcblk0 bs=4096 conv=fsync
- Reboot.

Flash instructions using a temporary "medkit" installation were written for
the older versions of Turris Omnia, and will *not* work on the Turris Omnia
2019.

Signed-off-by: Klaus Kudielka <klaus.kudielka@gmail.com>
Reviewed-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Tested-by: W. Michael Petullo <mike@flyn.org> (Turris Omnia "2020")
(cherry picked from commit afd4375a33840fa949c898fb6bc603e8645edd61)

3 years agouboot-envtools: mvebu: update uci defaults for Turris Omnia
Klaus Kudielka [Fri, 27 Dec 2019 18:15:31 +0000 (19:15 +0100)]
uboot-envtools: mvebu: update uci defaults for Turris Omnia

On the Turris Omnia 2019, u-boot environment is located at 0xF0000, instead
of 0xC0000. The switch happened with u-boot-omnia package version 2019-04-2
(May 10, 2019).

Check the installed u-boot release, and set the default accordingly.

Signed-off-by: Klaus Kudielka <klaus.kudielka@gmail.com>
[bump PKG_RELEASE, use lower case for hex offset]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit 04d3b517dc3301e0148a2ce811ffc136568b04bd)

3 years agoDefaults: Enable wolfssl as the default libssl
RISCi_ATOM [Sun, 29 Nov 2020 20:09:15 +0000 (15:09 -0500)]
Defaults: Enable wolfssl as the default libssl

Upstream has moved to using wolfssl as the default libssl.
This also fixes a bug where ssl support is missing in core images
in v1.5.3).

3 years agoBump version to v1.5.4
RISCi_ATOM [Sun, 29 Nov 2020 01:25:20 +0000 (20:25 -0500)]
Bump version to v1.5.4

3 years agoath79 : Add support for the TPE-R1300
RISCi_ATOM [Sun, 29 Nov 2020 01:23:31 +0000 (20:23 -0500)]
ath79 : Add support for the TPE-R1300

This new target is the same TPE-R1200 board but lacks
128MB of NAND flash.

3 years agomvebu : Add missing swconfig package for Turris / WRT1900ACv1)
RISCi_ATOM [Sun, 29 Nov 2020 01:19:48 +0000 (20:19 -0500)]
mvebu : Add missing swconfig package for Turris / WRT1900ACv1)

3 years agoath79 : TPE-R1100 / GL.iNet GL-AR150 LED Fixup
RISCi_ATOM [Fri, 27 Nov 2020 21:19:46 +0000 (16:19 -0500)]
ath79 : TPE-R1100 / GL.iNet GL-AR150 LED Fixup

Fixes issues with LEDs on the TPE-R1100 / GL-AR150 and simliar boards.

Based upon upstream : e36bdd5dc5bf48fc0102394736c24a075959bc53

3 years agoscripts: download.pl: retry download using filename
David Bauer [Wed, 18 Nov 2020 15:02:23 +0000 (16:02 +0100)]
scripts: download.pl: retry download using filename

With this commit, the download script will try downloading source files
using the filename instead of the url-filename in case the previous
download attempt using the url-filename failed.

This is required, as the OpenWrt sources mirrors serve files using the
filename files might be renamed to after downloading. If the original
mirror for a file where url-filename and filename do not match goes
down, the download failed prior to this patch.

Further improvement can be done by performing this only for the
OpenWrt sources mirrors.

Signed-off-by: David Bauer <mail@david-bauer.net>
(cherry picked from commit d36999389890fb952fc7cc8c0db8e1bbb671af12)

3 years agotcpdump: patch CVE-2020-8037
Jan Pavlinec [Wed, 25 Nov 2020 01:04:00 +0000 (02:04 +0100)]
tcpdump: patch CVE-2020-8037

This PR backports upstream fix for CVE-2020-8037.  This fix is only
relevant for tcpdump package, tcpdump-mini is not affeted by this issue.

Signed-off-by: Jan Pavlinec <jan.pavlinec@nic.cz>
[added missing commit description]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 5bb3cc749ee0d08d82acda3c084ff759f3829a91)

3 years agokernel: mtd: parser: cmdline: Fix parsing of part-names with colons
Sven Eckelmann [Sun, 22 Nov 2020 00:17:35 +0000 (01:17 +0100)]
kernel: mtd: parser: cmdline: Fix parsing of part-names with colons

Some devices (especially QCA ones) are already using hardcoded partition
names with colons in it. The OpenMesh A62 for example provides following
mtd relevant information via cmdline:

  root=31:11 mtdparts=spi0.0:256k(0:SBL1),128k(0:MIBIB),384k(0:QSEE),64k(0:CDT),64k(0:DDRPARAMS),64k(0:APPSBLENV),512k(0:APPSBL),64k(0:ART),64k(custom),64k(0:KEYS),0x002b0000(kernel),0x00c80000(rootfs),15552k(inactive) rootfsname=rootfs rootwait

The change to split only on the last colon between mtd-id and partitions
will cause newpart to see following string for the first partition:

  KEYS),0x002b0000(kernel),0x00c80000(rootfs),15552k(inactive)

Such a partition list cannot be parsed and thus the device fails to boot.

Avoid this behavior by making sure that the start of the first part-name
("(") will also be the last byte the mtd-id split algorithm is using for
its colon search.

Fixes: 9c718b5478ac ("kernel: bump 4.14 to 4.14.200")
Signed-off-by: Sven Eckelmann <sven@narfation.org>
(backported from commit 223eec7e81f8506592fc89cf79a2f14360f5c57b)

3 years agomusl: handle wcsnrtombs destination buffer overflow (CVE-2020-28928)
Petr Štetiar [Fri, 20 Nov 2020 12:13:27 +0000 (13:13 +0100)]
musl: handle wcsnrtombs destination buffer overflow (CVE-2020-28928)

The wcsnrtombs function in all musl libc versions up through 1.2.1 has
been found to have multiple bugs in handling of destination buffer
size when limiting the input character count, which can lead to
infinite loop with no forward progress (no overflow) or writing past
the end of the destination buffera.

This function is not used internally in musl and is not widely used,
but does appear in some applications. The non-input-limiting form
wcsrtombs is not affected.

All users of musl 1.2.1 and prior versions should apply the attached
patch, which replaces the overly complex and erroneous implementation.
The upcoming 1.2.2 release will adopt this new implementation.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 4d4ef1058c0f10aa2fa4070cd6b9db4d48b94148)

3 years agoar71xx,ath79: refresh 910-unaligned_access_hacks.patch
Petr Štetiar [Tue, 24 Nov 2020 08:21:12 +0000 (09:21 +0100)]
ar71xx,ath79: refresh 910-unaligned_access_hacks.patch

Commit c9c7b4b3945c ("kernel: add netfilter-actual-sk patch") has
touched net/ipv6/netfilter/ip6table_mangle.c which in turn has affected
910-unaligned_access_hacks.patch so the patch needs to be refreshed.

Fixes: c9c7b4b3945c ("kernel: add netfilter-actual-sk patch")
Signed-off-by: Petr Štetiar <ynezz@true.cz>
3 years agokernel: add netfilter-actual-sk patch
Aaron Goodman [Sun, 15 Nov 2020 04:51:38 +0000 (23:51 -0500)]
kernel: add netfilter-actual-sk patch

Backport of linux kernel commit 46d6c5a to 4.14 kernel.

netfilter: use actual socket sk rather than skb sk when routing harder

Signed-off-by: Aaron Goodman <aaronjg@stanford.edu>
3 years agouhttpd: update to 19.07 Git HEAD
Jo-Philipp Wich [Fri, 20 Nov 2020 21:50:57 +0000 (22:50 +0100)]
uhttpd: update to 19.07 Git HEAD

3abcc89 client: fix spurious keepalive connection timeouts

Fixes: FS#3443
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
3 years agokernel : bump to 4.14.209
RISCi_ATOM [Fri, 27 Nov 2020 19:32:38 +0000 (14:32 -0500)]
kernel : bump to 4.14.209

4 years agowireguard-tools: fix category/description in menuconfig
Alberto Bursi [Tue, 17 Nov 2020 07:58:40 +0000 (08:58 +0100)]
wireguard-tools: fix category/description in menuconfig

wireguard-tools is trying to import the menuconfig section
from the wireguard package, but since it's not anymore in
the same makefile this seems to fail and wireguard-tools
ends up in "extra packages" category instead with other
odds and ends.

Same for the description, it's trying to import it from the
wireguard package but it fails so it only shows the line
written in this makefile.

remove the broken imports and add manually the entries
and description they were supposed to load

Fixes: ea980fb9c6de ("wireguard: bump to 20191226")

Signed-off-by: Alberto Bursi <bobafetthotmail@gmail.com>
[fix trailing whitespaces, add Fixes]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
4 years agowireguard: bump to 1.0.20201112
Jason A. Donenfeld [Thu, 12 Nov 2020 09:14:18 +0000 (10:14 +0100)]
wireguard: bump to 1.0.20201112

* noise: take lock when removing handshake entry from table

This is a defense in depth patch backported from upstream to account for any
future issues with list node lifecycles.

* netns: check that route_me_harder packets use the right sk

A test for an issue that goes back to before Linux's git history began. I've
fixed this upstream, but it doesn't look possible to put it into the compat
layer, as it's a core networking problem. But we still test for it in the
netns test and warn on broken kernels.

* qemu: drop build support for rhel 8.2

We now test 8.3+.

* compat: SYM_FUNC_{START,END} were backported to 5.4
* qemu: bump default testing version

The real motivation for this version bump: 5.4.76 made a change that broke our
compat layer.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
4 years agouci: Backport security fixes
Hauke Mehrtens [Tue, 27 Oct 2020 23:16:38 +0000 (00:16 +0100)]
uci: Backport security fixes

This packports two security fixes from master.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit f9005d4f80dee3dcc257d4613cbc46668faad094)

4 years agofirewall: options: fix parsing of boolean attributes
Hauke Mehrtens [Wed, 30 Sep 2020 21:19:02 +0000 (23:19 +0200)]
firewall: options: fix parsing of boolean attributes

Boolean attributes were parsed the same way as string attributes,
so a value of { "bool_attr": "true" } would be parsed correctly, but
{ "bool_attr": true } (without quotes) was parsed as false.

Fixes FS#3284

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 7f676b5ed6a2bcd6786a0fcb6a6db3ddfeedf795)

4 years agomac80211: do not allow bigger VHT MPDUs than the hardware supports
Felix Fietkau [Thu, 17 Sep 2020 10:09:23 +0000 (12:09 +0200)]
mac80211: do not allow bigger VHT MPDUs than the hardware supports

Signed-off-by: Felix Fietkau <nbd@nbd.name>
(cherry picked from commit caf727767ab5c8f8d884ef458c74726a8e610d96)
[Refreshed patch]
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
4 years agoath79: ar8216: make switch register access atomic
Chuanhong Guo [Mon, 21 Sep 2020 06:57:44 +0000 (14:57 +0800)]
ath79: ar8216: make switch register access atomic

reg accesses on integrated ar8229 sometimes fails. As a result, phy read
got incorrect port status and wan link goes down and up mysteriously.
After comparing ar8216 with the old driver, these local_irq_save/restore
calls are the only meaningful differences I could find and it does fix
the issue.
The same changes were added in svn r26856 by Gabor Juhos:
ar71xx: ag71xx: make switch register access atomic

As I can't find the underlying problem either, this hack is broght
back to fix the unstable link issue.
This hack is only suitable for ath79 mdio and may easily break the
driver on other platform. Limit it to ath79-only as a target patch.

Fixes: FS#2216
Fixes: FS#3226
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
(cherry picked from commit 86fdc8abed5992a74078b000b5ff9da723b6f46b)

4 years agokernel : Bump to 4.14.202
RISCi_ATOM [Thu, 22 Oct 2020 13:27:00 +0000 (09:27 -0400)]
kernel : Bump to 4.14.202

4 years agokernel: fix nand_release() usage. v1.5.3 v1.5.3-20201002
Hauke Mehrtens [Sat, 4 Jul 2020 18:36:16 +0000 (20:36 +0200)]
kernel: fix nand_release() usage.

nand_release() takes nand_chip since commit 5bcfcbfc4019 ("mtd: rawnand:
Pass a nand_chip object to nand_release()")

Fixes: f4985a22ca1b ("kernel: Update kernel 4.14 to version 4.14.187")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
4 years agolibrecmc: Bump version to v1.5.3
RISCi_ATOM [Wed, 30 Sep 2020 20:39:00 +0000 (16:39 -0400)]
librecmc: Bump version to v1.5.3

4 years agofirewall: backport patch for mss clamping in both directions
Yousong Zhou [Sun, 26 Jul 2020 10:22:53 +0000 (18:22 +0800)]
firewall: backport patch for mss clamping in both directions

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
4 years agofirewall: update to latest Git HEAD
Jo-Philipp Wich [Fri, 22 Nov 2019 17:53:03 +0000 (18:53 +0100)]
firewall: update to latest Git HEAD

8174814 utils: persist effective extra_src and extra_dest options in state file
72a486f zones: fix emitting match rules for zones with only "extra" options

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 482114d3f78df2a19904cc8edf7d9adcfdbb8625)

4 years agobusybox: delete redundant patch
Magnus Kroken [Fri, 24 Jul 2020 12:15:17 +0000 (14:15 +0200)]
busybox: delete redundant patch

This problem has been fixed in upstream commit
6b6a3d9339f1c08efaa18a7fb7357e20b48bdc95. This patch now (harmlessly)
adds the same definition a second time.

Signed-off-by: Magnus Kroken <mkroken@gmail.com>
[bump PKG_RELEASE]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit 4165232c45df224f32a94f43b9938d13d643b2a8)

4 years agombedtls: update to 2.16.8
Magnus Kroken [Tue, 1 Sep 2020 20:28:25 +0000 (22:28 +0200)]
mbedtls: update to 2.16.8

This release of Mbed TLS provides bug fixes and minor enhancements. This
release includes fixes for security issues and the most notable of them
are described in more detail in the security advisories.

* Local side channel attack on RSA and static Diffie-Hellman
* Local side channel attack on classical CBC decryption in (D)TLS
* When checking X.509 CRLs, a certificate was only considered as revoked
if its revocationDate was in the past according to the local clock if
available.

Full release announcement:
https://github.com/ARMmbed/mbedtls/releases/tag/v2.16.8

Signed-off-by: Magnus Kroken <mkroken@gmail.com>
4 years agowolfssl: Activate link time optimization (LTO)
Hauke Mehrtens [Tue, 1 Sep 2020 12:50:52 +0000 (14:50 +0200)]
wolfssl: Activate link time optimization (LTO)

The ipk sizes for mips_24Kc change like this:
old:
libwolfssl24_4.5.0-stable-1_mips_24kc.ipk 391.545

new:
libwolfssl24_4.5.0-stable-2_mips_24kc.ipk 387.439

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
4 years agowolfssl: add certgen config option
Paul Spooren [Sat, 29 Aug 2020 08:20:18 +0000 (22:20 -1000)]
wolfssl: add certgen config option

The option allows to generate certificates.

Signed-off-by: Paul Spooren <mail@aparcar.org>
4 years agoluci: Add support for wolfssl as an alternative to mbedtls.
RISCi_ATOM [Tue, 29 Sep 2020 16:59:33 +0000 (12:59 -0400)]
luci: Add support for wolfssl as an alternative to mbedtls.

Upstream is moving towards using wolfssl as the default libssl and
this change allows for users to use wolfssl with luci.

* Adds wolfssl variant of px5g
* Adds luci-ssl-wolfssl pkg

4 years agowireguard-tools: bump to 1.0.20200827
Jason A. Donenfeld [Tue, 8 Sep 2020 16:30:01 +0000 (18:30 +0200)]
wireguard-tools: bump to 1.0.20200827

* ipc: split into separate files per-platform

This is in preparation for FreeBSD support, which I had hoped to have this
release, but we're still waiting on some tooling fixes, so hopefully next
wg(8) will support that. Either way, the code base is now a lot more amenable
to adding more kernel platform support.

* man: wg-quick: use syncconf instead of addconf for strip example

Simple documentation fix.

* pubkey: isblank is a subset of isspace
* ctype: use non-locale-specific ctype.h

In addition to ensuring that isalpha() and such isn't locale-specific, we also
make these constant time, even though we're never distinguishing between bits
of a secret using them. From that perspective, though, this is markedly better
than the locale-specific table lookups in glibc, even though base64 characters
span two cache lines and valid private keys must hit both. This may be useful
for other projects too: https://git.zx2c4.com/wireguard-tools/tree/src/ctype.h

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
4 years agoopenssl: bump to 1.1.1h
Eneas U de Queiroz [Mon, 28 Sep 2020 10:46:33 +0000 (07:46 -0300)]
openssl: bump to 1.1.1h

This is a bug-fix release.  Patches were refreshed.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
(cherry picked from commit 475838de1a33d49d1a0b81aad374a8db6dd2b3c8)

4 years agocomgt: fix hotplug event handling
Rozhuk Ivan [Sat, 16 Nov 2019 02:10:05 +0000 (05:10 +0300)]
comgt: fix hotplug event handling

Hotplug manager send: "remove" -> "add" -> "bind" events,
script interpret bind as "not add" = "remove" and mark device
as unavailable.

Signed-off-by: Rozhuk Ivan <rozhuk.im@gmail.com>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> [PKG_RELEASE increase]
(cherry picked from commit 4821ff064b735c320ae2625a739018d1fc7d6457)
Fixes: FS#3351
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
4 years agokernel : bump to 4.14.199
RISCi_ATOM [Mon, 28 Sep 2020 22:06:31 +0000 (18:06 -0400)]
kernel : bump to 4.14.199

4 years agowireguard: bump to 1.0.20200908
Jason A. Donenfeld [Tue, 8 Sep 2020 16:28:30 +0000 (18:28 +0200)]
wireguard: bump to 1.0.20200908

* compat: backport kfree_sensitive and switch to it
* netlink: consistently use NLA_POLICY_EXACT_LEN()
* netlink: consistently use NLA_POLICY_MIN_LEN()
* compat: backport NLA policy macros

Backports from upstream changes.

* peerlookup: take lock before checking hash in replace operation

A fix for a race condition caught by syzkaller.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
4 years agohostapd: Fix compile errors after wolfssl update
Hauke Mehrtens [Thu, 27 Aug 2020 10:09:58 +0000 (12:09 +0200)]
hostapd: Fix compile errors after wolfssl update

This fixes the following compile errors after the wolfssl 4.5.0 update:
  LD  wpa_cli
../src/crypto/tls_wolfssl.c: In function 'tls_match_alt_subject':
../src/crypto/tls_wolfssl.c:610:11: error: 'GEN_EMAIL' undeclared (first use in this function); did you mean 'ENAVAIL'?
    type = GEN_EMAIL;
           ^~~~~~~~~
           ENAVAIL
../src/crypto/tls_wolfssl.c:610:11: note: each undeclared identifier is reported only once for each function it appears in
../src/crypto/tls_wolfssl.c:613:11: error: 'GEN_DNS' undeclared (first use in this function)
    type = GEN_DNS;
           ^~~~~~~
../src/crypto/tls_wolfssl.c:616:11: error: 'GEN_URI' undeclared (first use in this function)
    type = GEN_URI;
           ^~~~~~~
../src/crypto/tls_wolfssl.c: In function 'wolfssl_tls_cert_event':
../src/crypto/tls_wolfssl.c:902:20: error: 'GEN_EMAIL' undeclared (first use in this function); did you mean 'ENAVAIL'?
   if (gen->type != GEN_EMAIL &&
                    ^~~~~~~~~
                    ENAVAIL
../src/crypto/tls_wolfssl.c:903:20: error: 'GEN_DNS' undeclared (first use in this function)
       gen->type != GEN_DNS &&
                    ^~~~~~~
../src/crypto/tls_wolfssl.c:904:20: error: 'GEN_URI' undeclared (first use in this function)
       gen->type != GEN_URI)
                    ^~~~~~~
Makefile:2029: recipe for target '../src/crypto/tls_wolfssl.o' failed

Fixes: 00722a720c77 ("wolfssl: Update to version 4.5.0")
Reported-by: Andre Heider <a.heider@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
4 years agocurl: Bump to 7.72.0
RISCi_ATOM [Thu, 27 Aug 2020 15:45:28 +0000 (11:45 -0400)]
curl: Bump to 7.72.0

* Removes previous CVE patches.

* Uses wolfssl as the default.

4 years agowolfssl: Update to version 4.5.0
Hauke Mehrtens [Mon, 24 Aug 2020 10:11:29 +0000 (12:11 +0200)]
wolfssl: Update to version 4.5.0

This fixes the following security problems:
* In earlier versions of wolfSSL there exists a potential man in the
  middle attack on TLS 1.3 clients.
* Denial of service attack on TLS 1.3 servers from repetitively sending
  ChangeCipherSpecs messages. (CVE-2020-12457)
* Potential cache timing attacks on public key operations in builds that
  are not using SP (single precision). (CVE-2020-15309)
* When using SGX with EC scalar multiplication the possibility of side-
  channel attacks are present.
* Leak of private key in the case that PEM format private keys are
  bundled in with PEM certificates into a single file.
* During the handshake, clear application_data messages in epoch 0 are
  processed and returned to the application.

Full changelog:
https://www.wolfssl.com/docs/wolfssl-changelog/

Fix a build error on big endian systems by backporting a pull request:
https://github.com/wolfSSL/wolfssl/pull/3255

The size of the ipk increases on mips BE by 1.4%
old:
libwolfssl24_4.4.0-stable-2_mips_24kc.ipk: 386246
new:
libwolfssl24_4.5.0-stable-1_mips_24kc.ipk: 391528

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
4 years agowolfssl: use -fomit-frame-pointer to fix asm error
Eneas U de Queiroz [Tue, 26 May 2020 13:45:22 +0000 (10:45 -0300)]
wolfssl: use -fomit-frame-pointer to fix asm error

32-bit x86 fail to compile fast-math feature when compiled with frame
pointer, which uses a register used in a couple of inline asm functions.

Previous versions of wolfssl had this by default.  Keeping an extra
register available may increase performance, so it's being restored for
all architectures.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
4 years agowolfssl: update to 4.4.0-stable
Eneas U de Queiroz [Fri, 1 May 2020 15:06:48 +0000 (12:06 -0300)]
wolfssl: update to 4.4.0-stable

This version adds many bugfixes, including a couple of security
vulnerabilities:
 - For fast math (enabled by wpa_supplicant option), use a constant time
   modular inverse when mapping to affine when operation involves a
   private key - keygen, calc shared secret, sign.
 - Change constant time and cache resistant ECC mulmod. Ensure points
   being operated on change to make constant time.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
4 years agokernel: Bump to 4.14.198
RISCi_ATOM [Mon, 14 Sep 2020 20:44:06 +0000 (16:44 -0400)]
kernel: Bump to 4.14.198

4 years agokernel: Bump to 4.14.196
RISCi_ATOM [Fri, 4 Sep 2020 18:53:33 +0000 (14:53 -0400)]
kernel: Bump to 4.14.196

4 years agokernel: Bump to 4.14.195
RISCi_ATOM [Thu, 27 Aug 2020 02:59:48 +0000 (22:59 -0400)]
kernel: Bump to 4.14.195

4 years agokernel: Bump to 4.14.194
RISCi_ATOM [Mon, 24 Aug 2020 17:19:44 +0000 (13:19 -0400)]
kernel: Bump to 4.14.194

4 years agokernel: Bump to 4.14.193
RISCi_ATOM [Sun, 9 Aug 2020 00:39:17 +0000 (20:39 -0400)]
kernel: Bump to 4.14.193

4 years agokernel: Bump kernel to 4.14.191
RISCi_ATOM [Tue, 4 Aug 2020 20:58:18 +0000 (16:58 -0400)]
kernel: Bump kernel to 4.14.191

Remove:

* mvebu/patches-4.14/526-PCI-aardvark-disable-LOS-state-by-default.patch

* Normal refresh

4 years agokernel: Bump to 4.14.187
RISCi_ATOM [Fri, 10 Jul 2020 19:10:07 +0000 (15:10 -0400)]
kernel: Bump to 4.14.187

4 years agomac80211: Update to 4.19.137-1
RISCi_ATOM [Mon, 10 Aug 2020 15:50:51 +0000 (11:50 -0400)]
mac80211: Update to 4.19.137-1

4 years agomac80211: Fix potential endless loop
Hauke Mehrtens [Sat, 29 Aug 2020 17:23:57 +0000 (19:23 +0200)]
mac80211: Fix potential endless loop

Backport a fix from kernel 5.8.3.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit ca5ee6eba34593ec9f8b5b195c94cf6c3f6ff914)

4 years agowireguard: bump to 1.0.20200729 v1.5.2-20200816
Jason A. Donenfeld [Thu, 6 Aug 2020 18:38:16 +0000 (14:38 -0400)]
wireguard: bump to 1.0.20200729

* compat: rhel 8.3 beta removed nf_nat_core.h
* compat: ipv6_dst_lookup_flow was ported to rhel 7.9 beta

This compat tag adds support for RHEL 8.3 beta and RHEL 7.9 beta, in addition
to RHEL 8.2 and RHEL 7.8. It also marks the first time that
<https://www.wireguard.com/build-status/> is all green for all RHEL kernels.
After quite a bit of trickery, we've finally got the RHEL kernels building
automatically.

* compat: allow override of depmod basedir

When building in an environment with a different modules install path, it's
not possible to override the depmod basedir flag by setting the DEPMODBASEDIR
environment variable.

* compat: add missing headers for ip_tunnel_parse_protocol

This fixes compilation with some unusual configurations.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
4 years agotor: update to version 0.4.3.6 (security fix) v1.5.2-20200803
RISCi_ATOM [Mon, 3 Aug 2020 17:12:34 +0000 (13:12 -0400)]
tor: update to version 0.4.3.6 (security fix)

Applicable CVEs:
* CVE-2020-15572

Notes:
* Removes libssp hack : Upstream pkg. feed: 0df6c58f82f0b84ca08696d9d0760d425ce11917

4 years agomac80211: fix use of local variable
Leon M. George [Thu, 30 Apr 2020 08:26:36 +0000 (10:26 +0200)]
mac80211: fix use of local variable

mac80211_get_addr is called from mac80211_generate_mac, where the local variable
initialisation id="${macidx:-0}" suggests that macidx is not always defined.
Probably, idx was supposed to be used instead of $(($macidx + 1)).

Fixes: 4d99db168cf7 ("mac80211: try to get interface addresses from wiphy sysfs 'addresses' if no mask is set")

Signed-off-by: Leon M. George <leon@georgemail.eu>
(cherry picked from commit 8f95220bcb554b1b668114e5264ebce4028c5f93)

4 years agonghttp2: bump to 1.41.0
Hans Dedecker [Sat, 6 Jun 2020 12:00:37 +0000 (14:00 +0200)]
nghttp2: bump to 1.41.0

8f7b008b Update bash_completion
83086ba9 Update manual pages
c3b46625 Merge pull request from GHSA-q5wr-xfw9-q7xr
3eecc2ca Bump version number to v1.41.0, LT revision to 34:0:20
881c060d Update AUTHORS
f8da73bd Earlier check for settings flood
336a98fe Implement max settings option
ef415836 Revert "Add missing connection error handling"
979e6c53 Merge pull request #1459 from nghttp2/proxyprotov2
b7d16101 Add missing connection error handling
cd53bd81 Merge pull request #1460 from gportay/patch-1
e5625b8c Fix doc
c663349f integration: Add PROXY protocol v2 tests
854e9fe3 nghttpx: Always call init_forwarded_for
c60ea227 Update doc
49cd8e6e nghttpx: Add PROXY-protocol v2 support
3b17a659 Merge pull request #1453 from Leo-Neat/master
600fcdf5 Merge pull request #1455 from xjtian/long_serials
4922bb41 static_cast size parameter in StringRef constructor to size_t
aad86975 Fix get_x509_serial for long serial numbers
dc7a7df6 Adding CIFuzz
b3f85e2d Merge pull request #1444 from nghttp2/fix-recv-window-flow-control-issue
ffb49c6c Merge pull request #1435 from geoffhill/master
2ec58551 Fix receiving stream data stall
459df42b Merge pull request #1442 from nghttp2/upgrade-llhttp
a4c1fed5 Bump llhttp to 2.0.4
866eadb5 Enable session_create_idle_stream test, fix errors
5e13274b Fix typo
e0d7f7de h2load: Allow port in --connect-to
df575f96 h2load: add --connect-to option
1fff7379 clang-format-9
b40c6c86 Merge pull request #1418 from vszakats/patch-1
9bc2c75e lib/CMakeLists.txt: Make hard-coded static lib suffix optional
2d5f7659 Bump up version number to 1.41.0-DEV

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
Note this is cherry-pick from master. It fixes CVE-2020-11080
and  https://github.com/nxhack/openwrt-node-packages/issues/679

Signed-off-by: Jan Pavlinec <jan.pavlinec@nic.cz>
4 years agombedtls: update to 2.16.7
Magnus Kroken [Mon, 27 Jul 2020 14:36:42 +0000 (10:36 -0400)]
mbedtls: update to 2.16.7

Mbed TLS 2.16.7 is a maintenance release of the Mbed TLS 2.16 branch,
and provides bug fixes and minor enhancements. This release includes
fixes for security issues and the most severe one is described in more
detail in a security advisory:
https://tls.mbed.org/tech-updates/security-advisories/mbedtls-security-advisory-2020-07

* Fix a side channel vulnerability in modular exponentiation that could
reveal an RSA private key used in a secure enclave.
* Fix side channel in mbedtls_ecp_check_pub_priv() and
mbedtls_pk_parse_key() / mbedtls_pk_parse_keyfile() (when loading a private
key that didn't include the uncompressed public key), as well as
mbedtls_ecp_mul() / mbedtls_ecp_mul_restartable() when called with a NULL
f_rng argument. An attacker with access to precise enough timing and
memory access information (typically an untrusted operating system
attacking a secure enclave) could fully recover the ECC private key.
* Fix issue in Lucky 13 counter-measure that could make it ineffective when
hardware accelerators were used (using one of the MBEDTLS_SHAxxx_ALT
macros).

Due to Mbed TLS moving from ARMmbed to the Trusted Firmware project, some
changes to the download URLs are required. For the time being, the
ARMmbed/mbedtls Github repository is the canonical source for Mbed TLS.

Signed-off-by: Magnus Kroken <mkroken@gmail.com>