loopbackio / loopback-connector-soap

LoopBack's SOAP based Web Services Connector

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

wsdl_options property not being used

mschmidt712 opened this issue · comments

It appears that the wsdl_options property is not being interpreted. When I try to connect to a soap service over HTTPS, I receive the following error with the strictSSL and rejectUnauthorized properties set to false :
{ "error": { "statusCode": 500, "name": "Error", "message": "unable to verify the first certificate", "code": "UNABLE_TO_VERIFY_LEAF_SIGNATURE", "stack": "Error: unable to verify the first certificate\n at Error (native)\n at TLSSocket.<anonymous> (_tls_wrap.js:1092:38)\n at emitNone (events.js:86:13)\n at TLSSocket.emit (events.js:185:7)\n at TLSSocket._finishInit (_tls_wrap.js:610:8)\n at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:440:38)" } }

However, if I add these as options to the ClientSSL security param then the certificate is bypassed, as expected. From looking at the implementation in soap-connector.js is appears that the wsdl_options are possibly not being interpreted.

Steps to Reproduce

  1. Attempt to connect to a https soap service, bypassing the certificate with the following wsdl_options params:
    { "strictSSL": false, "rejectUnauthorized": false }
commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

This stale bot is like cheating!

commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

commented

This issue has been closed due to continued inactivity. Thank you for your understanding. If you believe this to be in error, please contact one of the code owners, listed in the CODEOWNERS file at the top-level of this repository.

Same Problem here trying to connect to a self-signed HTTPS URL:

Unhandled error for request POST /api/EssenceService2SoapBinding/getLoResLinkForHiRes: Error: unable to get local issuer certificate
    at Error (native)
    at TLSSocket.<anonymous> (_tls_wrap.js:1092:38)
    at emitNone (events.js:86:13)
    at TLSSocket.emit (events.js:185:7)
    at TLSSocket._finishInit (_tls_wrap.js:609:8)
    at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:439:38)

From my datasources.json file:

  "wsdl_options": {
  "rejectUnauthorized": false,
  "strictSSL": false,
  "requestCert": true
}

Can you please reopen this issue?

Idiot framework