bouncepaw / mycorrhiza

🍄📑 Filesystem and git-based wiki engine for the independent web written in Go and using Mycomarkup as its primary markup language.
https://mycorrhiza.wiki
GNU Affero General Public License v3.0
300 stars 26 forks source link

Golang version bump to v1.22 not needed? Broken Win7 compatibility #246

Closed Darthagnon closed 23 hours ago

Darthagnon commented 1 month ago

This commit bumps the GoLang version, killing Windows 7/Server 2008r2 support in Mycorrhiza as GoLang > v1.21.4 does not support anything below Windows 10 (or possibly Win8?). It is not a critical dependency, as I have successfully built binaries of the latest master using GoLang v1.21.5 and they build and work perfectly; no features are added by the version bump.

Can this commit please be reverted/edited to target Go v1.21?

GoLang v1.22 broke compatibility with older Windows due to changing which under-the-hood random number generator it used to a Win8+ DLL (see https://github.com/stunndard/golangwin7patch):

As per this https://en.wikipedia.org/wiki/CryptGenRandom, there were no critical flaws in RtlGenRandom on Windows 7, and moreover, it wraps the same ProcessPrng function [from bcryptprimitives.dll , which exists only on Windows 8 and newer]: "All userspace calls to fetch randomness, be it CryptGenRandom or RtlGenRandom, ultimately fall to ProcessPrng, which returns bytes from the process's per-processor PRNG." So, for reasons unknown, and in favor of totally unnesessary change, [the GoLang maintainers] opted to completely break all Windows 7 compatibilty silently, showing just an exception with CPU registers dump to all Windows 7 users. This action leaves Windows 7 users completely unable to benefit from software compiled with the newer Go versions, (who said security updates, no security for you!) with issues closed due to https://github.com/golang/go/issues/64622, among other less accommodating practices.

bouncepaw commented 1 month ago

I don't seem to be using 1.22 features, right? Sure, I'll target 1.21 in the next release. I'll bump to 1.22 one day again, but let's prolong the old OS lifetime for a while

bouncepaw commented 23 hours ago

380a8c3 changes the version to 1.21