AdLuoboyunSign up and get 1 GB of trial traffic, valid 24 hours, works with Clash / MihomoAlipay · WeChat · cryptoSign upAdLuoboyun: 1 GB trial on sign-upValid 24 hours · Alipay / WeChat / cryptoSign up
hiddify.isapp handbook

Latest stablev5.9.15

Blog Privacy

How one local port gives a VPN away

In 2026 it was shown that apps can scan local proxy ports to detect and slip past a VPN. How it works, which versions, and which switch to check.

The door is locked; check the small window beside it
The door is locked; check the small window beside it iMahesh, CC BY-SA 4.0

Per-app routing sends banks and shops over the local network, so they should not know about your proxy. Issue 2120 of 2026 pointed out that it is not that simple.

Per-app routing opens a separate door for some apps. But there may be a small unlocked window through which any app can feel where your exit is. This is about closing it.

Where the problem was

Besides the VPN, Hiddify opens a local proxy port for programs that only understand proxies. In older versions the port stayed open in VPN mode, without a password.

Any app on the same device could therefore:

  1. Try the ports of 127.0.0.1 one by one.
  2. Send a request through the one that answers.
  3. Read which country it came from, and with it the exit IP.

Apps excluded from the VPN could do it too, even those in Android's private space. The report says companies in Russia were told to find VPN servers this way and add them to block lists.

Normal appBypassed appVPN tunnelLocal portExit address
An app outside the VPN can still touch the local port
A window left open at night: an open local port is visible to every app on the device
A window left open at night: an open local port is visible to every app on the device James Ryen, CC BY 3.0

The default today

The maintainers replied that in the new version the port is optional in VPN mode. The 5.9 docs are more precise: it is closed in VPN mode, and those who need it turn on Keep open in VPN mode, with Require password beside it.

What to check

WhereAdvice
Settings → About5.9.15 or later
Inbound → Keep open in VPN modeOff
Inbound → Require passwordOn, if the port must be open
Quick settings → Connection sharingOff when unused; the sharing port can be scanned too
Service modeIn system proxy mode the port must be open; use VPN if that matters
A keyhole: the issue is not the door but who can look from inside
A keyhole: the issue is not the door but who can look from inside alicia rae from Pittsburgh, USA, CC BY-SA 2.0

Not only Hiddify

Every client with an open local proxy port shares this, including the default mixed port of Clash apps. Checking the port beats changing apps.

Is it open on mine

In VPN mode, put a terminal app into the bypass list:

Terminal on the phone, port as in settings
curl -x socks5h://127.0.0.1:12334 https://api.ipify.org
curl -x http://127.0.0.1:12334 https://api.ipify.org

The proxy's IP means open, refused means closed. Try 12334, 2334, 7890, 10808 and 1080. On computers:

Windows and macOS
netstat -ano | findstr LISTENING | findstr 127.0.0.1
lsof -nP -iTCP -sTCP:LISTEN | grep 127.0.0.1

Is a password enough

It keeps the exit secret, but the way it refuses still shows that a proxy is there. Close it if you can; a password only if you must.

Other signs

SignCan it be hidden
The system reports a VPNNo
An adapter named tun0No
Local proxy portYes
Time zone, language, SIM countryThey may not match the exit
DNS serverBypassed apps use the local one

Closing the port protects your exit IP, not the fact that you use a VPN.

Sharing is a window too

It listens on every adapter: anyone in the same Wi-Fi can use it. Off in public places, with a password at home.

Five minutes

  1. Version5.9.15 or later
  2. Service modeVPN
  3. Inboundkeep open = off, password = on
  4. Connection sharingOff when unused
  5. Test with the commandRefused
Check

Other clients

Clash-type: remove mixed-port, socks-port and port or set 0, only TUN; a secret for the control port. v2rayNG: turn the local proxy off, or a random port with authentication. sing-box: no mixed inbound.

I am the only user of my phone. Does it matter?

It depends on what is installed. If you must keep an app you do not trust, spend the minute.

What breaks when the port is closed?

Only programs you pointed at 127.0.0.1 by hand, such as some download managers and developer tools.

In system proxy mode?

It needs a port. Switch to VPN mode, or use a password and accept being noticed.

iPhone?

Apps are more isolated but loopback is shared, so the same. Off by default in new versions.

On a router?

Devices can scan it: password, and only the needed subnet.

Read next

See also

Entries on this page: is Hiddify safe, local port VPN leak, Hiddify port settings