Open frhnfrq opened 1 year ago
I have tried monkey patching, by setting a custom httpsAgent with TLS v1.2 to the Axios instance in uapi-request but it didn't work.
Hello @frhnfrq, Could you provide me with the next information?
Thank you, and have a nice day!
Hi @kommandant-topp,
uapi-json: 1.16.0 nodejs version: 18.17.1 & 20.5.1
Here's the full request dump, request log.txt
Hello @frhnfrq, Looks like this is the problem with the disabled TLS 1.3 version on the apac region subdomain: https://www.ssllabs.com/ssltest/analyze.html?d=apac.universal-api.travelport.com (emec region is ok). You can try to use Node 16 or lower as a quick solution. You can also create a support ticket for Travelport to ask about this issue.
We'll discuss with our team the possible solution, but I'm not sure that we'll be able de deploy it fast.
Thank you, and have a nice day!
Hi @kommandant-topp, Thanks. Switching to 16.14.2 solved the TLS error, however I am getting error of invalid credentials, even though my credentials are correct. It works on the demo portal of travelport.
Here's the log
Input params {
"legs": [
{
"from": "DEL",
"to": "BOM",
"departureDate": "2023-08-28"
}
],
"passengers": {
"ADT": 1
},
"cabins": [
"Economy"
],
"requestId": "4e2fd1f8-2221-4b6c-bb6e-cf05c367cf60",
"maxJourneyTime": 300,
"pricing": {
"currency": "USD"
}
}
Request URL: https://apac.universal-api.travelport.com/B2BGateway/connect/uAPI/AirService
Request XML:
<!--Release 33-->
<!--Version Dated as of 14/Aug/2015 18:47:44-->
<!--Air Low Fare Search For Galileo(1G) Request-->
<soap:Envelope
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<air:LowFareSearchReq
AuthorizedBy="user" TraceId="4e2fd1f8-2221-4b6c-bb6e-cf05c367cf60" TargetBranch="P7205768"
ReturnUpsellFare="true"
xmlns:air="http://www.travelport.com/schema/air_v52_0"
xmlns:com="http://www.travelport.com/schema/common_v52_0"
>
<com:BillingPointOfSaleInfo OriginApplication="uAPI"/>
<air:SearchAirLeg>
<air:SearchOrigin>
<com:CityOrAirport Code="DEL" PreferCity="true"/>
</air:SearchOrigin>
<air:SearchDestination>
<com:CityOrAirport Code="BOM" PreferCity="true"/>
</air:SearchDestination>
<air:SearchDepTime PreferredTime="2023-08-28"/>
<air:AirLegModifiers>
<air:PreferredCabins>
<com:CabinClass Type="Economy"/>
</air:PreferredCabins>
</air:AirLegModifiers>
</air:SearchAirLeg>
<air:AirSearchModifiers
MaxJourneyTime="300"
>
<air:PreferredProviders>
<com:Provider Code="1G"
xmlns:com="http://www.travelport.com/schema/common_v52_0"/>
</air:PreferredProviders>
</air:AirSearchModifiers>
<com:SearchPassenger Code="ADT"
xmlns:com="http://www.travelport.com/schema/common_v52_0"/>
<air:AirPricingModifiers
CurrencyType="USD"
/>
</air:LowFareSearchReq>
</soap:Body>
</soap:Envelope>
Error Response SOAP: {
"status": 401,
"data": "<SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"><SOAP-ENV:Body><SOAP-ENV:Fault><SOAP-ENV:faultcode>76</SOAP-ENV:faultcode><SOAP-ENV:faultstring>Authentication Result Error Message Response (76): Authentication credentials are invalid.</SOAP-ENV:faultstring><SOAP-ENV:faultactor> </SOAP-ENV:faultactor><SOAP-ENV:detail>Authentication Result Error Message Response (76): Authentication credentials are invalid.</SOAP-ENV:detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>"
}
/Users/farhan/NodeProjects/uapi-json-test/node_modules/uapi-json/src/Request/uapi-request.js:131
return Promise.reject(new RequestSoapError.SoapRequestError(error));
^
SoapRequestError [RequestSoapError.SoapRequestError]: Error during request to SOAP API. Check url validity
at /Users/farhan/NodeProjects/uapi-json-test/node_modules/uapi-json/src/Request/uapi-request.js:131:33
at processTicksAndRejections (node:internal/process/task_queues:96:5) {
source: 'uapi-json',
data: {
status: 401,
data: '<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><SOAP-ENV:Body><SOAP-ENV:Fault><SOAP-ENV:faultcode>76</SOAP-ENV:faultcode><SOAP-ENV:faultstring>Authentication Result Error Message Response (76): Authentication credentials are invalid.</SOAP-ENV:faultstring><SOAP-ENV:faultactor> </SOAP-ENV:faultactor><SOAP-ENV:detail>Authentication Result Error Message Response (76): Authentication credentials are invalid.</SOAP-ENV:detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>'
},
statusCode: undefined
}
Moreover, please do have a discussion with your team regarding the TLS issue for newer version of node.
Thank you very much, you have a nice day too!
My bad, I missed the fact that production flag is set to true by default
Hello developer, when can this issue be resolved and merged into the main branch. Thanks!
Hello @misoag, Not sure about the terms of this update to be done.
Meanwhile, do you consider contributing to this fix? Check our contribution instruction.
Thank you, and have a nice day
@kommandant-topp i have same problem this issue. i use nodejs 20.10.0 and npm version 10. then should i downgrade my nodejs version?
Hello @kim00425, you can try to downgrade your nodejs version for the local solution or contribute a global fix. Check our contribution instruction.
Thank you, and have a nice day
@kommandant-topp i understand that support for nodejs version 16 is now ending. can this be resolved by contacting Travelport?
@kommandant-topp It is said that Travelport recently renewed its SSL certificate. please confirm.
Hello @kim00425, As I can see from here: https://www.ssllabs.com/ssltest/analyze.html?d=apac.universal-api.travelport.com, TLS1.3 is still disabled for the apac region subdomain. I'll try to test it again a bit later.
Thank you, and have a nice day!
@kommandant-topp If you run it now, it will work. when i run on version 20.10.0, the request was made normally. APAC UAPI endpoint has been updated with the newest ciphers
@frhnfrq try to node 18
Hello @kim00425,
Thank you a lot for the update!
Hi, I am getting the following error whenever trying to make a request,
I'm assuming it's because Travelport only supports TLS1.2 and the client is trying to make the request using a different version. Please let me know how I can fix this.