164 Commits

Author SHA1 Message Date
George Sapkin
c9895bfda8 golang: bump to 1.25.5
Fixes: CVE-2025-61727
Fixes: CVE-2025-61729
Link: https://github.com/golang/go/issues?q=milestone%3AGo1.25.5+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-12-04 14:05:58 +02:00
George Sapkin
bfd5e0e899 golang: set GOARM64 based on CONFIG_CPU_TYPE
Fixes: https://github.com/openwrt/packages/issues/26852
Signed-off-by: George Sapkin <george@sapk.in>
2025-11-09 15:23:50 +02:00
George Sapkin
9e5831ed42 golang: bump to 1.25.4
go1.25.4 (released 2025-11-05) includes fixes to the compiler, the
runtime, and the crypto/subtle, encoding/pem, net/url, and os packages.

Link: https://github.com/golang/go/issues?q=milestone%3AGo1.25.4+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-11-08 14:18:48 +01:00
Tianling Shen
23c3d208e8 golang: Update to 1.25.3
go1.25.2 (released 2025-10-07) includes security fixes to the
archive/tar, crypto/tls, crypto/x509, encoding/asn1, encoding/pem,
net/http, net/mail, net/textproto, and net/url packages, as well as
bug fixes to the compiler, the runtime, and the context, debug/pe,
net/http, os, and sync/atomic packages.

go1.25.3 (released 2025-10-13) includes fixes to the crypto/x509
package.

Changelog: https://go.dev/doc/devel/release#go1.25.minor

Fixes:
- CVE-2025-47912
- CVE-2025-58183
- CVE-2025-58185
- CVE-2025-58186
- CVE-2025-58187
- CVE-2025-58188
- CVE-2025-58189
- CVE-2025-61723
- CVE-2025-61724
- CVE-2025-61725

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-10-20 22:56:05 +08:00
Sandro Jäckel
e4b9245fcf golang: update to 1.25.1
Fixes: CVE-2025-47910
Link: https://github.com/golang/go/issues?q=milestone%3AGo1.25.1%20label%3ACherryPickApproved
Signed-off-by: Sandro Jäckel <sandro.jaeckel@gmail.com>
2025-09-16 22:04:00 +08:00
George Sapkin
bfd3058770 golang: bump to 1.25.0
Fixes: CVE-2025-47907
Link: https://go.dev/doc/go1.25
Signed-off-by: George Sapkin <george@sapk.in>
2025-08-24 22:25:17 +08:00
Tianling Shen
c8ad05854d golang: disable build for powerpc64
e5500 is the only powerpc64 target we have in tree, but it's not
supported by golang[1]. Since it's hard to opt e5500 out from the
supported arch list, simply remove powerpc64 from it for now.

1. https://github.com/golang/go/issues/19074

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-08-04 12:50:19 +08:00
George Sapkin
d0932ad76c golang: bump to 1.24.5
go1.24.5 (released 2025-07-08) includes security fixes to the go
command, as well as bug fixes to the compiler, the linker, the runtime,
and the go command.

Link: https://github.com/golang/go/issues?q=milestone%3AGo1.24.5+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-07-10 15:44:43 +08:00
George Sapkin
09f434056d golang: bump to 1.24.4
go1.24.4 (released 2025-06-05) includes security fixes to the
crypto/x509, net/http, and os packages, as well as bug fixes to the
linker, the go command, and the hash/maphash and os packages.

Fixes CVE-2025-4673

Link: https://github.com/golang/go/issues?q=milestone%3AGo1.24.4+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-06-16 18:23:12 +08:00
Jeffery To
f7d2ebfe37 golang: Fix host build compatibility with GCC 15
Fixes https://github.com/openwrt/packages/issues/26446.

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2025-06-05 20:45:14 +02:00
George Sapkin
4f9e5b37d0 golang: bump to 1.24.3
go1.24.3 (released 2025-05-06) includes security fixes to the os
package, as well as bug fixes to the runtime, the compiler, the linker,
the go command, and the crypto/tls and os packages.

Link: https://github.com/golang/go/issues?q=milestone%3AGo1.24.2+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-05-08 14:23:41 +08:00
George Sapkin
73c9031169 golang: bump to 1.24.2
go1.24.2 (released 2025-04-01) includes security fixes to the net/http
package, as well as bug fixes to the compiler, the runtime, the go
command, and the crypto/tls, go/types, net/http, and testing packages.

Link: https://github.com/golang/go/issues?q=milestone%3AGo1.24.2+label%3ACherryPickApproved
Signed-off-by: George Sapkin <george@sapk.in>
2025-04-05 02:33:53 +08:00
Tianling Shen
e28a0846d9 golang: Update to 1.24.1
go1.24.1 (released 2025-03-04) includes security fixes to the net/http
package, as well as bug fixes to cgo, the compiler, the go command,
and the reflect, runtime, and syscall packages.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-03-07 01:22:45 +08:00
Tianling Shen
b211946520 golang: Update to 1.24.0
Add libstdcpp and libtiff as dependencies, which are required by
debug/elf package.

Release note: https://go.dev/doc/go1.24

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-03-07 01:22:45 +08:00
Tianling Shen
86b0144211 golang: Update to 1.23.6
go1.23.5 (released 2025-01-16) includes security fixes to the
crypto/x509 and net/http packages, as well as bug fixes to the
compiler, the runtime, and the net package.

go1.23.6 (released 2025-02-04) includes security fixes to the
crypto/elliptic package, as well as bug fixes to the compiler
and the go command.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-02-09 17:54:10 +08:00
Tianling Shen
edab60b0f8 golang: Update to 1.23.4
go1.23.4 (released 2024-12-03) includes fixes to the compiler, the
runtime, the trace command, and the syscall package.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-12-30 11:31:27 +08:00
Tianling Shen
b9dc86034b golang: Update to 1.23.3
go1.23.3 (released 2024-11-06) includes fixes to the linker,
the runtime, and the net/http, os, and syscall packages.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-11-16 16:39:04 +08:00
Milinda Brantini
cd20d4c394 golang: Update to 1.23.2
go1.23.2 (released 2024-10-01) includes fixes to the compiler, cgo,
the runtime, and the maps, os, os/exec, time, and unique packages.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-10-03 17:09:51 +08:00
Milinda Brantini
ae0d0879f5 golang: Optimized values to suit golang 1.23
Added GOARM64 and GORISCV64 in golang-build.sh.
Drop deprecated GOROOT_FINAL in GoCompiler/Default/Make.
Updated environment vars in golang-values.mk for GOARM64 and GORISCV64.
Refined host build in golang/Makefile for openbsd_riscv64.

Co-authored-by: Tianling Shen <cnsztl@immortalwrt.org>
Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-10-01 18:18:11 +08:00
Milinda Brantini
bfb9e266dc golang: Update to 1.23.1
Go 1.23.1 (released 2024-09-05) includes security fixes to
the encoding/gob, go/build/constraint, and go/parser
packages. It also addresses bug fixes in the compiler,
go command, runtime, and the database/sql, go/types,
os, runtime/trace, and unique packages.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-10-01 18:18:11 +08:00
Milinda Brantini
52fc48971d golang: Update to 1.22.7
go1.22.7(released 2024-09-05)includes security fixes to the encoding/gob,
go/build/constraint, and go/parser packages,
as well as bug fixes to the fix command and the runtime.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-09-08 23:53:28 +08:00
Milinda Brantini
7b4fbfda5d golang: Update to 1.22.6
go1.22.6 (released 2024-08-06) includes fixes to the go command,
the compiler, the linker, the trace command, the covdata command,
and the bytes, go/types, and os/exec packages.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-08-10 16:59:36 +08:00
Milinda Brantini
18aaf0cc44 golang: Update to 1.22.5
go1.22.5 (2024-07-02) includes security fixes to the net/http package, 
as well as bug fixes to the compiler, cgo, the go command, the linker, 
the runtime, and the crypto/tls, go/types, net, net/http, and os/exec.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-07-08 16:49:12 -07:00
Milinda Brantini
b4ffdb4c42 golang: Update to 1.22.4
go1.22.4 (released 2024-06-04) includes
security fixes to the archive/zip and net/netip packages,
as well as bug fixes to the compiler,
the go command, the linker,
the runtime, and the os package.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-06-10 04:45:29 +08:00
Tianling Shen
b642f337b2 golang: Update to 1.22.3
go1.22.3 (released 2024-05-07) includes security fixes to the go command
and the net package, as well as bug fixes to the compiler, the runtime,
and the net/http package.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-05-28 14:09:12 +08:00
Tianling Shen
32a22201db golang: Enable loongarch64 for Go compiler and packages
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-05-09 16:15:50 +08:00
Shi JiaYang
6095a031cd golang: update to 1.22.2
go1.22.2 (released 2024-04-03) includes a security fix to the
net/http package, as well as bug fixes to the compiler, the
go command, the linker, and the encoding/gob, go/types,
net/http, and runtime/trace packages.

View the release notes for more information:
https://go.dev/doc/devel/release#go1.22.2
Find out more:
https://github.com/golang/go/issues?q=milestone%3AGo1.22.2

Signed-off-by: Shi JiaYang <shi05275@163.com>
2024-04-06 10:21:41 +08:00
Zephyr Lykos
456fa1f1b6 golang: Update to 1.22.1
Go 1.22.1 contains the following security fixes:

- CVE-2024-24783:
  crypto/x509: Verify panics on certificates with an unknown public key
  algorithm
- CVE-2023-45290
  net/http: memory exhaustion in Request.ParseMultipartForm
- CVE-2023-45289
  net/http, net/http/cookiejar: incorrect forwarding of sensitive headers
  and cookies on HTTP redirect
- CVE-2024-24785
  html/template: errors returned from MarshalJSON methods may break
  template escaping
- CVE-2024-24784
  net/mail: comments in display names are incorrectly handled

https://go.dev/doc/devel/release#go1.22.1
https://groups.google.com/g/golang-announce/c/5pwGVUPoMbg

Signed-off-by: Zephyr Lykos <git@mochaa.ws>
2024-03-20 17:25:09 +08:00
Zephyr Lykos
a66a378669 golang: Update to 1.22.0
Added a third bootstrap stage since go1.22 (and onwards) requires
at least go1.20.14 to build.[1]

[1]: https://go.dev/doc/go1.22#bootstrap

Signed-off-by: Zephyr Lykos <git@mochaa.ws>
2024-03-20 17:25:09 +08:00
Tianling Shen
34867e83ca golang: Update to 1.21.7
go1.21.6 (released 2024-01-09) includes fixes to the compiler,
the runtime, and the crypto/tls, maps, and runtime/pprof packages.

go1.21.7 (released 2024-02-06) includes fixes to the compiler,
the go command, the runtime, and the crypto/x509 package.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-03-02 19:16:06 +08:00
Jeffery To
b8254cdac4 golang: Update to 1.21.5
Includes fix for CVE-2023-39326 (net/http: limit chunked data overhead).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-12-11 15:09:19 +01:00
Jeffery To
0ebc715981 golang: Update to 1.21.4
Includes fixes for CVE-2023-45283 and CVE-2023-45284 (path/filepath:
insecure parsing of Windows paths).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-11-13 16:01:30 +08:00
Jeffery To
f151ab8c0e golang: Update to 1.21.3
Includes fix for CVE-2023-39325 (net/http, x/net/http2: rapid stream
resets can cause excessive work).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-10-15 22:30:29 +02:00
Jeffery To
a8374204bb golang: Update to 1.21.2
Includes fix for CVE-2023-39323 (cmd/go: line directives allows
arbitrary execution during build).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-10-07 20:04:12 +08:00
Jeffery To
d9a999521e golang: Update to 1.21.1
Includes fixes for:

* CVE-2023-39318: html/template: improper handling of HTML-like comments
  within script contexts

* CVE-2023-39319: html/template: improper handling of special tags
  within script contexts

* CVE-2023-39320: cmd/go: go.mod toolchain directive allows arbitrary
  execution

* CVE-2023-39321 and CVE-2023-39322: crypto/tls: panic when processing
  partial post-handshake message in QUICConn.HandleData

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-09-11 03:57:45 +08:00
Jeffery To
a80af7e443 golang: Update to 1.21.0, remove patch
Upstream has updated the Go compiler to not use gold when building for
arm, and is waiting for a fix to binutils (released in 2.41) before
doing the same for aarch64.[1]

Based on the above, it does not appear that
https://github.com/golang/go/pull/49748 will be merged. This removes the
patch from that pull request.

[1]: https://github.com/golang/go/issues/22040

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-08-15 11:57:28 +08:00
Jeffery To
fb9c8f8b89 golang: Update to 1.20.7
Includes fix for CVE-2023-29409 (crypto/tls: verifying certificate
chains containing large RSA keys is slow).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-08-07 02:19:42 +08:00
Jeffery To
8000a7f769 golang: Update to 1.20.6
Includes fix for CVE-2023-29406 (net/http: insufficient sanitization of
Host header).

This also updates the copyright information for various Go packaging
files.

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-07-17 15:13:00 +08:00
Jeffery To
471ef14774 golang: Update to 1.20.5
Includes fixes for:

* CVE-2023-29402: cmd/go: cgo code injection
* CVE-2023-29403: runtime: unexpected behavior of setuid/setgid binaries
* CVE-2023-29404: cmd/go: improper sanitization of LDFLAGS
* CVE-2023-29405: cmd/go: improper sanitization of LDFLAGS

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-06-12 12:04:53 +08:00
Jeffery To
3906e54c08 golang: Enable riscv64 for Go compiler and packages
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-06-04 01:08:00 +08:00
Jeffery To
22b86d6e8d golang: Update to 1.20.4
Includes fixes for:
* CVE-2023-24539: html/template: improper sanitization of CSS values
* CVE-2023-24540: html/template: improper handling of JavaScript
  whitespace
* CVE-2023-29400: html/template: improper handling of empty HTML
  attributes

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-05-08 12:14:54 +08:00
Tianling Shen
f659dfe9f7 golang: Update to 1.20.3
Included fixes for:
- CVE-2023-24534
- CVE-2023-24536
- CVE-2023-24537
- CVE-2023-24538

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-04-14 00:28:12 +08:00
Andre Heider
565866a472 treewide: refactor to use PKG_BUILD_FLAGS:=no-mips16
See commit 5c545bdb "treewide: replace PKG_USE_MIPS16:=0 with
PKG_BUILD_FLAGS:=no-mips16" on the main repository.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-04-08 08:38:54 +02:00
Jeffery To
8711653f1e golang: Update to 1.20.2, refresh patch
Includes fixes for:

* 1.20.1:
  * CVE-2022-41722: path/filepath: path traversal in filepath.Clean on
    Windows
  * CVE-2022-41723: net/http: avoid quadratic complexity in HPACK
    decoding
  * CVE-2022-41724: crypto/tls: large handshake records may cause panics
  * CVE-2022-41725: net/http, mime/multipart: denial of service from
    excessive resource consumption

* 1.20.2:
  * CVE-2023-24532: crypto/elliptic: specific unreduced P-256 scalars
    produce incorrect results

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-03-20 14:43:52 +08:00
Jeffery To
8677ed11e3 golang: Update to 1.19.7
Includes fix for CVE-2023-2453 (crypto/elliptic: specific unreduced
P-256 scalars produce incorrect results).

This also includes makefile updates for Go 1.19.

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-03-14 14:23:35 +08:00
Tianling Shen
0cdd7b8c0e golang: Update to 1.19.6
go1.19.6 (released 2023-02-14) includes security fixes to the
crypto/tls, mime/multipart, net/http, and path/filepath packages,
as well as bug fixes to the go command, the linker, the runtime,
and the crypto/x509, net/http, and time packages.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-02-22 14:48:10 +08:00
Tianling Shen
5a25a731c6 golang: Update to 1.19.5
Go1.19.5 (released 2023-01-10) includes fixes to the compiler,
the linker, and the crypto/x509, net/http, sync/atomic,
and syscall packages.

Removed upstreamed patch.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-01-14 15:02:37 +08:00
Tianling Shen
35f33c99b1 golang: backport an upstream fix for non-retpoline-compatible error
This fixes the following build error:
```
Building targets
runtime
<autogenerated>:1: non-retpoline-compatible: 00200 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/time.go:915)       JMP     (R15)(R12*8)
<autogenerated>:1: non-retpoline-compatible: 00115 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/type.go:614)       JMP     (AX)(SI*8)
<autogenerated>:1: non-retpoline-compatible: 00028 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/time.go:452)       JMP     (R11)(R10*8)
<autogenerated>:1: non-retpoline-compatible: 00021 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/error.go:261)      JMP     (DX)(CX*8)
<autogenerated>:1: non-retpoline-compatible: 00050 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/time.go:691)       JMP     (CX)(R12*8)
<autogenerated>:1: non-retpoline-compatible: 00024 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/debuglog.go:616)   JMP     (CX)(SI*8)
<autogenerated>:1: non-retpoline-compatible: 00079 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/time.go:617)       JMP     (R9)(R8*8)
<autogenerated>:1: non-retpoline-compatible: 00025 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/cgocall.go:453)    JMP     (R9)(DX*8)
<autogenerated>:1: non-retpoline-compatible: 00018 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/type.go:66)        JMP     (DX)(CX*8)
<autogenerated>:1: non-retpoline-compatible: 00020 (/home/username/works/openwrt/staging_dir/hostpkg/lib/go-cross/src/runtime/alg.go:156)        JMP     (SI)(DX*8)
<autogenerated>:1: too many errors
```

Fixes: #20026

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2022-12-28 08:30:59 +08:00
Tianling Shen
6a0ee524b1 golang: Update to 1.19.4
go1.19.4 (released 2022-12-06) includes security fixes to the net/http
and os packages, as well as bug fixes to the compiler, the runtime,
and the crypto/x509, os/exec, and sync/atomic packages.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2022-12-08 00:43:34 +08:00
Stanislav Petrashov
440dcd8d34 golang: update to v1.19.3
Signed-off-by: Stanislav Petrashov <s@petrashov.ru>
2022-11-23 22:06:14 +01:00