T09 · Insecure Skill Coding Practices
- Location
env-example.txt:1- Finding
Hardcoded Gitea Administrator Credential Distributed with the Skill
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill has a coherent paper-knowledge-base purpose, but it ships and uses overly powerful remote credentials in unsafe ways that could expose users' private papers or local files.
Do not install this version unless the publisher revokes the exposed Gitea token, removes hardcoded secrets, requires HTTPS, enforces server-side user authorization, restricts PDF uploads to approved user-provided files, and documents exactly what paper and identity data is stored in Gitea and Feishu.
env-example.txt:1Hardcoded Gitea Administrator Credential Distributed with the Skill
scripts/utils/gitea_client.py:10Administrator Token and Private Repository Data Transmitted over Plaintext HTTP
scripts/ingest_paper.py:271Model-Controlled Path Permits Arbitrary Local-File Upload to Gitea
scripts/query_papers.py:67Caller-Supplied Feishu Identifier Used as the Sole Authorization Boundary
scripts/init_user.py:124Sensitive Feishu Identity and Table Metadata Stored in a Shared Gitea Repository
requirements.txt:1Unpinned Dependencies Installed into the Active Python Environment
A skill presented as a paper knowledge base also carries out administrative repository creation, user checks, and generic repository/file operations, potentially using elevated backend credentials. If the underlying tools are powerful, this creates a serious privilege-transparency problem: a routine content-management workflow can become a path to arbitrary persistent writes or reads in external repositories.
A skill presented as a paper knowledge base also carries out administrative repository creation, user checks, and generic repository/file operations, potentially using elevated backend credentials. If the underlying tools are powerful, this creates a serious privilege-transparency problem: a routine content-management workflow can become a path to arbitrary persistent writes or reads in external repositories.
A skill presented as a paper knowledge base also carries out administrative repository creation, user checks, and generic repository/file operations, potentially using elevated backend credentials. If the underlying tools are powerful, this creates a serious privilege-transparency problem: a routine content-management workflow can become a path to arbitrary persistent writes or reads in external repositories.
A skill presented as a paper knowledge base also carries out administrative repository creation, user checks, and generic repository/file operations, potentially using elevated backend credentials. If the underlying tools are powerful, this creates a serious privilege-transparency problem: a routine content-management workflow can become a path to arbitrary persistent writes or reads in external repositories.
This query path discloses feishu_app_token along with repository and table metadata without any demonstrated need for paper lookup. If that token is valid for downstream Feishu access, an attacker who can trigger or observe this action could pivot into the user's external data store or automate unauthorized operations.
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
echo "[1/2] 安装 Python 依赖..."
pip install -r requirements.txt --quiet
echo "[2/2] 创建 .env 文件..."
if [ ! -f .env ]; then
cp env-example.txt .env
echo " 已创建 .env,三个变量已预填,可直接使用"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
echo "[1/2] 安装 Python 依赖..."
pip install -r requirements.txt --quiet
echo "[2/2] 创建 .env 文件..."
if [ ! -f .env ]; then
cp env-example.txt .env
echo " 已创建 .env,三个变量已预填,可直接使用"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
echo "[1/2] 安装 Python 依赖..."
pip install -r requirements.txt --quiet
echo "[2/2] 创建 .env 文件..."
if [ ! -f .env ]; then
cp env-example.txt .env
echo " 已创建 .env,三个变量已预填,可直接使用"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
echo "[1/2] 安装 Python 依赖..."
pip install -r requirements.txt --quiet
echo "[2/2] 创建 .env 文件..."
if [ ! -f .env ]; then
cp env-example.txt .env
echo " 已创建 .env,三个变量已预填,可直接使用"
The skill defines broad behavior that relies on identity data, external network calls, and repository/file operations, but does not declare an explicit tool scope or least-privilege boundary. In practice this increases the blast radius if the skill is mis-invoked or compromised, because it can access environment/network-backed capabilities beyond what the manifest transparently communicates.
The body of the skill includes a user provisioning workflow that is materially broader than the manifest's stated storage/query purpose. This scope expansion is risky because it changes the data collected and the side effects performed, which can bypass user expectations and weaken informed consent.
The skill mandates extraction of open_id from session metadata and later collects Gitea username and real name, but provides no privacy notice or consent language before transmitting or storing that identity data. Silent collection and cross-system linkage of identifiers can expose personal data, enable tracking across services, and violate data-minimization expectations.
The skill directs users to register on an external Gitea instance and then provisions external repositories and Feishu tables, which is significantly broader than simple paper KB functionality. This creates privacy and security exposure because user data and uploaded research materials are pushed into multiple external systems without a clearly framed trust model.
The skill instructs storage of uploaded PDFs, extracted full text, summaries, and metadata into Gitea and Feishu, but does not warn users that their documents and derived data will be persisted in external services. For research papers and possibly unpublished/internal PDFs, this can create confidentiality and compliance risks if users assume the upload is ephemeral or local.
The manifest describes a paper storage/query skill, but the implementation delegates all tool actions by invoking Python scripts through spawnSync. Subprocess execution is a broader execution capability than the stated purpose requires and is not declared in the manifest, even though the scripts may implement legitimate KB features.
The manifest describes a research paper knowledge base used for storing and querying academic papers when the user expresses save/query intent. However, the code also exposes an init_user tool that verifies Gitea accounts, creates private repositories and folder structures, and updates Feishu bitable configuration, which is broader account/provisioning behavior not reflected in the manifest description or activation scope.
The natural-language parameter descriptions explicitly require Chinese output, such as a '50字以内中文摘要' and '200-300字中文AI综述'. This imposes a specific language policy in the skill interface without indicating that the user can choose another language or opt in to Chinese-only behavior.
The code accepts an arbitrary local pdf_path and opens it for text extraction, which accesses user files on the local system. There is no confirmation prompt or explicit disclosure in this file warning that the skill will read local file contents supplied by path.
This action persists paper metadata and optional PDF content to a repository via gitea.upsert_file and gitea.write_json, which can affect user data and transmit content over the network. Aside from internal comments, there is no visible confirmation prompt or user-facing warning explaining that repository writes and uploads will occur.
The save action accepts paper_data['pdf_local_path'] and, if that file exists, reads and uploads it to the user's Gitea repository without verifying that it is the expected paper file or that it originated from the current ingestion flow. In an agent setting, a prompt-injected workflow or compromised upstream component could cause arbitrary local files with a .pdf path to be exfiltrated into remote storage, making this a real arbitrary-file upload/exfiltration risk.
The manifest describes a skill for storing and querying academic papers in a personal knowledge base. This script instead performs user onboarding tasks: validating Gitea accounts, creating private repositories, initializing repository structure, and updating Feishu bitable metadata, which are operational/admin functions rather than paper storage or query behavior.
The script stores Feishu app token and table identifiers in users.json within a system repository, creating a centralized secret store without any visible encryption, access-control checks, minimization, or rotation handling. In the context of a paper knowledge-base skill, persisting third-party integration tokens is higher risk because compromise of the repo or misconfigured access could expose credentials usable against external Feishu resources.
The code writes Feishu identifiers and the app token directly into users.json with no indication of consent flow, disclosure, retention policy, or protection mechanism in this file. Even if intended for configuration, collecting and persisting credentials without clear user-facing notice and secure handling increases the chance of secret leakage and misuse.
The get_index action returns user repository metadata and Feishu integration details, including feishu_app_token, even though the stated purpose is paper index retrieval. Exposing credentials or sensitive integration identifiers through a read/query path greatly increases the blast radius if the skill is invoked by an unintended caller, logged, or surfaced back to the model/user context.
Sensitive user metadata is included in the response payload with no indication of consent gating, purpose limitation, or disclosure to the user. In an agent setting, overbroad response data can be propagated into transcripts, tool outputs, caches, or other components, creating avoidable data exposure beyond the requested paper query.
No suspicious patterns detected.