03-14-2017
Hi,
After all your suggestions, I tried to make new setup as I have deleted old keys and .ssh directory.
Now to avoid manual pasting of keys, I can use cat keys >> authorizedkeys as suggested. But I need to paste the keys of source server into target server authorized keys file. and vice versa. To copy like that what command I can use?? while I am using the above command the keys of source server pasting into same server authorized keys.
please suggest.
---------- Post updated at 05:33 AM ---------- Previous update was at 03:00 AM ----------
Even I setup newly, not working properly asking for password again. I checked on permissions too. gave 700 for ssh directory and authorized keys. for both source and target servers. even in one way its not working. please suggest me what I am missing.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello all,
I would like to know if anyone had ever set up a network in which they used DHCP and OPENSSH with no password. I can configure my ssh files to allow me to enter any machine without a password as long as I have generated the public and private keysa nd store them in my .ssh/aut... ... (3 Replies)
Discussion started by: larryase
3 Replies
2. Solaris
Hi Gurus
I have a few Sol 5.9 servers and i have enabled password less authentication between them for my user ID. Often i have found that when my password has expired,the login fails.
Resetting my password reenables the keys.
Do i need to do something to avoid this scenario or is this... (2 Replies)
Discussion started by: Renjesh
2 Replies
3. Red Hat
I setup the keys between 2 servers, but my user account has no password specified for it (never set one up on the account for security reasons). When I try to SSH to the server, SSH prompts for a password that doesn't exist (so I can never connect successfully).
Note: 'passwd -d Rynok' removes... (3 Replies)
Discussion started by: Rynok
3 Replies
4. UNIX for Dummies Questions & Answers
How to setup SSH to not require a password when establishing an SSH connection from server A to server B for particular user? (4 Replies)
Discussion started by: sam101
4 Replies
5. Red Hat
i need to set up a user to execute a restricted command as another user and to be able to do so without entering a password. I understand the security concerns but let's not go there, unless you are really compelled to do so... The directive to permit is that I believe should work and did add to... (2 Replies)
Discussion started by: twk
2 Replies
6. Shell Programming and Scripting
hi,
i want to setup a password less FTP to a remote server so that i can ftp to a remote server without the password.
i have setup a passwordless ssh and i am able to use scp commands to connect to the remote server without asking for the password. but when i try to ftp to the same remote... (6 Replies)
Discussion started by: Little
6 Replies
7. Solaris
HI Community.
I was trying to create ssh password less authentication for one user called night and it's not working for me.
These are the steps I followed:-
I have logged into the server and issued ssh-ketgen -t rsabash-3.2$ ssh-keygen -t rsa
Generating public/private rsa key pair.... (4 Replies)
Discussion started by: bentech4u
4 Replies
8. UNIX for Advanced & Expert Users
How do I setup a Samba server to always ask to user and password, when a windows user, prints your files using a shared printer through a Samba Linux Server (CUPS)? (0 Replies)
Discussion started by: viga
0 Replies
9. AIX
Hello,
We're running AIX 6 & 7.
Previously we were using the old encryption techinique (DES/crypt)
I have a GUI application that has a verify button (the verify button is sort of a digital signature) - the user clicks it, enters his or her password and we then make a call to a C module, This... (3 Replies)
Discussion started by: evansch
3 Replies
10. Forum Support Area for Unregistered Users & Account Problems
I was unable to login and so used the "Forgotten Password' process. I was sent a NEWLY-PROVIDED password and a link through which my password could be changed. The NEWLY-PROVIDED password allowed me to login.
Following the provided link I attempted to update my password to one of my own... (1 Reply)
Discussion started by: Rich Marton
1 Replies
LEARN ABOUT PHP
ssh2_publickey_list
SSH2_PUBLICKEY_LIST(3) 1 SSH2_PUBLICKEY_LIST(3)
ssh2_publickey_list - List currently authorized publickeys
SYNOPSIS
array ssh2_publickey_list (resource $pkey)
DESCRIPTION
List currently authorized publickeys.
PARAMETERS
o $pkey
- Publickey Subsystem resource
RETURN VALUES
Returns a numerically indexed array of keys, each of which is an associative array containing: name, blob, and attrs elements.
Publickey elements
+----------+---------------------------------------------------+
|Array Key | |
| | |
| | Meaning |
| | |
+----------+---------------------------------------------------+
| name | |
| | |
| | Name of algorithm used by this publickey, for |
| | example: ssh-dss or ssh-rsa. |
| | |
| blob | |
| | |
| | Publickey blob as raw binary data. |
| | |
| attrs | |
| | |
| | Attributes assigned to this publickey. The most |
| | common attribute, and the only one supported by |
| | publickey version 1 servers, is comment, which |
| | may be any freeform string. |
| | |
+----------+---------------------------------------------------+
EXAMPLES
Example #1
Listing authorized keys with ssh2_publickey_list(3)
<?php
$ssh2 = ssh2_connect('shell.example.com', 22);
ssh2_auth_password($ssh2, 'jdoe', 'secret');
$pkey = ssh2_publickey_init($ssh2);
$list = ssh2_publickey_list($pkey);
foreach($list as $key) {
echo "Key: {$key['name']}
";
echo "Blob: " . chunk_split(base64_encode($key['blob']), 40, "
") . "
";
echo "Comment: {$key['attrs']['comment']}
";
}
?>
The above example will output:
Key: ssh-rsa
Blob: AAAAB3NzaC1yc2EAAAABIwAAAIEA5HVt6VqSGd5P
TrLRdjNONxXH1tVFGn0Bd26BF0aCP9qyJRlvdJ3j
4WBeX4ZmrveGrjMgkseSYc4xZ26sDHwfL351xjza
LpipuBGRrw17mWVBhuCExo476ri5tQFzbTc54VE
HYckxQ16CjSTibI5X69GmnYC9PNqEYq/1TP+HF10
Comment: John's Key
Key: ssh-rsa
Blob: AAAAB3NzaHVt6VqSGd5C1yc2EAAAABIwA232dnJA
AIEA5HVt6VqSGd5PTrLRdjNONxX/1TP+HF1HVt6V
qSGd50H1tVFGn0BB3NzaC1yc2EAd26BF0aCP9qyJ
RlvdJ3j4WBeX4ZmrveGrjMgkseSYc4xZ26HVt6Vq
SGd5sDHwfL351xjzaLpipuBGB3NzaC1yc2EA/1T
Comment: Alice's Key
NOTES
Note
The public key subsystem is used for managing public keys on a server to which the client is already authenticated. To authenticate
to a remote system using public key authentication, use the ssh2_auth_pubkey_file(3) function instead.
SEE ALSO
ssh2_publickey_init(3), ssh2_publickey_add(3), ssh2_publickey_remove(3).
PHP Documentation Group SSH2_PUBLICKEY_LIST(3)