0
votes

I tried setup ALLINONE in my local, followed the documentation https://apim.docs.wso2.com/en/latest/learn/api-security/api-authentication/secure-apis-using-mutual-ssl/ it worked, but what will be the curl command for request because the document talks about testing only through postman

1

1 Answers

0
votes

You can use the following curl commands when you want to use the header-based approach.

curl -X GET -H "X-WSO2-CLIENT-CERTIFICATE: (Base64 encoded public cert)" "https://localhost:8243/mock/v1" -v


curl -X GET -H "X-WSO2-CLIENT-CERTIFICATE: (Base64 encoded public cert)" "http://localhost:8280/mock/v1" -v

In order to work this, you need to add the following configuration to the deployment.toml in wso2am-3.2.0/repository/conf location.

[apimgt.mutual_ssl]
enable_client_validation = false

You can use the following curl commands if you are using the cert and key.

curl -k --cert int.ext.wso2.com.crt --key int.ext.wso2.com.key -X GET "https://localhost:8243/mock/v1" -v