Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^4: Running user-provided JavaScript code

by cavac (Parson)
on Apr 21, 2022 at 09:32 UTC ( [id://11143167]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Running user-provided JavaScript code
in thread Running user-provided JavaScript code

I thought about a simplified language. But nearly all my use cases require conditionals and loop constructs. Which make it turing complete.

Plus, inventing and implementing a domain-specific language has a lot of drawbacks as well, especially if it's done by a single person. First of, it still will have ways to exploit it, as all computer code inevitably does. And secondly, it will be single-use only, so the user has to learn a specific language for that one job. And if i implement something else that also needs scripting, the user will have to learn a second, different language. I have experimented with stuff like that in the past, and it's basically a neverending maintenance nightmare.

And frankly, i had to work with turing-complete stuff before that is way harder to properly sandbox with the usual tools available. You know, evil stuff like PDF, Ghostscript, True-Type fonts, MediaWiki Templates, Minecraft, laptop batteries, computer keyboards, printers, "smart" LED lamps, security cameras, smartphones, etc. At this point, i'm resigned to the fact that there is so much exploitable soft- and hardware around me that i'm never going to be truly secure.

perl -e 'use Crypt::Digest::SHA256 qw[sha256_hex]; print substr(sha256_hex("the Answer To Life, The Universe And Everything"), 6, 2), "\n";'

Replies are listed 'Best First'.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11143167]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (6)
As of 2024-04-19 14:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found