* Update Caddy to 1.0.1, and update import path This fix updates caddy to 1.0.1 and also updates the import path to github.com/caddyserver/caddy This fix fixes 2959 Signed-off-by: Yong Tang <yong.tang.github@outlook.com> * Also update plugin.cfg Signed-off-by: Yong Tang <yong.tang.github@outlook.com> * Update and bump zplugin.go Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
21 lines
366 B
Go
21 lines
366 B
Go
// +build fuzz
|
|
|
|
package rewrite
|
|
|
|
import (
|
|
"github.com/coredns/coredns/plugin/pkg/fuzz"
|
|
|
|
"github.com/caddyserver/caddy"
|
|
)
|
|
|
|
// Fuzz fuzzes rewrite.
|
|
func Fuzz(data []byte) int {
|
|
c := caddy.NewTestController("dns", "rewrite edns0 subnet set 24 56")
|
|
rules, err := rewriteParse(c)
|
|
if err != nil {
|
|
return 0
|
|
}
|
|
r := Rewrite{Rules: rules}
|
|
|
|
return fuzz.Do(r, data)
|
|
}
|