Skip to content
Back to skills

File Reference Skill

ASecurity

Example skill demonstrating secure file reference resolution with supporting files

  • 147 stars
  • 0 votes
  • 0 copies
  • 22 views
  • Added December 19, 2025
data-aipythonshellsecuritydocumentation

Security analysis

A100/100

Pro scans all 9 files and shows the line behind each finding

Scanned February 12, 2026

npx -y skills add maxvaega/skillkit --skill file-reference-skill --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of File Reference Skill?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for File Reference Skill
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/maxvaega-file-reference-skill/badge)](https://www.skillsdirectory.com/skills/maxvaega-file-reference-skill)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: file-reference-skill
description: Example skill demonstrating secure file reference resolution with supporting files
allowed-tools: []
---

# File Reference Skill

This skill demonstrates how to use supporting files (scripts, templates, documentation) within a skill directory.

## Overview

This skill uses helper scripts and templates for data processing. All supporting files are accessible via relative paths from the skill's base directory.

## Available Supporting Files

### Scripts
- `scripts/data_processor.py` - Main data processing script
- `scripts/validator.py` - Input validation utilities
- `scripts/helper.sh` - Shell helper script

### Templates
- `templates/config.yaml` - Configuration template
- `templates/report.md` - Report generation template

### Documentation
- `docs/usage.md` - Detailed usage instructions
- `docs/examples.md` - Example use cases

## Usage

When this skill is invoked with arguments, it can access supporting files using the FilePathResolver:

```python
from pathlib import Path
from skillkit.core.path_resolver import FilePathResolver

# Get the skill's base directory (injected by BaseDirectoryProcessor)
base_dir = Path("<base_directory_from_context>")

# Resolve supporting files securely
processor_script = FilePathResolver.resolve_path(base_dir, "scripts/data_processor.py")
config_template = FilePathResolver.resolve_path(base_dir, "templates/config.yaml")
usage_docs = FilePathResolver.resolve_path(base_dir, "docs/usage.md")

# Read file contents
with open(processor_script) as f:
    script_code = f.read()
```

## Processing Arguments

The skill expects data file paths as arguments:

**Example invocation**: `file-reference-skill data/input.csv data/output.csv`

Processing steps:
1. Validate input using `scripts/validator.py`
2. Process data using `scripts/data_processor.py`
3. Generate report using `templates/report.md`
4. Output results to specified location

## Security Notes

- All file paths are validated to prevent directory traversal attacks
- Symlinks are resolved and verified to stay within skill directory
- Absolute paths and path traversal patterns (../) are blocked
- Any security violation raises PathSecurityError with detailed logging

Files in this skill

  • SKILL.md2.2 KB
  • docs/examples.md6.2 KB
  • docs/usage.md3.8 KB
  • scripts/data_processor.py1.3 KB
  • scripts/env_demo.py3.2 KB
  • scripts/helper.sh1.1 KB
  • scripts/validator.py1.5 KB
  • templates/config.yaml528 B
  • templates/report.md688 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in data-ai →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.