C# Chrome缓存文件读取器

C# Chrome缓存文件读取器,c#,google-chrome,C#,Google Chrome,我对查看存储在chrome缓存文件中的数据感兴趣,该文件位于C:\Users\%user%\AppData\Local\Google\chrome\user data\Default\cache 以与CacheView相同的方式: 我看过数据库历史记录和Cookies。使用以下SQLite命令: 历史记录:URL 历史:下载 历史记录:下载\u Url\u缓存 饼干 其中不包含一般缓存数据(PNG、mp4s等)的文件类型、大小或url来源的基础元数据 应用目的 预期生成的应用程序将从缓存中获得当

我对查看存储在chrome缓存文件中的数据感兴趣,该文件位于
C:\Users\%user%\AppData\Local\Google\chrome\user data\Default\cache
以与CacheView相同的方式:

我看过数据库历史记录和Cookies。使用以下SQLite命令:
历史记录:URL

历史:下载

历史记录:下载\u Url\u缓存

饼干

其中不包含一般缓存数据(PNG、mp4s等)的文件类型、大小或url来源的基础元数据

应用目的 预期生成的应用程序将从缓存中获得当前文件数。当然,作为后台线程进行自我更新

因此,我花了8个多小时研究这个主题,包括通过binaryReader和UTF-8解码为前10个字符创建一个初始头处理类。大错误。研究的分支是HttpHeader处理,使用了一些正则表达式

问题:开发人员如何通过c-sharp访问缓存文件(即png)

在没有开发人员输入的情况下进一步研究,使我走上了十六进制内存指针的道路。在使用StreamReader对文件进行流式处理时插入一些正则表达式。一定要比那容易些吧

更多参考资料: 及

更新:一些psuedo

由于编码和填充而失败

GetEncoding(); // Returns ASCII
// freezes System.Text.Encoding.ASCII.GetString(buf);
// symbol no System.Text.Encoding.UTF8.GetString(buf);
// encoding no string finalLines = Convert.ToBase64String(thisData, Base64FormattingOptions.InsertLineBreaks);
// symbol no string datas = System.Text.Encoding.Default.GetString(thisData);
string cur = "";
this.Invoke((MethodInvoker)delegate ()
     {
       richTextBox1.Text = Convert.ToBase64String(File.ReadAllBytes(path));
       cur = richTextBox1.Text;
       richTextBox1.Enabled = true;
     });
 // INVAL MAGIC   byte[] decompressed = Decompress(thisData); // it's not gzip compressed as a file
// string[] data = File.ReadAllLines(path); 
Regex encRex = new Regex("^([^;]+);(?:\\s*([^=]+)=((?<q>\"?)[^\"]*\\k<q>);?)*$", RegexOptions.IgnoreCase);
GetEncoding();//返回ASCII码
//冻结System.Text.Encoding.ASCII.GetString(buf);
//符号no System.Text.Encoding.UTF8.GetString(buf);
//编码无字符串最终行=Convert.ToBase64String(thisData,Base64FormattingOptions.InsertLineBreaks);
//symbol无字符串数据=System.Text.Encoding.Default.GetString(thisData);
字符串cur=“”;
this.Invoke((MethodInvoker)委托()
{
richTextBox1.Text=Convert.ToBase64String(File.ReadAllBytes(path));
cur=richTextBox1.Text;
richTextBox1.Enabled=true;
});
//无效魔法字节[]已解压缩=解压缩(此数据);//它不是gzip压缩成文件的
//string[]data=File.ReadAllLines(路径);
Regex encRex=new Regex(“^([^;]+);(?:\\s*([^=]+)=((?\”?)[^\“]*\\k);?)*$”,RegexOptions.IgnoreCase);

您在这方面成功过吗?如果是的话,你能更新这个主题吗?不,我没有,我发现缓存文件结构不常见,Uni让我投入了深度学习,所以放弃了这个项目。如果能给我一个答复,我将不胜感激。
SELECT downloads.id, downloads_url_chains.url, downloads.received_bytes, downloads.total_bytes,
                                downloads.state, downloads.target_path, time(downloads.start_time / 1000000 + (strftime('%s', '1601-01-01')), 'unixepoch') AS Date, time(downloads.end_time / 1000000 + (strftime('%s', '1601-01-01')), 'unixepoch') AS Date,
                                downloads.opened, downloads.danger_type, downloads.interrupt_reason, downloads.etag,
                                time(downloads.last_modified / 1000000 + (strftime('%s', '1601-01-01')), 'unixepoch') AS Date, downloads_url_chains.chain_index
                            FROM downloads, downloads_url_chains WHERE downloads_url_chains.id = downloads.id
SELECT downloads_url_chains.id, downloads_url_chains.url, downloads_url_chains.chain_index FROM downloads_url_chains
SELECT host_key,name,encrypted_value,value FROM cookies WHERE value = ''
GetEncoding(); // Returns ASCII
// freezes System.Text.Encoding.ASCII.GetString(buf);
// symbol no System.Text.Encoding.UTF8.GetString(buf);
// encoding no string finalLines = Convert.ToBase64String(thisData, Base64FormattingOptions.InsertLineBreaks);
// symbol no string datas = System.Text.Encoding.Default.GetString(thisData);
string cur = "";
this.Invoke((MethodInvoker)delegate ()
     {
       richTextBox1.Text = Convert.ToBase64String(File.ReadAllBytes(path));
       cur = richTextBox1.Text;
       richTextBox1.Enabled = true;
     });
 // INVAL MAGIC   byte[] decompressed = Decompress(thisData); // it's not gzip compressed as a file
// string[] data = File.ReadAllLines(path); 
Regex encRex = new Regex("^([^;]+);(?:\\s*([^=]+)=((?<q>\"?)[^\"]*\\k<q>);?)*$", RegexOptions.IgnoreCase);