AnsweredAssumed Answered

Login Issue API v3

Question asked by MemoryCorruption on May 10, 2012
Latest reply on May 11, 2012 by MemoryCorruption

Hello,

 

I am attempting to authenticate to the API, but I keep getting the same "Invalid Credentials" response.  I have verified that my username and password are correct. I also read the following post: https://community.qualys.com/message/13393#13393. This was very informative, but did not seem to solve my problem. I tried to do as instructed in the workaround by changing the authorization headers and encoding the credentials with base64.  I am not using Python, I am attempting to use Perl. 

 

My POST request looks like this:

POST https://qualysapi.qualys.com/qps/rest/3.0/count/was/webapp

Authorization: Basic *Redacted*

User-Agent: libwww-perl/6.04

Content-Length: 341

Content-Type: text/xml

 

The response I get is this:

 

</ServiceRequest>
<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNam
espaceSchemaLocation="https://qualysapi.qualys.com/qps/xsd/3.0/was/webapp.xsd">
  <responseCode>INVALID_CREDENTIALS</responseCode>
  <responseErrorDetails>
    <errorMessage>Login or password invalid</errorMessage>
    <errorResolution>Verify both 'user' and 'password' credentials.</errorResolu
tion>
  </responseErrorDetails>
</ServiceResponse>

 

Any help would be much appreciated.  Thanks.

Outcomes