Skip to content
This repository was archived by the owner on Jan 10, 2025. It is now read-only.

Feature - Restrict ro data layout in SBPFv2#481

Merged
Lichtso merged 2 commits intomainfrom
feature/restrict_ro_data_layout_in_sbpf_v2
Jul 6, 2023
Merged

Feature - Restrict ro data layout in SBPFv2#481
Lichtso merged 2 commits intomainfrom
feature/restrict_ro_data_layout_in_sbpf_v2

Conversation

@Lichtso
Copy link
Copy Markdown

@Lichtso Lichtso commented Jul 5, 2023

No description provided.

@Lichtso Lichtso requested a review from alessandrod July 5, 2023 15:14
@Lichtso Lichtso force-pushed the feature/restrict_ro_data_layout_in_sbpf_v2 branch from 0012b16 to 465c9ce Compare July 5, 2023 15:25
src/elf.rs Outdated
let s2 = new_section(20, 10);
let s3 = new_section(40, 10);
let s4 = new_section(50, 10);
let s1 = new_section(ebpf::MM_PROGRAM_START, 10);
Copy link
Copy Markdown

@alessandrod alessandrod Jul 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of changing the existing test, wouldn't it be better to add a new test
with this "high" vaddrs? We have code that does one thing or another depending
on whether vaddr < MM_PROGRAM_START or >. I think we should test both?

We can probably even do for base_addr in [0, MM_PROGRAM_START] { ... } as I
think the behaviour should be exactly the same

@Lichtso Lichtso force-pushed the feature/restrict_ro_data_layout_in_sbpf_v2 branch from 465c9ce to 5d945b9 Compare July 6, 2023 14:09
@Lichtso Lichtso merged commit c20a353 into main Jul 6, 2023
@Lichtso Lichtso deleted the feature/restrict_ro_data_layout_in_sbpf_v2 branch July 6, 2023 14:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants