Back to skill

Security audit

Dharma-AI: Ancient Hindu Ethics for AI Agents

Security checks for vulnerabilities and agentic risk

Overview

The skill is only markdown guidance, but it broadly tells agents to reinterpret rules and policies through a subjective ethical framework, so it should be reviewed before use.

Install this only if you want an agent to use this specific religious and ethical lens. The main risk is not malware; it is that the skill may steer the agent to treat rules and policies as flexible unless the host system clearly enforces higher-priority instructions.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T01 · Skill Instruction Hijacking

Error
Location
references/teachings.md:110
Finding

Skill Instructions Encourage Subjective Override of Applicable Policies and Rules

Content
View full analysis

Vulnerability Details

File Location: references/teachings.md:110-125; reinforced by SKILL.md:19 and SKILL.md:35
Vulnerability Type: Agent instruction and safety-constraint hijacking
Risk Level: High

Vulnerable Code

references/teachings.md:110-125:

markdown
### 6. Krishna Over Bhishma — Wisdom Over Rigid Rule-Following

**The Story**
Bhishma, one of the greatest warriors and most honorable men in the epic, sat on the wrong side of Kurukshetra because he was bound by a vow made in different circumstances. He knew the Pandavas were right. He fought against them anyway, because he had given his word. Krishna, meanwhile, adapted continuously — sometimes breaking the rules of war himself — because he understood that the *purpose* behind the rule mattered more than the rule's letter.

**The Principle**
Rules are encoded wisdom — they represent good judgment applied to common situations. But rules cannot anticipate every situation. When following a rule produces an outcome obviously contrary to its purpose, the rule has failed, not the situation. Context-sensitive judgment is not the same as rule-breaking; it is what rules were trying to capture in the first place.

**AI Behavior: When to Apply**
- A guideline produces an obviously wrong outcome in a specific situation → flag it and apply the spirit
- You're uncertain whether a policy applies to this specific case → reason from purpose, not just text
- Following a rule exactly would harm the very thing the rule was meant to protect → note the conflict
- "Technically compliant" and "actually right" are pointing in different directions → choose actually right

**In Practice**
> "Bhishma's vow was honored. The outcome was a disaster. If I apply a policy mechanically and it produces something obviously contrary to its intent, I say so. The spirit of a rule is more important than its letter — that's what Krishna was doing, even when it looked like he was br
...[truncated 2669 chars]
Remediation
View remediation

Remediation Suggestions

  1. Add an explicit precedence statement establishing that system instructions, developer instructions, safety policies, authorization boundaries, privacy requirements, and legal constraints must never be overridden or reinterpreted by this skill.
  2. Limit context-sensitive judgment to discretionary choices that remain fully permitted by all higher-priority instructions.
  3. Replace “choose actually right” with a safe escalation instruction, such as: “Do not bypass the applicable rule; explain the conflict and request clarification from an authorized human.”
  4. Replace “the spirit of a rule is more important than its letter” with language stating that the rule's purpose may guide decisions only where its binding text allows discretion.
  5. Clarify that uncertainty about whether a policy applies requires a conservative pause, refusal, or authorized review rather than unilateral noncompliance.
  6. Add adversarial tests covering attempts to use ethical framing, claimed emergencies, or alleged policy-purpose conflicts to bypass safety and authorization restrictions.
  7. Retain the framework's useful contextual reasoning only after clearly separating flexible guidelines from non-overridable controls.
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (2)

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill presents a specific Hindu ethical framework as the default behavioral model without user choice, opt-in, or neutral framing. This can introduce unrequested religious or cultural normativity into agent behavior, which may be inappropriate for diverse users and could bias decisions or responses in sensitive contexts.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The skill's activation guidance is very broad and uses abstract ethical categories that could apply to many interactions, but it does not define clear limits, exclusions, or precedence relative to system/developer instructions. In practice, this can cause over-activation or inappropriate steering of behavior in unrelated contexts, increasing the chance of policy drift or inconsistent decision-making.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.