This commit is contained in:
xyou
2026-07-28 12:00:02 +08:00
parent efa626ed17
commit 17a577f2ed
51 changed files with 8446 additions and 787 deletions
+16
View File
@@ -11,12 +11,28 @@ PHDRS
SECTIONS
{
. = 0x1000;
/* 防篡改:导出 .text 段范围供运行时自校验 */
__text_start = .;
.text : ALIGN(4K) { *(.text*) } :text
__text_end = .;
.rodata : ALIGN(4K) { *(.rodata*) } :rodata
/* 防篡改:独立的 .hashseg 段存放预期 SHA256(32 字节)。
* 由构建后补丁脚本 patch_login_hash.exe 写入。
* 初始填充 0x00,运行时若发现全 0 则跳过校验(开发期便利)。 */
.hashseg : ALIGN(16) {
__expected_hash = .;
. = . + 32;
__expected_hash_end = .;
} :rodata
.data : ALIGN(4K) {
*(.data*)
*(.data.rel.ro*)
*(COMMON)
} :data
.bss : ALIGN(4K) {
*(.bss*)
} :data
.rela.dyn : ALIGN(8) { *(.rela.dyn*) } :data