I am trying to write a client (the middleware is actually a client for the entity, but also acts as a server for others). In his client capacity, it is supposed to talk with another server (VMware VirtualCenter) and ask him to do something on his behalf.
To provide you more context, VirtualCenter allows the application to register as an extension. The specified application can register its certificate at the time of registration ( setCertificate ). After that, the application can log into VirtualCenter using its certificate ( loginExtensionByCertificate () ) and, therefore, it is not necessary to store the username and password. However, for this, the client (my application) must send the certificate as part of its SSL connection, although the server (VirtualCenter) does not request it especially.
I am writing my application with Java. Created my own key manager, connected it to my keystore and specified an alias to use. Then initialized my ssl context to use this key manager. In the created sockets, I see that their SSLContext has my key manager. However, I do not see any of the key managers receiving a certificate. For some reason, the socket does not consider that it needs to send a certificate.
I understand that the server may ask the client to submit its certificate. In this case, this does not happen. What I'm wondering is there a way to get the created socket to present the certificate regardless of whether the server requests it.
source
share