Java will abort SSL connections to a server, when the server gives a "unrecognized name" alert in the ssl handshake

Solution In Progress - Updated -

Issue

  • Java will abort SSL connections to a server, when the server gives a "unrecognized name" alert in the ssl handshake. This alert always results in a java exception:

    Exception in thread "main" javax.net.ssl.SSLProtocolException: handshake alert:  unrecognized_name
    
  • Java ignores the fact that the Alert can have different severity levels. RFC 5246 (section-7.2) describes two severity levels: warning(1), fatal(2). RFC5246 also states:

    "Alert messages with a level of fatal result in the immediate termination of the connection."
    ...
    "If an alert with a level of warning is sent and received, generally the connection can continue normally."
    

Environment

  • Java
    • 7
    • 8

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