4
votes
0answers
28 views

How can I determine which SSH keyfile was used to authenticate a login?

We have a hosted CentOS 6.5 server in which we have a single user account. That account has been configured to use SSH keyfile authentication for the users who need to access it. I would like to be ...
2
votes
1answer
52 views

SSH: public key authentication without authorized_keys file

I have a lot of ssh public key logins on a Linux server, e.g.: Jul 25 11:41:01 host sshd[24594]: Accepted publickey for root from xxx.xxx.xx.xx port 33374 ssh2 This is strange for me since there's ...
5
votes
1answer
87 views

2 Factor Authentication in SSH using public key and PAM

I'm trying to setup 2 Factor Authentication. I want the user to login successfully if: The public private/public key matches (authentication method: publickey) or the password is correct My pam ...
1
vote
2answers
80 views

Why do my sshd logs show many trys on invalid ports?

My ssh daemon is setup to listen on port 2221. I have also disabled root login from ssh. I don't understand why in auth.log I have attempts to log on other ports (example with 4627 here). May 17 ...
1
vote
1answer
110 views

problem with unique ssh public/private key pair on second user

I have created an ssh key pair using ssh-keygen -t rsa for my main user and everything seems to be working well. Password login has been disabled. I have a second user that I am trying to create a ...
1
vote
1answer
39 views

Connecting to Github from server

I am trying to connect to Github from a server running Jenkins. To do this, I'm copying my public key from another server, into the authorized_keys on the new server. All I'm getting is the ...
0
votes
3answers
134 views

SSH public key authentication works on LAN and not from WAN

I've setup my SSH server to use public key authentication. When I connect to my server on local network, it authenticates. But it doesn't when I connect over the internet. I don't think the problem ...
0
votes
1answer
83 views

Ssh 'access denied' from one host but not the other

Consider the following scenario: I have a Debian-ssh-server setup and exposed it to the internet for some time for testing. Also I have an account which is basically configured as root in the sudoers ...
2
votes
0answers
166 views

SSH login from external authentication

Here is what I try to accomplish: I have a server with a git repository. I use ISPConfig as control panel for our websites and I want to integrate the ISPConfig API for email authentication as second ...
1
vote
1answer
156 views

Mount home partition on user login

I got a VPS with a user dedicated to store my files. As i am aware of the current situation with the NSA and many other governments, and my VPS is hosted on a doubtful country i would like to ensure ...
2
votes
3answers
523 views

How to do svn update without password on crontab [closed]

I'm new to svn and ssh. I'm trying to do svn update of 5 repositories in my local system every 3 hours on crontab. So, to achieve this I have setup ssh passwordless login using the below steps: ...
3
votes
2answers
119 views

SSH when to use public key and password?

I think I understand the difference between Public Key authentication and Password. But how do I decide which one to use and which one is most secure in what situation? Can anybody give me some real ...
1
vote
1answer
4k views

Meaning of “Connection closed by xxx [preauth]” in sshd logs

We have a Windows batch script, which connects automatically to a linux server via PLINK (putty). There is NO public private key authentication, the user and the password are in the script. On our ...
0
votes
1answer
136 views

Why is my ssh connection unauthorized although I have updated my key on the remote machine?

On my local machine I have a public key stored in .ssh/id_rsa.pub To be able to log in to a remote machine I copy this key using ssh-copy-id: ssh-copy-id user@remote-host On the remote host, I ...
5
votes
3answers
997 views

Permit root to login via ssh only with key-based authentication

I have some doubts about certain ssh server configurations on /etc/ssh/sshd_config. I want the next behavior: Public key authentication is the only way to authenticate as root (no password ...
0
votes
2answers
7k views

SSH authentication using gssapi-keyex or gssapi-with-mic (publickey not permitted)

My company has disabled SSH public key authentication, therefore I have to manually enter each time my password (I am not suppose to change /etc/ssh/sshd_config). However gssapi-keyex and ...
2
votes
2answers
514 views

ssh login in Bash script

I've been working on a series of scripts to perform tasks on my remote server, but have gotten stuck at how to log in via ssh mid script, as I cannot enter the password automatically. Is there a way ...
1
vote
1answer
99 views

SSH Authentication Mechanism

Doing a personal research project and I'm wondering: Why does SSH do its own mechanism negotiation rather than use SASL? At first I thought it might be to ensure confidentiality of the whole session, ...
2
votes
1answer
226 views

Restrict two way SSH and Apache authentication to non-local networks

I am using Google's open-source PAM module for two-way authentication for SSH logins and certain Apache directives. It works great, however I would like to use this only when trying to log in from an ...
0
votes
1answer
909 views

Unable to login to my server using ssh

Yesterday I was migrating to my new server, needed to use rsync, I created a RSA key, so that rsync could connect, I saw an error that says add to trusted key in location x I didn't have that location ...
1
vote
5answers
2k views

How to securely automate running commands as root with “sudo su -”?

hint (on client side, how to encrypt files/pwd's): # encrypt pwd with ssh key: openssl rsa -in ~/.ssh/id_rsa -outform pem > ~/.ssh/TEMP-id_rsa.pem 2>/dev/null openssl rsa -in ~/.ssh/id_rsa ...
1
vote
1answer
528 views

Session terminates immediately after authentication

I have a RedHat 5.3 server with several regular users created. Since last Friday the user "xpto" is getting "Authentication failed" error messages. Tha account isn't locked out. I have reset the ...
11
votes
3answers
585 views

Groups differ from the local ones when logging in remotely

We store our users in LDAP, alongside some groups that have meaning across different systems (organizational roles including wheel). There are also groups local to workstations, e.g. audio or video ...
1
vote
1answer
79 views

keeping keys on an auxiliary removable drive

It seems that servers are only as secure as the machine that holds the keys and that in turn means the desktop/screensaver password is the line of defence for not only the desktop itself but any ...
2
votes
1answer
1k views

Script to get file from SFTP and run it

We have 5 servers running our code: A, B , C, D and E. From a local machine, we sftp the file to A. Then ssh id@A su - applicationname sftp id@A get <file> bye tar -xzf <file> logout ...
2
votes
3answers
649 views

rsync server/daemon security

I have a NAS (Netgear Readynas NV+) at home and a linux (Arch) box at work that is always on. The linux box is already running an ssh server/daemon and the NAS is already running an rsync ...
4
votes
1answer
842 views

Does the SFTP server accept passwords at all?

I'm trying to connect to a sftp server via sftp USERNAME@SERVERNAME. Whatever I do, I get "Permission denied (publickey)." Googling doesn't help as everybody recommends switching to key-based ...
3
votes
1answer
182 views

How are loaded SSH keys referenced by name?

I'm using chef's knife ec2 tool which requires the name of a loaded SSH key (that was created in the Amazon EC2 control panel) It seems strange to me that it uses a name to reference the keypair - ...
6
votes
4answers
2k views

SSH authentication: either SSH keys or one time password

I have an Ubuntu 10.04 Linux server that I normally ssh into (from my home machine) using ssh key authentication. However, sometimes I need to ssh remotely from potentially insecure machines (like ...
1
vote
2answers
929 views

SSH on my local network - problem with login

I'm having problem with logging into my local-network-linux (server) ssh with Putty (and with Linux terminal, too) When my server shows me request to insert username, I insert "root" and I do press ...
23
votes
6answers
7k views

Can I find out which ssh key was used to access an account?

Is it possible to find out which ssh key was used to access an account? I have an account on a server that I let several (trusted!) people have access to via ssh. I'd find it useful to be able to ...
10
votes
3answers
1k views

How can I lock my own account from remote ssh login with password?

I don't want to disable remote login with password altogether, but I want to make it so that my account is only accessible with key pair authentication (there are other users who wants to use ...
2
votes
2answers
1k views

setting up ssh public key

Okay, so I'm trying to setup a login for logging in with ssh, using a public key. First, I am using puttygen to generate a rsa-ssh2 public key using a passphrase. I followed the directions and ...
6
votes
3answers
9k views

ssh remote server on some port other than 22 without password

I am usually connecting to the remote server with ssh user@server.com -p 11000 and then giving the password each time for user. How should I avoid entering the password each time I connect ...
1
vote
2answers
187 views

ssh fails for an unix server due to dual layer of authentication

I have a server which has dual authentication layer. Meaning first a user has to login to the box using his userid and then use a group id to access the development folder (say). Now I have a script ...
5
votes
2answers
5k views

Not able to ssh in to remote machine using shell script in Crontab

Below is the script which i am trying to run, which runs without any issue for i in `seq 200 2100` do usr=(`ssh -t -t -o ConnectTimeout=60 machine$1 finger | tail -1 | awk '{print$1}'`) echo ...
3
votes
1answer
11k views

How to enable remote login?

Currently I can only login to my remote linux via the "ubuntu" user account, without a password (via SSH authentication). I have another user configured on the machine, and if I try to login with its ...
10
votes
3answers
3k views

How can I make a user able to log in with ssh keys but not with a password?

I would like to create a user and have no password. As in you cant log in with a password. I want to add keys to its authorized_keys by using root. This is for my automated backup system.
1
vote
1answer
1k views

What strings should I look for in /var/log/auth.log?

I wrote a bash command to scan /var/log/auth.log for messages occurring on the current day indicating unauthorised access. Currently it just fetches messages matching BREAK-IN and unauthorized. What ...