1

We have an application that sends a request to an IBM Tivoli Netcool/OMNIbus 8.1 server's ObjectServer REST API. It sends a GET request to http://1.2.3.4/objectserver/restapi/alerts/status?filter=Severity=5%20and%20Manager%20not%20like%20'^.*Watch$' with the following HTTP headers:

Authorization: Basic DHCteF92S53fhUY6jlF=
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Content-Type: application/json

The request works fine in our dev environment, and the REST API returns the requested alert information. However, in our test environment, the REST API returns a "401 - Authorization Required" error.

The DHCteF92S53fhUY6jlF= value in the Authorization header seems to be some sort of authentication token, and it is hardcoded in our application. The developer who wrote that code is long gone, and I have no idea how that value is generated. Maybe it is incorrect for our test environment and thus the 401 error. How is that authentication token generated?

1 Answer 1

2

Anything can create the Basic authentication header. It is the base 64 encoded value of the username:password phrase.

In your test environment, base64 encode the current username:password for the account you want to use, and add it to the header.

You can use a site such as the following if you need a tool:

https://base64decode.org/

https://www.debugbear.com/basic-auth-header-generator

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .