This fork applies security‑focused patches to reduce error‑log leakage and enforce symbol stripping in release builds.
- Release error logging disabled: Non‑debug builds no longer emit
_err_print_erroroutput. Debug/editor builds behave as upstream. - Function/file redaction: When error logging is enabled in debug/dev builds, function/file/line are printed as normal. In release builds they are blanked, preventing name leakage.
- Release print_error blocked:
print_error()is a no‑op in non‑debug builds. - Default error print flag:
CoreGlobals::print_error_enableddefaults tofalsein non‑debug builds. - Export encryption hardening: Script encryption key loading is less signature-friendly (runtime reconstruction + non-sequential decoding), and encrypted-pack error strings are less stable as anchors.
A new SCons option controls symbol stripping:
strip_symbols(bool): Strip symbols in non‑debug builds.- Default: enabled for release (
template_release), disabled for debug/editor.
- Release with stripping (default):
scons target=template_release
- Release without stripping:
scons target=template_release strip_symbols=no
- Debug/editor builds (no stripping by default):
scons target=template_debugscons target=editor
This fork adds an extra XOR layer on top of the existing AES‑CFB pack encryption. To enable it, set the encryption key environment variable when compiling export templates, then enable pack encryption in the editor’s export settings.
- Set key before building templates:
export SCRIPT_AES256_ENCRYPTION_KEY="your_generated_key"
- Build export templates with this fork.
- In the editor, enable “Encrypt PCK” for the export preset.
Note: Packs encrypted by stock Godot are not compatible with this fork’s XOR layer.
core/core_globals.h— default error print flag by build type.core/core_builders.py— obfuscates generated script encryption key loading.core/error/error_macros.h— redactsFUNCTION_STRin release builds.core/error/error_macros.cpp— redacts function/file/line in release builds.core/io/file_access_encrypted.cpp— adds XOR masking for encrypted packs.core/io/file_access_pack.cpp— uses script key API for encrypted packs; reduces anchor strings.core/io/logger.cpp— suppresses error logging in release builds.core/object/script_language.h— declaresget_script_encryption_key().core/string/print_string.cpp— disablesprint_error()in release builds.SConstruct— addsstrip_symbolsoption and gates linker stripping.tests/core/io/test_encrypted_pack_directory.h— adds encrypted directory pack test.
This branch (4.5.1-stable-patch) is based on 4.5.1-stable and adds a small,
security-focused patch set aimed at reducing accidental information disclosure
and raising the bar for casual static inspection of exports.
- Reduce release-build leakage of engine internals (paths, symbols, call sites).
- Keep debug/editor ergonomics close to upstream.
- Provide opt-out controls for build/pipeline behavior.
dfe77f4e8aRelease builds suppress engine error logging (_err_print_error).f4ad1dc8f1Addstrip_symbolsSCons option (default: on for release).c46ea43832Document the patch controls and intended behavior.055e371f2cAdd XOR masking on top of AES-CFB pack encryption (fork-only).
- Script encryption key is no longer stored as a contiguous 32-byte global; it is reconstructed at runtime from obfuscated fragments.
- Encrypted pack open failures avoid stable, extractor-friendly anchor strings.
- These changes do not make exports “tamper-proof” or provide DRM; they reduce observability and make casual reversing harder, but motivated attackers can still inspect memory, hook APIs, or patch binaries.
- Pack encryption requires key handling discipline. Treat the key as a secret in your build pipeline and avoid shipping it in plain text.
- Packs encrypted by stock Godot are not compatible with this fork’s XOR layer.
- Build
template_releaseand confirm errors are not printed at runtime. - Build
template_debug/editorand confirm upstream-style error output is preserved for development. - Export with “Encrypt PCK” enabled and confirm the runtime can mount and read the encrypted pack on the target platform.
This fork is licensed under the GNU General Public License v3.0.
See LICENSE.txt for the full license text.
Some files and bundled third-party components are under different terms.
See COPYRIGHT.txt and the thirdparty/* license files for details.