webForumDet fria alternativet

Apache + SSL

2 svar · 285 visningar · startad av Qimen

QimenMedlem sedan juni 20015 009 inlägg
#1

Hej,

Försöker få SSL att fungera på min lokala webbserver. Allt fungerar ok när jag surfar direkt på servern men sitter jag på en annan dator så fungerar bara vanlig webb, dvs inte ssl. Det jag har gjort är skapat certifikat m.m. med hjälp av denna sida. Jag har aktiverat mod_ssl i httpd.conf. Jag har även lagt till detta i den:

<IfModule mod_ssl.c>
        Listen 443
        Listen 80
</IfModule>
    
<IfModule mod_ssl.c>
  AddType application/x-x509-ca-cert .crt
  AddType application/x-pkcs7-crl .crl
    
  SSLProtocol all -SSLv3
  SSLPassPhraseDialog builtin
  SSLSessionCache dbm:/var/run/ssl_scache
  SSLSessionCacheTimeout 300
  SSLMutex file:/var/run/ssl_mutex
  SSLRandomSeed startup builtin
  SSLLog /var/log/httpd/ssl_engine_log
  SSLLogLevel info

##
## SSL Virtual Host Context
##
    
<VirtualHost 192.168.0.100:80>
  #Just to keep things sane...
    DocumentRoot "/Users/Qimen/Arbete/Root"
    ServerName 192.168.0.100
    ServerAdmin [email]admin@qimen.net[/email]
    SSLEngine off
</VirtualHost>

<VirtualHost 192.168.0.100:443>
    DocumentRoot "/Users/Qimen/Arbete/Root"
    ServerName 192.168.0.100
    ServerAdmin [email]admin@qimen.net[/email]
    ErrorLog /var/log/httpd/error_log
    TransferLog /var/log/httpd/access_log
    SSLEngine on
    SSLProtocol all -SSLv3
    SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
    SSLCertificateFile /etc/httpd/ssl.key/server.crt
    SSLCertificateKeyFile /etc/httpd/ssl.key/server.key
    
    <Files ~ "\.(cgi|shtml|phtml|php3?)$">
      SSLOptions +StdEnvVars   
    </Files>

    <Directory "/Users/Qimen/Arbete/Root/CGI-Executables">
      SSLOptions +StdEnvVars
    </Directory>

    SetEnvIf User-Agent ".*MSIE.*" \
    nokeepalive ssl-unclean-shutdown \
    downgrade-1.0 force-response-1.0

    CustomLog /var/log/httpd/ssl_request_log \
    "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
</VirtualHost>

</IfModule>

Vad kan jag ha gjort för fel? :)

preyMedlem sedan jan. 2002341 inlägg
#2

Vad får du för felmeddelande i loggen?

Ifmodule mod_ssl
ska väl inte ha Listen 80?

den ska väl bara ha 443? 80 e ju http endast.

QimenMedlem sedan juni 20015 009 inlägg
#3

Jag löste det på ett enklare sätt. :)

<IfModule mod_ssl.c>
    Listen 443
</ifModule>
    
<VirtualHost pixelworld:443>
    ServerAdmin [email]admin@pixelworld.se[/email]
    DocumentRoot /Users/Qimen/Arbete/Webbprojekt/pwsystems/Upload/root
    ServerName Pixelworld-ssl
    ErrorLog /var/log/httpd/site.pixelworld-ssl
    CustomLog /var/log/httpd/site.pixelworld-ssl_custom common
    SSLEngine on
    SSLCertificateFile /etc/httpd/conf/ssl.crt/ca.crt
    SSLCertificateKeyFile /etc/httpd/conf/ssl.key/pixelworld.key
</VirtualHost>

:)

130 ms totalt · 3 externa anrop · v20260731065814-full.2b84b982
0 ms — hämta forumlista (cache)
0 ms — hämta statistik (cache)
128 ms — hämta tråd, inlägg och bilagor (db)