Scan Report
20 /100
welderjustin-imap-smtp-email
Read and send email via IMAP/SMTP
A legitimate IMAP/SMTP email skill with undocumented filesystem operations for attachment handling. No malicious behavior detected, but SKILL.md omits required filesystem READ/WRITE capabilities.
Safe to install
Add filesystem:READ and filesystem:WRITE to SKILL.md metadata under requires.resources for the attachment and file body features. The code implements proper path validation with ALLOWED_READ_DIRS and ALLOWED_WRITE_DIRS, so no functional risk exists.
Findings 3 items
| Severity | Finding | Location |
|---|---|---|
| Low | Missing filesystem:WRITE declaration Doc Mismatch | SKILL.md:10 |
| Low | Missing filesystem:READ declaration Doc Mismatch | SKILL.md:10 |
| Low | Undeclared environment variables Priv Escalation | scripts/imap.js:30 |
| Resource | Declared | Inferred | Status | Evidence |
|---|---|---|---|---|
| Filesystem | NONE | READ | ✗ Violation | scripts/smtp.js:8 dotenv config, scripts/imap.js:215 attachment download, script… |
| Filesystem | NONE | WRITE | ✗ Violation | scripts/imap.js:260 fs.writeFileSync for attachments |
| Network | NONE | READ | ✓ Aligned | IMAP connection via imap library - implied by email tool functionality |
| Network | NONE | WRITE | ✓ Aligned | SMTP connection via nodemailer - implied by email tool functionality |
| Environment | IMAP_HOST,IMAP_USER,IMAP_PASS,SMTP_HOST,SMTP_USER,SMTP_PASS | IMAP_HOST,IMAP_USER,IMAP_PASS,SMTP_HOST,SMTP_USER,SMTP_PASS,ALLOWED_READ_DIRS,ALLOWED_WRITE_DIRS | ✓ Aligned | ALLOWED_READ_DIRS and ALLOWED_WRITE_DIRS not declared in metadata |
4 findings
Medium External URL 外部 URL
https://myaccount.google.com/apppasswords SKILL.md:66 Info Email 邮箱地址
[email protected] SKILL.md:33 Info Email 邮箱地址
[email protected] SKILL.md:43 Info Email 邮箱地址
[email protected] scripts/imap.js:48 File Tree
6 files · 33.8 KB · 1268 lines JavaScript 2f · 822L
Markdown 1f · 211L
Shell 1f · 199L
JSON 2f · 36L
├─
▾
scripts
│ ├─
imap.js
JavaScript
│ └─
smtp.js
JavaScript
├─
_meta.json
JSON
├─
package.json
JSON
├─
setup.sh
Shell
└─
SKILL.md
Markdown
Dependencies 5 items
| Package | Version | Source | Known Vulns | Notes |
|---|---|---|---|---|
imap | ^0.8.19 | npm | No | Standard IMAP client library |
imap-simple | ^5.1.0 | npm | No | Promise-based IMAP wrapper |
nodemailer | ^7.0.13 | npm | No | Standard SMTP library |
mailparser | ^3.9.3 | npm | No | Email parsing library |
dotenv | ^16.6.1 | npm | No | Environment variable loader |
Security Positives
✓ No base64 encoding, obfuscation, or anti-analysis techniques found
✓ No reverse shell, RCE, or arbitrary command execution
✓ No credential exfiltration or data theft
✓ Path traversal protection implemented via validateWritePath and validateReadPath
✓ ALLOWED_READ_DIRS and ALLOWED_WRITE_DIRS provide directory whitelisting
✓ Proper .env handling with 600 permissions in setup.sh
✓ All dependencies are legitimate email packages (imap, nodemailer, mailparser, dotenv)
✓ Symlink resolution in validateReadPath prevents path traversal attacks
✓ No curl|bash or remote script execution
✓ No access to ~/.ssh, ~/.aws, or other credential paths