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

Proxy auth #35

Open
marcoroganovic opened this issue Nov 7, 2020 · 5 comments
Open

Proxy auth #35

marcoroganovic opened this issue Nov 7, 2020 · 5 comments

Comments

@marcoroganovic
Copy link

Hello, thanks for the convenient library.
I have one question regarding proxy usage, can I pass authentication for a proxy?

@tokers
Copy link
Owner

tokers commented Nov 7, 2020

@marcoroganovic Sorry i'm afraid that i don't understand your mean. Could you give me an example? Or i guess you are saying the Authorization header?

@marcoroganovic
Copy link
Author

@tokers Hey, thanks for replying.

Basically, I need to do next:

  1. Connect domain to some VPS
  2. On that domain setup OpenResty configs
  3. Once someone hits those domains I need to set headers like host, authorization, user-agent
  4. And then to forward that request through some dedicated proxy in order to not show servers IP

@marcoroganovic
Copy link
Author

@tokers Hi, any opinion on this?

@tokers
Copy link
Owner

tokers commented Nov 8, 2020

In my opinion, the process of authorization is not bound with lua-resty-requests, you can prepare these authorization related headers first and use them when calling methods provided by this library.

@marcoroganovic
Copy link
Author

@tokers

What I'm making is a small crawler and I need to change IP addresses, to avoid certain limits on a single IP, can this client library be used like that?

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

2 participants