Where does Chrome store cookies?

前端 未结 6 1141
执笔经年
执笔经年 2020-11-29 00:18

Let\'s say I set a cookie using the setcookie() function in PHP:

setcookie(\'name\',\'foo\',false,\'/\',false);

I

6条回答
  •  一向
    一向 (楼主)
    2020-11-29 00:49

    The answer is due to the fact that Google Chrome uses an SQLite file to save cookies. It resides under:

    C:\Users\\AppData\Local\Google\Chrome\User Data\Default\
    

    inside Cookies file. (which is an SQLite database file)

    So it's not a file stored on hard drive but a row in an SQLite database file which can be read by a third party program such as: SQLite Database Browser

    EDIT: Thanks to @Chexpir, it is also good to know that the values are stored encrypted.

提交回复
热议问题