TCC and the macOS Platform Sandbox Policy
bdash.net.nz
bdash.net.nz
JSON and xml are both data representation formats, but the code snippets in the article seem more like a declarative language.
You could make a declarative language using JSON semantics, but maybe they wanted something more bespoke.
it’s also super duper easy to write an s-expression parser
If you look at typical SBPL source code you'll see it tends to contain a mix of straightforward, declarative `(allow …)` policies and custom functions/macros used to simplify repeated patterns. See https://github.com/WebKit/WebKit/blob/11b5279aec6113c661dac3..., for example.
I don't have specific info on the rationale, but a powerful language with a small surface area that's easy to parse was probably an attractive choice for mid-2000s security code written in C.
(define build-exp
#~(begin
(mkdir #$output)
(chdir #$output)
(symlink (string-append #$coreutils "/bin/ls")
"list-files")))I interviewed with the team that worked on this a few years back, and if I recall correctly one of them just liked scheme, and it was easy to embed.
Not to be confused with numerous other uses of the acronym.