crypto: add dnf.crypto and fix things up so untrusted repo keys can be imported.

Related: RhBug:1118236
gpg: make key decoding work under Py3.
Add CLI parts to let the user confirm key imports. (RhBug:1118236)
lint: delinting of the repo_gpgcheck patchset.
dnf.util.urlopen(): do not create unicode streams for Py3 and bytes for Py2 by default.

This discrepancy causes unexpected unicode vs bytes problems when decoding GPG
keys.
crypto: fixup procgpgkey() to work with Py3 bytes.
crypto: document crypto options for repo.
doc: cosmetic: conf_ref: maintain alphabetical order of the options.
remove: Base._log_key_import().

Have the key logging at one place only.
Drop unused argument from getgpgkeyinfo().

All the clients always want all the keys.
crypto: use pubring_dir() context manager systematically.

Hard-changing GNUPGHOME can do no good.
tests: some tests for dnf.crypto.
remove: misc.valid_detached_sig().

not needed, librepo checks stuff for us.
unicode: fixed locale.format error (RhBug:1130432)
cosmetic: order of functions in dnf.crypto.
crypto: add crypto.retrieve() and drop Base._retrievePublicKey()

Add a test.
cleanup: header of dnf.yum.pgpmsg.
simplify misc.import_key_to_pubring()'s signature.

'cachedir' is never used.
util: get rid of an inconvenient 'default_handle' constant.
Fix dnf.crypto.keyinfo2keyid().

It produces wrong results on 64 bit platforms.