public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: David Sastre Medina <d.sastre.medina@gmail.com>
To: cygwin@cygwin.com
Subject: Re: 1.7.10/1.7.11: .Net programs started from a cygwin console may fail.
Date: Tue, 28 Feb 2012 21:42:00 -0000	[thread overview]
Message-ID: <20120228203956.GD6761@jethro.local.lan> (raw)
In-Reply-To: <20120228141754.GA6518@calimero.vinschen.de>

[-- Attachment #1: Type: text/plain, Size: 2138 bytes --]

On Tue, Feb 28, 2012 at 03:17:54PM +0100, Corinna Vinschen wrote:
> On Feb 28 08:51, Jon Clugston wrote:
> > Just a guess, but it does look suspiciously like the name of an
> > environment variable.  Wasn't there some discussion lately about
> > differing case environment variables ("tmp" as opposed to "TMP")?
> 
> Dead on, thanks!  The definitions of tmp and temp in /etc/profile result
> in a double definition of the %TMP% and %TEMP% dos variables from the
> .Net applications POV and it's too dumb to handle that gracefully.
> 
> So the solution is, either we drop the tmp and temp definitions in
> /etc/profile, or old .net apps should be started only after calling
> `unset tmp temp' in bash.
> 
> Btw., tmp and temp are not preserved this way in tcsh's profile scripts.
> So I'm wondering why we do it in /etc/profile.  Can somebody give me a
> management summary?

A while back (about the 3.x -> 4.x changes in base-files), it was
agreed to unset both TMP and TEMP and set them to /tmp.
A user concerned about the security of files owned by windows native 
applications started within cygwin, reported that those files were
created with 777 perms under /tmp, making it trivial for other users to
read/copy temps files easily.
The solution proposed, which I included in 4.0-7, was to set temporary
dirs as they are now in /etc/profile.

With regards to tcsh, and apart from /etc/profile.d/*.csh, it doesn't
use any startup file in base-files, as you know it has its own set of 

/etc/csh.login
/etc/csh.cshrc

and a couple of files under /etc/profile.d (as of 6.18.00-3).
So it is not easy for me to propagate this to tcsh. Regardless, it's probably 
my fault not having publicised enough that change to give tcsh, and
probably zsh and mksh (both can use /etc/their-own-startup-profile)
mantainers at least the chance to include it or complain.

If this setting is to be dropped, we'll go back to creating unsecure files
in /tmp under the described scenario (unless some other solution is implemented).

-- 
Huella de clave primaria: AD8F BDC0 5A2C FD5F A179  60E7 F79B AB04 5299 EC56

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 230 bytes --]

  reply	other threads:[~2012-02-28 20:40 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-27 16:54 Andres Martinelli
2012-02-28 14:15 ` Corinna Vinschen
2012-02-28 14:18   ` Jon Clugston
2012-02-28 14:50     ` Corinna Vinschen
2012-02-28 21:42       ` David Sastre Medina [this message]
2012-02-28 23:05         ` Corinna Vinschen
2012-02-29  9:42           ` Corinna Vinschen
2012-02-29  1:36       ` Andrey Repin
2012-02-29  9:47         ` Corinna Vinschen
2012-02-29 12:39           ` Andrey Repin
2012-02-29 12:49             ` Earnie Boyd
2012-02-29 14:51               ` Corinna Vinschen
  -- strict thread matches above, loose matches on Subject: below --
2012-03-12 19:51 James Johnston
2012-03-13 19:58 ` David Sastre Medina
2012-03-01 18:49 Matt Seitz (matseitz)
2012-03-01 18:17 Matt Seitz (matseitz)
2012-03-01 18:41 ` Corinna Vinschen
2012-02-29 22:47 Matt Seitz (matseitz)
2012-03-01 10:09 ` Corinna Vinschen
2012-02-27 16:12 Andres Martinelli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120228203956.GD6761@jethro.local.lan \
    --to=d.sastre.medina@gmail.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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 read-only IMAP folder(s) and NNTP newsgroup(s).