Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Douban Server ban no user-agnet request #16

Open
tywtyw2002 opened this issue Aug 19, 2014 · 0 comments
Open

Douban Server ban no user-agnet request #16

tywtyw2002 opened this issue Aug 19, 2014 · 0 comments

Comments

@tywtyw2002
Copy link

Hi,

The douban.fm server ban the request without user-agent. The default curl request is not include User-agent field, it would return a HTTP 403 error.

<html>
<head><title>403 Forbidden</title></head>
<body bgcolor="white">
<center><h1>403 Forbidden</h1></center>
<hr><center>nginx</center>
</body>
</html>

so, to fix this bug just need to add curl_easy_setopt(pl->curl, CURLOPT_USERAGENT, "curl/7.30.0"); to the source code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant