Skip to content
This repository has been archived by the owner on Nov 19, 2021. It is now read-only.

Inaccurate readings randomize_layout [Linux Kernel] #48

Open
pwnosaur opened this issue Sep 3, 2020 · 0 comments
Open

Inaccurate readings randomize_layout [Linux Kernel] #48

pwnosaur opened this issue Sep 3, 2020 · 0 comments

Comments

@pwnosaur
Copy link
Contributor

pwnosaur commented Sep 3, 2020

The current implementation for the Linux kernel debugging lacks support for kernel 4.13+ because of the randomize_layout security feature which randomizes the location of struct members during the kernel compilation process, thus the offset of each element may vary resulting in inaccurate readings.

More information here about the feature
https://lwn.net/Articles/722293/

note the randomized_struct_fields_start used in

Kernel 4.13+

struct task_struct 
{
#ifdef CONFIG_THREAD_INFO_IN_TASK
	struct thread_info		thread_info;
#endif
	volatile long			state;
	randomized_struct_fields_start
	void				*stack;
...

which was not yet implemented in previous kernel versions

Kernel 4.12-

struct task_struct {
#ifdef CONFIG_THREAD_INFO_IN_TASK
	struct thread_info		thread_info;
#endif
	volatile long			state;
	void				*stack;
@pwnosaur pwnosaur changed the title Inconsistent DTBs [Linux Kernel] Inaccurate readings randomize_layout [Linux Kernel] Sep 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant