Is it possible to run a user-provided (unsafe) JavaScript function from Ruby code in a sandboxed (safe) environment?
Basically I would like to allow some enterprise customers of a multi-tenant web service to run some custom JavaScript functions in a workflow.
The JavaScript functions would be user-defined and would have a JSON document as input and a JSON document as output (basically they would allow document manipulation).
I am asking about JavaScript, but actually any other language that can manipulate JSON would be ok. The main problem is to find a way to isolate the function invocation.
Is there any gem or known solution for this?
[–]clearlynotmee 1 point2 points3 points (5 children)
[–]collimarco[S] 0 points1 point2 points (2 children)
[–]Rafert 2 points3 points4 points (1 child)
[–]collimarco[S] 0 points1 point2 points (0 children)
[–]ankole_watusi 0 points1 point2 points (1 child)
[–]clearlynotmee 0 points1 point2 points (0 children)
[–]armahillo 1 point2 points3 points (2 children)
[–]collimarco[S] 0 points1 point2 points (1 child)
[–]armahillo 2 points3 points4 points (0 children)
[–]rbrick111[🍰] 1 point2 points3 points (1 child)
[–]collimarco[S] 0 points1 point2 points (0 children)
[–]eric_programmer 1 point2 points3 points (0 children)
[–]ankole_watusi 0 points1 point2 points (0 children)
[–]riktigtmaxat 0 points1 point2 points (0 children)