ureport: aggressive refactorization of uReport source

Simplify/unify the uReport API and provide a development documentation
in form of Doxygen comments.

Related to rhbz1139987

Signed-off-by: Jakub Filak <jfilak@redhat.com>
spec: install ureport.h

Related to rhbz#1139987

Signed-off-by: Jakub Filak <jfilak@redhat.com>
ureport: support HTTP Basic authentication

Relate to rhbz#1139987

Signed-off-by: Jakub Filak <jfilak@redhat.com>
rhtsupport: submit ureport and attach case ID to ureport

ABRT Server for RHEL provides an authenticated way of uReport
submission. The authentication can be done via client certificates or
HTTP Basic auth. ABRT client uses the client certificates for
Auto-reporting, but when user wants to report a problem manually he
needs to have special permissions to work with the certificates or he
cannot use this way of authentication.  Fortunately, RHEL ABRT Server
can authenticate user via RHTSupport user name an password, but we don't
want to ask users to provide/configure the Customer Portal credentials
twice, hence we will attach a case ID to a bthash from
reporter-rhtsupport.

This commit also addresses complaints about no evidences of sending
uReport to ABRT Server.  This commit adds a log message "Sending ABRT
crash statistics data".

Relate to rhbz#1139987, rhbz#1084028

Signed-off-by: Jakub Filak <jfilak@redhat.com>
rhtsupport: check for hints only when creating a new case

If the check for hints finds something, reporter-rhtsupport asks the
user whether he wants to continue in creating a new case. While it is a
useful feature, the reporter should ask that question only if the user
runs the reporter with option -t (create a new case).

We also want to receive as many uReports as possible, so we need to
submit uReport before checking for hints because the report might
interrupt the reporting process in case of positive hints results.

Related to rhbz#1139987

Signed-off-by: Jakub Filak <jfilak@redhat.com>
ureport: provide default URLs

We have two general use cases:
1. Completely anonymous uReporting
2. Authenticated uReporting

For good security reasons, we have to use a standalone server for each of
these use cases and this requirement complicates the configuration.
Users would have to change two options to switch between these two
configurations.

The configuration can be simplified by providing default URL for both of
them and single out the URL according to state of the "SSLClientAuth"
configuration option.

1. Completely anonymous uReporting
  - empty "SSLClientAuth"

2. Authenticated uReporting
  - "rhsm" or "rhsm-entitlement" in "SSLClientAuth"

Related to rhbz#1140224

Signed-off-by: Jakub Filak <jfilak@redhat.com>