Skip to content

Conversation

@alexeykiselev
Copy link
Collaborator

No description provided.

@alexeykiselev alexeykiselev added enhancement New feature or request wip This is a WIP, should not be merged right away do not merge The PR is not ready to be merged labels Jan 19, 2026
// The peer was not found in the larges group, time to change the peer.
// Select the random peer from the group and return it along with a new score value.
i := rand.IntN(len(g.peers)) // #nosec: it's ok to use math/rand/v2 here
i := rand.IntN(len(g.peers)) //nolint: gosec // it's ok to use math/rand/v2 here.

Check failure

Code scanning / gosec

Use of weak random number generator (math/rand or math/rand/v2 instead of crypto/rand) Error

Use of weak random number generator (math/rand or math/rand/v2 instead of crypto/rand)
return PeerInfo{}, err
}
n := rand.IntN(len(ips)) // #nosec: it's ok to use math/rand/v2 here
n := rand.IntN(len(ips)) //nolint: gosec // it's ok to use math/rand/v2 here.

Check failure

Code scanning / gosec

Use of weak random number generator (math/rand or math/rand/v2 instead of crypto/rand) Error

Use of weak random number generator (math/rand or math/rand/v2 instead of crypto/rand)
Moved TODOs from error handling blocks whether possible without loosing context.
Added suppression comments for test data that looks like telegram bot API keys or
AWS access tokens or generic API keys.
Call to time.After replaced with single Timer in session's keepAliveLoop function.
Added more suppression comments for API keys lookalike data.
Comment on lines +23 to +24
itests/config/template.conf

Check warning

Code scanning / Semgrep OSS

Semgrep Finding: generic.ci.audit.changed-semgrepignore.changed-semgrepignore Warning

itests/config/template.conf has been added to the .semgrepignore list of ignored paths. Someone from app-sec may want to audit these changes.
Comment on lines +26 to +27
**/*.pb.go
**/*.gen.go

Check warning

Code scanning / Semgrep OSS

Semgrep Finding: generic.ci.audit.changed-semgrepignore.changed-semgrepignore Warning

**/*.pb.go has been added to the .semgrepignore list of ignored paths. Someone from app-sec may want to audit these changes.

# Ignore generated protobuf files
**/*.pb.go
**/*.gen.go

Check warning

Code scanning / Semgrep OSS

Semgrep Finding: generic.ci.audit.changed-semgrepignore.changed-semgrepignore Warning

**/*.gen.go has been added to the .semgrepignore list of ignored paths. Someone from app-sec may want to audit these changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do not merge The PR is not ready to be merged enhancement New feature or request wip This is a WIP, should not be merged right away

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants