Re: password prompt, but pki auth working!?...



Zach, thanks for the tip - now I see that ssh under sudo is using
/root/.ssh for it's keys...

sudo allows for the setting of environment variables on the command line.

So
Which environment variable does ssh use to determine where it looks for
it's keys? I assumed it would be HOME, but under sudo HOME is set to
the home directory of the user executing sudo not root's home.

Thanks,
Morgan.

On 18/02/09 07:25, Zach wrote:
Try ssh -vvv -t [.....]

On Mon, Feb 16, 2009 at 8:39 PM, Morgan Read <mstuff@xxxxxxxxxxx> wrote:

My head hurts!

Can anyone help me with what follows - it shows ssh working with pki
auth in all the permutations I thought might be possible, but lastly
this command prompts for a password:
# ssh -t rsync@xxxxxxxxxxxx sudo rsync -avzAXHn --delete-after
root@xxxxxxxxxxxxx:/etc /media/bigdisk/morgansmachine/etc
...
Permission denied (publickey,gssapi-with-mic,password).


[root@morgansoldmachine /]# ssh rsync@xxxxxxxxxxxx
Last login: Sun Feb 15 20:29:39 2009 from morgansoldmachine.lan
[rsync@morgansmachine ~]$ logout
Connection to 192.168.1.40 closed.

[root@morgansoldmachine /]# ssh rsync@morgansmachine
Last login: Sun Feb 15 20:31:04 2009 from morgansoldmachine.lan
[rsync@morgansmachine ~]$ logout
Connection to morgansmachine closed.

[root@morgansoldmachine /]# ssh rsync@xxxxxxxxxxxxxxxxxx
Last login: Sun Feb 15 20:31:18 2009 from morgansoldmachine.lan
[rsync@morgansmachine ~]$ logout
Connection to morgansmachine.lan closed.

[root@morgansoldmachine /]# ssh rsync@xxxxxxxxxxxx
Last login: Sun Feb 15 20:31:48 2009 from morgansoldmachine.lan

[rsync@morgansmachine ~]$ ssh root@xxxxxxxxxxxxx
Last login: Sun Feb 15 20:10:52 2009 from morgansmachine.lan
[root@morgansoldmachine ~]# logout
Connection to 192.168.1.100 closed.

[rsync@morgansmachine ~]$ ssh root@morgansoldmachine
Last login: Sun Feb 15 20:32:25 2009 from morgansmachine.lan
[root@morgansoldmachine ~]# logout
Connection to morgansoldmachine closed.

[rsync@morgansmachine ~]$ ssh root@xxxxxxxxxxxxxxxxxxxxx
Last login: Sun Feb 15 20:32:44 2009 from morgansmachine.lan
[root@morgansoldmachine ~]# logout
Connection to morgansoldmachine.lan closed.

[rsync@morgansmachine ~]$ logout
Connection to 192.168.1.40 closed.

[root@morgansoldmachine /]# ssh -t rsync@xxxxxxxxxxxx sudo rsync
-avzAXHn --delete-after root@xxxxxxxxxxxxx:/etc
/media/bigdisk/morgansmachine/etc
root@xxxxxxxxxxxxx's password:
Permission denied, please try again.
root@xxxxxxxxxxxxx's password:
Permission denied, please try again.
root@xxxxxxxxxxxxx's password:
Permission denied (publickey,gssapi-with-mic,password).
rsync: connection unexpectedly closed (0 bytes received so far) [receiver]
rsync error: error in rsync protocol data stream (code 12) at io.c(600)
[receiver=3.0.5]
Connection to 192.168.1.40 closed.
[root@morgansoldmachine /]#


Thanks,
Morgan.
--
Getting errors: "There are problems with the signature" (or similar)?
Update your system by installing certificates from CAcert Inc, see here:

http://wiki.cacert.org/wiki/BrowserClients?#head-259758ec5ba51c5205cfb179cf60e0b54d9e378b
Or, if Internet Explorer is your default browser, simply click this link:
http://www.cacert.org/index.php?id=17

Morgan Read
NEW ZEALAND
<mailto:mstuffATreadDOTorgDOTnz>

fedora + freedom; fact || fiction?
http://fedoraproject.org/wiki/Overview
get freed-ora!
http://www.fsfla.org/svnwiki/selibre/linux-libre/freed-ora





--
Getting errors: "There are problems with the signature" (or similar)?
Update your system by installing certificates from CAcert Inc, see here:
http://wiki.cacert.org/wiki/BrowserClients?#head-259758ec5ba51c5205cfb179cf60e0b54d9e378b
Or, if Internet Explorer is your default browser, simply click this link:
http://www.cacert.org/index.php?id=17

Morgan Read
NEW ZEALAND
<mailto:mstuffATreadDOTorgDOTnz>

fedora + freedom; fact || fiction?
http://fedoraproject.org/wiki/Overview
get freed-ora!
http://www.fsfla.org/svnwiki/selibre/linux-libre/freed-ora

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature



Relevant Pages

  • Re: What is The SSH?
    ... Building and Using SSH Tunnels ... What is an SSH tunnel? ... how to use it to make a connection to a server. ... You will need a working SSH client and server installation to build and test ...
    (microsoft.public.windows.server.networking)
  • Re: Xforwarding question
    ... When I use ssh -X and I am done and exit if I have displayed a remote ... graphical program instead of exit giving me logout then connection ... closed then a prompt on the local machine I get a response of logout ... It sounds like your graphical program has not exited and so the ...
    (Ubuntu)
  • password prompt, but pki auth working!?...
    ... Can anyone help me with what follows - it shows ssh working with pki ... Last login: Sun Feb 15 20:29:39 2009 from morgansoldmachine.lan ... $ logout ... Connection to morgansmachine closed. ...
    (SSH)
  • Re: Problem connecting to SSH, OpenVMS7.3-2, HP TCP/IP v5.4 patched
    ... warning: Authentication failed. ... connection lost (Connection closed by remote host.). ... So, as you can see, I am trying to make an ssh connection with the ...
    (comp.os.vms)
  • Re: Keeping OpenSSH connections alive
    ... The TCP connection is timing out, not the SSH session. ... You can then, reconnect to the backgrounded screen session, upon relogin. ...
    (SSH)