Generating SSL Cert question

Discussion in 'Server Operation' started by satimis, Feb 22, 2008.

  1. satimis

    satimis Member

    Hi folks,


    Archlinux 86_64 2007-08-2


    On running
    $ sudo openssl rsa -in server.key -out server.key
    Code:
    Error opening Private Key server.key
    6879:error:02001002:system library:fopen:No such file or directory:bss_file.c:352:fopen('server.key','r')
    6879:error:20074002:BIO routines:FILE_CTRL:system lib:bss_file.c:354:
    unable to load Private Key
    Please advise where shall I check and how to fix this problem. Thanks


    On runniing;
    Code:
    $ sudo openssl req -new -x509 -newkey rsa:1024 -days 365 -keyout server,key -out server.crt
    /etc/ssl/certs/

    What FQDN shall I use on "Common Name"?


    On googling I found;
    TIP Setup Your FQDN
    http://gentoo-wiki.com/TIP_Setup_Your_FQDN


    Do I need to do the same on Arch? TIA


    B.R.
    satimis
     
  2. falko

    falko Super Moderator Howtoforge Staff

    There's no server.key file. Please check if you are in the correct directory.
     
  3. satimis

    satimis Member

    $ locate server.key
    $ sudo find / -name server.key
    both no printout

    $ locate .key
    /usr/share/mime-infor/gnome-vfs.keys
    /var/abs/extra/network/nxclient/nomachine.key

    $ sudo find / -name *.key
    /var/abs/extra/network/nxclient/nomachine.key


    Where can I find/download this file? Thanks


    satimis
     
  4. falko

    falko Super Moderator Howtoforge Staff

    I think you need to create it yourself.
     
  5. satimis

    satimis Member

    (solved)

    Problem solved as follow;


    Run;
    $ hostname --fqdn
    Code:
    arch.satimis.com
    

    $ cd /etc/ssl/certs/
    $ sudo openssl req -new -x509 -newkey rsa:1024 -days 365 -keyout server.key -out server.crt
    Code:
    ....
    ..
    Common Name (eg, YOUR name) []:arch.satimis.com
    ...
    etc
    
    At the end server.key generated


    then;
    $ sudo openssl rsa -in server.key -out server-no-pass.key
    Code:
    Enter pass phrase for server.key:
    writing RSA key
    

    B.R.
    satimis
     

Share This Page