google / google/codeworld

Run TemplateHaskell with sandboxing

Offen
#69 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
discussion
Vorherrschende Sprache
Haskell
Sterne
1.3k
Forks
201
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

From Luite:

> By the way, GHCJS runs Template Haskell with a JS engine now (it used to load native code) so it's not all that hard to build a variant that is safe enough for untrusted code. The standard implementation is a [small server script](https://github.com/ghcjs/ghcjs/blob/master/lib/etc/thrunner.js) that runs on node.js. GHCJS first sends the runtime system and the actual [Template Haskell runner code](https://github.com/ghcjs/ghcjs-prim/blob/master/GHCJS/Prim/TH/Eval.hs), and then incrementally all compiled splices and their dependencies. You could for example modify the script to use a [node.js sandbox](https://github.com/gf3/sandbox), if you're more adventurous you could even send it to the user's browser.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.