codeaudit

package
v0.4.15 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 28, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package codeaudit is a light static analyzer (SAST-lite) over a target's source tree (Target.Repo). It flags risky code by pattern — weak cryptography, insecure randomness for security, dangerous execution sinks, and secrets written to logs. It reads files only: no network, no build, no execution. It detects risky patterns; it does not exploit them.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Checks

func Checks() []core.Check

Checks returns the static-analysis checks.

Types

type DangerousSink

type DangerousSink struct{}

func (DangerousSink) ASVS

func (DangerousSink) ASVS() []string

func (DangerousSink) Category

func (DangerousSink) Category() core.Category

func (DangerousSink) Description

func (DangerousSink) Description() string

func (DangerousSink) ID

func (DangerousSink) ID() string

func (DangerousSink) Mode

func (DangerousSink) Mode() core.Mode

func (DangerousSink) OWASP

func (DangerousSink) OWASP() []string

func (DangerousSink) Run

type InsecureRandom

type InsecureRandom struct{}

func (InsecureRandom) Category

func (InsecureRandom) Category() core.Category

func (InsecureRandom) Description

func (InsecureRandom) Description() string

func (InsecureRandom) ID

func (InsecureRandom) ID() string

func (InsecureRandom) Mode

func (InsecureRandom) Mode() core.Mode

func (InsecureRandom) OWASP

func (InsecureRandom) OWASP() []string

func (InsecureRandom) Run

type Obfuscation added in v0.4.14

type Obfuscation struct{}

Obfuscation flags two supply-chain tampering signals that show up when a repo's config or source is compromised: install/CI scripts that fetch and execute remote code, and obfuscated code that hides a payload (the pattern behind the event-stream, xz and many npm/pip backdoors). It reads files only.

func (Obfuscation) ASVS added in v0.4.14

func (Obfuscation) ASVS() []string

func (Obfuscation) Category added in v0.4.14

func (Obfuscation) Category() core.Category

func (Obfuscation) Description added in v0.4.14

func (Obfuscation) Description() string

func (Obfuscation) ID added in v0.4.14

func (Obfuscation) ID() string

func (Obfuscation) Mode added in v0.4.14

func (Obfuscation) Mode() core.Mode

func (Obfuscation) OWASP added in v0.4.14

func (Obfuscation) OWASP() []string

func (Obfuscation) Run added in v0.4.14

type SecretLogging

type SecretLogging struct{}

func (SecretLogging) ASVS

func (SecretLogging) ASVS() []string

func (SecretLogging) Category

func (SecretLogging) Category() core.Category

func (SecretLogging) Description

func (SecretLogging) Description() string

func (SecretLogging) ID

func (SecretLogging) ID() string

func (SecretLogging) Mode

func (SecretLogging) Mode() core.Mode

func (SecretLogging) OWASP

func (SecretLogging) OWASP() []string

func (SecretLogging) Run

type UnpinnedDeps

type UnpinnedDeps struct{}

UnpinnedDeps flags npm dependencies declared with a loose version range. This is dependency hygiene (a supply-chain risk), not a CVE scan — reachable-CVE detection (govulncheck/Trivy) is separate, future work.

func (UnpinnedDeps) ASVS

func (UnpinnedDeps) ASVS() []string

func (UnpinnedDeps) Category

func (UnpinnedDeps) Category() core.Category

func (UnpinnedDeps) Description

func (UnpinnedDeps) Description() string

func (UnpinnedDeps) ID

func (UnpinnedDeps) ID() string

func (UnpinnedDeps) Mode

func (UnpinnedDeps) Mode() core.Mode

func (UnpinnedDeps) OWASP

func (UnpinnedDeps) OWASP() []string

func (UnpinnedDeps) Run

type WeakCrypto

type WeakCrypto struct{}

func (WeakCrypto) ASVS

func (WeakCrypto) ASVS() []string

func (WeakCrypto) Category

func (WeakCrypto) Category() core.Category

func (WeakCrypto) Description

func (WeakCrypto) Description() string

func (WeakCrypto) ID

func (WeakCrypto) ID() string

func (WeakCrypto) Mode

func (WeakCrypto) Mode() core.Mode

func (WeakCrypto) OWASP

func (WeakCrypto) OWASP() []string

func (WeakCrypto) Run

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL