asiekierka / FoamFix

Minecraft memory usage optimization mod. Please note that code contained herein is not a suggestion for Minecraft unless explicitly declared elsewhere, in writing, by the rightsholder(s).
http://asie.pl/foamfix
148 stars 23 forks source link

Log4j console spam [HackyMessageFactoryWrapper] [1.7] #289

Open SilearFlare opened 2 years ago

SilearFlare commented 2 years ago

A new issue that I had never noticed before has happened recently, enabling the log4j exploit fix spams the console with tens of pages repeating the same line over and over, this is an short excerpt from forestry's log4j spam. Screenshot from 2022-09-30 12-37-18

Disabling the exploit fix stops the spam, but obviously that's besides the point here.

Any help on what might have caused this? The log4j fix has been out for months and this never happened before. I even tried downgrading foamfix to 1.0 just in case it was the latest update, but it seems inherent to the log4j exploit fix because it spammed the console even in that version.

Thank you in advance.

makamys commented 2 years ago

A possible quick fix would be to make the fix automatically get disabled if it detects MultiMC's patched version of log4j (log4j-core-2.0-beta9-fixed.jar) on the class path, since, as far as I'm aware, the fix accomplishes nothing in that case.

By the way, I'm able to reproduce the issue with PolyMC 1.3.2-404b9599, running FoamFix 1.0.1 and Forestry 4.3.1.44.

SilearFlare commented 1 year ago

Hold on, multi/polymc fixes the exploit by default? Then I don't need to add Healer.

makamys commented 1 year ago

Yeah. I believe you only need a mod's fix if you (or someone you intend to play your pack) uses a different launcher, or a different method of launching the game (hosting a server being a big one).

asiekierka commented 1 year ago

Worked around in 1.0.2 - if it detects a known patched JndiLookup.class, FoamFix will prevent applying its own workaround.

SilearFlare commented 1 year ago

A'ght.

asiekierka commented 1 year ago

Opening this, because it's technically not fixed - even if most people won't see it again.