Recient distros from Red Hat (both Fedora and RHEL), and likely other
distros too though I haven't checked, have included a security feature
which, depending on how a program is built, and how the system is
configured, prevents code allocated on the stack or in the heap from
running.
This matters to jolt because jolt writes and executes code on the heap.
The symptom of this is that any atempt to exectute code on the heap or
stack seg faults.
The easiest sort term fix for this is to add -Wl,-zexecstack to any idc
command line that builds an executable that needs to write code to the
stack or heap. The following patch modifies the makefiles for all the
jolt's to do this.
-gavin...
--- ./function/jolt/Makefile.execstack 2007-07-01 15:52:36.000000000 -0400
+++ ./function/jolt/Makefile 2007-07-01 14:46:46.000000000 -0400
@@ -27,10 +27,10 @@
$(IDC) $(IDFLAGS) -c $< -o $@
%$(OBJEXT) : %.st
- $(IDC) $(IDFLAGS) $< -o $@
+ $(IDC) $(IDFLAGS) -Wl,-zexecstack $< -o $@
main$(OBJEXT) : main.st $(FILES)
- $(IDC) $(IDFLAGS) main.st $(FILES) $(LDLIBS) -o $@
+ $(IDC) $(IDFLAGS) -Wl,-zexecstack main.st $(FILES) $(LDLIBS) -o $@
../objects/objects.a : .FORCE
$(SHELL) -ec 'cd ../objects; $(MAKE)'
--- ./function/jolt-vpu/Makefile.execstack 2007-07-01 15:52:26.000000000
-0400
+++ ./function/jolt-vpu/Makefile 2007-07-01 15:11:58.000000000 -0400
@@ -39,7 +39,7 @@
$(IDC) -Jmpint $(IDFLAGS) -c $< -o $@
main$(OBJEXT) : main.st $(FILES)
- $(IDC) $(IDFLAGS) main.st $(FILES) $(LDLIBS) -o $@
+ $(IDC) $(IDFLAGS) -Wl,-zexecstack main.st $(FILES) $(LDLIBS) -o $@
./mksyms $@
VPU.st : VPU-$(ARCH).st
--- ./function/jolt-burg/Makefile.execstack 2007-07-01 15:52:19.000000000
-0400
+++ ./function/jolt-burg/Makefile 2007-07-01 15:37:12.000000000 -0400
@@ -29,10 +29,10 @@
$(IDC) $(IDFLAGS) -c $< -o $@
%$(OBJEXT) : %.st
- $(IDC) $(IDFLAGS) $< -o $@
+ $(IDC) $(IDFLAGS) -Wl,-zexecstack $< -o $@
main$(OBJEXT) : main.st $(LIBS)
- $(IDC) $(OFLAGS) $(IDFLAGS) main.st $(LDLIBS) -o $@
+ $(IDC) $(OFLAGS) $(IDFLAGS) -Wl,-zexecstack main.st $(LDLIBS) -o $@
jolt.a : $(FILES) ../objects/objects.a
ar rc [EMAIL PROTECTED] $(FILES) ../objects/*.o ../objects/mpint/*.o
_______________________________________________
fonc mailing list
[email protected]
http://vpri.org/mailman/listinfo/fonc