Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linter: gosec, Rule: G504 - Import blocklist: net/http/cgi. Should we enable it? #12953

Closed
zak-pawel opened this issue Mar 26, 2023 · 3 comments
Labels

Comments

@zak-pawel
Copy link
Collaborator

Use Case

This issue starts discussion about enabling:

Rule is mapped to CWE-327: Use of a Broken or Risky Cryptographic Algorithm.

Expected behavior

Decision if rule should be enabled or not.

Actual behavior

For this rule following findings were found in current code:

plugins/inputs/phpfpm/child.go:15:2  gosec  G504: Blocklisted import net/http/cgi: Go versions < 1.6.3 are vulnerable to Httpoxy attack: (CVE-2016-5386)

Additional info

For this rule no additional configuration can be provided.

@zak-pawel zak-pawel changed the title Linter: gosec, Rule: G504- Import blocklist: net/http/cgi. Should we enable it? Linter: gosec, Rule: G504 - Import blocklist: net/http/cgi. Should we enable it? Mar 26, 2023
@powersj
Copy link
Contributor

powersj commented Mar 27, 2023

+1

@srebhan
Copy link
Member

srebhan commented Apr 3, 2023

No opinion on this one. Especially due to the fact that only ancient go-versions are affected.

@zak-pawel
Copy link
Collaborator Author

@srebhan Right!

Bug was fixed for in Go 1.6.3 and Go 1.7rc2:
https://groups.google.com/g/golang-announce/c/7jZDOQ8f8tM/m/eWRWHnc8CgAJ

Since Telegraf requires Go version >= 1.20, I believe we don't want to enable this one.
Closing as not planned.

(similar case as for #12900)

@zak-pawel zak-pawel closed this as not planned Won't fix, can't repro, duplicate, stale Apr 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants