用大善人的cf直接提取自己的ck, 创建一个worker即可
代码填写进去, cookie替换成自己的就可以了, 不知道能不能一直用
而且可以把域名换成自己的防止被墙
const TELEGRAPH_URL = 'https://linux.do/latest.rss';
addEventListener('fetch', event => {
event.respondWith(handleRequest(event.request))
})
async function handleRequest(request) {
const url = new URL(TELEGRAPH_URL);
url.host = TELEGRAPH_URL.replace(/^https?:\/\//, '');
const modifiedRequest = new Request(url.toString(), {
headers: {
...request.headers, // 保持原有的headers
'Cookie': '你自己的cookie' // 添加或覆盖Cookie头
},
method: request.method,
body: request.body,
redirect: 'follow'
});
const response = await fetch(modifiedRequest);
const modifiedResponse = new Response(response.body, response);
modifiedResponse.headers.set('Access-Control-Allow-Origin', '*');
return modifiedResponse;
}