public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* SSHD /var/empty must be owned by root
@ 2012-04-24  7:11 Gyurmo
  2012-04-24  7:28 ` Corinna Vinschen
  0 siblings, 1 reply; 3+ messages in thread
From: Gyurmo @ 2012-04-24  7:11 UTC (permalink / raw)
  To: cygwin

Hello,
I have:

[code]
$ /usr/sbin/sshd.exe -D
/var/empty must be owned by root and not group or world-writable.
[/code]

I can I have a trivial error. But I cannot google it. Please help me.
This is mine environment:

[code]
$ ls -l /etc/ssh*
-rw-r--r-- 1 SYSTEM Rendszergazdák 1555 ápr.  24 08.17 /etc/ssh_config
-rw-r--r-- 1 SYSTEM Rendszergazdák 1763 febr. 13 13.54 /etc/ssh_config_1.txt
-rw-r--r-- 1 SYSTEM Rendszergazdák  668 2011 máj.  29 /etc/ssh_host_dsa_key
-rw-r--r-- 1 SYSTEM Rendszergazdák  602 2011 máj.  29 /etc/ssh_host_dsa_key.pub
-rw-r--r-- 1 SYSTEM Rendszergazdák  227 2011 máj.  29 /etc/ssh_host_ecdsa_key
-rw-r--r-- 1 SYSTEM Rendszergazdák  174 2011 máj.  29
/etc/ssh_host_ecdsa_key.pub
-rw-r--r-- 1 SYSTEM Rendszergazdák  977 2011 máj.  29 /etc/ssh_host_key
-rw-r--r-- 1 SYSTEM Rendszergazdák  642 2011 máj.  29 /etc/ssh_host_key.pub
-rw-r--r-- 1 SYSTEM Rendszergazdák 1675 2011 máj.  29 /etc/ssh_host_rsa_key
-rw-r--r-- 1 SYSTEM Rendszergazdák  394 2011 máj.  29 /etc/ssh_host_rsa_key.pub
-rw-r--r-- 1 SYSTEM Rendszergazdák 3344 ápr.  24 08.18 /etc/sshd_config
-rw-r--r-- 1 SYSTEM Rendszergazdák 3188 2011 aug.  24 /etc/sshd_config.bac
[/code]

[code]
$ getfacl.exe /var/empty/
# file: /var/empty/
# owner: root
# group: SYSTEM
user::rwx
group::r-x
mask:rwx
other:r-x
default:user::rwx
default:group::r-x
default:other:r-x
[/code]

[code]
$ cat /etc/passwd | grep sshd
sshd:unused:1010:513:sshd,U-KILOVES\sshd,S-1-5-21-1844237615-1801674531-839522115-1010:/var/empty:/bin/false
[/code]

And I have an user sshd name grouped with administrators and folder is
c:\cygwin\var\empty defined in windows.

What other things need I do.
I wait for your help.
Thanks

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: SSHD /var/empty must be owned by root
  2012-04-24  7:11 SSHD /var/empty must be owned by root Gyurmo
@ 2012-04-24  7:28 ` Corinna Vinschen
  2012-04-24  9:23   ` Gyurmo
  0 siblings, 1 reply; 3+ messages in thread
From: Corinna Vinschen @ 2012-04-24  7:28 UTC (permalink / raw)
  To: cygwin

On Apr 24 09:10, Gyurmo wrote:
> Hello,
> I have:
> 
> [code]
> $ /usr/sbin/sshd.exe -D
> /var/empty must be owned by root and not group or world-writable.

Why don't you run sshd as a service?  That's what the ssh-host-config
script is for.  The above call from the command line does not allow to
login with another account than the one sshd has been started under.

Usually sshd tests if /var/empty is owned by uid 0.  On Cygwin, where
there's usually no user with uid 0, the code has been modified to test
if /var/empty is owned by the user running sshd.  So, if you start sshd
on the command line, you have to chown /var/empty to the current user
account.  Same goes for the ssh-related files under /etc.  The error
message is the vanilla upstream error message.  It hasn't been changed
for Cygwin to keep the Cygwin-related upstream patchset small.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: SSHD /var/empty must be owned by root
  2012-04-24  7:28 ` Corinna Vinschen
@ 2012-04-24  9:23   ` Gyurmo
  0 siblings, 0 replies; 3+ messages in thread
From: Gyurmo @ 2012-04-24  9:23 UTC (permalink / raw)
  To: cygwin

Thanks,
This is solved me.
I only created /var/empty with login in sshd. Only this needed.
And I wrote inside win service sshd username and passwd.

Thanks.

2012/4/24 Corinna Vinschen <corinna-cygwin>:
> On Apr 24 09:10, Gyurmo wrote:
>> Hello,
>> I have:
>>
>> [code]
>> $ /usr/sbin/sshd.exe -D
>> /var/empty must be owned by root and not group or world-writable.
>
> Why don't you run sshd as a service?  That's what the ssh-host-config
> script is for.  The above call from the command line does not allow to
> login with another account than the one sshd has been started under.
>
> Usually sshd tests if /var/empty is owned by uid 0.  On Cygwin, where
> there's usually no user with uid 0, the code has been modified to test
> if /var/empty is owned by the user running sshd.  So, if you start sshd
> on the command line, you have to chown /var/empty to the current user
> account.  Same goes for the ssh-related files under /etc.  The error
> message is the vanilla upstream error message.  It hasn't been changed
> for Cygwin to keep the Cygwin-related upstream patchset small.
>
>
> Corinna

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

end of thread, other threads:[~2012-04-24  9:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-04-24  7:11 SSHD /var/empty must be owned by root Gyurmo
2012-04-24  7:28 ` Corinna Vinschen
2012-04-24  9:23   ` Gyurmo

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).