Why does telnet command show "400 Bad Request" for https connections?

Solution Verified - Updated -

Issue

  • Why does telnet command show "400 Bad Request" for https connections?

    $ telnet example.com 443
    Trying <IP Address of example.com> ...
    Connected to example.com
    Escape character is '^]'.
    GET  HTTP/1.1
    HTTP/1.1 400 Bad Request
    Date: Sat, 27 Jun 2017 10:45:29 GMT
    Server: Apache
    Content-Length: 362
    Connection: close
    Content-Type: text/html; charset=iso-8859-1
    
    <!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 />
    

Environment

  • Red Hat JBoss Web Server (JWS)

    • 3.0.3
  • Red Hat Enterprise Linux (RHEL)

    • 7.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content