Skip to content

Rule Reference

SEC662lintai-ai-securitythreat-reviewsecuritystablehookdeny

Hook script: setuid or setgid manipulation

Hook script manipulates setuid or setgid permissions

Public lane
threat-review
Category
security
Provider
lintai-ai-security
Scope
per-file
Surface
hook
Tier
stable
Severity
deny
Confidence
high
Detection
structural
Remediation
message only
How to read this lane

Explicit malicious, secret-bearing, or spyware-like review.

How to read this category

Strong exploit, secret, or unsafe-execution signal.

Activation Model

Preset Activation

These presets explain where this rule appears in the product experience.

Lifecycle

Stable Lifecycle Contract

State

stable

Graduation rationale

Matches explicit setuid or setgid chmod payloads in executable hook lines.

Deterministic signal basis

HookSignals shell-token analysis over non-comment hook lines for chmod octal modes with setuid/setgid bits or symbolic modes such as `u+s` and `g+s`.

Malicious corpus
hook-privilege-escalation-payloads
Benign corpus
cursor-plugin-clean-basic
structured evidence required remediation reviewed
Canonical note

Structural stable rule positioned as an explicit threat-review control: high-signal malicious, credential-bearing, or spyware-like behavior that stays opt-in rather than shaping the quiet default.

Nearby Signals

Related Rules

Why It Matters

Setting setuid or setgid bits can turn ordinary binaries into privilege-escalation paths.

What Triggers

SEC662 matches executable hook lines that run chmod with setuid/setgid octal modes such as 4755, 2755, 6755, or symbolic modes like u+s and g+s.

False Positives

System packaging scripts may use these bits intentionally, but shared hooks should not silently install privileged executables.

Remediation

Remove setuid/setgid manipulation from the hook or move it into a separately reviewed administrative provisioning path.