diff options
| author | Xe Iaso <me@xeiaso.net> | 2025-03-23 18:46:01 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-23 18:46:01 -0400 |
| commit | 725e11d3a643bd6e909aa00aa2297a34765b7bca (patch) | |
| tree | 1b85f32537e501e6e0ff7f1a2fb6e1add71eb0ea /lib/anubis.go | |
| parent | f462209b02cbb62864f5c4ccacd5a31cca5b138e (diff) | |
| download | anubis-725e11d3a643bd6e909aa00aa2297a34765b7bca.tar.xz anubis-725e11d3a643bd6e909aa00aa2297a34765b7bca.zip | |
lib: fix default difficulty (#96)
Before this did not respect the difficulty flag and instead used
difficulty 4. This has been fixed.
Signed-off-by: Xe Iaso <me@xeiaso.net>
Diffstat (limited to 'lib/anubis.go')
| -rw-r--r-- | lib/anubis.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/anubis.go b/lib/anubis.go index 5953a48..43993bb 100644 --- a/lib/anubis.go +++ b/lib/anubis.go @@ -498,8 +498,8 @@ func (s *Server) check(r *http.Request) (CheckResult, *policy.Bot, error) { return cr("default/allow", config.RuleAllow), &policy.Bot{ Challenge: &config.ChallengeRules{ - Difficulty: anubis.DefaultDifficulty, - ReportAs: anubis.DefaultDifficulty, + Difficulty: s.policy.DefaultDifficulty, + ReportAs: s.policy.DefaultDifficulty, Algorithm: config.AlgorithmFast, }, }, nil |
