
Security News
Official Go SDK for MCP in Development, Stable Release Expected in August
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.
用 asyncio 重写 shadowsocks
pip install aioshadowsocks
aioshadowsocks 将json作为配置文件, 会读取当前目录下 userconfigs.json
作为默认的配置文件
{
"users": [
{
"user_id": 1,
"port": 2345,
"method": "none",
"password": "hellotheworld1",
"transfer": 104857600,
"speed_limit": 0
},
{
"user_id": 2,
"port": 2346,
"method": "chacha20-ietf-poly1305",
"password": "hellotheworld2",
"transfer": 104857600,
"speed_limit": 384000
}
]
}
同时也支持从http服务器读取配置文件,这时需要注入环境变量 SS_API_ENDPOINT
作为读取配置的api地址
export SS_API_ENDPOINT="https://xxx/com"
aioss run_ss_server
curl -sSL https://get.docker.com/ | sh
sudo curl -L "https://github.com/docker/compose/releases/download/1.23.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose up
主要想通过这个项目的推进来深入了解 asyncio
另外我的一个项目: django-sspanel 依赖 shadowsocksr
但该项目已经停止开发了,所以决定重新造个轮子
Shadowsocks本身是一个IO密集行的应用,但是由于加入了AEAD加密,使得SS本身变成了CPU密集行的应用 而Python本身是不太适合CPU密集的场景的,所以在AEAD模式中的表现不佳 PS: 当然,其实是我代码写的烂,python不背锅
syntax = "proto3";
package aioshadowsocks;
// REQ
message UserIdReq { int32 user_id = 1; }
message PortReq { int32 port = 1; }
message UserReq {
int32 user_id = 1;
int32 port = 2;
string method = 3;
string password = 4;
bool enable = 5;
}
// RES
message Empty {}
message User {
int32 user_id = 1;
int32 port = 2;
string method = 3;
string password = 4;
bool enable = 5;
int32 speed_limit = 6;
int32 access_order = 7;
bool need_sync = 8;
repeated string ip_list = 9;
int32 tcp_conn_num = 10;
int64 upload_traffic = 11;
int64 download_traffic = 12;
}
// service
service ss {
rpc CreateUser(UserReq) returns (User) {}
rpc UpdateUser(UserReq) returns (User) {}
rpc GetUser(UserIdReq) returns (User) {}
rpc DeleteUser(UserIdReq) returns (Empty) {}
}
FAQs
shadowsocks build with asyncio , also support many user in one port
We found that aioshadowsocks demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.
Security News
New research reveals that LLMs often fake understanding, passing benchmarks but failing to apply concepts or stay internally consistent.
Security News
Django has updated its security policies to reject AI-generated vulnerability reports that include fabricated or unverifiable content.