[GH-ISSUE #1879] Failed to intercept connections from kubectl command #1871

Open
opened 2026-03-03 19:55:06 +03:00 by kerem · 1 comment
Owner

Originally created by @NitroCao on GitHub (Dec 14, 2023).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/1879

Description

I want to intercept traffic generated by kubectl command but Proxyman doesn't work.

Steps to Reproduce

  • Intercept HTTPS traffic of kubectl command by adding kubectl app in Tools -> SSL Proxying List -> Include List.
  • Add client certificate and client key file in Certificate -> Add Custom Certificate.
  • Enable SOCKS Proxy in Proxyman.
  • Set HTTPS_PROXY environment variable in terminal.
  • Run command kubectl --insecure-skip-tls-verify=true get pods.
    CleanShot 2023-12-14 at 12 45 50@2x
    CleanShot 2023-12-14 at 12 46 22@2x

Current Behavior

kubectl command retries all the time.
CleanShot 2023-12-14 at 12 42 42@2x

CleanShot 2023-12-14 at 12 43 43@2x

BTW, if I edit and repeat the request, Proxyman fails with invalid host.

Expected Behavior

kubectl command works as usual.

Environment

  • App version: 4.15.0 (49600)
  • macOS version: 14.1.2 (23B92)
Originally created by @NitroCao on GitHub (Dec 14, 2023). Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/1879 ## Description <!--- Description for the bug? --> I want to intercept traffic generated by `kubectl` command but Proxyman doesn't work. ## Steps to Reproduce * Intercept HTTPS traffic of `kubectl` command by adding `kubectl` app in **Tools -> SSL Proxying List -> Include List**. * Add client certificate and client key file in **Certificate -> Add Custom Certificate**. * Enable SOCKS Proxy in Proxyman. * Set `HTTPS_PROXY` environment variable in terminal. * Run command `kubectl --insecure-skip-tls-verify=true get pods`. ![CleanShot 2023-12-14 at 12 45 50@2x](https://github.com/ProxymanApp/Proxyman/assets/17915615/1b699f53-9047-4735-98b3-d0164a0f182f) ![CleanShot 2023-12-14 at 12 46 22@2x](https://github.com/ProxymanApp/Proxyman/assets/17915615/65df3a78-8ee3-427d-ab7d-4e1fdbb8e154) ## Current Behavior kubectl command retries all the time. ![CleanShot 2023-12-14 at 12 42 42@2x](https://github.com/ProxymanApp/Proxyman/assets/17915615/d6cce3d8-dbf5-4616-abfd-c9afc67fed2e) ![CleanShot 2023-12-14 at 12 43 43@2x](https://github.com/ProxymanApp/Proxyman/assets/17915615/f4c96a7f-fe46-43fb-a690-dc3273700b09) BTW, if I edit and repeat the request, Proxyman fails with `invalid host`. <!--- What went wrong? --> ## Expected Behavior kubectl command works as usual. <!--- What should have happened? --> ## Environment - App version: 4.15.0 (49600) - macOS version: 14.1.2 (23B92)
Author
Owner

@kamontat commented on GitHub (Jul 9, 2024):

You need to set proxy-url on .kube/config too.

clusters:
- name: cluster-name
  cluster:
    proxy-url: http://localhost:9090

CleanShot 2024-07-09 at 10 57 47@2x

<!-- gh-comment-id:2216423886 --> @kamontat commented on GitHub (Jul 9, 2024): You need to set proxy-url on `.kube/config` too. ```yaml clusters: - name: cluster-name cluster: proxy-url: http://localhost:9090 ``` ![CleanShot 2024-07-09 at 10 57 47@2x](https://github.com/ProxymanApp/Proxyman/assets/14089557/72c977d7-2853-468a-ba70-470ab93c0528)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Proxyman#1871
No description provided.