Using HTTP Basic authentication

HTTP Basic Authentication is the least secure form of authentication supplied in the client.
Prerequisites: You are working in Workbench and are connected to the station with an HttpClientNetwork.
The username and password are included in the requests Authorization header in the form:

Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==

where the username:password are Base64 encoded.


Perform the following steps:
  1. Double-click HttpClient and expand Address.
    The Property Sheet opens.
    Image

    In this example, the url has been changed to one that is protected by HTTP Basic authorization.

  2. Set Mode to Secure.
    This setting is required because credentials are not encrypted and the encoding is simple to reverse engineer. If the client’s Mode is set to Insecure, the HTTP client will fail to send with this error message: Exception occurred, Failed to build request BasicHttpAuth requires HTTPS and HttpClient Health displays:
    Image
  3. Expand Config > Drivers > HttpClientNetwork, double-click the HttpClientDevice and expand Authenticator.
    The properties expand.
    Image
  4. Select BasicHttpAuth from the Auth Type drop-down list and click Save
    The driver updates the Config options.
  5. Expand Config, set up Username And Password credentials and click Save.
  6. Right-click HttpClient and click Actions > Send.