Commit Graph

8007 Commits

Author SHA1 Message Date
Tianling Shen
5699f9a760
CONTRIBUTED: add OSDN logo
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 1a14adb127)
2021-11-30 20:44:37 +08:00
AmadeusGhost
ee017ae07d mac80211: fix typo error in scripts 2021-11-30 11:41:32 +08:00
AmadeusGhost
3d8937fc08 ath10k: drop unneeded ignore debug info patch 2021-11-30 11:39:18 +08:00
Stefan Lippers-Hollmann
a2d8c9a8c8 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 1ca5de13a1)
2021-11-30 11:36:45 +08:00
Raphaël Mélotte
91c02d06de 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 fb860b4e41)
2021-11-30 11:36:04 +08:00
Daniel Golle
61c6cbaa2c 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 7c8c4f1be6)
2021-11-30 11:35:16 +08:00
Felix Fietkau
0cc1b0e1f1 hostapd: unconditionally enable ap/mesh for wpa-cli
Without this change, wpa-cli features depend on which wpad build variant was
used to build the wpa-cli package

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Tested-by: Jérôme Benoit <jerome.benoit@piment-noir.org> [WRT1900AC v1]
[added missing package version bump]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit 03e9e4ba9e)
2021-11-30 11:33:44 +08:00
AmadeusGhost
202742604b default-settings: simplified installation
Also fix typo error which will cause build failed.
Fixes: 75954bd ("default-settings: split cnh variant into a separated pkg")
2021-11-29 23:29:39 +08:00
Tianling Shen
476c1bb63f
autocore-arm: rebuild when target was changed
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 37b7b17698)
2021-11-29 23:18:35 +08:00
Tianling Shen
4c3a0af01c
scripts/download.pl: tweak default mirrors
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-29 13:23:45 +08:00
Tianling Shen
3c902654f2
default-settings: add missing INSTALL_DIR
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 0a62131a05)
2021-11-29 11:02:17 +08:00
Tianling Shen
923d73b691
scripts/download.pl: reorder self-hosted mirrors
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit d26b4ff4de)
2021-11-29 03:31:03 +08:00
Tianling Shen
58954a92d6
Config-images: change default title to ImmortalWrt
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-29 03:20:25 +08:00
Tianling Shen
20d63fb882
Config-images: tweak default settings for x86
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-29 03:18:26 +08:00
Tianling Shen
097de3d38b
kernel: bump to 4.9.291, 4.14.256, 4.19.218
Upstreamed patches:
- ar71xx/patches-4.9/821-serial-core-add-support-for-boot-console-with-arbitr.patch
- ar71xx/patches-4.14/821-serial-core-add-support-for-boot-console-with-arbitr.patch
- ath79/patches-4.14/921-serial-core-add-support-for-boot-console-with-arbitr.patch

Manually rebased:
- generic/backport-4.14/273-batman-adv-Convert-packet.h-to-uapi-header.patch
- ipq806x/patches-4.14/0065-arm-override-compiler-flags.patch
- ipq806x/patches-4.19/0065-arm-override-compiler-flags.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-29 01:23:44 +08:00
Tianling Shen
75954bd23a
default-settings: split cnh variant into a separated pkg
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-29 01:11:22 +08:00
AmadeusGhost
f763a22235 ppp/2.4.9: refresh patches
Cherry picked from commit bdc9c0c.
2021-11-28 23:48:18 +08:00
Eike Ritter
af4a60eb4c ppp: compile fix: unset FILTER variable in Makefile
If the environment variable FILTER is set before compilation,
compilation of the ppp-package will fail with the error message

Package ppp is missing dependencies for the following libraries:
libpcap.so.1

The reason is that the OpenWrt-patch for the Makefile only comments
out the line FILTER=y. Hence the pcap-library will be dynamically
linked if the environment variable FILTER is set elsewhere, which
causes compilation to fail. The fix consists on explicitly unsetting
the variable FILTER instead.

Signed-off-by: Eike Ritter <git@rittere.co.uk>
2021-11-28 23:43:23 +08:00
Hauke Mehrtens
298cd3388c ppp: Update to version 2.4.9
Upstream integrated multiple patches from Distributions and did other
changes:
* rp-pppoe.so was renamed to pppoe.so
* Converted to ANSI C

The following patches were applied upstream:
* 100-debian_ip-ip_option.patch
* 101-debian_close_dev_ppp.patch
* 103-debian_fix_link_pidfile.patch
* 106-debian_stripMSdomain.patch
* 107-debian_pppoatm_wildcard.patch
* 110-debian_defaultroute.patch
* 202-no_strip.patch

Compilation with musl libc was fixed upstream so
140-pppoe_compile_fix.patch is not needed any more

Parts of the 203-opt_flags.patch patch were applied in a different way
upstream.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-11-28 23:42:24 +08:00
Rosy Song
1fcc7aba42 ppp: don't start ppp with IPv6 support if ipv6 is not supported
Signed-off-by: Rosy Song <rosysong@rosinson.com>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-11-28 23:35:03 +08:00
Rosen Penev
8a52924c8e
tools/libressl: update to 3.4.1
Signed-off-by: Rosen Penev <rosenp@gmail.com>
(cherry picked from commit 03bb3412a2)
2021-11-28 00:02:46 +08:00
Paul Spooren
fdd28bfdee
config: pack toolchain per default on buildbots
The toolchain can be used for accelerated CI builds. This commit enabled
the packing of it by default on buildbots.

Signed-off-by: Paul Spooren <mail@aparcar.org>
(cherry picked from commit f887c93be7)
2021-11-27 03:52:11 +08:00
Adrian Schmutzler
3a3fc47da8
target: fix copying of licenses for SDK/toolchain
The SDK and target/toolchain copy the license file into their
directories. During the rename/move from LICENSE to a LICENSES
folder, this has not been updated.

Update it now, and include the new COPYING file.

While at it, improve formatting/indent.

Fixes: 882e301461 ("LICENSES: include all used licenses in
LICENSES directory")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit 4894a3ff28)
2021-11-27 03:50:59 +08:00
Tianling Shen
a8e033e020
rules: add legacy mark
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-26 00:14:49 +08:00
Daniel Golle
828c88adbf libubox: update to git HEAD
9e52171 blobmsg: introduce BLOBMSG_CAST_INT64

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-11-25 23:38:16 +08:00
Andy Walsh
0abf4a4d09
librpc: remove package
* replaced with packages/libtirpc
* remove busybox options rarely used/deprecated
BUSYBOX_CONFIG_FEATURE_MOUNT_NFS
BUSYBOX_CONFIG_FEATURE_INETD_RPC

Signed-off-by: Andy Walsh <andy.walsh44+github@gmail.com>
(cherry picked from commit 94f6030170)
2021-11-25 23:11:20 +08:00
Oldřich Jedlička
1c32248ab0 dnsmasq: fix ismounted check
Fix the return value, shell return codes should be 0 to indicate success
(i.e. mount point found), 1 should be failure (i.e. mount point not-found).

Fixes: ac4e8aa ("dnsmasq: fix more dnsmasq jail issues")
Signed-off-by: Oldřich Jedlička <oldium.pro@gmail.com>
2021-11-24 12:39:18 +08:00
Rui Salvaterra
da2e72fef7 dnsmasq: fix the dynamic dns object names patch
We can't use booleans, since we're not including stdbool.h. Use integers
instead.

Fixes: 0b79e7c01e ("dnsmasq: generate the dns object name dynamically")

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-11-24 12:38:04 +08:00
Felix Fietkau
48d8bf977a dnsmasq: generate the dns object name dynamically
Fixes an issue with running multiple dnsmasq instances

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-11-24 12:37:44 +08:00
Felix Fietkau
9dbd56c36a dnsmasq: add support for monitoring and modifying dns lookup results via ubus
The monitoring functionality will be used for dns rule support in qosify

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-11-24 12:37:21 +08:00
Paul Fertser
f271ce5b3c dnsmasq: add match_tag for --dhcp-host
A set of tags can be specified for --dhcp-host option to restrict the
assignment to the requests which match all the tags.

Example usage:

config vendorclass
        option networkid 'udhcp'
        option vendorclass 'udhcp'

config host
        option mac '*:*:*:*:*:*'
        list match_tag 'switch.10'
        list match_tag 'udhcp'
        option ip '192.168.25.10'

Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2021-11-24 12:36:23 +08:00
Daniel Golle
f74dd21b5c dnsmasq: fix jail mount in case of ignore_hosts_dir being set
Commit a2fcd3900c ("dnsmasq: improve init script") broke the existing
handling for hosts_dir. Remove the redundant mount again to fix it.

Reported-by: Hartmut Birr <e9hack@gmail.com>
Fixes: a2fcd3900c ("dnsmasq: improve init script")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-11-24 12:35:44 +08:00
Daniel Golle
a9725f32a0 dnsmasq: improve init script
* fix restart in LuCI (inherited umask was to restrictive)
 * make directory of hosts-file (!= /tmp) accessible in ujail

Reported-by: Hannu Nyman <hannu.nyman@iki.fi>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-11-24 12:35:20 +08:00
Tianling Shen
404f8f2992
scripts/download.pl: add immortalwrt's mirrors
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-21 01:07:21 +08:00
Felix Fietkau
cb8dc7b14e toolchain: add a version that can be bumped to force toolchain/target rebuild
This can be used to ensure that the compiled code is up to date, when
something important changes in the toolchain.
A recent example of this is the gcc 11 fix for a code miscompilation issue

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-11-19 23:58:57 +08:00
Felix Fietkau
3595a902d3 toolchain/gcc: revert a faulty upstream commit that caused miscompiled code
This broke at least the OKLI loader, but possibly other things as well

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-11-19 23:58:34 +08:00
Daniel Golle
11fd374b67 ltq-vdsl-fw: update w921v firmware download URL
Update Telekom Speedport W921V firmware download URL.
Contained TAPI and VDSL firmware blobs are identical.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-11-19 23:58:21 +08:00
Tianling Shen
c3ca7d454b
kernel: bump to 4.9.290, 4.14.255, 4.19.217
Manually rebased:
- generic/pending-4.19/110-ehci_hcd_ignore_oc.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-18 20:27:23 +08:00
Tianling Shen
92c43b059b
target: add luci-lib-ipkg to default packages
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-11-17 00:07:15 +08:00
Eneas U de Queiroz
9faf4324d4 hostapd: set VARIANT=* for wpa-cli, hostapd-utils
19aae94 [build: avoid rebuilds of unset VARIANT packages] builds
packages defined without a VARIANT only once, using the first VARIANT
defined in the Makefile.

This caused problems with wpa-cli, as it is only built for variants that
include supplicant support, and the first VARIANT defined may not build
it.

The same happens to hostapd-utils, which is not built for
supplicant-only variants.

To circumvent this, set VARIANT=* for both packages so that they get
built for every defined variant.  This should not cause spurious
rebuilds, since tey are not a dependency of any other package defined in
this Makefile.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:19:02 +08:00
Eneas U de Queiroz
066d40393f build: allow package to be built for all variants
This allows a package to be rebuilt for all different VARIANTs.
To do so, set VARIANT=*.

The wpa-cli package is not getting built after changes made by
19aae94 [build: avoid rebuilds of unset VARIANT packages], because
wpa-cli is only built when compiling a variant that includes
supplicant support, and the first selected variant may not build it.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:18:49 +08:00
Eneas U de Queiroz
28c057976c iproute2: Avoid unnecessary package rebuilds
Build the tc-mod-iptables before the tc-tiny and tc-full packages.

This avoids unnecessary package rebuild when calling make back to back.
Before this change, tc-mod-iptables will be built after the main tc
binary packages.

Both tc-tiny and tc-full depend on tc-mod-ipables.  If make is called
after the packages are already built, it will check the timestamps of
both packages, and will rebuild the main binaries, since the module
package will be newer than the tc package.

Calling BuildPackage,mod-iptables first ensures that its variant gets
built before the other packages' variants.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:17:52 +08:00
Eneas U de Queiroz
a09443deb9 f2fstools: set each library package VARIANT
Set the different libf2fs packages's VARIANT, so that the right settings
will be used by each different variant, if they are both being built.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:17:31 +08:00
Eneas U de Queiroz
87fb61cd89 hostapd: avoid unnecessary package rebuilds
Package hostapd-common is a dependency of every other package defined in
hostpad Makefile.  It is currently built next to the bottom of that
Makefile's package list.

If you run make back to back, then check-compile will compare the
hostapd-common timestamp to the variant being compiled, to decide if the
varint needs to be rebuilt or not.  Since the hostapd-conf package is
built towards the end of the list, it will be newer than most of the
variants, causing unnecessary package rebuilds.

Move it to the top, so that its timestamp will be older than dependent
packages, avoiding unnecessary rebuild of every selected variant.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:16:44 +08:00
Eneas U de Queiroz
3c3cbd9214 build: kernel: avoid unnecessary package rebuilds
The $(LINUX_DIR)/.config timesptamp changes between runs of
make target/compile and make target/install (which builds the image).

Kernel-dependent packages and out of tree modules are built in between
those runs, and they check the .config timestamp to decide if they need
to be rebuilt.

Save the target/compile .config to use its timestamp if the file does
not change between runs.  That way the subsequent kernel packages are
not unnecessarily rebuilt when you run 'make' back to back.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:15:41 +08:00
Eneas U de Queiroz
7162cbb4b5 download: improve handling of invalid local files
4e19cbc553: [download: handle possibly invalid local tarballs] added a
FORCE rule to downloaded files, so that they will be always checked by
download.pl.

As a side-effect, check-compile will fail, forcing unnecessary package
rebuilds.
The check-compile.txt log shows (for libxml2 for example):
  Considering target file '.../dl/libxml2-2.9.12.tar.gz'.
    ...
    prerequisite 'FORCE' of target '.../dl/libxml2-2.9.12.tar.gz' does
    not exist.
    Must remake target '.../dl/libxml2-2.9.12.tar.gz'.
    ...
   Giving up on target file '...libxml2-2.9.12/.prepared_...'.
   Giving up on target file '...libxml2-2.9.12/.configured_...'.
   Giving up on target file '...libxml2-2.9.12/.built'.
   Giving up on target file '...stamp/.libxml2_installed'.
  Giving up on target file '.compile'.

Then the package is rebuilt even if it is not otherwise needed.

To fix this, instead of always forcing the download target to be remade,
check its hash first: if it matches, then the FORCE is not added.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2021-11-16 13:12:54 +08:00
Felix Fietkau
d0eae20238
build: add SUBDIR_MAKE_DEBUG variable to make it easier to debug package makefiles
Signed-off-by: Felix Fietkau <nbd@nbd.name>
(cherry picked from commit 94b0849c19)
2021-11-12 14:20:06 +08:00
Eneas U de Queiroz
8ae4d1d901
build: avoid rebuilds of unset VARIANT packages
If a Makefile defines some packages with VARIANT set, and others without
it, the latter will be built once for every different VARIANT set, each
build trumping the previous one.

Avoid rebuilds by only building unnamed variant packages when the first
variant is built.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
(cherry picked from commit 19aae949c6)
2021-11-12 14:19:51 +08:00
AmadeusGhost
b3527703b2 fstools: update to 2020-07-11
Remove upstreamed patch.
2021-11-11 23:58:42 +08:00
AmadeusGhost
b613d40f8d gargoyle: cleanup build warning and makefile 2021-11-11 15:46:50 +08:00