File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -53,10 +53,13 @@ the key principles of Deno's security model:
5353 All modules that are imported in the initial static module graph (local files,
5454 npm packages, jsr packages, and remote URLs) are loaded by the runtime without
5555 consulting the permission system. No ` --allow-read ` is required to load local
56- files, and no ` --allow-net ` is required to fetch remote modules. This
56+ files, and no ` --allow-net ` is required to fetch remote modules. The static
57+ graph includes static ` import ` statements and ` import() ` calls whose specifier
58+ is a string literal — anything that can be resolved without running code. This
5759 exemption applies only to loading. Once code runs, anything it does still goes
58- through the permission system, and dynamic imports are not covered by the
59- exemption.
60+ through the permission system, and ` import() ` calls with non-literal
61+ specifiers (e.g. ` import(someVariable) ` ) are checked against ` --allow-read ` /
62+ ` --allow-import ` at runtime.
6063
6164These key principles are designed to provide an environment where a user can
6265execute code with minimal risk of harm to the host machine or network. The
You can’t perform that action at this time.
0 commit comments