Skip to content

sunowsir/DirectPath

Repository files navigation

DirectPath

eBPF学习项目:利用ebpf实现国内IP绕过openclash实现快速转发

部署方法

  1. 解压openwrt编译好的llvm工具链:llvm-bpf-21.1.6.Linux-x86_64
  2. 将代码tc_direct_path.c和编译脚本build.sh拷贝到工具链目录中llvm-bpf-21.1.6.Linux-x86_64/llvm-bpf/
  3. 执行编译脚本build.sh
  4. 拷贝生成的tc_direct_path.o到openwrt设备上
  5. 拷贝其他脚本cleanup_env.shdeploy_direct_path.sh以及load_china_ip.sh等到openwrt设备上与tc_direct_path.o同目录
  6. 部署执行deploy_direct_path.sh,然后载入国内域名执行load_china_ip.sh

恢复环境

  1. 如需恢复环境执行cleanup_env.sh

调试信息

  1. 查看调试信息可在openwrt设备上执行:cat /sys/kernel/debug/tracing/trace_pipe

缓存

  1. 查看缓存利用率,执行 check_cache.sh

About

eBPF学习项目:利用ebpf实现国内IP绕过openclash实现快速转发

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published