MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / detectXSSOne

Function detectXSSOne

internal/waf/injectionutils/utils_xss.go:84–97  ·  view source on GitHub ↗
(input string, isStrict bool)

Source from the content-addressed store, hash-verified

82}
83
84func detectXSSOne(input string, isStrict bool) bool {
85 if len(input) == 0 {
86 return false
87 }
88
89 var cInput = C.CString(input)
90 defer C.free(unsafe.Pointer(cInput))
91
92 var isStrictInt = 0
93 if isStrict {
94 isStrictInt = 1
95 }
96 return C.libinjection_xss(cInput, C.size_t(len(input)), C.int(isStrictInt)) == 1
97}

Callers 1

DetectXSSFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected