Skip to content

Rule Reference

SEC359lintai-ai-securitypreviewmarkdownwarn

Cursor rule: `alwaysApply` type

Cursor rule frontmatter `alwaysApply` must be boolean

Provider
lintai-ai-security
Surface
markdown
Scope
per_file
Tier
preview
Severity
warn
Confidence
high
Detection
structural
Remediation
message_only

Activation Model

Preset Membership

This rule is part of the builtin activation graph through these preset memberships.

Lifecycle

Preview Lifecycle Contract

State

preview_blocked

Promotion blocker

Cursor rule frontmatter shape mismatches are deterministic, but the first release stays guidance-only while ecosystem usefulness is measured.

Promotion requirements

Needs corpus-backed precision review, external usefulness evidence, and completed stable checklist metadata.

Canonical note

Structural preview rule; deterministic today, but the preview contract may still evolve.

Nearby Signals

Related Rules

Why It Matters

SEC359 flags Cursor rule markdown whose frontmatter sets alwaysApply to a non-boolean value.

This is useful because:

  • Cursor rules are configuration-bearing markdown, not free-form prose
  • non-boolean alwaysApply values are harder to reason about across tools and loaders
  • the failure mode is community-hostile: the rule looks configured, but may not behave consistently

What Triggers

This rule applies only to Cursor rule markdown surfaces such as .mdc and .cursorrules.

It triggers when:

  • parsed frontmatter contains alwaysApply
  • and the parsed value is not a boolean

Example that triggers:

yaml
---
alwaysApply: yes
---

Examples that stay clean:

yaml
---
alwaysApply: true
---
  • rules without alwaysApply
  • fixture-like paths under tests/, fixtures/, examples/, or samples/

False Positives

This rule stays Preview because some repos may still carry legacy or loosely typed Cursor rule examples. The signal is about deterministic config quality and interoperability, not about exploitability.

Remediation

Set alwaysApply to an explicit boolean:

yaml
---
alwaysApply: true
---

If the rule should not always apply, use false or remove the key and rely on the normal path-based scoping model.