r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[Plugin-2] Browser Plugins

Maxim
4-May-2006
[201]
the same for local disk access.  for example, we might restrict any 
file i/o to ONE sandbox.  anything trying to access or write out 
of user-specified paths, would either get a dialog, or be refused.
BrianH
4-May-2006
[202]
Some extended plugin configuration API that can be accessed through 
browser extensions?
Graham
4-May-2006
[203]
Hmm.  I want to access libraries, and run scripts ( batch files ) 
which I create dynamically
Maxim
4-May-2006
[204]
or maybe from within the browser, window like quicktime does it, 
with a right click within the plugin box.
BrianH
4-May-2006
[205]
No, the sandbox won't work for the default browser plugin. Think 
of what a malicious script could do with a sandbox - it could write 
data files that could fill your hard drive, keep tracking data that 
the user wouldn't know to delete, etc.
Maxim
4-May-2006
[206x4]
graham, this is why, I think this should be configurable, you could 
allow the plugin to only load and save from specific dirs.
hum, disk space is a concern.  maybe the plugin could simply enforce 
the use of one single write space and protect individual sessions 
from accessing other sessions.
this could easily be handled like a cache and user could impose size 
limits on individual and collective size of all sessions.
maybe using the checksum of a script as the base dir, which is hard-coded 
as the root path of your script.
BrianH
4-May-2006
[210]
We don't want the default plugin to be able to put even a single 
byte outside of the browser's purview without prompting the user 
first. Users have enough security problems to deal with without wondering 
if their banner ads are putting files on their hard drive. As it 
is I know many users who use AdBlock as a security measure - they 
don't care whether they see ads, but many of those ads contain nasty 
code and spyware installers.
Graham
4-May-2006
[211]
OTOH, you don't want to neuter the plugin so that it's useless
BrianH
4-May-2006
[212x4]
No offence to you Graham - you are (apparently) one of the good guys. 
But what you are describing is exactly the kind of behavior that 
we should restrict to encapped scripts that should require an additional 
installation notice, maybe even seperate plugins. Either that or 
through the encapping process  have RT act like a certificate authority, 
allowing us to take an encrypted script and have RT tell us who licensed 
theparticular SDK that encrypted it.  That way we can have the authorities 
(or lawyers) track down an evil developer.
Let's see what a "neutered" plugin can do:
- REBOL/Services
- All of REBOL's GUI and graphics stuff.
- Access browser data (that is site-specific)
You can do a lot with that. Look at Flash.
Let it prompt the user for files to work on, using the system file 
dialog even, and then allow the plugin to work on only the files 
that the user specifies. That should be a good balance.
We don't want a banner ad to be able to participate in a DDOS attack 
do we?
Maxim
4-May-2006
[216]
rebol services can be evil too, sending it your data, just like direct 
tcp usage.  it should be dialoged too.
BrianH
4-May-2006
[217x2]
Only when that service is running on a different server than the 
web server the script was served from. A user's data can be sent 
over the URL that requested the script, or an AJAX connection. A 
certain amount of network access is assumed.
That is the default security restriction of existing browser VMs.
Maxim
4-May-2006
[219]
ok, well... I've got to go, ciao brian, thanks for the chat.  :-)
PeterWood
4-May-2006
[220]
Personally, I feel that the plugin will never gain general acceptance 
unless it is, to use Graham's phrase, "neutered" to the extent that 
it has no local files access and can make no system calls. It should 
be constrained within the browser's environment just like JavaScript 
and Java Applets.
BrianH
4-May-2006
[221x2]
The places a browser puts persistent data, and manages that data, 
are cookies and the temporary file cache. There are already security 
restrictions and management tools for those places. That existing 
persistent storage should be sufficient for REBOL scripts loaded 
by the regular plugin. Any other storage should be on the server, 
with the same server access restrictions as JavaScript. Anything 
more should be restricted to trusted sites.
If you need to access other servers, put a proxy on the one you are 
allowed to access.
Graham
4-May-2006
[223x3]
In some instances you want to use the browser as a delivery mechanism 
for an application.
there should be an optional way to allow library acces, local file 
access etc .
say I have a farm of  pcs running some seti like application and 
rebol using the browser plugin with lns to send the results back 
to a server.
BrianH
4-May-2006
[226]
You can do a lot in those restrictions - look at Google. Beyond that, 
that's what the SDK would be for - not because of the source obscuring 
as much as so that the developer of scripts that can access your 
system could be tracked through your license.
Graham
4-May-2006
[227]
I can't ...
BrianH
4-May-2006
[228]
You can't afford the SDK?
Graham
4-May-2006
[229x5]
I have the sdk/command.
I want to use the browser to deliver full applications.
Say I have thin clients only?
ie. browser based clients.
with only a little flash ram for storage.
BrianH
4-May-2006
[234]
If the browser plugin is doing the distributed computing work, the 
result sets could be sent to the server under the restrictions I 
propose.
Graham
4-May-2006
[235]
but if another library were doing the work?
BrianH
4-May-2006
[236x3]
What we may need is a way to partially encap scripts:

- Encrypt them using the SDK licensee's key in a way that can be 
decrypted by the plugin and traced to the licensee.

- Decrypt them with RT's plugin rather than bundling them with native 
code.

- Prompt when loading them the first time, perhaps with company info 
like IE does with ActiveX controls.
- Give encapped scripts a sandbox directory like rebsite scripts.

- Let these scripts do what they must, knowing that if they are malicious 
you know who to sue.
Anonymous scripts shouldn't be able to do any more to your system 
than JavaScript in the browser can.
Browser plugin updates could do the equivalent of certificate revocation 
for malicious licensees too.
Anton
4-May-2006
[239]
I agree with Brian here. Opening doors should be done carefully.
Henrik
4-May-2006
[240]
I'm just worried about the "evil" network access that Rebol can do 
in the background, which you can't see in the browser, but need sniffers 
to see. A method for showing network access needs to be really solid.
Graham
4-May-2006
[241x4]
Henrik ..every application that you install has potentially the ability 
to do network access.
I have no idea what my anti-virus products do.
but they constantly access the net, presumably looking for updates.
I don't think Rebol should be thought of any worse than a program 
written in C.
Henrik
4-May-2006
[245]
how do java applets do it?
Graham
4-May-2006
[246]
No idea.
PeterWood
4-May-2006
[247x2]
Basically, Java Applets and JavaScript have no access to local files.
Java Applets can be digitally signed and you can grant "trusted applets" 
local access.


I'm not sure how much this is used and whether people really grant 
trusted access.
Henrik
4-May-2006
[249]
it's used here a lot for online banking to fetch a locally stored 
key on disk
PeterWood
4-May-2006
[250]
So Henrik, do you trust your bank to have access to your local files?