Obteniendo javax.net.ssl.SSLHandshakeException: Se recibió una alerta fatal: error de handshake_failure

Estoy tratando de enviar una notificación de inserción al iPhone usando Java-pns pero recibo el siguiente error:javax.net.ssl.SSLHandshakeException: se recibió una alerta fatal: handshake_failure

Mi código es -

String token="95076d2846e8979b46efd1884206a590d99d0f3f6139d947635ac4186cdc5942";
String host = "gateway.sandbox.push.apple.com";
int port = 2195;
String payload = "{\"aps\":{\"alert\":\"Message from Java o_O\"}}";

NotificationTest.verifyKeystore("res/myFile.p12", "password", false);
KeyStore keyStore = KeyStore.getInstance("PKCS12");
keyStore.load(getClass().getResourceAsStream("res/myFile.p12"), "password".toCharArray());

KeyManagerFactory keyMgrFactory = KeyManagerFactory.getInstance("SunX509");
keyMgrFactory.init(keyStore, "password".toCharArray());

SSLContext sslContext = SSLContext.getInstance("TLS");
sslContext.init(keyMgrFactory.getKeyManagers(), null, null);
SSLSocketFactory sslSocketFactory = sslContext.getSocketFactory();

SSLSocket sslSocket = (SSLSocket) sslSocketFactory.createSocket(host, port);
String[] cipherSuites = sslSocket.getSupportedCipherSuites();
sslSocket.setEnabledCipherSuites(cipherSuites);
sslSocket.startHandshake();

char[] t = token.toCharArray();
byte[] b = Hex.decodeHex(t);

OutputStream outputstream = sslSocket.getOutputStream();

outputstream.write(0);
outputstream.write(0);
outputstream.write(32);
outputstream.write(b);
outputstream.write(0);
outputstream.write(payload.length());
outputstream.write(payload.getBytes());

outputstream.flush();
outputstream.close();

System.out.println("Message sent .... ");

porNotificationTest.verifyKeystore Estoy obteniendo que este válido es File y Keystore.

No entiendo por qué estoy recibiendo este error.

Por favor alguien me puede ayudar?

Gracias por adelantado ...

En mi registro he visto que

** Solicitud de certificado

Tipos de certificados: RSA, DSS, ECDSA

Autoridades Cert:

[leer] hashes MD5 y SHA1: len = 10

0000: 0D 00 00 06 03 01 02 40 00 00 ....... @ ..

** ServerHelloDone

[leer] hashes MD5 y SHA1: len = 4

0000: 0E 00 00 00 ....

** Cadena de certificados

**

** ClientKeyExchange, RSA PreMasterSecret, TLSv1

[escribir] hashes MD5 y SHA1: len = 269

.

.

.

.

.

principal, LEER: Alerta TLSv1, longitud = 2

ALERTA principal, RECV TLSv1: fatal, handshake_failure

principal, llamado closeSocket ()

principal, manejo de excepción: javax.net.ssl.SSLHandshakeException: Alerta fatal recibida: handshake_failure

No entiendo porqueAutoridades Cert: ¿esta vacio?

Respuestas a la pregunta(1)

Su respuesta a la pregunta