This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ssh and user env vars from control panel

On 3/2/2011 2:44 PM, Larry Hall (Cygwin) wrote:
> On 3/1/2011 10:14 PM, Rafael Kitover wrote:
>> I generally set most of my environment variables in the System control
>> panel for my user, instead of in my .bashrc/.zshrc
>> I noticed that when I log in to Cygwin via ssh, these environment
>> variables are not available.
>> Would this be considered a misfeature?
> No, it's considered a security feature.  The environment for OpenSSH is
> stripped to the basics so as to not let lots of information about the
> remote
> system slip through to the client.  If there's stuff you want in your
> OpenSSH
> session that you're not getting now, a small script that you can run after
> login is the prescribed solution.

Or change /etc/sshd_config on the server and enable
	PermitUserEnvironment yes

and then you can add a file on the server:
that contains the envvars you want to sshd to set for incoming
connections authenticated as you, and the desired values.

Note that 'man sshd_config' warns about this option, as it can be exploited.

See here:


Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]