News for hackers. Stuff that matters.

Show HN: Code-snippets for developing eBPF Programs

https://github.com/h0x0er/ebpf-snippets

When developing eBPF-programs, we need to figure correct program-section SEC() and program-context.

Similary while creating eBPF-maps, we need to add certain fields such as; map-type, key/values, map_options etc..

If you’re like me, you probably end up digging through documentation or browsing open-source projects just to piece this together every time.

So, I created a vscode-extension to help with these repetitive tasks.

Try it out and do share your feedback. I hope you like it.

Thanks !

( 2 comments | 2 points | on HN )
Re:Show HN: Code-snippets for developing eBPF Programs by skyzouwdev on Saturday August 16, 2025 @05:13PM (#44926970)
Nice idea — eBPF is powerful but the boilerplate around maps and SEC() sections is definitely a time sink. Do you plan to include inline links back to the kernel docs/specs in the extension? That could make it even more useful as a learning aid.
Re:Show HN: Code-snippets for developing eBPF Programs by forxtrot on Sunday August 17, 2025 @02:20AM (#44929343)
That's good point. I will add inline links. Thanks !