Skip to content

Commit

Permalink
正则匹配去掉scheme匹配,以适应http协议 (#120)
Browse files Browse the repository at this point in the history
* Create FUNDING.yml

* 稍作修改即可支持 reCaptcha (#34)

* 更换代理地址

* 添加edge支持 (#36)

Co-authored-by: Your Name <[email protected]>

* 强制使用https (#48)

* 修改自定义安装方式

fixed #45

* 移除不可用的 firefox addon 地址 (#51)

fixed #32

* remove github funding

* Create Privacy.md

* 移除 download badges

Signed-off-by: 迷渡 <[email protected]>

* 更新 readme

Signed-off-by: 迷渡 <[email protected]>

* 替换 gstatic 资源

Signed-off-by: 迷渡 <[email protected]>

* publish 0.5.0

Signed-off-by: 迷渡 <[email protected]>

* 添加 Content-Security-Policy

Signed-off-by: 迷渡 <[email protected]>

* 移除旧版 edge

Signed-off-by: 迷渡 <[email protected]>

* Fix bootstrapcdn issue (#66)

* fix bootstrapcdn (#65)

* fix bootstrapcdn

* Update background.js

* 使用微软 CDN 镜像 jquery.com (#67)

* 添加 Edge

* fix: onBeforeRequest's filter function return wrong data type (#70)

see #64 (comment)
see https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/onBeforeRequest

Co-authored-by: Andy <[email protected]>

* publish 0.7.0

Signed-off-by: 迷渡 <[email protected]>

* 添加 typescript 支持

Signed-off-by: 迷渡 <[email protected]>

* 调整目录结构

Signed-off-by: 迷渡 <[email protected]>

* 添加速度说明

Signed-off-by: 迷渡 <[email protected]>

* fix img path

Signed-off-by: 迷渡 <[email protected]>

* fmt

Signed-off-by: 迷渡 <[email protected]>

* 补充原理说明

Signed-off-by: 迷渡 <[email protected]>

* 添加 cdn 替换说明

Signed-off-by: 迷渡 <[email protected]>

* update firefox

* feat: replace secure.gravatar.com to gravatar.loli.net (#74)

* release v0.8.0 (#75)

* fix: www.gravatar.com not work (#77)

* release v0.9.0 (#78)

* Add browser publish github action (#80)

* Add zip build script

* Add Github action workflow

Co-authored-by: Stefan Aleksic <[email protected]>

* remove CSP  (#81)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* Dev (#82)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置和演示用例 (#83)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* V2 prune 纯净版本,主要是移除 与 chrome 扩展无关的服务端配置文件 (#86)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* 移除与扩展无关的server文件

* V3 prune 纯净版本 chrome manifest version upgrade to v3 适配 chromium manifest v3版本 (建议管理员新建一个分支) (#87)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* 移除与扩展无关的server文件

* 去除普通用户无关的测试脚本以及服务端搭建脚本

* maxcdn.bootstrapcdn.com 替换为  lib.baomitu.com ;新增 code.jquery.com 域名下的 jquery 替换 (#89)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* 移除与扩展无关的server文件

* 去除普通用户无关的测试脚本以及服务端搭建脚本

* 修改maxcdn.bootstrapcdn.com替换地址

* 替换code.jquery.com 为 ajax.aspnetcdn.com

* code.jquery.com 地址替换

* 1、增加域名替换白名单机制;2、两种地址替换方法,依靠优先级混合使用;3新增code.jquery.com域名下jquery 替换

* delete ytb

* 新增高级玩法

* 新增test service-worker

* change changelog

* add replace jquery-ui

* fix(doc): 更新文档中的安装目录 extension

#91

* Upgrade bpp to v2 (#90)

* 1、屏蔽 content-security-policy功能,新增4个屏蔽选项;2、新增 移除CSP的请求地址 githubusercontent.com;3、test 环境 新增功能;4、test 环境新增 PJAX报错解决办法 (#93)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* 移除与扩展无关的server文件

* 去除普通用户无关的测试脚本以及服务端搭建脚本

* 修改maxcdn.bootstrapcdn.com替换地址

* 替换code.jquery.com 为 ajax.aspnetcdn.com

* code.jquery.com 地址替换

* 1、增加域名替换白名单机制;2、两种地址替换方法,依靠优先级混合使用;3新增code.jquery.com域名下jquery 替换

* delete ytb

* 新增高级玩法

* 新增test service-worker

* change changelog

* add replace jquery-ui

* test sw.js

* 增加cdnjs.cloudflare.com替换为cdnjs.loli.net

* add opensource.google url replace

* remove githubusercontent.com content-security-policy

* 新增CSP 4个屏蔽选项

* 解决冲突

* 解决冲突

* 解决冲突

* 解决冲突

* add docker run nginx server

* 补上80端口配置

* 解决冲突4

* 新增新增  替换规则 ,默认未启用

* remove manifesst rule ruleset_cdn_cloudflare_1

* 修改注释

* change test enviroment README.md

* 1、修复 www.google.com/recaptcha/ 无法显示问题 ;2、修复pub.dev`域名下`fonts.googleapis.com`无法地址重定向 (#94)

* add func remove CSP

* 新增参考文档

* 添加测试用例

* 添加替换地址为指定服务地址功能,用于查看chromium源码

* add docker run nginx server

* 补上80端口配置

* add opensource.goole url

* add cs.opensource.google  url

* 使用自己架设的 nginx服务地址替换CDN地址

* change CSP variable name

* 添加固定替换CDN地址方法

* 替换指定数目的域名

* 添加测试用例

* 优化nginx 配置

* 优化nginx 配置二

* 优化nginx 配置三

* 优化nginx 配置增加简单权限验证阻止滥用

* 优化nginx 配置五

* 添加测试演示用例

* 添加测试演示用例

* 修改动态地址替换注释

* 修改错误的单词

* 移除与扩展无关的server文件

* 去除普通用户无关的测试脚本以及服务端搭建脚本

* 修改maxcdn.bootstrapcdn.com替换地址

* 替换code.jquery.com 为 ajax.aspnetcdn.com

* code.jquery.com 地址替换

* 1、增加域名替换白名单机制;2、两种地址替换方法,依靠优先级混合使用;3新增code.jquery.com域名下jquery 替换

* delete ytb

* 新增高级玩法

* 新增test service-worker

* change changelog

* add replace jquery-ui

* test sw.js

* 增加cdnjs.cloudflare.com替换为cdnjs.loli.net

* add opensource.google url replace

* remove githubusercontent.com content-security-policy

* 新增CSP 4个屏蔽选项

* 解决冲突

* 解决冲突

* 解决冲突

* 解决冲突

* add docker run nginx server

* 补上80端口配置

* 解决冲突4

* 新增新增  替换规则 ,默认未启用

* remove manifesst rule ruleset_cdn_cloudflare_1

* 修改注释

* change test enviroment README.md

* 修改test例子说明文档

* 修复 recaptcha 无法显示问题

* add test example README.md

* 修复  无法地址重定向

* 修改READM.md 描述

* 修改READM.md 描述

* 修改READM.md 描述

* cdn.jsdelivr.net replace to fastly.jsdelivr.net  (#96)

* cdn.jsdelivr.net replace fastly.jsdelivr.net

* cdn.jsdelivr.net replace

* 新增cdn.jsdelivr.net 地址替换

* add gitignore

* chang comment

* chang comment

* chang comment

* chang comment

* chang comment

* add 国内镜像 克隆 链接

* add emoji point_up

* add emoji point_up

* 新增 通过国内镜像 克隆本项目源代码

* 参考文档 extensions declare_permissions

* change comment

* change comment

* change comment

* 重新启用对firefox 的支持和衍生新仓库

* 重新启用对firefox 的支持和衍生新仓库extension-v3-test (#97)

* 重新启用对firefox 的支持和衍生新仓库

* change log

* change log

* 移除的目录衍生新仓库

* fix v2 load icons error

* comment remove 移除 Content-Security-Policy

* use 'actions/checkout@v3' (#99)

* 新增 高阶定制玩法 辅助工具 新增 扩展程序选项 使用 prettier 格式化代码

* change options_ui

* test update-auth.sh

* save update-domain.sh changed

* save change

* fix error

* fix error

* add public static library

* fix error

* 修改打包程序,打包时去除无用文件

* fix test/READM.md test

* change v2 version

* change auto deploy.yaml setup

* change release-archive.sh

* 扩展选项:添加规则功能暂时屏蔽

* 新增 扩展程序选项雏形、格式化代码、新增高阶定制玩法辅助工具、新增自动化测试脚本 (#100)

* 重新启用对firefox 的支持和衍生新仓库

* 新增 高阶定制玩法 辅助工具 新增 扩展程序选项 使用 prettier 格式化代码

* change options_ui

* test update-auth.sh

* save update-domain.sh changed

* save change

* fix error

* fix error

* add public static library

* fix error

* 修改打包程序,打包时去除无用文件

* fix test/READM.md test

* change v2 version

* change auto deploy.yaml setup

* change release-archive.sh

* 扩展选项:添加规则功能暂时屏蔽

* 完善扩展选项页

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 扩展选项页完善-第二版 (#102)

* 重新启用对firefox 的支持和衍生新仓库

* 新增 高阶定制玩法 辅助工具 新增 扩展程序选项 使用 prettier 格式化代码

* change options_ui

* test update-auth.sh

* save update-domain.sh changed

* save change

* fix error

* fix error

* add public static library

* fix error

* 修改打包程序,打包时去除无用文件

* fix test/READM.md test

* change v2 version

* change auto deploy.yaml setup

* change release-archive.sh

* 扩展选项:添加规则功能暂时屏蔽

* 完善扩展选项页

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善自定义规则

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展选项页

* 完善扩展页选项

* 添加新工具

* change update libray

* change

* save

* add chrome action open extension option page

* lable pre add cursor

* format code

* fix bug

* del no use libray

* add force use bash

* change release-archive.sh

* 完善扩展选项页

* save change

* 新增默认隐藏显示演示例子

* 新增扩展选项功能截图

* 格式化代码

* upgrade mainfiest version

* add CHANGELOG

* fix word description error

* save changed

* fix merge code error

* remove third_party/frontend-utils/utils.js

* 添加CDN 静态资源加速服务库

* 添加匹配规则文档链接

* 关闭部分控制台输出

* 高级玩法新增修改请求头参数

* 完善manifest v2版本高级玩法

* 完善manifest v2版本高级玩法

* 完善manifest v2版本高级玩法

* 完善manifest v2版本高级玩法

* save 修改打包脚本

* 修改打包程序

* manifest add connect-src

* 新增cn.gravatar.com en.gravatar.com 地址重定向

* add CHANGELOG for 0.10.10

* change CHANGELOG for 0.10.10

* 修改描述

* 记录测试例子

* 记录测试例子

* 解决空错误

* 补上v2版本jquery的替换

* format code

* 去除可能存在隐患的屏蔽规则

* 添加下载扩展方式四

* 添加扩展下载方式

* 添加扩展下载方式

* save changed

* 不更新扩展的条件下,同步主仓库最新版规则

* 实现不更新扩展的前提下,实现同步主仓库静态规则

* change button describe

* change changelog

* 修改打包

* 解决多次同步静态规则,删除问题

* 调整顺序

* 使用chrome.runtime.getManifest()获取默认配置

* 稍微调整选项三button

* 稍微调整选项一描述

* 稍微调整选项三描述

* add repository mirror

* v2修改注释描述

* 提供web server 用于测试同步规则

* save changed

* save 解决谷歌翻译不能用的问题

* 添加下载浏览器应用商店扩展源码

* save changed

* 添加下载浏览器应用商店扩展源码

* 修改下载google-translate扩展的脚本

* 启动可以打开扩展商店

* 发现有UI的v2版本的扩展

* v2版本添加域名拦截功能

* 添加下载谷歌应用商店扩展,并保存crx文件

* 移除无效的CDN参考名单

* change test example url

* 为了解决虚拟机的XP系统,chromium 能49使用本插件,做相应的修改

* 让 XP 系统下的 chrome 49 能使用本扩展的V2版本

* 本扩展的 v2 版本支持 chromium 内核版本 49

* 让本扩展V2版本支持chrome 49版本

* 修复firefox浏览器里判断chrome_version错误

* 修改打包脚本,忽略test

* 添加v3版本更新规则的原理和选项页简要说明

* 添加v3版本更新规则的原理和选项页简要说明2

* 添加v3版本更新规则的原理和选项页简要说明2

* 添加v3版本更新规则的原理和选项页简要说明4

* 添加v3版本更新规则的原理和选项页简要说明5

* 添加v3版本更新规则的原理和选项页简要说明5

* 修改函数用法例子

* 添加拖拽上传文件

* 限制拖拽上传文件类型

* 修改选项页注释

* 修改打开chromium 启动脚本

* new changelog

* update mainifest version to 0.10.14

* 缩小规则匹配场景

* 缩小部分规则匹配场景

* 添加候选资源

* 添加候选规则

* add changed log

* 添加 静态默认规则候选项载入地址 README.md

* save changed

* 改变规则候选项描述

* 新增域名fonts.gstatic.com、fonts.googleapis.com 镜像地址

* 新增fonts.gstatic.com fonts.googleapis.com 镜像地址

* 添加code.jquery.com 规则候选项

* 添加code.jquery.com 规则候选项

* 正则匹配去掉scheme匹配,适应http协议

* 合并代码修正冲突

* 添加jquery替换规则

* 新增 code.jquery.com-ui.json 规则候选项

Signed-off-by: 迷渡 <[email protected]>
Co-authored-by: 迷渡 <[email protected]>
Co-authored-by: wuxianucw <[email protected]>
Co-authored-by: fjy202 <[email protected]>
Co-authored-by: Your Name <[email protected]>
Co-authored-by: YuxuanZuo <[email protected]>
Co-authored-by: Frost Wong <[email protected]>
Co-authored-by: Zhenbo Li <[email protected]>
Co-authored-by: amadman <[email protected]>
Co-authored-by: Andy <[email protected]>
Co-authored-by: JRoger <[email protected]>
Co-authored-by: mishi321 <[email protected]>
Co-authored-by: Stefan Aleksic <[email protected]>
Co-authored-by: Stefan Aleksic <[email protected]>
  • Loading branch information
14 people authored Nov 22, 2022
1 parent 0595b2b commit 8b42bed
Show file tree
Hide file tree
Showing 9 changed files with 452 additions and 31 deletions.
36 changes: 18 additions & 18 deletions extension/rules/mirrors/ajax.googleapis.com.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://use.sevencdn.com/gajax/\\1"
"regexSubstitution": "use.sevencdn.com/gajax/\\1"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -105,11 +105,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://mirrors.sustech.edu.cn/cdnjs/ajax/libs/\\1"
"regexSubstitution": "mirrors.sustech.edu.cn/cdnjs/ajax/libs/\\1"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -136,11 +136,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://gapis.geekzu.org/ajax/ajax/libs/\\1"
"regexSubstitution": "gapis.geekzu.org/ajax/ajax/libs/\\1"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -167,11 +167,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://lf9-cdn-tos.bytecdntp.com/cdn/expire-1-y/\\1/\\2/\\3"
"regexSubstitution": "lf9-cdn-tos.bytecdntp.com/cdn/expire-1-y/\\1/\\2/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/(.*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/(.*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -198,11 +198,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://lib.baomitu.com/\\1/\\2/\\3"
"regexSubstitution": "lib.baomitu.com/\\1/\\2/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/(.*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/(.*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -229,11 +229,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://fastly.jsdelivr.net/npm/\\1@\\2/dist/\\3"
"regexSubstitution": "fastly.jsdelivr.net/npm/\\1@\\2/dist/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -260,11 +260,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://unpkg.com/\\1@\\2/dist/\\3"
"regexSubstitution": "unpkg.com/\\1@\\2/dist/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -291,11 +291,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://cdnjs.cloudflare.com/ajax/libs/\\1/\\2/\\3"
"regexSubstitution": "cdnjs.cloudflare.com/ajax/libs/\\1/\\2/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand All @@ -322,11 +322,11 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://cdn.staticfile.org/\\1/\\2/\\3"
"regexSubstitution": "cdn.staticfile.org/\\1/\\2/\\3"
}
},
"condition": {
"regexFilter": "^https://ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"regexFilter": "ajax\\.googleapis\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"requestDomains": ["ajax.googleapis.com"],
"resourceTypes": [
"main_frame",
Expand Down
35 changes: 33 additions & 2 deletions extension/rules/mirrors/cdnjs.cloudflare.com.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,42 @@
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "https://mirrors.sustech.edu.cn/cdnjs/ajax/libs/\\1"
"regexSubstitution": "mirrors.sustech.edu.cn/cdnjs/ajax/libs/\\1"
}
},
"condition": {
"regexFilter": "^https://cdnjs\\.cloudflare\\.com/ajax/libs/(.*?)",
"regexFilter": "cdnjs\\.cloudflare\\.com/ajax/libs/(.*?)",
"requestDomains": ["cdnjs.cloudflare.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},
{
"id": 4,
"priority": 300,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "fastly.jsdelivr.net/npm/\\1@\\2/dist/\\3"
}
},
"condition": {
"regexFilter": "cdnjs\\.cloudflare\\.com/ajax/libs/(.*?)/([\\.|\\d]*?)/(.*?)",
"requestDomains": ["cdnjs.cloudflare.com"],
"resourceTypes": [
"main_frame",
Expand Down
189 changes: 189 additions & 0 deletions extension/rules/mirrors/code.jquery.com-ui.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,189 @@
[
{
"id": 1,
"priority": 1,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "ajax.aspnetcdn.com/ajax/jquery.ui/\\1/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},

{
"id": 2,
"priority": 1,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "lib.baomitu.com/jqueryui/\\1/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},
{
"id": 3,
"priority": 993,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "cdn.staticfile.org/jqueryui/\\1/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},
{
"id": 4,
"priority": 1,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "cdnjs.cloudflare.com/ajax/libs/jqueryui/\\1/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},
{
"id": 5,
"priority": 1,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "fastly.jsdelivr.net/npm/jquery-ui@\\1/dist/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
},
{
"id": 5,
"priority": 1,
"action": {
"type": "redirect",
"redirect": {
"regexSubstitution": "lf3-cdn-tos.bytecdntp.com/cdn/expire-1-y/jqueryui/\\1/\\2"
}
},
"condition": {
"regexFilter": "code\\.jquery\\.com/ui/(\\d{1,4}\\.\\d{1,4}\\.\\d{1,4})/(.*?)",
"requestDomains": ["code.jquery.com"],
"resourceTypes": [
"main_frame",
"sub_frame",
"stylesheet",
"script",
"image",
"font",
"object",
"xmlhttprequest",
"ping",
"csp_report",
"media",
"websocket",
"webtransport",
"webbundle",
"other"
]
}
}
]
Loading

0 comments on commit 8b42bed

Please sign in to comment.