https path??

Discussion in 'Installation/Configuration' started by vulfs, Jan 9, 2008.

  1. vulfs

    vulfs New Member

    :confused: Have made en ssl for a domain: https://osc.syd-data.dk

    But when it loads it shows the standard install page for apache.

    Why dosn't it use the same path as the normal http://osc.syd-data.dk

    And i can't find https in the config files..

    Im using 2.3.3..
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    The https pazh is the same then the http path. Please check if the Vhost_ispconfig.conf file has been updated and contains the ssl configuration:

    http://www.howtoforge.com/forums/showthread.php?t=13596

    Is the code of the sl certificate and certificate request shown on the ssl tab of the site settings?
     
  3. vulfs

    vulfs New Member

    ssl-tab shown

    Yes the ssl tab is shown.

    But nowhere in the vhost is there a ssl/443 host.

    new host on 80 is added correctly.

    If You try the 2 https://osc.syd-data.dk and http://osc.syd-data.dk you can se they show 2 different pages.

    If I go under the ssl tab and make an ssl request the file is made correctly i the webs ssl directory.

    But I have a certificate for that domain I need to transfer from another server.

    Just tried to remove ssl-option from the domain and add it again.

    ispconfig does something with the vhost file, as the date/time on the file is altered everytime. But if I look in the file there is no change??
     
    Last edited: Jan 9, 2008
  4. falko

    falko Super Moderator Howtoforge Staff

    Please try the link that Till posted above.
     
  5. vulfs

    vulfs New Member

    done that

    Tried the link

    Syntax OK with all of them

    Here is another domain i tired to add ssl. tab is shown in controlpanel

    ######################################
    # Vhost: www.vulfs.dk:80
    ######################################
    #
    #
    <VirtualHost 89.184.154.53:80>
    ServerName www.vulfs.dk:80
    ServerAdmin [email protected]
    DocumentRoot /var/www/web2/web
    ServerAlias vulfs.dk
    DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm
    ScriptAlias /cgi-bin/ /var/www/web2/cgi-bin/
    AddHandler cgi-script .cgi
    AddHandler cgi-script .pl
    ErrorLog /var/www/web2/log/error.log
    php_admin_flag safe_mode Off
    # {STATSALIAS}
    Alias /error/ "/var/www/web2/web/error/"
    ErrorDocument 400 /error/invalidSyntax.html
    ErrorDocument 401 /error/authorizationRequired.html
    ErrorDocument 403 /error/forbidden.html
    ErrorDocument 404 /error/fileNotFound.html
    ErrorDocument 405 /error/methodNotAllowed.html
    ErrorDocument 500 /error/internalServerError.html
    ErrorDocument 503 /error/overloaded.html
    AliasMatch ^/~([^/]+)(/(.*))? /var/www/web2/user/$1/web/$3
    AliasMatch ^/users/([^/]+)(/(.*))? /var/www/web2/user/$1/web/$3
    </VirtualHost>

    No 443 anywhere in the conf files.

    here is the ispconfig log

    vulfs.dk-webmaster:x:10027:10002:webmaster:/var/www/web2/user/vulfs.dk-webmaster:/dev/null
    14.01.2008 - 09:11:20 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1027: setquota -u vulfs.dk-webmaster 0 0 0 0 -a &> /dev/null
    14.01.2008 - 09:11:20 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1028: setquota -T -u vulfs.dk-webmaster 604800 604800 -a &> /dev/null
    14.01.2008 - 09:11:20 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_procmail.lib.php, Line 59: cp -f /root/ispconfig/isp/conf/forward.master /var/www/web2/user/vulfs.dk-webmaster/.forward
    14.01.2008 - 09:11:20 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 98: cp -fr /etc/postfix/local-host-names /etc/postfix/local-host-names~
    14.01.2008 - 09:11:20 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 249: cp -fr /etc/postfix/virtusertable /etc/postfix/virtusertable~
    14.01.2008 - 09:11:21 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 254: postmap hash:/etc/postfix/virtusertable
    14.01.2008 - 09:11:21 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1381: cp -fr /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf~
    14.01.2008 - 09:11:21 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 2043: cp -fr /etc/proftpd_ispconfig.conf /etc/proftpd_ispconfig.conf~

    If you go to https://vulfs.dk it just shows the standard centos/apache ssl page.
    Have deleted the ssl for syd-data.dk but still when you go to https://osc.syd-data.dk it shows standard sll page.

    Mark the OSC.syd-data.dk its because syd-data.dk remains on old server because of the lack of ssl.

    Here is the content of the vhost dir

    [root@naja vhosts]# ls -al
    total 124
    drwxr-xr-x 2 root root 4096 Jan 14 09:07 .
    drwxr-xr-x 3 root root 4096 Jan 14 09:08 ..
    -rw-r--r-- 1 root root 25811 Jan 14 09:11 Vhosts_ispconfig.conf
    -rw-r--r-- 1 root root 25811 Jan 14 09:11 Vhosts_ispconfig.conf~
    -rw-r--r-- 1 root root 27069 Jan 7 21:11 Vhosts_ispconfig.conf_07-01-08_21-11-31
    -rw-r--r-- 1 root root 27069 Jan 7 21:13 Vhosts_ispconfig.conf_07-01-08_21-13-14

    Do you have any ideas??

    Hopefully:(
     
    Last edited: Jan 14, 2008
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    If there are more then 2 files, then the syntax is not ok as the files with a date appaneded are only created when the syntax chck failed.

    Please try to do the checexactly as it is described in the post I linked above.
     
  7. vulfs

    vulfs New Member

    did that now

    Tried that now.. renamed

    [root@naja vhosts]# httpd -t
    Syntax OK

    Content og vhost dir:

    [root@naja vhosts]# ls -al
    total 68
    drwxr-xr-x 2 root root 4096 Jan 14 09:42 .
    drwxr-xr-x 4 root root 4096 Jan 14 09:41 ..
    -rw-r--r-- 1 root root 25811 Jan 14 09:44 Vhosts_ispconfig.conf
    -rw-r--r-- 1 root root 27013 Jan 14 09:44 Vhosts_ispconfig.conf~


    no ssl/443 in any conf files.

    vulfs.dk-webmaster:x:10027:10002:webmaster:/var/www/web2/user/vulfs.dk-webmaster:/dev/null
    14.01.2008 - 09:44:26 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1027: setquota -u vulfs.dk-webmaster 0 0 0 0 -a &> /dev/null
    14.01.2008 - 09:44:26 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1028: setquota -T -u vulfs.dk-webmaster 604800 604800 -a &> /dev/null
    14.01.2008 - 09:44:26 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_procmail.lib.php, Line 59: cp -f /root/ispconfig/isp/conf/forward.master /var/www/web2/user/vulfs.dk-webmaster/.forward
    14.01.2008 - 09:44:26 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 98: cp -fr /etc/postfix/local-host-names /etc/postfix/local-host-names~
    14.01.2008 - 09:44:26 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 249: cp -fr /etc/postfix/virtusertable /etc/postfix/virtusertable~
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_postfix.lib.php, Line 254: postmap hash:/etc/postfix/virtusertable
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 1381: cp -fr /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf /etc/httpd/conf/vhosts/Vhosts_ispconfig.conf~
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 2541: httpd -t &> /dev/null
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 2548: httpd syntax ok
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/classes/ispconfig_system.lib.php, Line 730: /etc/rc.d/init.d/httpd restart &> /dev/null
    14.01.2008 - 09:44:27 => INFO - /root/ispconfig/scripts/lib/config.lib.php, Line 2043: cp -fr /etc/proftpd_ispconfig.conf /etc/proftpd_ispconfig.conf~
     
  8. falko

    falko Super Moderator Howtoforge Staff

    Please try to create an SSL vhost again, then (after a few seconds) post the output of
    Code:
    ls -la
    in the Vhosts_ispconfig.conf directory.
     
  9. vulfs

    vulfs New Member

    output

    [root@naja vhosts]# ls -al
    total 68
    drwxr-xr-x 2 root root 4096 Jan 14 09:42 .
    drwxr-xr-x 4 root root 4096 Jan 15 11:28 ..
    -rw-r--r-- 1 root root 25811 Jan 15 12:39 Vhosts_ispconfig.conf
    -rw-r--r-- 1 root root 25811 Jan 15 12:39 Vhosts_ispconfig.conf~


    host vulfs.dk again if u try https://vulfs.dk it is the default apache page
     
    Last edited: Jan 15, 2008
  10. falko

    falko Super Moderator Howtoforge Staff

    What's in Vhosts_ispconfig.conf?
     
  11. vulfs

    vulfs New Member

    here goes

    See file...
     

    Attached Files:

  12. falko

    falko Super Moderator Howtoforge Staff

    What's the output of
    Code:
    which openssl
    and
    Code:
    openssl --help
    ? If the last command shows errors (maybe something like segmentation fault), then there's a problem with OpenSSL.
     
  13. vulfs

    vulfs New Member

    openssl

    [root@naja ~]# which openssl
    /usr/bin/openssl


    [root@naja ~]# openssl --help
    openssl:Error: '--help' is an invalid command.

    Standard commands
    asn1parse ca ciphers crl crl2pkcs7
    dgst dh dhparam dsa dsaparam
    enc engine errstr gendh gendsa
    genrsa nseq ocsp passwd pkcs12
    pkcs7 pkcs8 prime rand req
    rsa rsautl s_client s_server s_time
    sess_id smime speed spkac verify
    version x509

    Message Digest commands (see the `dgst' command for more details)
    md2 md4 md5 rmd160 sha
    sha1

    Cipher commands (see the `enc' command for more details)
    aes-128-cbc aes-128-ecb aes-192-cbc aes-192-ecb aes-256-cbc
    aes-256-ecb base64 bf bf-cbc bf-cfb
    bf-ecb bf-ofb cast cast-cbc cast5-cbc
    cast5-cfb cast5-ecb cast5-ofb des des-cbc
    des-cfb des-ecb des-ede des-ede-cbc des-ede-cfb
    des-ede-ofb des-ede3 des-ede3-cbc des-ede3-cfb des-ede3-ofb
    des-ofb des3 desx rc2 rc2-40-cbc
    rc2-64-cbc rc2-cbc rc2-cfb rc2-ecb rc2-ofb
    rc4 rc4-40



    Can you tell me what the configuration for a site with SSL would look like.

    The Ill put it in manually to begin. Need to get a SSL site up an running.

    Rasmus
     
  14. falko

    falko Super Moderator Howtoforge Staff

    An SSL vhost looks like this:

    Code:
    <IfModule mod_ssl.c>
    <VirtualHost 1.2.3.4:443>
    ServerName www.example.com:443
    ServerAdmin [email protected]
    DocumentRoot /var/www/web2/web
    DirectoryIndex index.html index.htm index.php index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm
    ScriptAlias  /cgi-bin/ /var/www/web2/cgi-bin/
    AddHandler cgi-script .cgi
    AddHandler cgi-script .pl
    ErrorLog /var/www/web2/log/error.log
    AddType application/x-httpd-php .php .php3 .php4 .php5
    php_admin_flag safe_mode Off
    php_admin_value open_basedir /var/www/web2/
    php_admin_value file_uploads 1
    php_admin_value upload_tmp_dir /var/www/web2/phptmp/
    php_admin_value session.save_path /var/www/web2/phptmp/
    AddType text/html .shtml
    AddOutputFilter INCLUDES .shtml
    SSLEngine on
    SSLCertificateFile /var/www/web2/ssl/www.example.com.crt
    SSLCertificateKeyFile /var/www/web2/ssl/www.example.com.key
    Alias /error/ "/var/www/web2/web/error/"
    ErrorDocument 400 /error/invalidSyntax.html
    ErrorDocument 401 /error/authorizationRequired.html
    ErrorDocument 403 /error/forbidden.html
    ErrorDocument 404 /error/fileNotFound.html
    ErrorDocument 405 /error/methodNotAllowed.html
    ErrorDocument 500 /error/internalServerError.html
    ErrorDocument 503 /error/overloaded.html
    AliasMatch ^/~([^/]+)(/(.*))? /var/www/web2/user/$1/web/$3
    AliasMatch ^/users/([^/]+)(/(.*))? /var/www/web2/user/$1/web/$3
    SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
    </VirtualHost>
    </IfModule>
     

Share This Page