add plugin system

This commit is contained in:
ginuerzh
2023-04-18 20:52:56 +08:00
parent 7576651a67
commit 32c8188351
48 changed files with 761 additions and 115 deletions

View File

@ -105,7 +105,7 @@ func (h *http3Handler) roundTrip(ctx context.Context, w http.ResponseWriter, req
w.Header().Set(k, h.md.header.Get(k))
}
if h.options.Bypass != nil && h.options.Bypass.Contains(addr) {
if h.options.Bypass != nil && h.options.Bypass.Contains(ctx, addr) {
w.WriteHeader(http.StatusForbidden)
log.Debug("bypass: ", addr)
return nil