[CentOS] freenx [SOLVED]

Tue Jan 24 16:51:54 UTC 2006
Maciej Żenczykowski <maze at cela.pl>

> turns out that install will create
>
> /var/lib/nxserver/home/.ssh/authorized_keys2
>
> but sshd on CentOS 4 doesn't look there.
>
> so I merely
>
> cd /var/lib/nxserver/home/.ssh
> cp authorized_keys2 authorized_keys
> chown nx authorized_keys
>
> et voila - login
>
> Thanks for everyone's help
>
> I can't believe that people didn't stumble into this installing freenx
> on CentOS as it simply cannot work out of the box without doing this or
> some other change in /etc/ssh/sshd_config

Okay, weird:

# cat /etc/ssh/sshd_config | grep -v "^#" | grep -v "^\$"
SyslogFacility AUTHPRIV
PermitRootLogin without-password
PasswordAuthentication yes
GSSAPIAuthentication yes
GSSAPICleanupCredentials yes
UsePAM yes
X11Forwarding yes
AllowGroups root users nx
Subsystem       sftp    /usr/libexec/openssh/sftp-server

# strace -ff -s 2048 -p [main_sshd_pid] 2>&1 | grep -i authorized_k
[pid 2216] stat64("/var/lib/nxserver/home/.ssh/authorized_keys", 
0xbfe63c20) = -1 ENOENT (No such file or directory)
[pid 2216] stat64("/var/lib/nxserver/home/.ssh/authorized_keys2", 
{st_mode=S_IFREG|0640, st_size=16192, ...}) = 0
[pid 2216] open("/var/lib/nxserver/home/.ssh/authorized_keys2", 
O_RDONLY|O_LARGEFILE) = 4
[pid 2216] lstat64("/var/lib/nxserver/home/.ssh/authorized_keys2", 
{st_mode=S_IFREG|0640, st_size=16192, ...}) = 0

while "ssh -i client.key nx at server" is run.

So the CentOS42 up2date server with no special (?) configuration is 
checking both auth_key2 and auth_key files...

Weird,

MaZe.