You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is regarding running a script relying on the sandbox.
This seems like it couldn't access any API keys on your computer:
deno run downloadedscript.js --allow-net=thirdpartysite.com
However, if downloadedscript.js is in your download folder or at a guessable level from your home folder, it can access a JSON file containing credentials with a JSON import assertion.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
This is regarding running a script relying on the sandbox.
This seems like it couldn't access any API keys on your computer:
However, if downloadedscript.js is in your download folder or at a guessable level from your home folder, it can access a JSON file containing credentials with a JSON import assertion.
As an example, https://begin.com/docs/getting-started/github-actions has the API token in ~/.begin/config.json
This is what downloadedscript.js would need to contain to get the API key and send it to thirdpartysite.com:
Running it:
The output:
It might seem like a contrived example, but:
Does this not fit with the purpose of sandboxing in Deno? If not, why not?
Beta Was this translation helpful? Give feedback.
All reactions