Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 9 of 9
  1. #1
    Member
    Join Date
    Oct 2006
    Posts
    8

    Default putty ssh keys

    I'm wanting to require ssh key to login to the ssh... However when I click on "Manage SSH keys" in the WHM and then goto import a putty .ppk it says

    /usr/local/cpanel/bin/puttygen is missing or not executable. Please build it from /usr/local/cpanel/src/3rdparty/mit/

    so I went to the folder and went to make it and then i get


    root@web02 [/usr/local/cpanel/src/3rdparty/mit]# make
    /usr/local/cpanel/src/3rdparty/mit/utils/build_prep.pl cgiemail-1.6
    (cd cgiemail-1.6; \
    rm -f config.cache; \
    ./configure --enable-owner-bounce; \
    make)
    creating cache ./config.cache
    checking cgienv... yes
    checking owner-bounce... yes
    checking x-headers... yes
    checking for sendmail... /usr/sbin/sendmail
    checking for gcc... gcc
    checking whether the C compiler (gcc ) works... yes
    checking whether the C compiler (gcc ) is a cross-compiler... no
    checking whether we are using GNU C... yes
    checking whether gcc accepts -g... yes
    checking how to run the C preprocessor... gcc -E
    checking for ANSI C header files... yes
    checking for size_t... yes
    checking for sigprocmask... yes
    checking for strerror... yes
    checking for socket... yes
    updating cache ./config.cache
    creating ./config.status
    creating cgi.h
    creating Makefile
    creating testce.html
    creating config.h
    config.h is unchanged
    make[1]: Entering directory `/usr/local/cpanel/src/3rdparty/mit/cgiemail-1.6'
    gcc -DCSOHEADER=\"/afs/net.mit.edu/admin/www/root/csoheader\" -DCSOFOOTER=\"/afs/net.mit.edu/admin/www/root/csofooter\" -c cgilibcso.c
    gcc -o cgicso cgilib.o cgilibcso.o csoget.o cgicso.o
    cgilib.o: In function `cgi_mail_template':cgilib.c.text+0x16ca): warning: the use of `tmpnam' is dangerous, better use `mkstemp'
    make[1]: Leaving directory `/usr/local/cpanel/src/3rdparty/mit/cgiemail-1.6'


    I also noticed there was a bash script called buildputty - so trying that

    and then it errors out


    putty-0.58/README
    putty-0.58/sshpubk.c
    putty-0.58/mkunxarc.sh
    putty-0.58/sftp.h
    putty-0.58/Recipe
    putty-0.58/logging.c
    putty-0.58/sshsha.c
    putty-0.58/putty.h
    putty-0.58/sshprime.c
    putty-0.58/misc.c
    putty-0.58/telnet.c
    putty-0.58/cmdgen.c
    putty-0.58/manifest
    putty-0.58/version.def
    cc -O2 -Wall -Werror -g -I.././ -I../charset/ -I../windows/ -I../unix/ -I../mac/ -I../macosx/ `gtk-config --cflags` -c ../cmdgen.c
    /bin/sh: gtk-config: command not found
    cc1: warnings being treated as errors
    ../cmdgen.c: In function âblobfpâ:
    ../cmdgen.c:235: warning: pointer targets in passing argument 2 of âMD5Updateâ differ in signedness
    ../cmdgen.c: In function âmainâ:
    ../cmdgen.c:699: warning: pointer targets in passing argument 1 of âssh1_read_bignumâ differ in signedness
    ../cmdgen.c:705: warning: pointer targets in passing argument 1 of âssh1_read_bignumâ differ in signedness
    ../cmdgen.c:877: warning: pointer targets in assignment differ in signedness
    ../cmdgen.c:889: warning: pointer targets in assignment differ in signedness
    ../cmdgen.c:909: warning: pointer targets in passing argument 1 of âbase64_encode_atomâ differ in signedness
    gmake: *** [cmdgen.o] Error 1
    install: cannot stat `puttygen': No such file or directory



    Any suggestions on getting this to work?

  2. #2
    Member
    Join Date
    Oct 2006
    Posts
    11

    Default

    Been wanting to know that also.

  3. #3
    Member freedog96150's Avatar
    Join Date
    Mar 2005
    Location
    Nevada, USA
    Posts
    68

    Default

    puttygen already exists on my installation. Look in /usr/local/cpanel/bin for puttygen. You can also try
    Code:
    root@host [software]locate puttygen
    or
    Code:
    root@host [software]find / -name "puttygen" -depth -print
    If it is not there, you can use the scripts mentioned previously. Make sure that you install the gtk libraries/tools first. Depending on your OS, you can use yum, apt-get, up2date, or whatever rpm manager your system uses and install gtk and gtk-config. On my CentOS 3.x system I use
    Code:
    root@host [software] yum install gtk gtk-config
    After gtk is installed you can run the /usr/local/cpanel/src/3rdparty/mit/buildputty script.

    As an alternative, I mostly use puttygen on my windows box and cut/paste the key into the appropriate .ssh/authorized_keys file for each user.
    **********************
    Brian Frias
    "Without fear, there is no
    courage"
    **********************

  4. #4
    Registered User
    Join Date
    Dec 2004
    Posts
    4

    Default

    hello...

    still the same error at cpanel Private SSH Key id_dsa conversion to ppk format::

    /usr/local/cpanel/bin/puttygen is missing or not executable. Please build it from /usr/local/cpanel/src/3rdparty/mit/

    can someone tell me how to solve it?

  5. #5
    Member
    Join Date
    Oct 2001
    Posts
    344

    Default

    I have this problem on my centos 5 box too.

    Anyone can help ?

  6. #6
    cPanelBilly
    Guest

    Default

    This is a bug in putty-0.58 I have contacted development to have them add in the latest version of putty which fixes this

  7. #7
    cPanel Product Evangelist Infopro's Avatar
    Join Date
    May 2003
    Location
    Pennsylvania
    Posts
    7,165
    cPanel/Enkompass Access Level

    Root Administrator

    Lightbulb

    Quote Originally Posted by cPanelBilly View Post
    This is a bug in putty-0.58 I have contacted development to have them add in the latest version of putty which fixes this

    Does this bug exist in 0.60 as well?

    Latest news
    2007-04-29 PuTTY 0.60 is released

  8. #8
    Registered User
    Join Date
    Nov 2004
    Posts
    3

    Default

    0.60 works.

    Locate puttygen. Mine was here:
    Code:
    cd /usr/local/cpanel/src/3rdparty/mit/
    Download putty 0.60 using wget:
    Code:
    wget http://the.earth.li/~sgtatham/putty/latest/putty-0.60.tar.gz
    unzip it:
    Code:
    tar -zxvf putty-0.60.tar.gz
    Then change the 58 at the top of this file to a 60:
    Code:
    pico /usr/local/cpanel/src/3rdparty/mit/buildputty
    Then run
    Code:
    ./buildputty
    After that, create an ssh key with Manage SSH keys. RSA or DSA, it doesn't matter. If you use a passphrase you'll have to enter that when you connect (which kind of defeats the purpose of using a key in the first place).

    Authorize the key with Manage Authorization.

    View/download the private key. Enter the passphrase to convert it to Putty PPK

    Copy/paste the PPK output into a new file on your computer ending in the .ppk extension.

    In Putty, under Connection > User Name, enter the username you'd like to log in as.
    Under Connection > SSH > Auth, browse to where you saved the .ppk file.
    Save this as a Saved Session and enjoy.

    Done. (whew, was that really easier?)
    Last edited by phatteus; 10-24-2007 at 01:21 AM.

  9. #9
    Member
    Join Date
    Apr 2005
    Posts
    126

    Default

    Thanks a lot phatteus, that did it!

Similar Threads & Tags
Similar threads

  1. How to connect in SSH after create key in Manage SSH Keys
    By konrath in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 07-03-2009, 11:57 PM
  2. Create SSH Keys and login using putty - access denied
    By isputra in forum cPanel and WHM Discussions
    Replies: 8
    Last Post: 05-05-2008, 10:34 PM
  3. Download Files Using SSH & Putty
    By Supafly in forum cPanel and WHM Discussions
    Replies: 10
    Last Post: 03-18-2006, 07:36 AM
  4. putty/ssh is very slow
    By jegefe in forum cPanel and WHM Discussions
    Replies: 5
    Last Post: 03-01-2004, 03:59 PM
  5. SSH (putty) Help
    By Justin182004 in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 10-17-2003, 06:28 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube