Logging in and using cookies in pycurl

前端 未结 3 1029
隐瞒了意图╮
隐瞒了意图╮ 2021-02-04 15:45

I need to download a file that is on a password protected page. To get to the page manually I first have to authenticate via an ordinary login page. I want to use curl to fetc

3条回答
  •  时光取名叫无心
    2021-02-04 16:00

    wds is right on.

    for your further edification, the available options are based on those at http://curl.haxx.se/libcurl/c/curl_easy_setopt.html (see the section on cookie shortcuts).

    a 500 is an internal server error...hard to be sure whether this can be blamed on your script without knowing more information about what's going on here. you could be failing to pass other data the page is expecting (unrelated to cookies) for all we know (and they have not implemented graceful error handling!)

    jb

提交回复
热议问题