Let program accept invalid certificates

We might validate the certificate when using TLS. We will fail this if
the certificate doesn't validate correctly. We should let the program
decide if we should accept the certificate or not.

Catch the accept-certificate event and ask the program what to do. For
now the program will just return true, but it would be nice if the user
was able to decide.

Signed-off-by: Marcus Karlsson <mk@acc.umu.se>