Added support of self-signed certificates to REST dao.