[cap-talk] Applications for a capability platform - PLASH discussion

Toby Murray toby.murray at comlab.ox.ac.uk
Fri Feb 29 18:32:02 EST 2008


On Fri, 2008-02-29 at 18:08 -0500, Jonathan S. Shapiro wrote:
> On Fri, 2008-02-29 at 14:44 -0800, Jed Donnelley wrote:
> > On 2/29/2008 9:49 AM, Jonathan S. Shapiro wrote:
> > > On Fri, 2008-02-29 at 09:27 -0800, Jed Donnelley wrote:
> > >> At 06:18 AM 2/29/2008, Jonathan S. Shapiro wrote:
> > > 
> > > The net effect of this is that the application is oblivious to the fact
> > > that it runs within a capability environment, and no "caplib" is
> > > required. A major point of PLASH is that application re-engineering is
> > > not required.
> > 
> > How do I run "chmod" under PLASH?
> 
> Toby has used it, so I suspect he is better able to answer this than I
> am,

See for yourself. Plash now includes a number of components, only one
of which is the traditional Bash-style shell, known as pola-shell. 

toby at gnosis:~ $ pola-shell
plash$ ls -l newfile
plash: error in resolving filename `newfile': No such file or directory
/bin/ls: newfile: No such file or directory
plash: job 1: process #1 (pid 19230) exited with status 2
plash$ touch => newfile
plash$ ls -l newfile
/bin/ls: newfile: No such file or directory
-rw-r--r-- 1 toby toby 0 2008-02-29 23:24 newfile
plash$ chmod "u+x" => newfile
plash$ ls -l newfile
/bin/ls: newfile: No such file or directory
-rwxr--r-- 1 toby toby 0 2008-02-29 23:24 newfile
plash$ ls -l ./newfile
/bin/ls: ./newfile: No such file or directory
-rwxr--r-- 1 toby toby 0 2008-02-29 23:24 ./newfile
plash$ plash: end of user input

toby at gnosis:~ $ ls -l newfile
-rwxr--r-- 1 toby toby 0 2008-02-29 23:24 newfile


As you can see, the newly created file "newfile" persisted after
pola-shell exited. Also the chmod effects persisted as well.

(Arguments after => are put into the child process's namespace with
write access. Those before => are put in as read-only.) 
(I'm not sure why when ls is invoked under pola-shell with the -l
argument, we get a the error message "No such file or directory" but
then it appears to work.  I'm running an out-of-date version of Plash so
this could be a bug that has been fixed since version 1.16)





More information about the cap-talk mailing list