Reputation: 1
I'm trying to connect to a host using the CONNECT command in Progress, but it's returning a connection failure, but when trying to do it through Postman, the sending is done correctly. Could someone tell me what is missing to connect through Progress?
Below is the code I ran to make the CONNECT:
DEFINE VARIABLE hSocket123 AS HANDLE NO-UNDO.
DEFINE VARIABLE cConnectionURL AS CHARACTER NO-UNDO.
cConnectionURL = "-H ":U + "7d8p6n4c7b.execute-api.us-east-1.amazonaws.com" + " -S ":U + STRING(80).
CREATE SOCKET hSocket123.
hSocket123:CONNECT(cConnectionURL) NO-ERROR.
MESSAGE hSocket123:CONNECT(cConnectionURL) VIEW-AS ALERT-BOX INFORMATION BUTTONS OK.
Attached is the informacao.xml file, which I successfully sent via Postman.
Send an xml file through Progress[[
enter image description here]
(https://i.sstatic.net/bkA32.jpg)](https://i.sstatic.net/oqdrw.jpg)
Upvotes: 0
Views: 187
Reputation: 3909
The Postman image shows an HTTPS connection.
So you're going to need to change your connection string to
cConnectionURL = "-H ":U + "7d8p6n4c7b.execute-api.us-east-1.amazonaws.com" + " -S ":U + STRING(443).
You are, at that point, likely to run into issues with certificates, because OpenEdge does not import as many root CA's as, say, a browser does. The doc at https://docs.progress.com/bundle/openedge-security-keys-and-certificates-122/page/Manage-certificate-stores-for-OpenEdge-clients-and-servers.html can help.
I usually connect to the site with a browser like Firefox, and use that to download the root CA and import it into the OpenEdge certificate store, using the proenv> certutil -import <file>
command.
Upvotes: 6