github.com/HXSecurity/DongTai-agent-go@v0.4.2/core/base/regexpRegexpReplaceAllString/replacement.go (about)

     1  package regexpRegexpReplaceAllString
     2  
     3  import (
     4  	"github.com/HXSecurity/DongTai-agent-go/model/request"
     5  	"regexp"
     6  )
     7  
     8  func ReplaceAllString(re *regexp.Regexp, src, repl string) string {
     9  	s := ReplaceAllStringT(re, src, repl)
    10  	request.FmtHookPool(request.PoolReq{
    11  		Args:            request.Collect(src, repl),
    12  		Reqs:            request.Collect(s),
    13  		Source:          false,
    14  		OriginClassName: "regexp.(*Regexp)",
    15  		MethodName:      "ReplaceAllString",
    16  		ClassName:       "regexp.(*Regexp)",
    17  	})
    18  	return s
    19  }
    20  
    21  func ReplaceAllStringT(re *regexp.Regexp, src, repl string) string {
    22  	return ""
    23  }