summaryrefslogtreecommitdiffhomepage
path: root/pkg
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2019-12-06 08:35:18 -0800
committergVisor bot <gvisor-bot@google.com>2019-12-06 08:37:14 -0800
commitf8bb3f79041bf819cdf803c1009a442154692301 (patch)
treecea0e153e0dd91f6f6016979e3235e9376fc7ffc /pkg
parent40035d7d9c18d0467075cdaebe3d26d2dbd2720b (diff)
Document ELF PT_LOAD difference from Linux
PiperOrigin-RevId: 284191345
Diffstat (limited to 'pkg')
-rw-r--r--pkg/sentry/loader/elf.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/pkg/sentry/loader/elf.go b/pkg/sentry/loader/elf.go
index c2c3ec06e..6299a3e2f 100644
--- a/pkg/sentry/loader/elf.go
+++ b/pkg/sentry/loader/elf.go
@@ -408,6 +408,8 @@ func loadParsedELF(ctx context.Context, m *mm.MemoryManager, f *fs.File, info el
start = vaddr
}
if vaddr < end {
+ // NOTE(b/37474556): Linux allows out-of-order
+ // segments, in violation of the spec.
ctx.Infof("PT_LOAD headers out-of-order. %#x < %#x", vaddr, end)
return loadedELF{}, syserror.ENOEXEC
}