simple modules

ihab.awad at ihab.awad at
Tue Feb 2 12:05:59 PST 2010

On Tue, Feb 2, 2010 at 6:41 PM, Brendan Eich <brendan at> wrote:
> On Feb 1, 2010, at 7:17 PM, ihab.awad at wrote:
> Because any object I create in my Context is capable of gaining access
> to the filesystem simply by uttering "import fs", the "fs" authority
> is ambient in my Context.
> This is simply not the case. The Context proposal needs to be written still,
> but we have already discussed several times how a Context can have its own
> module id resolver, which can deny "fs" and anything else to the would-be
> importer.

I'm confused.

"I" am a piece of code. I exist in a Context wherein module instances
are ambiently shared. Within that context, "fs" resolves to the
filesystem module. I import some other module. Can I prevent that
module from importing "fs"? Is access to imports importer-subjective?

I think the point you are making is that it is possible to *create* a
new Context that has no, or attenuated, access to the "fs" module.
That's fine, but then we move to the arguments about the Turing tarpit
presented to programmers wishing to work in a fine-grained secure


Ihab A.B. Awad, Palo Alto, CA

More information about the es-discuss mailing list