Merge remote-tracking branch 'origin/master'
commit
3f2b0a8b3b
10
README.md
10
README.md
|
@ -256,6 +256,9 @@ networksetup -setwebproxy 'WiFi' 127.0.0.1 1181
|
||||||
|
|
||||||
### 3、浏览器打开提示证书不受信任
|
### 3、浏览器打开提示证书不受信任
|
||||||
|
|
||||||
|

|
||||||
|
一般是证书安装位置不对,重新安装证书后,重启浏览器
|
||||||
|
|
||||||
#### 3.1 windows: 请确认证书已正确安装在“信任的根证书颁发机构”下
|
#### 3.1 windows: 请确认证书已正确安装在“信任的根证书颁发机构”下
|
||||||
|
|
||||||
#### 3.2 mac: 请确认证书已经被安装并已经设置信任。
|
#### 3.2 mac: 请确认证书已经被安装并已经设置信任。
|
||||||
|
@ -268,12 +271,13 @@ networksetup -setwebproxy 'WiFi' 127.0.0.1 1181
|
||||||
> 4、勾选信任由此证书颁发机构来标识网站,确定即可
|
> 4、勾选信任由此证书颁发机构来标识网站,确定即可
|
||||||
|
|
||||||
### 4. 打开github显示连接超时
|
### 4. 打开github显示连接超时
|
||||||
```html
|
```html
|
||||||
DevSidecar Warning:
|
DevSidecar Warning:
|
||||||
Error: www.github.com:443, 代理请求超时
|
Error: www.github.com:443, 代理请求超时
|
||||||
```
|
```
|
||||||
如果是安全模式,则是因为不稳定导致的,等一会再刷新试试
|
1、检查测速界面github.com是否有ip ,如果没有ip,则可能是由于你的网络提供商封锁了dns服务商的ip(试试能否ping通:1.1.1.1 / 9.9.9.9 )
|
||||||
如果是增强模式,则是由于访问人数过多,正常现象
|
2、如果是安全模式,则是因为不稳定导致的,等一会再刷新试试
|
||||||
|
3、如果是增强模式,则是由于访问人数过多,正常现象
|
||||||
|
|
||||||
### 5、查看日志是否有报错
|
### 5、查看日志是否有报错
|
||||||
如果还是不行,请在下方加作者好友,将服务日志发送给作者进行分析
|
如果还是不行,请在下方加作者好友,将服务日志发送给作者进行分析
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
|
@ -14,5 +14,5 @@
|
||||||
"ignore": []
|
"ignore": []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"version": "1.7.2"
|
"version": "1.7.3"
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@docmirror/dev-sidecar",
|
"name": "@docmirror/dev-sidecar",
|
||||||
"version": "1.7.2",
|
"version": "1.7.3",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@docmirror/dev-sidecar",
|
"name": "@docmirror/dev-sidecar",
|
||||||
"version": "1.7.2",
|
"version": "1.7.3",
|
||||||
"description": "给开发者的加速代理工具",
|
"description": "给开发者的加速代理工具",
|
||||||
"main": "src/index.js",
|
"main": "src/index.js",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -17,7 +17,7 @@
|
||||||
"test": "mocha"
|
"test": "mocha"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docmirror/mitmproxy": "^1.7.2",
|
"@docmirror/mitmproxy": "^1.7.3",
|
||||||
"agentkeepalive": "^2.1.1",
|
"agentkeepalive": "^2.1.1",
|
||||||
"babel-preset-es2020": "^1.0.2",
|
"babel-preset-es2020": "^1.0.2",
|
||||||
"charset": "^1.0.0",
|
"charset": "^1.0.0",
|
||||||
|
|
|
@ -6,12 +6,18 @@
|
||||||
proxy: 'github.githubassets.com',
|
proxy: 'github.githubassets.com',
|
||||||
sni: 'baidu.com',
|
sni: 'baidu.com',
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"www.gstatic.com": {
|
||||||
|
"/recaptcha/.*": {
|
||||||
|
"proxy": "www.recaptcha.net"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
dns: {
|
dns: {
|
||||||
mapping: {
|
mapping: {
|
||||||
'*jetbrains.com': 'quad9',
|
'*jetbrains.com': 'quad9',
|
||||||
'*azureedge.net': 'quad9'
|
'*azureedge.net': 'quad9',
|
||||||
|
'*stackoverflow.com': 'quad9'
|
||||||
},
|
},
|
||||||
speedTest: {
|
speedTest: {
|
||||||
interval: 300000,
|
interval: 300000,
|
||||||
|
|
|
@ -17,7 +17,7 @@ module.exports = {
|
||||||
// 'cdn.cypress.io': [{ regexp: '/desktop/.*', proxy: 'http://npmmirror.com/mirrors/cypress/' }]
|
// 'cdn.cypress.io': [{ regexp: '/desktop/.*', proxy: 'http://npmmirror.com/mirrors/cypress/' }]
|
||||||
// },
|
// },
|
||||||
variables: {
|
variables: {
|
||||||
phantomjs_cdnurl: 'https://npmmirror.com/dist/phantomjs',
|
phantomjs_cdnurl: 'https://npmmirror.com/mirrors/phantomjs',
|
||||||
chromedriver_cdnurl: 'https://npmmirror.com/mirrors/chromedriver',
|
chromedriver_cdnurl: 'https://npmmirror.com/mirrors/chromedriver',
|
||||||
sass_binary_site: 'https://npmmirror.com/mirrors/node-sass',
|
sass_binary_site: 'https://npmmirror.com/mirrors/node-sass',
|
||||||
ELECTRON_MIRROR: 'https://npmmirror.com/mirrors/electron/',
|
ELECTRON_MIRROR: 'https://npmmirror.com/mirrors/electron/',
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@docmirror/dev-sidecar-gui",
|
"name": "@docmirror/dev-sidecar-gui",
|
||||||
"version": "1.7.2",
|
"version": "1.7.3",
|
||||||
"private": false,
|
"private": false,
|
||||||
"license": "MPL-2.0",
|
"license": "MPL-2.0",
|
||||||
"main": "background.js",
|
"main": "background.js",
|
||||||
|
@ -21,8 +21,8 @@
|
||||||
"name": "Greper"
|
"name": "Greper"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docmirror/dev-sidecar": "^1.7.2",
|
"@docmirror/dev-sidecar": "^1.7.3",
|
||||||
"@docmirror/mitmproxy": "^1.7.2",
|
"@docmirror/mitmproxy": "^1.7.3",
|
||||||
"adm-zip": "^0.5.5",
|
"adm-zip": "^0.5.5",
|
||||||
"ant-design-vue": "^1.6.5",
|
"ant-design-vue": "^1.6.5",
|
||||||
"compressing": "^1.5.1",
|
"compressing": "^1.5.1",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@docmirror/mitmproxy",
|
"name": "@docmirror/mitmproxy",
|
||||||
"version": "1.7.2",
|
"version": "1.7.3",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "src/index.js",
|
"main": "src/index.js",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
|
|
@ -36,8 +36,12 @@ module.exports = function createRequestHandler (createIntercepts, middlewares, e
|
||||||
if (interceptors == null) {
|
if (interceptors == null) {
|
||||||
interceptors = []
|
interceptors = []
|
||||||
}
|
}
|
||||||
const reqIncpts = interceptors.filter(item => { return item.requestIntercept != null })
|
const reqIncpts = interceptors.filter(item => {
|
||||||
const resIncpts = interceptors.filter(item => { return item.responseIntercept != null })
|
return item.requestIntercept != null
|
||||||
|
})
|
||||||
|
const resIncpts = interceptors.filter(item => {
|
||||||
|
return item.responseIntercept != null
|
||||||
|
})
|
||||||
|
|
||||||
const requestInterceptorPromise = () => {
|
const requestInterceptorPromise = () => {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
|
@ -131,12 +135,20 @@ module.exports = function createRequestHandler (createIntercepts, middlewares, e
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// rOptions.sigalgs = 'RSA-PSS+SHA256:RSA-PSS+SHA512:ECDSA+SHA256'
|
||||||
|
// rOptions.agent.options.sigalgs = rOptions.sigalgs
|
||||||
|
// rOptions.ciphers = 'TLS_CHACHA20_POLY1305_SHA256:TLS_AES_128_GCM_SHA256:TLS_AES_256_GCM_SHA384:DHE-RSA-AES128-SHA256:DHE-RSA-AES256-SHA384:DHE-RSA-AES256-SHA256:ECDHE-RSA-AES256-SHA256:HIGH'
|
||||||
|
// rOptions.agent.options.ciphers = rOptions.ciphers
|
||||||
|
// console.log('rOptions:', rOptions)
|
||||||
|
// console.log('agent:', rOptions.agent)
|
||||||
|
// console.log('agent.options:', rOptions.agent.options)
|
||||||
proxyReq = (rOptions.protocol === 'https:' ? https : http).request(rOptions, (proxyRes) => {
|
proxyReq = (rOptions.protocol === 'https:' ? https : http).request(rOptions, (proxyRes) => {
|
||||||
const end = new Date().getTime()
|
const end = new Date().getTime()
|
||||||
const cost = end - start
|
const cost = end - start
|
||||||
if (rOptions.protocol === 'https:') {
|
if (rOptions.protocol === 'https:') {
|
||||||
log.info('代理请求返回:', url, cost + 'ms')
|
log.info('代理请求返回:', url, cost + 'ms')
|
||||||
}
|
}
|
||||||
|
// console.log('request:', proxyReq, proxyReq.socket)
|
||||||
if (cost > MAX_SLOW_TIME) {
|
if (cost > MAX_SLOW_TIME) {
|
||||||
countSlow(isDnsIntercept, 'to slow ' + cost + 'ms')
|
countSlow(isDnsIntercept, 'to slow ' + cost + 'ms')
|
||||||
}
|
}
|
||||||
|
@ -243,7 +255,10 @@ module.exports = function createRequestHandler (createIntercepts, middlewares, e
|
||||||
body += append.body
|
body += append.body
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
InsertScriptMiddleware.responseInterceptor(req, res, proxyReq, proxyRes, ssl, next, { head, body })
|
InsertScriptMiddleware.responseInterceptor(req, res, proxyReq, proxyRes, ssl, next, {
|
||||||
|
head,
|
||||||
|
body
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
next()
|
next()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue