LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > General > [Solved] Header showing 200 OK but title 400 Bad Request

Reply
 
Thread Tools Display Modes
  #1  
Old 01-05-2012, 03:26 PM
thehelpdesk thehelpdesk is offline
Member
 
Join Date: Feb 2011
Posts: 14
Default [Solved] Header showing 200 OK but title 400 Bad Request

We're having trouble passing PCI Compliance testing because it seems that LiteSpeed Web Server is outputting a 200 OK header with just a title of 400 Bad Request. How can we get LSWS to stop this behavior?

We have tried different LSWS versions with and without custom ErrorDocument statements. The current LSWS version is installed, Enterprise 4.1.9.

Here is an example (with the domain name changed) of the test failure:

[root@server /]# curl --max-time 10 -iskL 'http://www.domain.com:443/info.php'
HTTP/1.0 200 OK
Cache-Control: private, no-cache, max-age=0
Pragma: no-cache
Connection: Close

<html><head><title>400 Bad Request</title></head><body>
<h2>HTTPS is required</h2>
<p>This is an SSL protected page, please use the HTTPS scheme instead of the plain HTTP scheme to access this URL.<br />
<blockquote>Hint: The URL should starts with <b>https</b>://</blockquote> </p>
<hr />
Powered By LiteSpeed Web Server<br />
<a href='http://www.litespeedtech.com'><i>http://www.litespeedtech.com</i></a>
</body></html>
Reply With Quote
  #2  
Old 01-05-2012, 05:50 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,390
try https instead.

Quote:
curl --max-time 10 -iskL 'https://www.domain.com:443/info.php'
Reply With Quote
  #3  
Old 01-05-2012, 09:06 PM
thehelpdesk thehelpdesk is offline
Member
 
Join Date: Feb 2011
Posts: 14
That is not an option. The command line that I listed is what McAfee Secure servers are running intentionally to test the server for PCI Compliance. The actual file info.php does not exist, it's part of their test of the web server software.

All of our other web servers pass the test just fine (Apache and IIS). However, our LSWS servers will not pass the test. McAfee indicates this is an error on the part of the web server and will not pass any of our sites on the LSWS servers or grant an exception.
Reply With Quote
  #4  
Old 01-07-2012, 02:21 PM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,603
Looks like apache reply does not have any response header, just response body directly.
can you confirm it? we certainly can change LiteSpeed response accordingly.
Reply With Quote
  #5  
Old 01-07-2012, 03:28 PM
thehelpdesk thehelpdesk is offline
Member
 
Join Date: Feb 2011
Posts: 14
While we cannot confirm what the ASV is looking for (they won't tell us), it would be safe to assume that based on their responses that the problem is the status code 200 OK that LSWS is returning.

You are correct that Apache and other servers appear to just return a blank header and just the body. An example of a passing server is below:

[root@server /]# curl --max-time 10 -iskL 'http://www.domain.com:443/info.php'
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>400 Bad Request</title>
</head><body>
<h1>Bad Request</h1>
<p>Your browser sent a request that this server could not understand.<br />
Reason: You're speaking plain HTTP to an SSL-enabled server port.<br />
Instead use the HTTPS scheme to access this URL, please.<br />
<blockquote>Hint: <a href="https://domain.com/"><b>https://domain.com/</b></a></blockquote></p>
</body></html>
[root@server /]#
Reply With Quote
  #6  
Old 01-09-2012, 04:54 PM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,390
will let you know once a fix is available.
Reply With Quote
  #7  
Old 01-10-2012, 04:20 AM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,603
Please try the latest build of 4.1.10.
Reply With Quote
  #8  
Old 01-16-2012, 02:03 PM
thehelpdesk thehelpdesk is offline
Member
 
Join Date: Feb 2011
Posts: 14
Default [solved]

With the upgrade to version 4.1.10 the issue appears to now be fixed. LSWS is returning a page without the header status. There's no doctype. But, the return value is now passing the ASV tests.
Reply With Quote
Reply

Tags
error, pci compliance

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 06:40 PM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.