9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Re: [9fans] What's up with $home? And a security question.
@ 2013-02-24  4:27 Erik Quanstrom
  2013-02-24  4:53 ` Stuart Morrow
  0 siblings, 1 reply; 19+ messages in thread
From: Erik Quanstrom @ 2013-02-24  4:27 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

When do you expect environment variables to change underfoot?

- erik


Stuart Morrow <morrow.stuart@googlemail.com> wrote:

>I know that about /tmp.  I know devenv too.  By the way, have you ever
>noticed that the *env libc functions only allow accesses to env files
>with names of length 100 - strlen("/env/") - sizeof '\0', while rc
>allows names of up to 256 characters?  I'm not too concerned about
>that one, just saying it's inconsistent.  Rio is hardcoded for a
>maximum of 100 windows and I don't think anyone's ever had a problem.
>
>A more realistic one is:  rc doesn't go out to /env every time a
>variable is accessed.  If they're changed underfoot the only way rc
>can see them is if you start up a new rc (like the rc under EXAMPLES
>in pipefile(1))
>
>What's the reason for this, just speed?  It seems weird to me that a
>Plan 9 program would do something "intelligent" like that (and
>therefore less predictable, like ls's that do isatty on /fd/1).
>
>

^ permalink raw reply	[flat|nested] 19+ messages in thread
[parent not found: <CABB-WO9gegFWirXjQhAK0g9vNHn=W2+vwC+bTvRcRDw7xs096g@mail.gmail.c>]
* [9fans] What's up with $home? And a security question.
@ 2013-02-24  2:49 Stuart Morrow
  2013-02-24  3:05 ` andrey mirtchovski
  0 siblings, 1 reply; 19+ messages in thread
From: Stuart Morrow @ 2013-02-24  2:49 UTC (permalink / raw)
  To: 9fans

I'd like to dedicate this email to all the programs that don't know
how to expand environment variables.

See*, $path is no longer in the environment (more or less): it's a
union of all the relevant executables at a known place: /bin.

What's a good reason for your home to be in the environment instead of
the namespace?  I can see no problem with letting "me" (say) be a
reserved name so that "/usr/me" can be assumed to always point to the
home you want.  ""'s denote literal values here by the way.  I'm
talking about /usr/me being a bind to /usr/stuart.

You'd lose your home after certain types of rforks but then the same
is true for a home in the environment.

* - that's my trick for avoiding having to put a capital letter in a
command- or other case sensitive token-name just because it's at the
start of a sentence.  That pisses me off in computer documentation so
much.

My other question is: what's the security implications of cpu?  You
get to do processes on the remote box, but then they also get to have
filesystem access on yours.  Does this not worry anyone?  Security is
really the hard thing for me to understand in Plan 9.

Stuart



^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2013-02-25 11:56 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-24  4:27 [9fans] What's up with $home? And a security question Erik Quanstrom
2013-02-24  4:53 ` Stuart Morrow
     [not found] <CABB-WO9gegFWirXjQhAK0g9vNHn=W2+vwC+bTvRcRDw7xs096g@mail.gmail.c>
2013-02-24 13:29 ` a
2013-02-25  8:49   ` Bruce Ellis
2013-02-25 11:56     ` Charles Forsyth
  -- strict thread matches above, loose matches on Subject: below --
2013-02-24  2:49 Stuart Morrow
2013-02-24  3:05 ` andrey mirtchovski
2013-02-24  3:43   ` Stuart Morrow
2013-02-24  3:53     ` andrey mirtchovski
2013-02-24  4:19       ` Stuart Morrow
2013-02-24  4:45         ` Federico G. Benavento
2013-02-24  5:06           ` Stuart Morrow
2013-02-24  5:10             ` andrey mirtchovski
2013-02-24  5:20               ` Stuart Morrow
2013-02-24  6:24                 ` Bruce Ellis
2013-02-24  7:05                   ` Matthew Veety
2013-02-24  7:14                     ` Bruce Ellis
2013-02-24  9:31               ` steve
2013-02-24  4:33     ` cinap_lenrek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).