summaryrefslogtreecommitdiff
path: root/sample.elf.lua
diff options
context:
space:
mode:
Diffstat (limited to 'sample.elf.lua')
-rw-r--r--sample.elf.lua47
1 files changed, 47 insertions, 0 deletions
diff --git a/sample.elf.lua b/sample.elf.lua
new file mode 100644
index 0000000..f6b48d5
--- /dev/null
+++ b/sample.elf.lua
@@ -0,0 +1,47 @@
+header {
+ magic = { 0x7f, 0x45, 0x4c, 0x46 },
+ class = Class.bit64,
+ data = Endian.big,
+ ident_version = ELFVERSION,
+ osabi = Osabi.netbsd,
+ abiversion = 0,
+ type = Type.exec,
+ machine = Machine.i386,
+ version = ELFVERSION,
+ entry = 0,
+ phoff = 0x40,
+ shoff = 0xff,
+ flags = 0,
+ ehsize = 64,
+ shentsize = 0x40,
+ shnum = 0,
+ shstrndx = 0,
+}
+
+segments {
+ {
+ type = SegmentType.dynamic,
+ flags = SegmentFlags.x,
+ offset = 0xf,
+ vaddr = 0xff,
+ paddr = 0xfff,
+ filesz = 0xffff,
+ memsz = 0xfffff,
+ align = 1,
+ },
+ {
+ type = SegmentType.dynamic,
+ flags = SegmentFlags.r,
+ offset = 0xa,
+ vaddr = 0xaa,
+ paddr = 0xaaa,
+ filesz = 0xaaaa,
+ memsz = 0xaaaaa,
+ align = 1,
+ },
+}
+
+sections {
+ {},
+ {},
+}