I'm writing a bit of a net utility, and I want it to have three protocols. PLAIN_TEXT
, which, obviously, sends plain text/bytes over the network. ENCRYPTED_UNSECURED
, which uses encryption, but doesn't verify any identities, and ENCRYPTED_SECURED
, which uses SSL or TSL.
Right now, I've implemented PLAIN_TEXT
, and I've partially implemented ENCRYPTED_UNSECURED
, but I've hit a block. I'm using SSLSockets for ENCRYPTED_UNSECURED
, but with self-signed certs and a fake trust manager, however, the self-signed certs need to come from a key manager, which comes from a keyfile, generated by the java key tool.
What I want to know is: would using the same key file in every instance of the server/client subtract from the security of the encryption? As it is ENCRYPTED_UNSECURED
, I don't care about the security of the authentication.
Note: this is being done in java.
EDIT: Why this is not a duplicate? I'm not trying to import the certificate, I know how to do that, I want to know if using the same certificate could decrease the security of SSL/TSL's encryption protocol.