T09 · Insecure Skill Coding Practices
Warning
- Location
- memory-template.md:8
- Finding
- Persistent Plaintext Storage of Sensitive Personal and Government Information<![CDATA[ ## Vulnerability Details **File Location**: `setup.md:21`; `memory-template.md:8-31, 58-64, 108-114, 144-147` **Vulnerability Type**: Plaintext sensitive-data storage without data minimization or access-control guidance **Risk Level**: Medium ### Vulnerable Code `setup.md:21`: ```markdown Copy `memory-template.md` to `~/valencia/profile.md` and fill in: ``` `memory-template.md:8-31`: ```markdown ### Legal Status - **Nationality**: [Your country] - **EU citizen**: [Yes | No] - **Visa type**: [Tourist | Digital Nomad | Work | Student | Non-lucrative | Other] - **Visa status**: [Applied | Approved | Need to apply | N/A (EU)] - **NIE status**: [Have | Applied | Need] - **Empadronamiento**: [Done | Pending | N/A] ### Work Situation - **Employment type**: [Remote | Local job | Self-employed | Student | Retired | Looking] - **Employer location**: [Country if remote] - **Industry**: [Your field] - **Income range**: [For cost planning] ### Family - **Household**: [Solo | Couple | Family with kids] - **Children ages**: [If applicable] - **School needs**: [Public | International | Homeschool | N/A] - **Pets**: [Yes/No and type] ``` `memory-template.md:58-64`: ```markdown ### Current Status - **Housing found**: [Yes | Searching | Not started] - **Address**: [If found] - **Neighborhood**: [If found] - **Contract until**: [If found] ``` `memory-template.md:108-114`: ```markdown ### Contacts | Name | Role | Contact | |------|------|---------| | | Gestoría | | | | Doctor | | | | Landlord | | | | | | ``` `memory-template.md:144-147`: ```markdown ### Documents - NIE number: ___ - SIP number: ___ - Social Security: ___ ``` ### Technical Analysis The setup guide directs users to create a persistent profile at `~/valencia/profile.md`. The supplied template encourages that file to contain sensitive information, including: - Full government-issued identifiers - Healthcare and Social Security identifiers - Residential address - Income range and employment de ...[truncated 2734 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. **Remove unnecessary identifiers** - Delete fields requesting full NIE, SIP, and Social Security numbers. - Track only workflow status, such as `NIE obtained: Yes`, rather than the identifier itself. - If partial identification is genuinely necessary, retain only a masked suffix such as `***1234`. 2. **Minimize personal information** - Replace the exact address with a neighborhood or district. - Avoid storing children's exact ages, third-party contact details, and precise income unless essential. - Clearly label every sensitive field as optional. 3. **Add explicit privacy warnings** - Warn users not to enter passwords, authentication tokens, payment-card details, full government identifiers, medical records, or document scans. - Explain that other local applications and Agents may be able to read plaintext files. 4. **Use a private storage location and restrictive permissions** - Store profiles in an application-specific private data directory rather than a general-purpose folder. - On POSIX systems, create the directory with mode `0700` and profile files with mode `0600`. - Provide equivalent access-control instructions for Windows. - Verify existing permissions rather than assuming the environment uses a secure `umask`. 5. **Protect data at rest** - Offer encrypted storage for any information that must persist. - Do not embed encryption keys beside the encrypted profile. - Avoid automatic synchronization to third-party cloud services unless the user knowingly opts in. 6. **Define retention and deletion behavior** - Document how users can securely remove the profile when it is no longer needed. - Recommend periodic review and deletion of obsolete addresses, contacts, and legal-status information. 7. **Restrict subsequent access** - Require explicit user consent before another Skill or Agent reads the profile. - Read only fields necessary for the current request r ...[truncated 55 chars]
