Back to skill

Security audit

sausg

Security checks for vulnerabilities and agentic risk

Overview

This SAUSG helper is mostly aligned with its engineering purpose, but it can automatically launch local executables and delete broad sets of project files without strong safeguards.

Review this skill before installing. Use it only with trusted SAUSG installation paths and trusted model directories, prefer explicitly passing the SAUSG directory, and avoid default cleanup unless you have backups or have verified the directory contains only disposable SAUSG artifacts.

Vulnerability Patterns
  • Tool Hijacking and SpoofingModifies or replaces tools so legitimate-looking calls execute attacker logic
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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
Findings (3)

T07 · Tool Hijacking and Spoofing

Error
Location
scripts/sausg_calc.py:91
Finding

Automatic SAUSG Discovery Can Execute a Spoofed Local Binary

Content
View full analysis
nul') if returncode == 0: for line in stdout.strip().split('\n'): if line.strip(): match = re.search(r'SAUSG(\d+)', line, re.IGNORECASE) if match: version = int(match.group(1)) dir_path = os.path.join("D:\\", line.strip()) if os.path.isdir(dir_path): saug_dirs.append((dir_path, version)) # If none are found on D, search other drives. if not saug_dirs: for drive in ['C:', 'E:', 'F:']: try: returncode, stdout, _ = run_command( f'dir /ad /b {drive}\\SAUSG* 2>nul' ) if returncode == 0: for line in stdout.strip().split('\n'): if line.strip(): match = re.search( r'SAUSG(\d+)', line, re.IGNORECASE ) if match: version = int(match.group(1)) dir_path = os.path.join( drive, line.strip().replace('/', '\\') ) if os.path.isdir(dir_path): saug_dirs.append((dir_path, version)) except Exception: continue saug_dirs.sort(key=lambda x: x[1], reverse=True) latest_dir = saug_dirs[0][0] if os.path.exists(os.path.join(latest_dir, "SAUSAGE.exe")): return latest_dir ``` The selected executable is subsequently launched: ```python cmd = f'"{SAUSG_DIR}\\SAUSAGE.exe" TYPE=OPEN BATCH=0 PATH="{model_path}"' pro ...[truncated 2564 chars]
Remediation
View remediation

T07 · Tool Hijacking and Spoofing

Error
Location
scripts/sausg_open.py:77
Finding

SAUSG Module Launcher Trusts Spoofable Installation Directories

Content
View full analysis
nul', shell=True, capture_output=True, text=True, encoding='utf-8', errors='replace' ) if result.returncode == 0: for line in result.stdout.strip().split('\n'): if line.strip(): match = re.search(r'SAUSG(\d+)', line, re.IGNORECASE) if match: version = int(match.group(1)) dir_path = os.path.join("D:\\", line.strip()) if os.path.isdir(dir_path): saug_dirs.append((dir_path, version)) if not saug_dirs: for drive in ['C:', 'E:', 'F:']: try: result = subprocess.run( f'dir /ad /b {drive}\\SAUSG* 2>nul', shell=True, capture_output=True, text=True, encoding='utf-8', errors='replace' ) if result.returncode == 0: for line in result.stdout.strip().split('\n'): if line.strip(): match = re.search( r'SAUSG(\d+)', line, re.IGNORECASE ) if match: version = int(match.group(1)) dir_path = os.path.join( drive, line.strip().replace('/', '\\') ) if os.path.isdir(dir_path): saug_dirs.append((dir_path, version)) except Exception: continue saug_dirs.sort(key=lambda x: x[1], reverse=True) latest_dir = saug_dirs[0][0] if os.path.exists(os.path.join(latest_dir, "SAUSAGE.exe" ...[truncated 2443 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/sausg_calc.py:399
Finding

Default Cleanup Can Delete Unrelated Files and Directories

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (26)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The declared purpose is a normal engineering workflow, but the behavior described includes local disk scanning, executable discovery, and launching local binaries, which are materially more sensitive than simple analysis guidance. The mismatch also means users may not understand that the skill can inspect local drives and start programs, creating consent, safety, and auditability gaps.

Content

No source excerpt is available for this finding.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

This is a true tool-parameter abuse issue because the function accepts an arbitrary command string and executes it through the shell. In an agent skill, any future or indirect user influence over cmd can turn a convenience wrapper into arbitrary OS command execution, which is especially dangerous because the skill is expected to operate on local engineering workstations.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 61)May include surrounding context.

python
tuple: (returncode, stdout, stderr)
    """
    try:
        result = subprocess.run(
            cmd,
            shell=True,
            capture_output=True,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
98% confidence
Finding

The backup execution path exposes the same command-injection primitive, so an attacker does not lose capability if the preferred encoding path errors out. Duplicating the unsafe pattern increases maintenance risk and makes future exploitation paths more likely.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 73)May include surrounding context.

python
except Exception as e:
        # 备用方案:使用系统默认编码
        try:
            result = subprocess.run(
                cmd,
                shell=True,
                capture_output=True

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

This duplicate TM1 finding identifies the same unsafe Popen(shell=True) sink from a slightly different matcher perspective. It remains a real vulnerability for the same reason: shell-based process creation around untrusted path input can be abused for OS command injection.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 549)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

This duplicate TM1 finding identifies the same unsafe Popen(shell=True) sink from a slightly different matcher perspective. It remains a real vulnerability for the same reason: shell-based process creation around untrusted path input can be abused for OS command injection.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 549)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · scripts/sausg_open.py (reported line 81)May include surrounding context.

python
try:
        # 列出 D 盘根目录下的文件夹
        result = subprocess.run(
            'dir /ad /b D:\\SAUSG* 2>nul',
            shell=True,
            capture_output=True,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · scripts/sausg_open.py (reported line 105)May include surrounding context.

python
if not saug_dirs:
            for drive in ['C:', 'E:', 'F:']:
                try:
                    result = subprocess.run(
                        f'dir /ad /b {drive}\\SAUSG* 2>nul',
                        shell=True,
                        capture_output=True,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

The shell-based Popen call gives the tool a direct process-execution primitive using partially external inputs. In the context of an agent skill, that significantly increases danger because a user request can be transformed into local code execution rather than a bounded file-open action.

Content

Scanner excerpt · scripts/sausg_open.py (reported line 247)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

The shell-based Popen call gives the tool a direct process-execution primitive using partially external inputs. In the context of an agent skill, that significantly increases danger because a user request can be transformed into local code execution rather than a bounded file-open action.

Content

Scanner excerpt · scripts/sausg_open.py (reported line 247)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding

The skill documentation instructs running local Python scripts and interacting with the filesystem and shell, but it does not declare any explicit tool scope or permissions. This increases the risk of overbroad execution because the agent may invoke file read or shell capabilities without clear user-visible boundaries or least-privilege constraints.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The trigger conditions are broad enough that ordinary engineering phrases could activate the skill unintentionally. In this skill's context, accidental activation is more dangerous because the skill is tied to shell execution, local file access, opening models, and potentially destructive cleanup behaviors.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The keyword list lacks boundaries and includes common domain terms such as nonlinearity, damping, reinforcement, steel structure analysis, and reading results. Because these phrases appear in many benign conversations, the skill could be invoked outside the user's intent and then proceed toward filesystem and execution actions.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill states that it will delete prior result files and entire result directories by default, but the warning is not prominent and there is no explicit safeguard described. This creates a real risk of unintended data loss, especially in engineering workflows where prior runs, reports, and result folders may be needed for verification, traceability, or recovery.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
98% confidence
Finding

run_command executes a caller-provided string with shell=True, which enables shell metacharacter interpretation and command injection if any part of cmd is influenced by user input or untrusted filesystem data. In this script, the helper is later used with interpolated commands for directory probing, so the unsafe primitive is real even if some current call sites are mostly fixed strings.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 61)May include surrounding context.

python
tuple: (returncode, stdout, stderr)
    """
    try:
        result = subprocess.run(
            cmd,
            shell=True,
            capture_output=True,

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
97% confidence
Finding

The fallback branch repeats the same unsafe pattern by passing a raw command string to subprocess.run with shell=True. This preserves the injection surface even if the primary execution path fails, so the risk is not mitigated by the exception handling.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 73)May include surrounding context.

python
except Exception as e:
        # 备用方案:使用系统默认编码
        try:
            result = subprocess.run(
                cmd,
                shell=True,
                capture_output=True

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

cleanup_model_files broadly deletes files based on extension and prefix across the model directory, not just temporary files created by the current run. In an agent/tool context, this exceeds the narrowly stated purpose and can destroy unrelated results, reports, images, CSV/TXT/DAT data, and entire result folders if pointed at the wrong directory.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill is described as calculation and result-reading automation, but run_sausg performs destructive cleanup by default before running. That mismatch increases the chance that a user triggers deletion of existing analysis artifacts without realizing the skill will remove files and folders in the model directory.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

Destructive cleanup happens automatically with no explicit confirmation, warning prompt, or dry-run preview at the point of execution. In a security-sensitive agent setting, silent deletion is dangerous because user intent may only be to run a calculation or read results, yet the tool erases prior artifacts first.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
99% confidence
Finding

The script builds cmd using model_path and SAUSG_DIR, then launches it with subprocess.Popen(..., shell=True). Because both values can come from user input and path discovery, a crafted path containing shell metacharacters could escape quoting rules on Windows shells and execute arbitrary commands under the user's privileges.

Content

Scanner excerpt · scripts/sausg_calc.py (reported line 549)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/sausg_open.py (reported line 81)May include surrounding context.

python
try:
        # 列出 D 盘根目录下的文件夹
        result = subprocess.run(
            'dir /ad /b D:\\SAUSG* 2>nul',
            shell=True,
            capture_output=True,

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/sausg_open.py (reported line 105)May include surrounding context.

python
if not saug_dirs:
            for drive in ['C:', 'E:', 'F:']:
                try:
                    result = subprocess.run(
                        f'dir /ad /b {drive}\\SAUSG* 2>nul',
                        shell=True,
                        capture_output=True,

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The implementation acts as an application launcher, which materially expands capability beyond the manifest's stated calculation/result-reading scope. In an agent environment, capability mismatch is security-relevant because users may unknowingly grant a tool the ability to start local processes rather than just inspect or compute on files.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
98% confidence
Finding

The launcher builds a shell command from paths influenced by user input and executes it with shell=True. On Windows, quoting alone is not a reliable defense for cmd.exe metacharacters, so a crafted model path or installation path can break out of the intended command and trigger arbitrary command execution.

Content

Scanner excerpt · scripts/sausg_open.py (reported line 247)May include surrounding context.

python
try:
        # 启动进程
        process = subprocess.Popen(
            cmd,
            shell=True,
            stdout=subprocess.PIPE,

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill's core behavior is to launch a local executable, not merely process SAUSG data. In an agent/tooling context, this is dangerous because it can be abused to execute arbitrary local programs if the installation directory or resolved executable is attacker-controlled, especially combined with shell-based invocation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The natural-language documentation, status output, and usage guidance are written entirely in Chinese, which effectively forces a specific language/locale for users without any opt-in or alternative. The policy allows locale constraints when explicitly documented and justified, but this file does not state that the skill is intentionally limited to Chinese-speaking users or a China-specific environment.

Content

No source excerpt is available for this finding.