Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library
← Back to context

Comment by jmclnx

2 hours ago

Interesting no mentioned about OpenBSD pledge(2), unveil(2). By far the easiest sandboxing out there. An example:

    #ifdef OpenBSD
      if(pledge("stdio rpath wpath cpath",NULL) == -1)
        err(1,"pledge\n");
    #endif

Very easy, all the other examples seem rather complex to me. unveil(2) is just as easy.

0 comments

jmclnx

Reply

No comments yet

Contribute on Hacker News ↗

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities