https://github.com/cdpdriver/kdriver-proxy
A lightweight SOCKS5 proxy server written in pure Kotlin. It allows you to create local SOCKS5 proxy endpoints that forward traffic through a remote HTTPS proxy with optional authentication.
https://github.com/cdpdriver/kdriver-proxy
http kotlin proxy sock5 sock5-proxy-server
Last synced: 2 days ago
JSON representation
A lightweight SOCKS5 proxy server written in pure Kotlin. It allows you to create local SOCKS5 proxy endpoints that forward traffic through a remote HTTPS proxy with optional authentication.
- Host: GitHub
- URL: https://github.com/cdpdriver/kdriver-proxy
- Owner: cdpdriver
- License: apache-2.0
- Created: 2025-06-01T19:58:08.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-11-09T09:37:11.000Z (3 months ago)
- Last Synced: 2025-11-09T11:27:26.813Z (3 months ago)
- Topics: http, kotlin, proxy, sock5, sock5-proxy-server
- Language: Kotlin
- Homepage:
- Size: 74.2 KB
- Stars: 3
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# kdriver-proxy
[](LICENSE)
[](https://klibs.io/project/cdpdriver/kdriver-proxy)
[]()
[]()
[](https://codecov.io/github/cdpdriver/kdriver-proxy)
[](https://www.codefactor.io/repository/github/cdpdriver/kdriver-proxy)
[](https://www.codetriage.com/cdpdriver/kdriver-proxy)
A lightweight SOCKS5 proxy server written in pure Kotlin. It allows you to create local SOCKS5
proxy endpoints that forward traffic through a remote HTTPS proxy with optional authentication.
Ideal for Kotlin applications needing dynamic local proxies without relying on external binaries
like [Gost](https://github.com/go-gost/gost), especially on platforms like Windows.
It's perfect for use with [KDriver](https://github.com/cdpdriver/kdriver).
## ๐ฆ Installation
Add the dependency to your `build.gradle.kts`:
```kotlin
dependencies {
implementation("dev.kdriver:proxy:0.1.0")
}
```
## ๐ Features
* Start a local SOCKS5 proxy on any port
* Forward all traffic through a remote HTTPS proxy (with optional auth)
* Run multiple proxies in parallel
* Fully coroutine-based (non-blocking)
* Pure Kotlin (JVM)
## ๐งช Usage
### Start a Proxy
```kotlin
val startUseCase = StartLocalProxyUseCase()
startUseCase(1080, Proxy(URI("https://your-remote-proxy.com:443"), "yourUsername", "yourPassword"))
```
Now you can connect to: `socks5://localhost:1080`
Your traffic will go through the remote proxy with authentication.
### Stop a Proxy
```kotlin
val stopUseCase = StopLocalProxyUseCase()
stopUseCase(1080)
```