![]() |
'invalid method in request' - Apache & SSL on Centos
Hi everyone,
Ever since I have changed my Centos 5 server to work with HTTPS, I've not been able to view my locally stored webpages. Apache starts fine, but any attempts to access my webserver results in a "ssl_error_rx_record"too_long_" error in my browser, and in the Apache error log I get the error: "[error] [client 192.168.1.100' invalid method in request \x16\x03\x01". I know my SSL certificate is fine, because It's a signed one from GoDaddy and it works fine with other services (eg. 'telnet localhost smtp' works fine for my postfix configuration). I read somewhere that if i type the following: Code:
# telnet 192.168.0.1 443Below are the important lines of my ssl.conf and httpd.conf. I've been stumped on this for a while, so any help would be wonderful! Thanks again, Scott httpd.conf: Code:
Timeout 300Code:
Listen 443 https |
Hi,
You cannot use telnet to test https. Better use: Code:
openssl s_client -connect 192.168.0.1 443Also add a Code:
NameVirtualHost *:443Code:
<VirtualHost *:443>Code:
Listen 443 |
hey again!
Thanks for the advice, but i am still getting the same error when i attempt to access the https:// site. Code:
# openssl s_client -connect 192.168.0.1:443Code:
#LoadModule ssl_module modules/mod_ssl.so |
Hi,
Somehow you're talking plain http to the ssl server. Why don't you load the mod_ssl module? And you have an error in ServerName (no need for :443 at the end) Anyway, use the following and see if it works Code:
LoadModule ssl_module modules/mod_ssl.so |
Sorry I forgot to mention that I was loading mod_ssl.so from httpd.conf. For completeness sake, I have included the whole httpd.conf file below.
Anyway, Good news! (well sort of). Removing the <ifDefine> tags has gotten rid of the invalid method request error. I'm still unable to view my SquirrelMail login page whenever i attempt to access https://my.mailserverlogin.com (or https://my.mailserverlogin.com:443 , for that matter). Instead of the "rx_record_too_long_" I am now getting a different error: The connection was interrupted. The connection to my.mailserverlogin.com was interrupted while the page was loading. and this is what happens when I do an openssl s_client -connect:192.168.0.1:443 : Code:
CONNECTED(00000003)Code:
192.168.1.80 - - [08/Sep/2011:15:03:49 +1000] "\x80@\x01\x03" 302 - "-" "-"Thanks again :) httpd.conf: Code:
ServerTokens OS---------- Post added 08-09-11 at 03:45 PM ---------- oh, btw, shall I mark this as [solved] now? Perhaps the above post belongs elsewhere? |
Quote:
I noticed that you miss the following in ssl.conf: Code:
SSLEngine onRegards |
Thanks again for the reply - its all working now! seems as though the SSLEngine on did the trick.
Incidentally, I also had to remove the paraphrase from my .key file before my newly downloaded SSL certificate would start to work. So glad its going - Thanks again! |
| All times are GMT -5. The time now is 03:54 PM. |