Skip to content

refraction-networking/dynamic-decoylist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Dynamic Decoy Lists Generator For TapDance

This program benches sub-par decoys for each country to lower the perceived failure rate.

Prerequisite

Installation & Usage

Clone the repo and its dependencies

go get -d -u -t github.com/refraction-networking/dynamic-decoylist/...

cd ${GOPATH:-~/go}/src/github.com/refraction-networking/dynamic-decoylist/runanalyser

go run main.go

How It Works

When running, the program will update the active decoy lists once per day at 5 minutes past midnight. The program fetches the newest decoy list and yesterday's log. Using the average failure rate for each country, the program then uses a state machine to decide the status of each decoy.

The penalty threshold is set as the average failure rate (#faileddecoys / (#failleddecoys + #newflows)) + const amnesty (default = 0.05)

  • If a decoy is not on parole and under the penalty threshold, the decoy remains on the active duty list.
  • If a decoy is on parole and under the penalty threshold, the decoy remains on the active duty list. Its future benching period is shortened by one day. If its future benching period is zero, it will be excluded from the bench list.
  • If a decoy is on parole and above the penalty threshold, the decoy gets benched for the future benching period. Its future benching period doubles.
  • If a decoy is not on parole and above the penalty threshold, the decoy gets benched for one day. Its future benching period is two days.
  • If a decoy is benched, Its remaining day is shortened by one day. If the days remaining is zero, the decoy is added to the active duty list.

The program left joins the up-to-date decoy list with decoys not benched for each country, and output the active duty list in /list/. All files in /list/ end in _Active.txt will be converted to .blob to be used as ClientConf.

TODO

License

MIT

About

Make TapDance Great Again

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published