Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Why I have both in home directory? Is this just different versiosn and one can be deletec?

When I generate SSH public/private key with program ssh-keygen, which is used?

share|improve this question
What OS?? What version of SSH are you running? – Zoredache Feb 1 '12 at 8:50
@Zoredache: Ubuntu 11.04 and its default SSH – zaharpopov Feb 1 '12 at 12:07
@Zoredache: how I know ssh version? ssh -v say OpenSSH_5.8p1 Debian-1ubuntu3, OpenSSL 0.9.8o 01 Jun 2010 – zaharpopov Feb 1 '12 at 12:49
That is the version. Not sure why you would have a .ssh2 folder. OpenSSH by default will only use .ssh. – Zoredache Feb 1 '12 at 17:35

There were two major versions of the SSH protocols: Version 1 and Version 2. Generally, the later versions of the software support both versions of the protocol (though I believe it is best practice to disable SSH version 1 support in the SSH daemon/sevice configuration).

The current version of the ssh-keygen program from OpenSSH typically generates keys (for SSH protocol 1 or 2) in a folder named .ssh

Some commercial SSH programs and apparently some earlier versions of openssh might use a .ssh2 folder.

share|improve this answer
But you can find a sshd2_config manual page online which lists more options that are not documented for sshd_config of OpenSSH. What is with that? For instance AllowTcpForwardingForUsers. – Kaz Dec 7 '12 at 21:51
^ Aha, OpenSSH has Match blocks in the configuration. You can Match on users and groups, and enclose the AllowTcpForwarding within to do the same thing. – Kaz Dec 7 '12 at 22:47

Check whether .ssh and .ssh2 are really directories and not files. Just checked the other day and the same entries in my system happened to be files that too malicious ones which were generating huge outbound traffic.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .