How can I read Chrome Cache files?

前端 未结 12 1130
無奈伤痛
無奈伤痛 2020-12-12 21:22

A forum I frequent was down today, and upon restoration, I discovered that the last two days of forum posting had been rolled back completely.

Needless to say, I\'d

12条回答
  •  天涯浪人
    2020-12-12 21:51

    The Google Chrome cache directory $HOME/.cache/google-chrome/Default/Cache on Linux contains one file per cache entry named <16 char hex>_0 in "simple entry format":

    • 20 Byte SimpleFileHeader
    • key (i.e. the URI)
    • payload (the raw file content i.e. the PDF in our case)
    • SimpleFileEOF record
    • HTTP headers
    • SHA256 of the key (optional)
    • SimpleFileEOF record

    If you know the URI of the file you're looking for it should be easy to find. If not, a substring like the domain name, should help narrow it down. Search for URI in your cache like this:

    fgrep -Rl '' $HOME/.cache/google-chrome/Default/Cache
    

    Note: If you're not using the default Chrome profile, replace Default with the profile name, e.g. Profile 1.

提交回复
热议问题