Using ssh-keygen to generate key pairs

Rob Read
2009-01-29
2013-05-20
  • Rob Read
    Rob Read
    2009-01-29

    Hi,

    In the documentation (rel url ./j2ssh/documentation/j2ssh-authentication.htm#Publickey), there are instruction on generating  key pairs for public-key authentication:

    "First you will require a key pair which can be generated using the ssh-keygen tool, located in the bin directory of the J2SSH installation.

    C:\sshtools-j2ssh\bin>ssh-keygen -b 1024 -t dsa mykey "

    Which download is the ssh-keygen tool in, I can't locate it?

    Cheers,
    Robert

     
    • Pat
      Pat
      2009-01-29

      Look in the daemon under Unmaintained http://downloads.sourceforge.net/sshtools/SSHTools-SSHDaemon-Win32-0.0.9-bin.zip?use_mirror=

      It has a batch file which uses the com.sshtools.j2ssh.transport.publickey.SshKeyGenerator class.

      Pat

       
    • Andy Putnins
      Andy Putnins
      2009-02-03

      com.sshtools.common.keygen.Main is a Swing program. On *nix, try:

      >cat sshtools-keygen.sh
      SSHTOOLS_HOME=/usr/local/java/j2ssh-0.2.9
      CLASSPATH=$CLASSPATH:$SSHTOOLS_HOME/dist/lib/j2ssh-core-0.2.9.jar
      CLASSPATH=$CLASSPATH:$SSHTOOLS_HOME/dist/lib/j2ssh-common-0.2.9.jar
      CLASSPATH=$CLASSPATH:$SSHTOOLS_HOME/lib/commons-logging.jar
      CLASSPATH=$CLASSPATH:$SSHTOOLS_HOME/lib/xercesImpl.jar
      CLASSPATH=$CLASSPATH:$SSHTOOLS_HOME/lib/xmlParserAPIs.jar

      java com.sshtools.common.keygen.Main

      >./sshtool-keygen.sh

      will pop up a nice little GUI.

           - Andy