public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Frank-Ulrich Sommer <f-u.s@gmx.net>
To: cygwin@cygwin.com
Subject: Re: cygsshd fails due to bad ownership or modes of /cygdrive/c/Users
Date: Wed, 7 Feb 2024 22:27:13 +0100	[thread overview]
Message-ID: <451dd3c1-16f4-4d6b-bc9e-fa02307948f3@gmx.net> (raw)
In-Reply-To: <ZcPZkcrwpZ78mR9v@calimero.vinschen.de>



On 07.02.2024 20:27, Corinna Vinschen via Cygwin wrote:
> On Feb  7 20:23, ASSI via Cygwin wrote:
>> Frank-Ulrich Sommer via Cygwin writes:
>>> I'm trying to run cygsshd on my PC with Windows 11 and connect from a
>>> linux machine. I have added the public key to
>>> /cygdrive/c/Users/xxx/.ssh/authorized_keys and created a symbolic link
>>> from  /cygdrive/c/Users/xxx/.ssh to /home/xxx/.ssh. As usual I checked
>>> the access rights and mode of the .ssh directory (700 and belongs to
>>> user xxx) and the authorized_keys file (600 and also belongs to user
>>> xxx) and also of the home directory (had to change ownership).
>> Just bind mount instead of symlinking .ssh and everything should work.
> Assuming you have installed CYgwin under your own account, that's even
> better than utilizing "StrictModes"
>
>
> Corinna
>

Ich decided to move the .ssh directory to /home/username/.ssh and edited nsswitch.conf to specify the home directory with "db_home: /home/%U" (all entries in this file were commented). Now sshd seems to work without deactivating strict mode. If I should still get problems with something else missing the .ssh directory in the WIndows Users directory I will try the bind mount.

I do not know how the .ssh got in /cygdrive/c/Users/... because I did not change anything manually.

Thanks for all the help!


      parent reply	other threads:[~2024-02-07 21:27 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-04 23:53 Frank-Ulrich Sommer
2024-02-06  1:28 ` Frank-Ulrich Sommer
2024-02-06  1:36   ` Eliot Moss
2024-02-06 21:22     ` Brian Inglis
2024-02-07  2:26       ` Frank-Ulrich Sommer
2024-02-07  5:34         ` marco atzeri
2024-02-07 19:01         ` matthew patton
2024-02-07 19:25           ` Corinna Vinschen
2024-02-07 19:23 ` ASSI
2024-02-07 19:27   ` Corinna Vinschen
2024-02-07 19:55     ` Corinna Vinschen
2024-02-07 21:27     ` Frank-Ulrich Sommer [this message]

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=451dd3c1-16f4-4d6b-bc9e-fa02307948f3@gmx.net \
    --to=f-u.s@gmx.net \
    --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).