Automate configuring Dev Proxy certificate on Linux
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
研究方向
先在 Linux 上重現文件中記載的 ./devproxy --install-cert --log-level trace 流程,並與 issue 中描述的 Windows 行為進行比較。檢查 --install-cert 進入點如何處理憑證信任,然後使用提供的 wget HTTPS 請求(不帶 --no-check-certificate)驗證是否完成。
由索引模型根據 Issue 內容生成。
描述
Description
Hey everyone,
I've been trying to get devproxy to work on Linux for HTTPS proxying, but I'm hitting a wall.
It works fine with HTTP, and on Windows, it's working as per the documentation.
However, when I switch to Linux, HTTPS isn't cooperating.
I even tried exporting the Windows certificate and adding it to the trusted root certificates on Linux, but no luck there.
I've checked the docs, but I can't seem to find a fix. Any help or advice would be greatly appreciated!
I tried on Ubuntu app (Windows 11 pro wsl2)
I tried on Ubuntu 18.04
I tried on a Docker container based on Ubuntu 22.04
Thanks!
Expected behaviour
The devproxy binary should register a root certificate when --install-cert is used
Actual behaviour
Any attempt to access a website through the proxy with HTTPS results with an error.
Steps to reproduce
Install dev proxy on a Linux (ubuntu) environment following documented instructions.
cd ~/devproxy
./devproxy --install-cert --log-level trace
Output is:
Loading plugin RetryAfterPlugin from: /home/patrick/devproxy/plugins/dev-proxy-plugins.dll
Loading plugin GenericRandomErrorPlugin from: /home/patrick/devproxy/plugins/dev-proxy-plugins.dll
8 error responses loaded from /home/patrick/devproxy/devproxy-errors.json
Listening on 127.0.0.1:8000...
WARNING: Configure your operating system to use this proxy's port and address [127.0.0.1:8000](http://127.0.0.1:8000/)
Press CTRL+C to stop Dev Proxy
Open another terminal and try this:
wget -e use_proxy=yes -e https_proxy=https://127.0.0.1:8000/ https://jsonplaceholder.typicode.com/posts
The output:
Connecting to 127.0.0.1:8000... connected.
ERROR: cannot verify [jsonplaceholder.typicode.com](http://jsonplaceholder.typicode.com/)'s certificate, issued by ‘CN=Dev Proxy CA’:
Unable to locally verify the issuer's authority.
To connect to [jsonplaceholder.typicode.com](http://jsonplaceholder.typicode.com/) insecurely, use `--no-check-certificate'.
If we follow recommendation and add --no-check-certificate, it works
request GET https://jsonplaceholder.typicode.com/posts
api ╭ Passed through
╰ GET https://jsonplaceholder.typicode.com/posts
Dev Proxy Version
0.15.0
Operating system (environment)
Linux
Shell
bash
Configuration file
{
"$schema": "https://raw.githubusercontent.com/microsoft/dev-proxy/main/schemas/v0.15.0/rc.schema.json",
"plugins": [
{
"name": "RetryAfterPlugin",
"enabled": true,
"pluginPath": "~appFolder/plugins/dev-proxy-plugins.dll"
},
{
"name": "GenericRandomErrorPlugin",
"enabled": true,
"pluginPath": "~appFolder/plugins/dev-proxy-plugins.dll",
"configSection": "genericRandomErrorPlugin"
}
],
"urlsToWatch": [
"https://jsonplaceholder.typicode.com/*"
],
"genericRandomErrorPlugin": {
"errorsFile": "devproxy-errors.json"
},
"rate": 50,
"labelMode": "text",
"logLevel": "information",
"newVersionNotification": "stable"
}
Additional Info
No response
- 主要語言
- C#
- 星號
- 832
- 分支
- 90
- 平均合併
- 17 小時 54 分鐘
- 30 天內合併 PR
- 47
環境準備
- 提供 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
dotnet/dev-proxy 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 85/100
維護者通常 1 天內回覆
-
waiting for response
難度 4/5 3-5 天 新手友好度 28/100
dotnet/dev-proxy#1914 · 2 則留言 ·
維護者通常 1 天內回覆
-
MockStdioResponsePlugin: @stdin.body.id placeholder fails to resolve when messages arrive back-to-back after an id-less message可能重新可做 @garrytrinder 於 87 天前認領,目前沒有進行中的 PR。 未關閉
dotnet/dev-proxy#1757 · 1 個 reaction · 已指派 2 人 ·
維護者通常 1 天內回覆
-
難度 4/5 3-5 天 新手友好度 55/100
維護者通常 1 天內回覆
相似的 Issue
-
type/automation type/tech-debt
難度 1/5 1 小時以內 新手友好度 72/100
維護者通常 1 天內回覆
-
no-stack-trace
難度 2/5 1-3 小時 新手友好度 83/100
維護者通常 1 天內回覆
-
enhancement
難度 2/5 1-3 小時 新手友好度 65/100
維護者通常 1 天內回覆
-
docs/external squad/utforming
難度 2/5 1-3 小時 新手友好度 75/100
Altinn/altinn-studio#21041 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
stryker-mutator/stryker-net#3892 ·
維護者通常 1 天內回覆