Jump to content

unable to make simple request to http-in URL, anything special required?


Laranjinha Broome
 Share

You are about to reply to a thread that has been inactive for 1002 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hello Community,

i have a basic implementation to:

1-request http-in URL [OK]
2-access it from out-world python code [NOK]

I am using python requests library to access the URL with GET method (tried POST too), as below:

url = 'http://simhost-0b0f86c450b540326.agni.secondlife.io:12046/cap/.......'
requests.get(url, verify=False)

i also tried using urlib library:

urllib.urlopen(url,{'key':'value'})

and both options keeps me with the same unsuccessful response:  HTTP Error 502: Proxy Error

Do you have any light?

Thanks in advance

Link to comment
Share on other sites

On 7/26/2021 at 7:02 PM, Laranjinha Broome said:

hey @bobsknief Orsini for now, i am sending nothing in the header. Empty. 

Do you have any working example of this outside call to http-in? 

Only in PHP.

First of do try changing to HTTPS. And in LSL use llRequestSecureURL.
You may also try using a different get command that uses a different port. 
Do you have an equivalent of the PHP command curl_init(); in python? (if yes, give that a go).

My PHP, maybe it helps:

curl_setopt($ch,CURLOPT_POST,1);
curl_setopt($ch,CURLOPT_POSTFIELDS,$post_str);
curl_setopt($ch,CURLOPT_FOLLOWLOCATION,1);
curl_setopt($ch,CURLOPT_HEADER,0);
curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);	
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER,0);	

 

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 1002 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...