Commit Graph

7 Commits

Author SHA1 Message Date
Kartik K. Agaram 9ec94aa982 disallow all relative paths (./ or ../)
Teliva's model doesn't include any way to change directory. We just have
relative paths and absolute paths. Relative paths should not be able to
reach into parent directories.

The current test is a bit hacky; it also disallows directories ending in
a period. Hopefully not an issue.
2022-03-20 17:58:14 -07:00
Kartik K. Agaram 56f1b97b9c sandbox os.remove 2022-03-17 15:38:50 -07:00
Kartik K. Agaram 08c49b5a0a protect framework files from apps
There's a separate open question here of where Teliva should store files
like teliva_editor_state and teliva_editor_buffer. One school of thought
is that apps should never be dropping crud into people's directories. On
the other hand, I'm kinda encouraging people so far to just run apps
from Teliva's directory. Perhaps that makes it ok?
2022-03-08 19:20:53 -08:00
Kartik K. Agaram 2b47f76308 just always temp files to be created
Implication: os.rename now needs to be sandboxed. Hopefully it's
tractable to treat it as conceptually identical to opening two files.
2022-03-07 21:57:11 -08:00
Kartik K. Agaram 1fd7f4ad18 drop os.getenv 2022-01-02 19:59:49 -08:00
Kartik K. Agaram 1b25d58a4f sandbox: no system()
Too hard to sandbox. Maybe we'll get back to it if there's some use case
only it can satisfy.
2021-12-25 08:22:15 -08:00
Kartik K. Agaram 74f8cd15bb new fork of Lua 5.1
https://www.lua.org
2021-10-22 19:24:44 -07:00