Skip to content

Commit

Permalink
Standardize verified TTL
Browse files Browse the repository at this point in the history
  • Loading branch information
joecorall authored Feb 20, 2025
1 parent 7c1b377 commit 136367d
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,12 @@ func New(ctx context.Context, next http.Handler, config *Config, name string) (h
}

bc := CaptchaProtect{
next: next,
name: name,
config: config,
rateCache: lru.New(expiration, 1*time.Minute),
botCache: lru.New(expiration, 1*time.Minute),
// allow good IPs to pass through for ten days
verifiedCache: lru.New(240*time.Hour, 1*time.Hour),
next: next,
name: name,
config: config,
rateCache: lru.New(expiration, 1*time.Minute),
botCache: lru.New(expiration, 1*time.Hour),
verifiedCache: lru.New(expiration, 1*time.Hour),
exemptIps: ips,
}

Expand Down

0 comments on commit 136367d

Please sign in to comment.