API key and API deployment fails on proxy gateway's
search cancel

API key and API deployment fails on proxy gateway's

book

Article ID: 233598

calendar_today

Updated On:

Products

CA API Developer Portal

Issue/Introduction

When trying to deploy API keys to the proxy Gateway, the following error shows up in the Gateway logs:

 

2022-01-24T18:50:29.040+0100 INFO    125825 com.l7tech.external.assertions.portaldeployer.server.client.PortalDeployerClient: Message Arrived - ID: 1, Topic: developer/application/command/deploy/tenantGatewayUuid/b88426ed-3eeb-48c8-a791-57d37aebdfe8
2022-01-24T18:50:29.040+0100 INFO    125825 com.l7tech.external.assertions.portaldeployer.server.client.PortalDeployerClient: Node is master, continuing to process message 1
2022-01-24T18:50:29.145+0100 WARNING 125825 com.l7tech.external.assertions.portaldeployer.server.SelfTrustManager: Couldn't find trusted certificate [cn=Gatewayhostname] in peer's certificate chain
2022-01-24T18:50:29.336+0100 INFO    125825 com.l7tech.external.assertions.portaldeployer.server.client.MessageProcessor: target request failed with response code 401, body Authentication Required
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.message: Processing request for service: Portal API Key Storage Service [/portalman/api-keys/storage*]
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.policy.assertion.ServerSslAssertion: 4113: No Client Certificate was present in the request.
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.policy.assertion.credential.http.ServerHttpBasic: 4101: No Authorization header
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.policy.assertion.credential.http.ServerHttpBasic: 4100: Authentication required
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.external.assertions.comparison.server.ServerComparisonAssertion: 7103: At least one comparison value was null
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.MessageProcessor: 3017: Policy evaluation for service Portal API Key Storage Service [5b84baad2d894df379df24e4550f17ea] resulted in status 401 (Authentication Required)
2022-01-24T18:50:29.362+0100 INFO    705 com.l7tech.server.message: Message was not processed: Authentication Required (401)

 

When deploying API the following error shows up: 

2022-12-08T14:49:09.991+0100 INFO    239 com.l7tech.external.assertions.portaldeployer.server.client.PortalDeployerClient: Message Arrived - ID: 9, Topic: tenantdevportal/api/command/deploy/tenantGatewayUuid/c85f24e5-24dd-4c8b-a9f7-cce629dab08a
2022-12-08T14:49:09.991+0100 INFO    239 com.l7tech.external.assertions.portaldeployer.server.client.PortalDeployerClient: Node is master, continuing to process message 9
2022-12-08T14:49:10.198+0100 SEVERE  239 com.l7tech.external.assertions.portaldeployer.server.client.MessageProcessor: There was performAction for message 
java.net.ConnectException: Connection refused (Connection refused)
    at java.base/java.net.PlainSocketImpl.socketConnect(Native Method)

Environment

Release : 5.x

Component : API Portal

Resolution

The gateway is receiving a message from the portal and will use this message to call the local service at "https://localhost:8443/portalman/api-keys/storage*"  on port 8443 or  "https://localhost:8443/restman/1.0/bundle" to install an API.

Make sure the gateway is trusting its own certificate and verify the client authentication setting for the 8443 listener port. The client authentication setting should be set to optional.

Also, make sure the local gateway is able to access the local service on localhost.