Current time: 09-26-2024, 04:25 AM Hello There, Guest! (LoginRegister)


Post Reply 
Subdomains mit SSL Unterstützung
Author Message
IncheZ Offline
Junior Member
*

Posts: 56
Joined: Oct 2007
Reputation: 0
Post: #1
Subdomains mit SSL Unterstützung
Guten Morgen,

ich habe nach dem Tutorial aus der DOcumentation ispCP so eingestellt das zu jeder Domain auch SSL funktioniert.

FUnzt auch soweit..

Code:
<VirtualHost 70.*.*.*:443>
     <IfModule suexec_module>
            SuexecUserGroup vu2001 vu2001
     </IfModule>
     ServerAdmin     webmaster@**.de
     DocumentRoot    /var/www/virtual/**.de/htsdocs
     ServerName      **.de
     ServerAlias     www.**.de **.de *.**.de
     SSLEngine On
     SSLCertificateFile /etc/ssl/certs/usa.**.de.crt
     SSLCertificateKeyFile /etc/ssl/certs/usa.**.de.key
     Alias /errors   /var/www/virtual/**.de/errors/
     #RedirectMatch permanent ^/ftp([\/]?)                http://usa.**.de/ftp/
     #RedirectMatch permanent ^/pma([\/]?)                http://usa.**.de/pma/
     #RedirectMatch permanent ^/webmail([\/]?)    http://usa.**.de/webmail/
     ErrorDocument 401 /errors/401.html
     ErrorDocument 403 /errors/403.html
     ErrorDocument 404 /errors/404.html
     ErrorDocument 500 /errors/500.html
     ErrorDocument 503 /errors/503.html
     <IfModule mod_cband.c>
         CBandUser **.de
     </IfModule>
     # httpd awstats support BEGIN.
     # httpd awstats support END.
     # httpd dmn entry cgi support BEGIN.
     # httpd dmn entry cgi support END.
     <Directory /var/www/virtual/**.de/htsdocs>
         # httpd dmn entry PHP support BEGIN.
         # httpd dmn entry PHP support END.
         Options -Indexes Includes FollowSymLinks MultiViews
         AllowOverride All
         Order allow,deny
         Allow from all
     </Directory>
     # httpd dmn entry PHP2 support BEGIN.
     <IfModule mod_php5.c>
         php_admin_value open_basedir "/var/www/virtual/**.de/:/var/www/virtual/**.de/phptmp/:/usr/share/php/"
         php_admin_value upload_tmp_dir "/var/www/virtual/**.de/phptmp/"
         php_admin_value session.save_path "/var/www/virtual/**.de/phptmp/"
         php_admin_value sendmail_path '/usr/sbin/sendmail -f vu2001 -t -i'
     </IfModule>
     <IfModule mod_fastcgi.c>
         ScriptAlias /php5/ /var/www/fcgi/**.de/
         <Directory "/var/www/fcgi/**.de">
             AllowOverride None
             Options +ExecCGI -MultiViews -Indexes
             Order allow,deny
             Allow from all
         </Directory>
     </IfModule>
     <IfModule mod_fcgid.c>
         <Directory /var/www/virtual/**.de/htsdocs>
             FCGIWrapper /var/www/fcgi/**.de/php5-fcgi-starter .php
             Options +ExecCGI
         </Directory>
         <Directory "/var/www/fcgi/**.de">
             AllowOverride None
             Options +ExecCGI MultiViews -Indexes
             Order allow,deny
             Allow from all
         </Directory>
     </IfModule>
     # httpd dmn entry PHP2 support END.
</VirtualHost>

Das wurde ber ispcp.conf eingefügt, funktioniert auch, alles in /htsdocs SSL gesichert.

Allerdings möchte Ich auch Subdomains SSL sichern, ohne in die config einzugreifen gehts nicht. Wie diese Hauptdomain habe ich die Subdomain auch ohne SSL ind er ispcp.conf, also habe Ich diese passage kopiert und SSL fähig gemacht.

Code:
</VirtualHost>

<VirtualHost 70.*.*.*:80>

    #
    #User vu2001
    #Group vu2001
    #

    <IfModule suexec_module>
           SuexecUserGroup vu2001 vu2001
    </IfModule>

    ServerAdmin     webmaster@**.de
    DocumentRoot    /var/www/virtual/**.de/board/htdocs

    ServerName      board.**.de
    ServerAlias     www.board.**.de board.**.de *.board.**.de

    Alias /errors /var/www/virtual/**.de/errors/

    RedirectMatch permanent ^/ftp([\/]?)        http://usa.**.de/ftp/
    RedirectMatch permanent ^/pma([\/]?)        http://usa.**.de/pma/
    RedirectMatch permanent ^/webmail([\/]?)    http://usa.**.de/webmail/
    RedirectMatch permanent ^/ispcp([\/]?)        http://usa.**.de/

    ErrorDocument 401 /errors/401.html
    ErrorDocument 403 /errors/403.html
    ErrorDocument 404 /errors/404.html
    ErrorDocument 500 /errors/500.html
    ErrorDocument 503 /errors/503.html

    <IfModule mod_cband.c>
        CBandUser **.de
    </IfModule>

    # httpd sub entry cgi support BEGIN.
    ScriptAlias /cgi-bin/ /var/www/virtual/**.de/board/cgi-bin/
    <Directory /var/www/virtual/**.de/board/cgi-bin>
        AllowOverride AuthConfig
        #Options ExecCGI
        Order allow,deny
        Allow from all
    </Directory>
    # httpd sub entry cgi support END.

    <Directory /var/www/virtual/**.de/board/htdocs>
        # httpd sub entry PHP support BEGIN.
        # httpd sub entry PHP support END.
        Options -Indexes Includes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>

    # httpd sub entry PHP2 support BEGIN.
    <IfModule mod_php5.c>
        php_admin_value open_basedir "/var/www/virtual/**.de/:/var/www/virtual/**.de/phptmp/:/usr/share/php/"
        php_admin_value upload_tmp_dir "/var/www/virtual/**.de/phptmp/"
        php_admin_value session.save_path "/var/www/virtual/**.de/phptmp/"
        php_admin_value sendmail_path '/usr/sbin/sendmail -f vu2001 -t -i'
    </IfModule>
    <IfModule mod_fastcgi.c>
        ScriptAlias /php5/ /var/www/fcgi/**.de/
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI -MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    <IfModule mod_fcgid.c>
        Include /etc/apache2/mods-available/fcgid_ispcp.conf
        <Directory /var/www/virtual/**.de/board/htdocs>
            FCGIWrapper /var/www/fcgi/**.de/php5-fcgi-starter .php
            Options +ExecCGI
        </Directory>
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    # httpd sub entry PHP2 support END.

    Include /etc/apache2/ispcp/board.**.de.conf

</VirtualHost>

Dort habe Ich dann htdocs in htsdocs geändert, den port geändert und dies eingefügt:

Code:
SSLEngine On
     SSLCertificateFile /etc/ssl/certs/usa.**.de.crt
     SSLCertificateKeyFile /etc/ssl/certs/usa.**.de.key

Tut aber nicht, und ich verstehe nicht wieso?

Muss ich für die SSL DOmains eine zweite IP nehmen? Wenn ja wieos geht es bei der Hauptdomain?

Gruß
(This post was last modified: 03-04-2010 12:47 PM by IncheZ.)
03-04-2010 12:47 PM
Find all posts by this user Quote this message in a reply
TheCry Away
Member
***

Posts: 851
Joined: Oct 2008
Reputation: 21
Post: #2
RE: Subdomains mit SSL Unterstützung
(03-04-2010 12:47 PM)IncheZ Wrote:  Muss ich für die SSL DOmains eine zweite IP nehmen? Wenn ja wieos geht es bei der Hauptdomain?

Gruß

Ja musst Du.. Und dann musst Du Deinen DNS auch dementsprechend einstellen. Damit meine ich den DNS wo Du Deine Domains registierst.
Das hat mit Deiner Hauptdomain funktioniert weil Du dort noch kein SSL drin hattest. Du kannst halt nur ein SSL pro IP machen. Es gibt da zwar eine Möglichkeit (Siehe: http://www.isp-control.net/forum/thread-9471.html)
Und anstatt in der ispcp.conf des Apaches Änderungen zu machen, würde ich die Änderungen im Verzeichnis /etc/apache/ispcp durchführen.
Denn wenn Du irgendwas in ispCP an Deinen Einstellungen der Domains änderst wird diese Datei gandenlos geändert und Deine Änderungen sind weg!
In diesem Verzeichnis (was ich Dir eben genannt habe) findest Du für jeden Domain eine eigene Conf-Datei die Du dementsprechend auf Deine Bedürfnisse anpassen kannst.

Hier wurde das Thema aber schon mal besprochen:
http://www.isp-control.net/forum/thread-9450.html
(This post was last modified: 03-04-2010 06:05 PM by TheCry.)
03-04-2010 06:01 PM
Find all posts by this user Quote this message in a reply
IncheZ Offline
Junior Member
*

Posts: 56
Joined: Oct 2007
Reputation: 0
Post: #3
RE: Subdomains mit SSL Unterstützung
Danke für die Informationen.
Also muss Ich für jede SUbdomain eine eigene IP verwenden?

Btw: Was für einen Record muss ich den anlegen damit die https auf eine andere IP zeigt?

Also damit SSL und nonSSL geht, zwei A-Records oder was?


Anhang:

Code:
<VirtualHost 70.*.*.*:443> <-andere ip als hauptip

    #
    #User vu2001
    #Group vu2001
    #

    <IfModule suexec_module>
           SuexecUserGroup vu2001 vu2001
    </IfModule>

    ServerAdmin     webmaster@**.de
    DocumentRoot    /var/www/virtual/**.de/board/htsdocs

    ServerName      board.**.de
    ServerAlias     www.board.**.de board.**.de *.board.**.de
    SSLEngine On
    SSLCertificateFile /etc/ssl/certs/usa.**.de.crt
    SSLCertificateKeyFile /etc/ssl/certs/usa.**.de.key

    Alias /errors /var/www/virtual/**.de/errors/

    RedirectMatch permanent ^/ftp([\/]?)        http://usa.**.de/ftp/
    RedirectMatch permanent ^/pma([\/]?)        http://usa.**.de/pma/
    RedirectMatch permanent ^/webmail([\/]?)    http://usa.**.de/webmail/
    RedirectMatch permanent ^/ispcp([\/]?)        http://usa.**.de/

    ErrorDocument 401 /errors/401.html
    ErrorDocument 403 /errors/403.html
    ErrorDocument 404 /errors/404.html
    ErrorDocument 500 /errors/500.html
    ErrorDocument 503 /errors/503.html

    <IfModule mod_cband.c>
        CBandUser **.de
    </IfModule>

    # httpd sub entry cgi support BEGIN.
    ScriptAlias /cgi-bin/ /var/www/virtual/**.de/board/cgi-bin/
    <Directory /var/www/virtual/**.de/board/cgi-bin>
        AllowOverride AuthConfig
        #Options ExecCGI
        Order allow,deny
        Allow from all
    </Directory>
    # httpd sub entry cgi support END.

    <Directory /var/www/virtual/**.de/board/htdocs>
        # httpd sub entry PHP support BEGIN.
        # httpd sub entry PHP support END.
        Options -Indexes Includes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>

    # httpd sub entry PHP2 support BEGIN.
    <IfModule mod_php5.c>
        php_admin_value open_basedir "/var/www/virtual/**.de/:/var/www/virtual/**.de/phptmp/:/usr/share/php/"
        php_admin_value upload_tmp_dir "/var/www/virtual/**.de/phptmp/"
        php_admin_value session.save_path "/var/www/virtual/**.de/phptmp/"
        php_admin_value sendmail_path '/usr/sbin/sendmail -f vu2001 -t -i'
    </IfModule>
    <IfModule mod_fastcgi.c>
        ScriptAlias /php5/ /var/www/fcgi/**.de/
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI -MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    <IfModule mod_fcgid.c>
        Include /etc/apache2/mods-available/fcgid_ispcp.conf
        <Directory /var/www/virtual/**.de/board/htsdocs>
            FCGIWrapper /var/www/fcgi/**.de/php5-fcgi-starter .php
            Options +ExecCGI
        </Directory>
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    # httpd sub entry PHP2 support END.

    Include /etc/apache2/ispcp/board.**.de.conf

</VirtualHost>

Das habe Ich jetzt in einer extra Datei eingebunden, er fragt auch wenn ich per https://ip drauf gehe nach dem cert, aber sobald ichs akzeptiert habe bin ich ungeschützt auf der seite.
(This post was last modified: 03-04-2010 11:05 PM by IncheZ.)
03-04-2010 10:48 PM
Find all posts by this user Quote this message in a reply
TheCry Away
Member
***

Posts: 851
Joined: Oct 2008
Reputation: 21
Post: #4
RE: Subdomains mit SSL Unterstützung
Du musst schon den A-Record setzen!
Code:
board.deine-domain.tld IN A ***.***.***.***
Dann sollte Dein Board per SSL erreichbar sein.
Diese Umstellung kann aber etwas dauern.
Das heisst nicht das nach 5 Minuten alle DNS im Internet abgeglichen sind!
Deswegen beachte auch den Thread den ich Dir angegeben habe!
03-04-2010 11:51 PM
Find all posts by this user Quote this message in a reply
IncheZ Offline
Junior Member
*

Posts: 56
Joined: Oct 2007
Reputation: 0
Post: #5
RE: Subdomains mit SSL Unterstützung
Okay, dann muss Ich den vhost vom nonSSL board Zugang auch auf diese IP legen, oder?

Wenn ja, wie mach ich das am besten da ich ispcp.conf ja deiner Aussage nach nicht editieren soll.

Also die Hauptdomain, ihr SSL und einige SUbdomains laufen ja per IP 1

Jetzt lege ich den SSL Vhost fürs Board auf IP 2 an, und lege den A-Red von board* auf IP2, dann muss ich den normalen board* vhost ja auch auf IP2 legen oder? Wenn ja, wie?

Danke
03-05-2010 12:01 AM
Find all posts by this user Quote this message in a reply
TheCry Away
Member
***

Posts: 851
Joined: Oct 2008
Reputation: 21
Post: #6
RE: Subdomains mit SSL Unterstützung
Den SSL-Vhost musst Du ja laut Thread manuell anlegen.
Dann sollte die 2te IP in ispCP eingetragen werden!
Diese weisst Du dann auch dem Reseller zu wo der Client zugehört.

Da Du ja nur die Subdomain auf diese IP leiten willst musst Du für Non-ssl auch eine Conf-Datei anlegen.
Denn für SubDomains gibt es keine eigene IP-Zuweisung!!!

Dafür nimmst Du einfach den Teil aus der ispcp.conf. Aktivierst die Conf-Datei und pass die IP an.
Besser wäre natürlich die ganze Domain auf die IP zu legen!
Dann hättest Du weniger gemurkse und Du brüchtest nur der Hauptdomain die andere IP in der Datenbank zuordnen, die Domain auf "toadd" stellen und den Requestmanager durchstarten!
(This post was last modified: 03-05-2010 12:18 AM by TheCry.)
03-05-2010 12:18 AM
Find all posts by this user Quote this message in a reply
IncheZ Offline
Junior Member
*

Posts: 56
Joined: Oct 2007
Reputation: 0
Post: #7
RE: Subdomains mit SSL Unterstützung
Das Problem was ich jetzt habe, habe folgende config angelegt:

Code:
<VirtualHost *.*.*.*:443>

    #
    #User vu2001
    #Group vu2001
    #

    <IfModule suexec_module>
           SuexecUserGroup vu2001 vu2001
    </IfModule>

    ServerAdmin     webmaster@**.de
    DocumentRoot    /var/www/virtual/**.de/board/htsdocs

    ServerName      board.**.de
    ServerAlias     www.board.**.de board.**.de board.**.de
    SSLEngine On
    SSLCertificateFile /etc/ssl/certs/usa.**.de.crt
    SSLCertificateKeyFile /etc/ssl/certs/usa.**.de.key

    Alias /errors /var/www/virtual/**.de/errors/

    RedirectMatch permanent ^/ftp([\/]?)        http://usa.**.de/ftp/
    RedirectMatch permanent ^/pma([\/]?)        http://usa.**.de/pma/
    RedirectMatch permanent ^/webmail([\/]?)    http://usa.**.de/webmail/
    RedirectMatch permanent ^/ispcp([\/]?)        http://usa.**.de/

    ErrorDocument 401 /errors/401.html
    ErrorDocument 403 /errors/403.html
    ErrorDocument 404 /errors/404.html
    ErrorDocument 500 /errors/500.html
    ErrorDocument 503 /errors/503.html

    <IfModule mod_cband.c>
        CBandUser **.de
    </IfModule>

    # httpd sub entry cgi support BEGIN.
    ScriptAlias /cgi-bin/ /var/www/virtual/**.de/board/cgi-bin/
    <Directory /var/www/virtual/**.de/board/cgi-bin>
        AllowOverride AuthConfig
        #Options ExecCGI
        Order allow,deny
        Allow from all
    </Directory>
    # httpd sub entry cgi support END.

    <Directory /var/www/virtual/**.de/board/htsdocs>
        # httpd sub entry PHP support BEGIN.
        # httpd sub entry PHP support END.
        Options -Indexes Includes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>

    # httpd sub entry PHP2 support BEGIN.
    <IfModule mod_php5.c>
        php_admin_value open_basedir "/var/www/virtual/**.de/:/var/www/virtual/**.de/phptmp/:/usr/share/php/"
        php_admin_value upload_tmp_dir "/var/www/virtual/**.de/phptmp/"
        php_admin_value session.save_path "/var/www/virtual/**.de/phptmp/"
        php_admin_value sendmail_path '/usr/sbin/sendmail -f vu2001 -t -i'
    </IfModule>
    <IfModule mod_fastcgi.c>
        ScriptAlias /php5/ /var/www/fcgi/**.de/
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI -MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    <IfModule mod_fcgid.c>
        Include /etc/apache2/mods-available/fcgid_ispcp.conf
        <Directory /var/www/virtual/**.de/board/htsdocs>
            FCGIWrapper /var/www/fcgi/**.de/php5-fcgi-starter .php
            Options +ExecCGI
        </Directory>
        <Directory "/var/www/fcgi/**.de">
            AllowOverride None
            Options +ExecCGI MultiViews -Indexes
            Order allow,deny
            Allow from all
        </Directory>
    </IfModule>
    # httpd sub entry PHP2 support END.

    Include /etc/apache2/ispcp/board.**.de.conf

</VirtualHost>

Habe den A rec auf diese IP gelegt, komme per https drauf, ABBER, da ist kein SSL?!

Wie passiert das
03-05-2010 12:44 AM
Find all posts by this user Quote this message in a reply
TheCry Away
Member
***

Posts: 851
Joined: Oct 2008
Reputation: 21
Post: #8
RE: Subdomains mit SSL Unterstützung
(03-05-2010 12:44 AM)IncheZ Wrote:  Habe den A rec auf diese IP gelegt, komme per https drauf, ABBER, da ist kein SSL?!

Wie passiert das
Du musst Dich schon was genauer ausdrücken.
Ich weiss gerade nicht was Du für ein Problem hast.
Du hast in der Adressleiste https://board-deineDomain.tld stehen und es wurde kein Zertifikat angezeigt?
03-05-2010 12:54 AM
Find all posts by this user Quote this message in a reply
IncheZ Offline
Junior Member
*

Posts: 56
Joined: Oct 2007
Reputation: 0
Post: #9
RE: Subdomains mit SSL Unterstützung
Genau das!
03-05-2010 03:04 AM
Find all posts by this user Quote this message in a reply
TheCry Away
Member
***

Posts: 851
Joined: Oct 2008
Reputation: 21
Post: #10
RE: Subdomains mit SSL Unterstützung
Was sprechen denn Deine Logfiles?
So eine blinde Analyse ist ziemlich schwer.
03-05-2010 04:17 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 12 Guest(s)