Hacker News

Top stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. Jemalloc 5.4.0(github.com/jemalloc ↗)
    22comments
  2. Astra for Law(openai.com ↗)
    498comments
  3. The scourge of x86 emulation(fex-emu.com ↗)
    11comments
  4. Bonsai 2 27B: Near-Lossless Compression in a 9x Smaller Footprint(prismml.com ↗)
    119comments
  5. Bend – A language that blocks AI mistakes via proof, on CPU and GPU(bend-lang.com ↗)
    205comments
  6. Qwen 3.8 Omni Flash(qwen.ai ↗)
    66comments
  7. Hister: A private search engine for the pages you visit and the files you keep(github.com/asciimoo ↗)
    161comments
  8. Pre-Greek: The lost language hidden within Ancient Greek(linguisticdiscovery.com ↗)
    28comments
  9. When the fractional part of a float fixes your shader(crocidb.com ↗)
    discuss
  10. A heap overflow and SSO misconfiguration to compromise OpenAI internal repos(hacktron.ai ↗)
    129comments
  11. Wax motor(wikipedia.org ↗)
    64comments
  12. Fujitsu launches made-in-Japan next-generation CPU FUJITSU-MONAKA(global.fujitsu ↗)
    224comments
  13. Shapelearn Qwen 3.8 27B (13.1 GB VRAM)(byteshape.com ↗)
    6comments
  14. How to Write with an LLM(sockpuppet.org ↗)
    85comments
  15. Flet 1.0 – Build cross-platform apps in Python(flet.dev ↗)
    52comments
  16. Telstra outage: The night a network decided the year was 2006(netnod.se ↗)
    23comments
  17. Apple detectives solved mystery of ancient tree and rewrote the history of fruit(scientificamerican.com ↗)
    5comments
  18. Ask A Monk – A digital wilderness for thoughts with no immediate answer(askamonk.online ↗)
    20comments
  19. Diplodocus, Long Thought Exclusively American, Turns Up in Spain(sci.news ↗)
    37comments
  20. The most important product decision is what you don't build(liamnugent.me ↗)
    33comments
  21. Fixing an NZXT Signal 4K30 part 2: the green/pink video bug(downtowndougbrown.com ↗)
    8comments
  22. CrowdSec Source Code Leak(crowdsec.net ↗)
    44comments
  23. Why I didn’t sign the Fields medallists’ letter(gowers.wordpress.com ↗)
    358comments
  24. How do we prevent mathemathics from devolving into the Medieval Era of secrecy?(mathoverflow.net ↗)
    96comments
  25. Speeding up gearhash on ARM64(sam.dev ↗)
    discuss
  26. Khipu (Quipu) Field Guide(khipufieldguide.com ↗)
    discuss
  27. How Uber Protects Against Retry Storms(uber.com ↗)
    36comments
  28. Infinite-Parameter LLMs: Generating and Adapting Weights from Live Data(arxiv.org ↗)
    39comments
  29. Show HN: Snapdrop: Instantly share files between devices. No setup, no signup(snapdrop.me ↗)
    34comments
  30. Code Scans(devin.ai ↗)
    4comments

SerenityOS: Writing a Full Chain Exploit

86 pointsby 5y agodevcraft.io
9 comments
5y agoHN ↗

SerenityOS is an amazing project. Great videos, fun and interesting to watch and the os itself is surprisingly usable. Great example of modern C++.

5y agoHN ↗

I think the whole project is just so fun. I contributed a couple of patches and the whole community behind it is so warm and welcoming. Its incredibly pleasant and refreshing to interact with.

5y agoHN ↗

Looks like a lot went into this, i'm sure you must have been paid for your efforts with a bounty right?

5y agoHN ↗

Serenity is a great community to keep up with if you're interested in OS security (along with a whole lot of other topics that are typically buried in decades of incidental complexity).

There are a number of things in this exploit you can no longer do in latest Serenity:

1. As the author mentioned, the entry point of this chain is fixed (the specific overflow problem in JSLib).

2. User libs have ASLR (edit: this used to say the kernel has a slide, but this is incorrect).

3. You can no-longer mprotect with PROT_EXEC after you create a writeable page (W^X)

4. This may or may not be relevant, but there is now a "blessed syscall pages" feature, preventing anyone except libc^h^h^h^h libSystem.so and a couple of other places from directly invoking syscalls, so you better find a few pages from libSystem or it will be a whole lot harder to reach out and touch someone with your exploit.

(Andreas and crew went on a month-or-so long security trek after a few CTFs and these changes plus quite a few others were the result.)

5y agoHN ↗

Yeah a lot of work has happened in the few weeks since I started looking at this!

The kernel has a slide

Oh cool must have missed that, very nice :)

5y agoHN ↗

Indeed, I've had a ton of fun learning about system security by implementing various protection mechanisms and security mitigations (and doing some of my own exploits, too!) I'm learning new stuff all the time, so I've been growing the system's defenses along with my own skills.

One small correction: the kernel does not yet have a slide, but everything else is accurate. Also, the blessed syscall pages is now down to a single page in in libsystem.so[1]

Furthermore, as of today[2] we also randomize the location of JavaScript heap memory, which makes the spray technique used in this exploit a lot less reliable as well :)

1. https://github.com/SerenityOS/serenity/commit/e87eac92730f1c...

2. https://github.com/SerenityOS/serenity/commit/e8d38567369253...

5y agoHN ↗

Thanks Andreas. I've updated my comment to reflect those corrections.