Javascript File i/o

Thursday May 25th, 2000

Pete Collins from Alphanumerica and Mozilla developers have created a Javascript interface for doing file i/o in Mozilla, which will allow new Mozilla components like Alphanumerica's Crash Recovery system to function properly.

Patterned after the PHP filesystem functions, simple functions such as file read/write and directory create are supported. The code has not yet made it into the nightly build, but they expect it will get in soon.

Note from AN: There seems to be a misconception about Javascript File I/O being a security risk. It is important to clarify that this project is not opening any security holes in Mozilla. There is a difference between Javascript on the Internet and Javascript inside the application. Javascript is used inside Mozilla to create the functionality for the application. This is in contrast to any Javascript downloaded from the Internet that is used for functionality only inside a Web page. This project does not grant any access to Javascript found on the Internet. For more information about how Javascript is used inside Mozilla read more about XPCOM and XPConnect.

#42 OOOOOOOHHHHHH, Nevermind.

by SomeSmartAss

Friday May 26th, 2000 9:17 AM

You are replying to this message

I was wrong (although I apreciate petejc acknoledging how I *could* have been misled)

Now I get it. They're not adding file I/O access to JavaScript, per ce, they're making it easier for Mozilla coders (not us mear mortal end user/skin designers) to access the exsisting function calls, without having to dig out their C++ coders bible.

Still, in an effort to better understand this easier access to existing functionality, may ask a few more uniformed questions.

I get that this is *only* part of the inner workings of Mozilla, but as I see it, things like Chatzilla will be able to gain access, right?. (no biggie here, you essentially installing a new app, that happens to tie into Mozilla, you get what you deserve for not taking due dilegence in reading security warnings)

Now, sinse JS is diabled in Skins, what about the posibility of mini-add ons? Would we, for example, be able to add a custom button to the toolbar? (i.e. my lame "cute animal of the week" example) that has limited JS funtionality (say, normal DOM access) without full access to the "mozilla coder toolsets"?

I'm also wondering if there is a way we can access XUL files (including skins) straight off the web? Or will these things have to be downloaded/installed first?

Maaan, you stop playing with nightly builds for a while.....