Is it possible to disable ssl for https?
Literally, no.
Use of SSL is fundamental to the HTTPS protocol. If you don't want to use SSL at all, configure your server with an HTTP endpoint and use that instead of HTTPS.
Furthermore use of SSL requires a certificate that is (at least) syntactically well-formed. That is also fundamental to the HTTPS protocol.
Now if the problem is that your server certificate has expired, then a possible solution is to use the approach described in:
And if the problem is that you cannot get a proper certificate for the server (e.g. you can't afford it) then an alternative solution is:
- generate a self-signed certificate; see How to generate a self-signed certificate using Java Keytool,
- install it on the server side,
- configure the client as above to ignore certificate validity.
But note that doing either of those things has security issues.
There is a third solution that is more secure.
- generate a self-signed certificate (as above)
- install it on the server side,
- use Keytool to add the certificate to the client app's keystore as a trusted certificate.