-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Description
When using hashtree as a Go dependency, the linker emits warnings about missing .note.GNU-stack
sections:
/usr/bin/ld: warning: sha256_shani.o: missing .note.GNU-stack section implies executable stack
/usr/bin/ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker
Root Cause
The pre-compiled .syso
files in the repository are outdated and don't include the .note.GNU-stack
section, even though the assembly source files (.S
) have been properly updated with this section.
Analysis
- All assembly source files in
src/
correctly include.section .note.GNU-stack,"",@progbits
for Linux builds - The pre-compiled
hashtree_amd64.syso
contains object files without this section - Go uses the
.syso
files directly during builds, not the source assembly files
Reproduction
- Import hashtree in a Go project
- Run
go build
- Observe linker warnings for each assembly object file
Solution
Rebuild all .syso
files from current sources:
make go_bindings
# For platform-specific files:
mv hashtree.syso hashtree_amd64.syso
Impact
- Current: Linker warnings on every build
- Future: Build failures when linkers remove support for executable stacks
- Security: Potential security implications from executable stack
Suggested Fix
Update the build process to regenerate all platform-specific .syso
files with current toolchain and commit the updated files.
issue description powered by claude, but verified and tested manually :)
Metadata
Metadata
Assignees
Labels
No labels