Sponsored Content
Special Forums UNIX and Linux Applications Oracle Updates (RSS) how to configure ssh2 for not asking password when logging from remote Post 302252173 by arunrao_oradba on Tuesday 28th of October 2008 10:08:55 PM
Old 10-28-2008
how to configure ssh2 for not asking password when logging from remote

Hi gurus,
I am trying to configure ssh2 for not asking passwords when logging in from a remote machine, but it is failing. I ran the command based on the oracle documentation. down below are the steps, please do let me know how to get this solved.
the steps followed
$ /usr/bin/ssh-keygen2 -t dsa
Generating 2048-bit dsa key pair
16 .oOOo.oOo.oO
Key generated.
2048-bit dsa, uvarshne@sunsm1a, Tue Oct 28 2008 18:02:01 -0500
Passphrase :
Again :
Key is stored with NULL passphrase.
(You can ignore the following warning if you are generating hostkeys.)
This is not recommended.
Don't do this unless you know what you're doing.
If file system protections fail (someone can access the keyfile),
or if the super-user is malicious, your key can be used without
the deciphering effort.
Private key saved to /home/dba/uvarshne/.ssh2/id_dsa_2048_b
Public key saved to /home/dba/uvarshne/.ssh2/id_dsa_2048_b.pub
$ /usr/bin/ssh-keygen2 -t rsa
Generating 2048-bit rsa key pair
4 .oOo.oOo.oOo
Key generated.
2048-bit rsa, uvarshne@sunsm1a, Tue Oct 28 2008 18:10:01 -0500
Passphrase :
Again :
Key is stored with NULL passphrase.
(You can ignore the following warning if you are generating hostkeys.)
This is not recommended.
Don't do this unless you know what you're doing.
If file system protections fail (someone can access the keyfile),
or if the super-user is malicious, your key can be used without
the deciphering effort.
Private key saved to /home/dba/uvarshne/.ssh2/id_rsa_2048_b
Public key saved to /home/dba/uvarshne/.ssh2/id_rsa_2048_b.pub

$ touch ~/.ssh2/authorization

$ ssh2 cat id_rsa_2048_*.pub >> authorization^C
$ stty erase
$ ssh2 ^C
$ uname -a
SunOS sunsm1a 5.8 Generic_117350-39 sun4u sparc SUNW,Sun-Fire-280R
$ ssh2 sunsm1a cat ^C
$ pwd
/home/dba/uvarshne/.ssh2

$ ssh2 sunsm1a /home/dba/uvarshne/.ssh2/id_rsa_2048_*.pub >> authorization
Host key not found from database.
Key fingerprint:
xihel-hobyk-mimiv-tifal-dicyb-vubul-hezek-begap-nafyg-lamym-bexux
You can get a public key's fingerprint by running
% ssh-keygen -F publickey.pub
on the keyfile.
warning: tcgetattr failed in ssh_rl_set_tty_modes_for_fd: fd 1: Inappropriate ioctl for device

^C
Received signal 2. (no core)

$ cat id_rsa_2048_b.pub >authorization
$ cat id_dsa_2048_b.pub >>authorization

$ ssh sunsm1a date
Host key not found from database.
Key fingerprint:
xihel-hobyk-mimiv-tifal-dicyb-vubul-hezek-begap-nafyg-lamym-bexux
You can get a public key's fingerprint by running
% ssh-keygen -F publickey.pub
on the keyfile.
Are you sure you want to continue connecting (yes/no)? yes
Host key saved to /home/dba/uvarshne/.ssh2/hostkeys/key_22_sunsm1a.pub
host key for sunsm1a, accepted by uvarshne Tue Oct 28 2008 18:14:22 -0500

uvarshne's password:


I am not sure where i am going wrong
Can you please help me out on this.

thanks in advance
Arun
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Delay when logging in remote

Hello again! When I log in to my computer (Ultra 5 running Solaris 8) from a pc (FTP or Telnet) I have to wait forever (about 30 seconds) before I can log in. Is this some kind of security thing? Can I turn it of? How? Anders (8 Replies)
Discussion started by: alfabetman
8 Replies

2. Shell Programming and Scripting

logging to remote server

Hi, I want to log-in to a remote server using shell script. The server requires the following while allowing a connection: username password one - letter authorisation. How can i implement this in my script? thanks, abey (6 Replies)
Discussion started by: abey
6 Replies

3. Shell Programming and Scripting

Problem with logging into remote host

Hi All, I am using a script for remotely logging into a rhost using telnet and shutdown a server. The script is as follows. IP = 10.24.12.23; export IP UNAME = username ; export UNAME PWD = password; export PWD CRDIR = /etc/rc.d/init.d ; export CRDIR echo "logging into remote... (4 Replies)
Discussion started by: patil_reddy
4 Replies

4. AIX

how to configure ssh2 for not asking password when logging from remote

Hi gurus, I am trying to configure ssh2 for not asking passwords when logging in from a remote machine, but it is failing. I ran the command based on the oracle documentation. down below are the steps, please do let me know how to get this solved. the steps followed $ /usr/bin/ssh-keygen2 -t dsa... (1 Reply)
Discussion started by: arunrao_oradba
1 Replies

5. Cybersecurity

how to configure ssh2 for not asking password when logging from remote

Hi gurus, I am trying to configure ssh2 for not asking passwords when logging in from a remote machine, but it is failing. I ran the command based on the oracle documentation. down below are the steps, please do let me know how to get this solved. the steps followed $ /usr/bin/ssh-keygen2 -t dsa... (2 Replies)
Discussion started by: arunrao_oradba
2 Replies

6. AIX

How to enable password expired messages in ssh2

My SSH version is OpenSSH_5.0p1 and it is not prompting for new password and it is saying that when password expired "Permission denied". Please some one help me regarding this $ ssh devdhq4 "Use is subject to monitoring by First American CREDCO personnel. Any Criminal activity or wrongdoing... (1 Reply)
Discussion started by: choudarysuresh
1 Replies

7. Solaris

how to login with ssh to remote system with out applying the remote root/usr password

how to login with ssh to remote system with out applying the remote root/user password with rlogin we can ujse .rhosts file but with ssh howits possible plz guide (2 Replies)
Discussion started by: tv.praveenkumar
2 Replies

8. SCO

sco remote logging problem

Hello, I am trying to write log from sco box to a remote host. We already have that setting working for linux server using syslog. With this setting(on LINUX) *.* @remote-host for sco I have this *.debug /usr/adm/syslog *.* ... (3 Replies)
Discussion started by: polestar
3 Replies

9. AIX

Remote Script command logging question

I've noticed that when running a script that connects to a number of our servers (to essentially run batch commands) that the commands aren't logged in the user's .sh_history or .bash_history files. Is there a place where this is logged (assuming the script itself isn't doing the logging and I'm... (3 Replies)
Discussion started by: kneemoe
3 Replies

10. Shell Programming and Scripting

How to login with other set of credentials while remote logging?

Below is the code. I need to login into the router if the 1st set of credentials are correct.. if wrong... then it has to check with 2nd set of credentials.. => if the credentials are correct... then it should continue.. => if the credentials are wrong(should not check for 2nd time... then... (0 Replies)
Discussion started by: scriptscript
0 Replies
Net::OpenSSH::Compat::SSH2(3pm) 			User Contributed Perl Documentation			   Net::OpenSSH::Compat::SSH2(3pm)

NAME
Net::OpenSSH::Compat::SSH2 - Net::OpenSSH adapter for Net::SSH2 API compatibility SYNOPSIS
use Net::OpenSSH::Compat::SSH2 qw(:supplant); use Net::SSH2; my $ssh2 = Net::SSH2->new; $ssh2->connect('host'); $ssh2->auth_publickey("jsmith", "/home/jsmith/.ssh/id_dsa.pub", "/home/jsmith/.ssh/id_dsa"); my $c = $ssh2->channel; $c->exec("ls"); print while <$c>; $c->close; print "exit status: ", $c->exit_status, " "; DESCRIPTION
This module implements Net::SSH2 API on top of Net::OpenSSH. After the module is loaded as... use Net::OpenSSH::Compat::SSH2 qw(:supplant); it will supplant the Net::SSH2 module as if it was installed on the machine and use Net::OpenSSH under the hood to handle SSH operations. Most programs using Net::SSH2 should continue to work without any change. Setting defaults The hash %Net::OpenSSH::Compat::SSH2::DEFAULTS can be used to set default values for Net::OpenSSH and other modules called under the hood and otherwise not accesible through the Net::SSH2 API. The entries currently supported are: connection => [ %opts ] Extra options passed to "Net::OpenSSH::new" constructor. Example: $Net::OpenSSH::Compat::SSH2::DEFAULTS{connection} = [ ssh_path => "/opt/SSH/bin/ssh" ]; channel => [ %opts ] Extra options passed to "Net::OpenSSH::open_ex" method. sftp => [ %opts ] Extra options passed to "Net::SFTP::Foreign::new" constructor. $Net::OpenSSH::Compat::SSH2::DEFAULTS{connection} = [ read_ahead => 128 * 1024, queue_size => 20 ]; BUGS AND SUPPORT
This is a work in progress. Besides that, there are some functionality of Net::SSH2 that can not be emulated with Net::OpenSSH. Fortunatelly, the missing bits are rarely used so probably you may not need them at all. Specifically, the return values from the "$ssh2->method($ATTR)" are not real but faked ones. "auth_list" return value is also faked. Anyway, if your Net::SSH2 script fails, fill a bug report at the CPAN RT bugtracker (https://rt.cpan.org/Ticket/Create.html?Queue=Net-OpenSSH-Compat <https://rt.cpan.org/Ticket/Create.html?Queue=Net-OpenSSH-Compat>) or just send me an e-mail with the details. Include at least: 1 - The full source of the script 2 - A description of what happens in your machine 3 - What you thing it should be happening 4 - What happens when you use the real Net::SSH2 5 - The version and name of your operating system 6 - The version of the OpenSSH ssh client installed on your machine ("ssh -V") 7 - The Perl version ("perl -V") 8 - The versions of the Perl packages Net::OpenSSH, IO::Pty and this Net::OpenSSH::Compat. Git repository The source code repository is at https://github.com/salva/p5-Net-OpenSSH-Compat <https://github.com/salva/p5-Net-OpenSSH-Compat>. My wishlist If you like this module and you're feeling generous, take a look at my Amazon Wish List: <http://amzn.com/w/1WU1P6IR5QZ42> Also consider contributing to the OpenSSH project this module builds upon: <http://www.openssh.org/donations.html>. COPYRIGHT AND LICENSE
Copyright (C) 2011 by Salvador Fandin~o (sfandino@yahoo.com) This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.10.0 or, at your option, any later version of Perl 5 you may have available. perl v5.14.2 2011-09-28 Net::OpenSSH::Compat::SSH2(3pm)
All times are GMT -4. The time now is 02:17 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy