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

How get cookies? #74

Open
MakcStudio opened this issue Oct 6, 2020 · 4 comments
Open

How get cookies? #74

MakcStudio opened this issue Oct 6, 2020 · 4 comments

Comments

@MakcStudio
Copy link

in response to the request, I get cookies, but for some reason the container does not save them automatically. Why isn't this possible? aren't these standard functions?

@MakcStudio
Copy link
Author

I spent a whole day trying to figure out why this shitcode doesn't do what I need, and as it turned out, it doesn't even accept cookies sent to it, but uses some kind of cookie container that is static for all cookies. In General, if someone needs to use cookies with this shit, I advise you to download and manage this library for yourself

@alexrainman
Copy link
Owner

This "shit" code is used by thou devs around the world. The cookie handler is not static, it uses each platform cookie container. If you want to send cookies, use SetCookie method. Yes, it doesn't offer a ReadCookie method. I may add it to this "shitty" code if i have some time.

@MakcStudio
Copy link
Author

This "shit" code is used by thou devs around the world. The cookie handler is not static, it uses each platform cookie container. If you want to send cookies, use SetCookie method. Yes, it doesn't offer a ReadCookie method. I may add it to this "shitty" code if i have some time.

The method for getting cookies is good. It would be great if it also collected cookies there during the redirect. You use Cookie storage (in the ios project, when passing nativeCookie, nothing is done with them, I corrected this code yesterday)

This is not normal logic if you need to send different cookies all the time. I have several accounts and several sessions in the app. Using a single storage is wildly inconvenient. I would advise you to abandon the implementation of cookies through storage with a cache, disable it completely, so that people completely add the necessary cookies manually.

Your library helped me solve the problem with ssl , but it caused other problems that I had to solve. Not very intuitive problems, I spent a long time debugging your code yesterday to understand where cookies come from (after I removed them in SendAsync)
It turns out this happens in session, if my container is empty, in session it still inserts cookies from storage.

@alexrainman
Copy link
Owner

If you have something you think need to be fixed, please submit a PR.

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

No branches or pull requests

2 participants