mirror of
https://github.com/github/codeql.git
synced 2026-04-27 09:45:15 +02:00
Do not use variadic sink fn in tests
This commit is contained in:
@@ -14,10 +14,8 @@ func UntrustedSources_ClevergoTechClevergoV052() {
|
||||
{
|
||||
var receiverContext656 clevergo.Context
|
||||
resultUsername414, resultPassword518, _ := receiverContext656.BasicAuth()
|
||||
sink(
|
||||
resultUsername414, // $ untrustedFlowSource
|
||||
resultPassword518, // $ untrustedFlowSource
|
||||
)
|
||||
sink(resultUsername414) // $ untrustedFlowSource
|
||||
sink(resultPassword518) // $ untrustedFlowSource
|
||||
}
|
||||
// func (*Context).Decode(v interface{}) (err error)
|
||||
{
|
||||
@@ -102,10 +100,8 @@ func UntrustedSources_ClevergoTechClevergoV052() {
|
||||
// Untrusted flow sources from clevergo.tech/clevergo.Param struct fields.
|
||||
{
|
||||
structParam246 := new(clevergo.Param)
|
||||
sink(
|
||||
structParam246.Key, // $ untrustedFlowSource
|
||||
structParam246.Value, // $ untrustedFlowSource
|
||||
)
|
||||
sink(structParam246.Key) // $ untrustedFlowSource
|
||||
sink(structParam246.Value) // $ untrustedFlowSource
|
||||
}
|
||||
}
|
||||
// Untrusted flow sources from types.
|
||||
|
||||
@@ -7,6 +7,6 @@ func source() interface{} {
|
||||
return nil
|
||||
}
|
||||
|
||||
func sink(v ...interface{}) {}
|
||||
func sink(v interface{}) {}
|
||||
|
||||
func link(from interface{}, into interface{}) {}
|
||||
|
||||
@@ -121,13 +121,11 @@ func UntrustedFlowSources_GithubComGofiberFiberV1146() {
|
||||
// Untrusted flow sources from github.com/gofiber/fiber.Cookie struct fields.
|
||||
{
|
||||
structCookie322 := new(fiber.Cookie)
|
||||
sink(
|
||||
structCookie322.Domain, // $ untrustedFlowSource
|
||||
structCookie322.Name, // $ untrustedFlowSource
|
||||
structCookie322.Path, // $ untrustedFlowSource
|
||||
structCookie322.SameSite, // $ untrustedFlowSource
|
||||
structCookie322.Value, // $ untrustedFlowSource
|
||||
)
|
||||
sink(structCookie322.Domain) // $ untrustedFlowSource
|
||||
sink(structCookie322.Name) // $ untrustedFlowSource
|
||||
sink(structCookie322.Path) // $ untrustedFlowSource
|
||||
sink(structCookie322.SameSite) // $ untrustedFlowSource
|
||||
sink(structCookie322.Value) // $ untrustedFlowSource
|
||||
}
|
||||
// Untrusted flow sources from github.com/gofiber/fiber.Error struct fields.
|
||||
{
|
||||
|
||||
@@ -7,6 +7,6 @@ func source() interface{} {
|
||||
return nil
|
||||
}
|
||||
|
||||
func sink(v ...interface{}) {}
|
||||
func sink(v interface{}) {}
|
||||
|
||||
func link(from interface{}, into interface{}) {}
|
||||
|
||||
Reference in New Issue
Block a user