I need to call a rest API service in Saleforce from an external client. This application logins in Salesforce with the SOAP standard login service and then has to call some custom services. The profile of the user has the Enforce SSL/TLS Mutual Authentication flag enabled and needs a certificate to make calls. The endpoint is something like this https://istance.my.salesforce.com:8443/services/apexrest/my_web_service.
I tried to call the webservice with curl and the result is:
curl "https://istance.my.salesforce.com:8443/services/apexrest/my_web_service" -H "Authorization: Bearer <session_id>" -H "Accept: application/json" -H "Content-Type: application/json; charset=UTF-8" -E fullcert.pem
[{"message":"INVALID_HEADER_TYPE","errorCode":"INVALID_AUTH_HEADER"}]
I didn't find anything about call rest services with mutual authentication, so my question is, is it possible to call rest service with mutual authentication? And if so, how can I do that?
set +H
before the command it works. If you write that as an answer I'll accept it. Thank you very much.