Expose getters for SessionCacheSize and SessionCacheTimeout

Motivation:

There is correctly no way to get the current values of the SessionCacheSize and SessionCacheTimeout.

Modifications:

* Add SSLContext.getSessionCacheSize(...)
* Add SSLContext.getSessionCacheTimeout(...)

Result:

It's now possible to get the SessionCacheSize and SessionCacheTimeout for the context
Allow to explicit set and get the session_cache_mode

Motivation:

Sometimes it is useful to be able to explicit set the session_cache_mode or get the current used mode.

Modifications:

* add SSLContext.setSessionCacheMode(...) and SSLContext.getSessionCacheMode(...)
* allow to pass 0 into SSLContext.setSessionCacheSize(...) to allow unlimited size

Result:

It's now possible to set the cache mode on the fly.
Add support for SSL_CTX_set_session_id_context

Motivation:

Openssl supports to set the context for which a session can be used. To support this we need to add support for SSL_CTX_set_session_id_context

Modifications:

- Implement JNI call for SSL_CTX_set_session_id_context

Result:

It's now possible to set the context for which a session can be used.
Allow to get and set options of the SSLContext and SSL

Motivation:

Often it is useful to be able to retrieve the previous set options for the SSLContext and SSL. Also changing SSL options later can be useful.

Modifications:

- Add SSLContext.getOptions(...)
- Add SSL.getOptions(...) and SSL.setOptions(...)

Result:

It's now possible to get previous set options for the SSLContext and SSL, and also possible to set SSL options.
Fix segfault when calling SSL.getCiphers() / SSL.getPeerCertChain() and no ciphers/certs are used.

Motivation:

Because of incorrect usage of unsigned we fail to detect if no ciphers/certs are used and so cause a segfault.

Modifications:

- Use int when call sk_num(...) to store the result

Result:

No more segfault
Add support to get and set ciphers on SSL instance.

Motivation:

At the moment it is only possible to set the cipher suites to use on the SSLContext while it sometimes is needed to set it explicit on SSL.

Modifications:

Add SSL.setCipherSuites(...) and SSL.getCiphers()

Result:

It's now possible to set and get ciphers on SSL
Release memory allocated by i2d_X509(...)

Motivation:

As i2d_X509(...) allocates memory we need to call OPENSSL_free(...) on the pointer.

Modifications:

Call OPENSSL_free(...) on allocated memory by i2d_X509(...) and so remove memory leak.

Result:

No more memory leak.
Allow to obtain session as byte[]

Motivation:

Often it is useful to be able to get a session as a byte[] representation for later re-use or storage.

Modifications:

Add SSL.getSessionId(...) which allows to retrive a byte[] representation of the session.

Result:

It's now possible to store a session for later usage.