Commit Graph
74 Commits
Author SHA1 Message Date
kulikov0 97c4d4b617 wire bx to other platforms 2026-09-11 14:39:57 +02:00
kulikov0 c3070210bc extend vp8 idle keepalive 2026-09-10 17:53:06 +02:00
kulikov0 cdf37997bf add custom resources support for bitrix creator 2026-09-09 21:48:52 +02:00
kulikov0 0c2f96addc bitrix dual track support 2026-09-09 17:40:05 +02:00
kulikov0 5690cf58a9 add bitrix support 2026-09-07 21:14:11 +02:00
Sbenazar 747f8f2312 stop the creator dialing private/internal destinations (#175)
connectTCP and dialCreatorUDP dialed whatever address came over the tunnel, so a joiner could make the creator reach its own LAN, loopback or the metadata ip at 169.254.169.254. dc mode had the same hole so the check lives in common now, all three paths call it. i block everything that isn't global unicast plus RFC1918 and cgnat, and ":80" too - empty host dials the local machine. names get checked inside Dialer.Control, per resolved address right before connect, so a re-resolve can't rebind past it and the dialer keeps its address fallback. with an upstream socks the name is resolved proxy-side, so there only the literal is mine to check. --allow-private-dst brings the old behaviour back.
2026-09-03 20:20:52 +02:00
kulikov0 1b506b9ee7 ios vpn app 2026-09-03 14:35:47 +02:00
kulikov0 b2cb0cbd42 cleanup dead code, update gitignore 2026-08-31 23:36:16 +02:00
kulikov0 da3bf64efc Merge branch 'main' of github.com:kulikov0/whitelist-bypass 2026-08-31 23:05:10 +02:00
kulikov0 7f603bdb24 add dual track support for tm 2026-08-31 22:58:17 +02:00
06866244cb Stop two idle tickers from spinning when there is nothing to send (#170)
* tunnel: stop spinning idle tickers in the vp8 writer and kcp update loop

Two hot loops woke the CPU constantly even with no traffic in the tunnel.

vp8tunnel writerLoop: sampleInterval is (1s / fps) / pacedBatch, so the
default fps=24 batch=30 gives 1.54ms - 648 ticks per second. With an empty
send queue the loop still woke on every tick just to bump idleTicks; a real
frame only goes out every keepaliveEvery ticks (~9/s), so ~639 wakeups per
second did nothing but keep the core out of deep sleep. With dualTrack there
are two such writers.

The loop now has two phases. While data flows nothing changes - the ticker
holds the frame pace and the traffic shape is identical. After 40 consecutive
empty ticks (~60ms) the ticker stops and the goroutine blocks on a select over
the send queue and a keepalive timer; incoming data returns it to pace at once.
Gaps shorter than 60ms are still ridden out on the ticker, so bursty transfers
do not flap between modes.

multi_track_kcp_tunnel updateLoop: same shape, a fixed 10ms ticker calling
Update 100 times a second regardless of traffic. While idle WaitSnd() is zero
across every session, so there is nothing to retransmit. The loop keeps 10ms
while segments are in flight and drops to 500ms once idle; sends and receives
nudge it back through a buffered channel, so the first packet after silence is
not delayed.

Measured with relay/benchidle (single track, 30s of pure idle):

                        before   after
  vp8 only              2.47 %   0.14 %
  vp8 + reliable KCP    2.95 %   0.15 %

The second row is the typical mobile client configuration.

* tunnel: add an idle emission-rate test

Measures both halves of what an idle tunnel costs: frames put on the wire per
second, and CPU burned by the writer. The frame rate is the number that matters
on a phone, since every frame is a packet that keeps the radio awake.

Single track, 30s idle window:

                              frames/s   cpu
  original                    7.9        2.155 %
  patched, same keepalive     7.7        0.154 %
  patched, keepalive 3-8s     0.2        0.007 %

The middle row is the limit of the loop fix on its own - CPU drops 14x while
the packet rate barely moves, because idle traffic is driven by the keepalive
period rather than by the ticker.

* avoid waking the kcp update loop on udp sends, cleanup

---------

Co-authored-by: jynk0 <106554291+Jynk0_btw@users.noreply.github.com>
Co-authored-by: kulikov0 <19497634+kulikov0@users.noreply.github.com>
2026-08-30 10:54:41 +02:00
kulikov0 d7b43786ca call DrainSenderRTCP in remaining carriers 2026-08-26 17:36:08 +02:00
kulikov0 5f4d0636fa bring kcp to tm, fix disconnections 2026-08-25 21:54:29 +02:00
kulikov0 0f9f908874 do inplace rewrite for dion cookies to fix docker's EBUSY 2026-07-31 15:32:30 +02:00
kulikov0 d470aaee9b bump to v0.3.8 2026-07-26 22:50:27 +02:00
kulikov0 2bad03c542 fix config ack, add randomness for keyframes and interframes 2026-07-26 20:30:48 +02:00
kulikov0 c36c561e35 add randomness to reconnections 2026-07-26 12:06:11 +02:00
kulikov0 6c732f34e3 dion: add email/password to fix cookie expiration 2026-07-26 11:21:17 +02:00
kulikov0 c89688afd2 close ws gracefully to avoid stale joiners 2026-07-25 18:14:21 +02:00
kulikov0 2dbc6ea1eb fix vpn notification, add more logs under debug flag 2026-07-25 12:23:41 +02:00
kulikov0 d66be97922 reduce logs for non-debug runtime 2026-07-25 09:15:10 +02:00
kulikov0 5103d87211 fix extra vk links disclosures 2026-07-24 15:37:02 +02:00
kulikov0 e6502a4ac4 migrate to vk.ru, temporarily disable dual vp8 for vk 2026-07-24 15:19:55 +02:00
kulikov0 f4714f93d6 return unreachable for ipv6 addresses to force ipv4 (#159) 2026-07-24 14:38:57 +02:00
kulikov0 a0229885ca bring kcp over vp8 (#160)
* bring kcp over vp8 for wbstream

* add multitrack kcp

* make kcp configurable param

* fix lingered kcp tunnel after switch into raw vp8 tunnel

* add reliable setting into ios and desktop joiners
2026-07-24 13:38:08 +02:00
kulikov0 99e5630f19 migrate VK signaling from ws to quic, update js bundles versions 2026-07-07 14:12:18 +02:00
kulikov0 78bb07f3ab bump to v0.3.7 2026-06-25 23:33:21 +02:00
kulikov0 c62aa89d4c update tm bundle fetch, fix desktop joiners 2026-06-25 22:34:30 +02:00
kulikov0 b454e6f6ee bump to v0.3.6 2026-06-10 17:16:12 +02:00
kulikov0 c6a688d8ab fix config race condition for wbstream in ios 2026-06-09 21:07:36 +02:00
kulikov0 f1ce863405 fight with topology changes at vk dual track 2026-06-09 16:27:17 +02:00
kulikov0 b40c59651a second track for vk 2026-06-06 21:02:40 +02:00
kulikov0 aef273556b bump to v0.3.5 2026-05-30 17:31:02 +02:00
kulikov0 94742960b7 refactor release files structure 2026-05-30 17:06:53 +02:00
kulikov0 000447b77c add upstream proxy support for creator 2026-05-30 15:39:12 +02:00
kulikov0 48dcb04c77 add --version flag 2026-05-30 13:22:10 +02:00
Morendaisandkulikov0 98525f333c обновление для приложения (#118)
* feat(android): rename to whitelistbypass and implement various UI, settings, and service enhancements

* fix(android): prevent crash on service stop

* Fix PORT_BUSY uncaught exception crash

* fix(android): improve app stability and fix port 1080 busy

* final fix

* sync with main branch

* fix(android): harden disconnect and session shutdown

* cleanup imports/callbacks

* more refactor

* edit profiles for a specific call via settings, resolve errors/issues during ide analysis

* fix callback in main fragment

---------

Co-authored-by: kulikov0 <19497634+kulikov0@users.noreply.github.com>
2026-05-29 21:20:50 +02:00
kulikov0 dfdc494340 update vk captcha proxy 2026-05-29 14:08:41 +02:00
kulikov0 c9538d4193 port pr 106 stateful udp socks5, dedup nack, drop send queue to 128 2026-05-28 20:43:32 +02:00
kulikov0 b730c63298 update vk bundle versions 2026-05-27 18:53:45 +02:00
kulikov0 3d7e96acad add local proxy addr configuration 2026-05-25 16:21:22 +02:00
kulikov0 5b98351e58 add dual track support for wbstream's vp8 2026-05-25 13:40:41 +02:00
kulikov0 62da620ec0 reconnect vk 2026-05-23 22:37:01 +02:00
kulikov0 28a87adc70 reconnect dion, fix dion cookies export 2026-05-23 21:51:01 +02:00
kulikov0 529072bcd1 reconnect telemost, reset wait counter in wbstream 2026-05-23 20:44:30 +02:00
kulikov0 cfb9b4c8f7 reconnect wbstream on a tunnel lost 2026-05-23 19:37:18 +02:00
kulikov0 c02843d6c3 reanimate wbstream dc mode 2026-05-21 22:29:20 +02:00
kulikov0 97560d4386 repair telemost in a dirty way 2026-05-17 22:47:31 +02:00
kulikov0 d7800f6328 remove wbstream dc support 2026-05-16 14:06:24 +02:00
kulikov0 cdfed572f0 add dion for desktop joiner 2026-05-16 09:35:21 +02:00