main.lv
Dont think code it

2010-8-23 ELF text section

This code based on .text writable

Find out .text section and make it writable.
segmentcheck.h contains two functions

int sec_text_check( FILE* );

check if given file have .text writable section or not. return 0 if 
fasle, 1 if true and -1 if there was some kind error.
int sec_text_set( FILE* , int );

set section segment to writable/unwritable depends on second value
that canbe 0 or 1.
Code:
Source includes two tests for both functions.I have not tested both
functions very whell. That whay there can be some error.I have used
used that for proving concept. And have checked result with
test1
and
readelf -l simple



Links


Downloads

elf_segment.tar.gz26KiB