In the method getCommandResponse(String, InputStream) of the class com.thoughtworks.selenium.HttpCommandProcessor a SeleniumException will be thrown if the HTTP status code is not equal 200. The exception's message is simply the response message. This doesn't help. I myself got an message
com.thoughtworks.selenium.SeleniumException: Internal Server Error
but didn't know that this is the HTTP response message and therefore had to look to the code.
Please extend the message at line 124 of HttpCommandProcessor . My proposal is
throw new SeleniumException("Status code " + HttpURLConnection.HTTP_OK + " expected but " + uc.getResponseCode() + " (" + uc.getResponseMessage() + ") received.");
A related feature request to access the HTTP status code of a page:
http://jira.seleniumhq.org/browse/SRC-563