Questions tagged [pycurl]

PycURL is a Python interface to libcurl.

PycURL is a Python interface to libcurl. PycURL can be used to fetch objects identified by a URL from a Python program, similar to the urllib Python module. PycURL is mature, very fast, and supports a lot of features.

609 questions
0
votes
1 answer

pycurl.error: (35, 'error reading X.509 key or certificate file')

The code below works on Windows, but on Ubuntu I'm receiving the error (35, 'error reading X.509 key or certificate file'). It seems like pycurl can't find the path to certificate file: c.setopt(c.URL, self.INTERFACE_URL) c.setopt(c.POST,…
0
votes
1 answer

next InitializeSecurityContext failed - SSL CONNECTION using pycurl

I'm struggling to translate command like this below curl "https://my.website.address.com" --key path\to\client_key.pem --cert path\to\client.crt --pass P4$$w0rD to a python script using pycurl: import pycurl URL =…
k667
  • 101
  • 3
  • 6
0
votes
0 answers

Python Key Error for Instagram Auth Token

I found some code online for Instagram Auto Like script. My current issue is this error http://s1.postimg.org/griyd3pjz/code_sample.png the error you see is for the first blacked out key The relevant code is: # Function to encode the string with the…
Web Dev
  • 305
  • 1
  • 12
0
votes
0 answers

defer downloading the response body when making GET reques

By default, when you make a request, the body of the response is downloaded immediately. You can override this behaviour in Requests module and defer downloading the response body until you access the Response.content attribute with the…
iMath
  • 2,326
  • 2
  • 43
  • 75
0
votes
1 answer

Pycurl ssl connection throught ntlm

I am struggling with connection to https sites and files. We have ntlm network proxy authentication. HTTP connections are working like a charm, but https is stuck with error: pycurl.error: (27, "SSL: couldn't create a context:…
Synal
  • 75
  • 3
  • 11
0
votes
1 answer

How to perform HTTPS Calls in Pycurl?

I want to login into a website sending POST request using `pycurl' on a HTTPS page. I did the following: import pycurl, urllib curl = pycurl.Curl() curl.setopt(pycurl.COOKIEFILE, "") post =…
codersofthedark
  • 9,183
  • 8
  • 45
  • 70
0
votes
1 answer

What error does cURL throws when we curl a http service which is not reachable over IPv6?

We have a service which can't be discoverable over IPv6 and so we have to reach it over IPv4 always. I'd like to do a Http request over IPv6 to the service on a port 1234 and i want to know what will be the error code cURL throws?
user1159517
  • 5,390
  • 8
  • 30
  • 47
0
votes
1 answer

Web Server using pycurl - GET

I'm setting up a webserver using pycurl, and im having a small problem, where if i send commands using CURL, i get the json response, but if i use the pycurl method i dont get a response from the server, i have check the packets flow using…
Dave Fontes
  • 19
  • 1
  • 1
  • 5
0
votes
1 answer

Tornado CurlAsyncHTTPClient over Https: Segmentation fault on RHEL 5.3

Has anyone ever experienced segmentation fault when using CurlAsyncHTTPClient on RHEL 5.3? It crashes when calling an https url, but not with http.
DevLounge
  • 8,313
  • 3
  • 31
  • 44
0
votes
1 answer

How do I resolve this curl-related error?

please tell me the solution Traceback (most recent call last): File "", line 1, in File "build/bdist.linux-x86_64/egg/pycurl.py", line 7, in File "build/bdist.linux-x86_64/egg/pycurl.py", line 6, in…
suresh
  • 11
0
votes
3 answers

Issues with invalid syntax error in a url

In my code Im trying to get the user to log in and retrive some information, but I get a syntax error with my variables user and password. bold print is commented out in code import urllib.request import time import pycurl #Log in user =…
user3897196
  • 17
  • 1
  • 2
0
votes
0 answers

Pycurl giving me errors saying object doesnt have curl

Below is my code with some mods to it because it contained passwords and such. But when i run this code it get a error saying (AttributeError: 'module' object has no attribute 'Curl'). I tried looking for this and cant find a working method, so how…
user3897196
  • 17
  • 1
  • 2
0
votes
2 answers

What is the equivalent to cURLs --data-urlencode in pycurl?

I'm trying to convert the following cURL command to pycurl but am unable to determine what the equivalent to --data-urlendcode is? curl --connect-timeout 5 -u usr:pwd --data-urlencode…
Moonie
  • 55
  • 1
  • 11
0
votes
1 answer

pyCURL download and get content from mp3 file

I'm trying to get content from downloaded file. If i save file like .mp3 it even playing. But when i get content there are a lot of "terrible" characters i.e. (û…
0
votes
1 answer

pycurl READFUNCTION with a bytestream

Is there a way to write a callback function for pycurl's READFUNCTION that does not return a string? I am planning on sending blocks of binary data via pycurl. i tried writing a callback function that does this: def read_callback(self, size): for…
maranas
  • 1,396
  • 1
  • 12
  • 21