IE/Firefox/Chrome等浏览器保存Cookie的位置
IE/Firefox/Chrome等浏览器保存Cookie的位置
前面写了篇长文( 使用Jmeter登录WordPress的问题 )中也重点是Cookie的问题,这里再简单说下什么是Cookie并且列举一下主流浏览器保存Cookie的位置吧。
什么是Cookie?
A cookie, also known as an HTTP cookie, web cookie, or browser
cookie, is a small piece of data sent from a website and stored in a
user’s web browser while a user is browsing a website. When the user
browses the same website in the future, the data stored in the cookie
can be retrieved by the website to notify the website of the user’s
previous activity. Cookies were designed to be a reliable mechanism for
websites to remember the state of the website or activity the user had
taken in the past. This can include clicking particular buttons, logging
in, or a record of which pages were visited by the user even months or
years ago.
(上面的解释来时wikipedia)
在Windows系统上(这里以Win7为例)浏览器的Cookie
IE浏览器Cookie数据位于:%APPDATA%\Microsoft\Windows\Cookies\ 目录中的xxx.txt文件 (里面可能有很多个.txt Cookie文件)
如:C:\Users\yren9\AppData\Roaming\Microsoft\Windows\Cookies\0WQ6YROK.txt
在IE浏览器中,IE将各个站点的Cookie分别保存为一个XXX.txt这样的纯文本文件(文件个数可能很多,但文件大小都较小);而
Firefox和Chrome是将所有的Cookie都保存在一个文件中(文件大小较大),该文件的格式为SQLite3数据库格式的文件。
Firefox的Cookie数据位于:%APPDATA%\Mozilla\Firefox\Profiles\ 目录中的xxx.default目录,名为cookies.sqlite的文件。
如:C:\Users\jay\AppData\Roaming\Mozilla\Firefox\Profiles\ji4grfex.default\cookies.sqlite
在Firefox中查看cookie, 可以选择”工具 > 选项 >” “隐私 > 显示cookie”。
Chrome的Cookie数据位于:%LOCALAPPDATA%\Google\Chrome\User Data\Default\ 目录中,名为Cookies的文件。
如:C:\Users\jay\AppData\Local\Google\Chrome\User Data\Default\Cookies
在Linux系统上(以Ubuntu 12.04 和 RHEL6.x 为例)浏览器的Cookie
Firefox的Cookie路径为:$HOME/.mozilla/firefox/xxxx.default/目录下的cookie.sqlite文件。
1 2 3 4 |
master@jay-linux:~/.mozilla/firefox/tffagwsn.default$ ll cookies.sqlite -rw-r--r-- 1 master master 1572864 Apr 21 16:54 cookies.sqlite master@jay-linux:~/.mozilla/firefox/tffagwsn.default$ pwd /home/master/.mozilla/firefox/tffagwsn.default |
chrome: 在文件夹./cache/google-chrome/Default/Cache
参考资料:
http://en.wikipedia.org/wiki/HTTP_cookie
http://www.milincorporated.com/a2_cookies.html
http://support.mozilla.org/en-US/kb/profiles-where-firefox-stores-user-data
http://superuser.com/questions/292952/chrome-cookies-folder-in-windows-7
IE/Firefox/Chrome等浏览器保存Cookie的位置的更多相关文章
- 简单明了区分IE,Firefox,chrome主流浏览器
简单明了判断浏览器Firefox:typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().index ...
- python模拟浏览器保存Cookie进行会话
#! /usr/bin/env python # -*-coding:utf- -*- import urllib import urllib2 import cookielib class NetR ...
- 兼容IE浏览器保存Cookie
兼容IE:Response.Cookies[":member"].Expires=DateTime.Now.AddDays(1); 其它浏览器:Response.Cookies[& ...
- 浏览器禁用Cookie
做JavaWeb的都知道Session的底层是使用Cookie来实现的,服务器端会在本地文件中保存session信息,并将sessionID发给客户端(浏览器),浏览器就会把这个sessionID(准 ...
- 各浏览器的cookie的name个数/最大容量限制测试
测试代码 for(var ii = 0; ii< 5000;ii++){ if (!window.ia) window.ia=0; window.ia++; var s = 'a'+window ...
- C#后台保存Cookie
一般是: Response.Cookies["backurl"].Expires.AddDays(2); 但是,IE浏览器保存Cookie用 Response.Cookies[&q ...
- 如何从桌面程序向浏览器传递cookie或自定义header
类似问题 从c#程序启动ie并传递cookie 打开默认浏览器并传递cookie 打开一个web浏览器使用c#应用程序并添加请求头 猜想 从wpf程序打开默认浏览器并定位到一个url ,并且向这个ur ...
- 各种浏览器(IE,Firefox,Chrome,Opera)COOKIE修改方法[转]
各种浏览器(IE,Firefox,Chrome,Opera)COOKIE修改方法[转] 网站通过 Cookie 保存了我们访问网站的信息,在不同的浏览器中修改 Cookie 可以如下操作: Firef ...
- 【转】IE8浏览器无法保存Cookie的解决方法
转自:http://blog.csdn.net/sjsm2007/article/details/17958145 使用IE8浏览器经常出现了无法保存Cookie的故障.每次打开网站需要重新登录,登录 ...
随机推荐
- java编程思想恶心的enum状态机示例
下面是一个包装输入的类 package test; import java.util.Random; public enum Input { NICKEL(5) , DIME(10) , QUARTE ...
- 中介者模式(Mediator)
GOF:用一个中介对象来封装一系列的对象交互.中介者使对象不需要显式地相互引用,从而使其耦合松散,而且可以独立地改变它们之间的交互. 类图:
- 【iCore3 双核心板】例程二十七:DMA LAN实验——高速数据传输测速
实验指导书及代码包下载: http://pan.baidu.com/s/1o7qnCUI iCore3 购买链接: https://item.taobao.com/item.htm?id=524229 ...
- ActiveMQ: 搭建Broker集群(cluster)
上一篇介绍了基于Networks of Borkers的2节点HA方案,这一篇继续来折腾Networks of Brokers,当应用规模日渐增长时,2节点的broker可能仍然抗不住访问压力,这时候 ...
- 现在写 PHP,你应该知道这些
现在写 PHP,你应该知道这些 2015-10-21 分类:WEB开发.编程开发.首页精华2人评论 来源:Scholer's Blog 分享到:更多3 二十万年薪PHP工程师培养计划 成 ...
- (lleetcode)Single Number
Given an array of integers, every element appears twice except for one. Find that single one. Note:Y ...
- php连接和操作mysql数据库
<?php //数据库连接文件:link.php $link = mysql_connect("localhost", "root", "&qu ...
- Java中的集合框架
概念与作用 集合概念 现实生活中:很多事物凑在一起 数学中的集合:具有共同属性的事物的总体 java中的集合类:是一种工具类,就像是容器,储存任意数量的具有共同属性的对象 在编程时,常常需要集中存放多 ...
- 如何在C#中获得input文本框中的值
前台 <input type="text" id="txt" name="txtn" style="width:213px& ...
- jQuery源代码学习之六——jQuery数据缓存Data
一.jQuery数据缓存基本原理 jQuery数据缓存就两个全局Data对象,data_user以及data_priv; 这两个对象分别用于缓存用户自定义数据和内部数据: 以data_user为例,所 ...