如何阅读“仅限http”的“来自BHO的cookie,当属于cookie中设置的范围的页面未加载时。 [英] How to read a "http-only" cookie from a BHO, when a page belonging to the scope set in the cookie is NOT LOADED.

查看:74
本文介绍了如何阅读“仅限http”的“来自BHO的cookie,当属于cookie中设置的范围的页面未加载时。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以下是我的使用案例:


  1. 我想读取一个cookie X,设置为一个域让我们说D。
  2. 不能假设属于域D的页面之前已打开过。所以我不能按照我可以从IHtmlDocument2获取cookie的方法。
  3. 我试图读取的cookie是HTTP-ONLY,因此我不能使用像 InternetGetCookie() 它不会返回仅限http的cookie。

所以看起来似乎没有建议的方法
here
,对我有用。


我见过附加组件chrome和firefox,如Cookie管理器,可以读/写cookie,所以我假设浏览器插件应该可以读取任何cookie。 


有人可以建议吗我可以按照方法阅读cookie吗?



谢谢,


Ashish

解决方案

InternetGetCookieEx  INTERNET_COOKIE _HTTPONLY

Following is my use case:

  1. i want to read a cookie X, which is set to a domain lets say D.
  2. It cannot be assumed that a page belonging to domain D, has been opened before. So i cannot follow the approach where I can get the cookie from IHtmlDocument2.
  3. The cookie i am trying to read is HTTP-ONLY, so i cannot use something like InternetGetCookie() which doesn't return http-only cookies.

So It doesnt seem like the approach suggested here, works for me.

I have seen add-ons for chrome and firefox such as Cookie Manager, which can read/write cookies, so i am assuming that it should be possible for a browser addon to read any cookie. 

Can somebody please suggest me an approach i can follow to read the cookie?

Thanks,

Ashish

解决方案

InternetGetCookieEx INTERNET_COOKIE_HTTPONLY


这篇关于如何阅读“仅限http”的“来自BHO的cookie,当属于cookie中设置的范围的页面未加载时。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆