Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where cookies are stored in system?

If i use Response.Cookies["test"].Value ="Hi"; where are cookie stored in system?

Can i check Cookies["test"] value in my pc because cookies are stored in text format.

I am using VS 2008. Operating system is Windows 7.

I have tried to find in Google but not getting the exact answer. Please help to sort out this problem.

like image 328
PrateekSaluja Avatar asked Sep 27 '10 06:09

PrateekSaluja


People also ask

Where does cookies get stored?

Cookies are stored on your device locally to free up storage space on a website's servers. In turn, websites can personalize while saving money on server maintenance and storage costs.

Where are cookies stored on server?

Cookies are created with the help of an HTTP header and then transferred between the browser and the server. Cookies are saved in the Temporal Internet File Folder by Internet Explorer, but the location where they are saved is determined by the browser being used.


2 Answers

IE and Windows keeps cookies here:

%AppData%\Microsoft\Windows\Cookies 

Points to the same directory as @Sohnee's does under Windows Visa and newer, but his doesn't under Windows XP and earlier, my - does.

also Temporary Internet Files can contain some cookies.

Meanwhile Firefox keeps cookies into SQLite database under profile root:

%AppData%\Mozilla\Firefox\Profiles\%FirefoxProfile%\cookies.sqlite 

To read the data you need to connect to that database using any SQLite client and execute next query:

select value from moz_cookies where name = 'test' 

I did it just now using trial SQLite Maestro. And don't forget to close all running Firefoxes before connection attempt.

like image 69
abatishchev Avatar answered Sep 30 '22 19:09

abatishchev


Cookies are stored in the cookies folder on Windows 7. To open the cookies folder, open run in Windows and type shell:cookies. Also, as suggested above, they might be in Temporary internet files. However, I see that your cookies are not persistent. This means you are not setting any expiration on them. Therefore, they won't be stored on your machine and they will only be part of the browser's memory.

like image 26
kunal Avatar answered Sep 30 '22 21:09

kunal