最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

android - How to disable react native fetch to store request cache on the disk - Stack Overflow

programmeradmin0浏览0评论

I'm experiencing the very same problem as described in this issue

namely, I noticed that when doing requests using fetch in react native android app (and my assumption this is an inherited behavior of OkHttpClient in Java, but not 100% sure) it creates files with plain text of a request including cookies.

set-cookie: nameOfCookie1=cookieValue1; Max-Age=3600; Path=/; Expires=Wed, 29 Jan 2020 11:47:41 GMT; HttpOnly; Secure
set-cookie: nameOfCookie2=cookieValue2; Max-Age=3600; Path=/; Expires=Wed, 29 Jan 2020 11:

This problem was also flagged by our security team since our app is going to be used in tightly regulated area.

Is it possible to disable this cache? What I've tried so far is to use headers Pragma: no-cache and cache: no-cache while sending the request and it didn't have any effect.

发布评论

评论列表(0)

  1. 暂无评论