Back to skill

Security audit

finding-tiktok-ugc-creators-for-brands

Security checks for vulnerabilities and agentic risk

Overview

This skill is a user-directed TikTok creator research workflow that uses Apify as advertised, with some privacy and token-handling cautions but no hidden or destructive behavior.

Install only if you are comfortable using Apify/apidojo to process TikTok search terms and profile URLs. Prefer MCP or API calls that pass APIFY_TOKEN in an Authorization header, use a restricted token, avoid sensitive target lists, and store any exported creator roster carefully.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:97
Finding

Apify API Token Exposed in URL Query Parameters

Content
View full analysis

Vulnerability Details

File Location: SKILL.md:97-100 and SKILL.md:119
Vulnerability Type: API credential exposure through URL query parameters
Risk Level: Medium

Vulnerable Code

bash
curl -X POST   "https://api.apify.com/v2/acts/apidojo~tiktok-scraper/runs?token=$APIFY_TOKEN"   -H "Content-Type: application/json"   -d '{
    "keywords": ["#skincarereviews", "#skincarehaul"],
    "maxItems": 200
  }'
bash
curl -X POST   "https://api.apify.com/v2/acts/apidojo~tiktok-profile-scraper/runs?token=$APIFY_TOKEN"   -H "Content-Type: application/json"   -d '{"profiles": ["https://www.tiktok.com/@handle1"]}'

Technical Analysis

The documented REST fallback places APIFY_TOKEN in the request URL. When the shell expands the environment variable, the credential becomes part of the curl process command line. It may consequently be exposed through process inspection, shell history, terminal or command auditing, proxy and access logs, monitoring systems, error telemetry, and other systems that record URLs.

HTTPS protects the request while it is in transit but does not prevent credential disclosure at the local endpoint or through URL logging by trusted infrastructure.

Attack Path

  1. A user follows one of the documented REST API examples with APIFY_TOKEN set.
  2. The shell expands $APIFY_TOKEN into the URL passed to curl.
  3. A local user or monitoring component captures the process command line or records the complete URL.
  4. An attacker obtains the exposed token from that record.
  5. The attacker reuses the token against Apify APIs within the permissions assigned to it.

Impact Assessment

Successful exploitation grants access limited to the compromised token's Apify permissions. Depending on those permissions, an attacker could execute actors using the victim's account resources, consume paid platform capacity, inspect accessible actor-run metadata or datasets, and cau ...[truncated 104 chars]

Remediation
View remediation

Remediation Suggestions

Remove the token from both query-string examples and transmit it through an authorization header:

bash
curl -X POST \
  "https://api.apify.com/v2/acts/apidojo~tiktok-scraper/runs" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "keywords": ["#skincarereviews", "#skincarehaul"],
    "maxItems": 200
  }'

Apply the same pattern to the profile-scraper request. In addition:

  • Use a restricted token granting only the permissions required by this workflow.
  • Store the token in a protected secret manager or environment variable rather than source files.
  • Avoid verbose command logging that could capture authorization headers.
  • Rotate the token if the query-string examples have been used in environments where URLs or process command lines are retained.
  • Review and sanitize proxy, access, shell-history, and telemetry records that may contain previously exposed tokens.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (5)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs users to send search keywords, TikTok URLs, and profile identifiers to Apify actors without clearly warning that this data is transmitted to a third-party service. This can lead to unintended disclosure of user-supplied or business-sensitive inputs, especially if users provide confidential campaign targets, prospect lists, or region-specific research parameters.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
91% confidence
Finding

This REST example performs an outbound POST to Apify and includes user-provided search parameters, creating an external data transmission path. In context this is expected functionality, but it remains a real security/privacy concern because the skill does not prominently warn users that their inputs will be transmitted off-platform to a third party.

Content

Scanner excerpt · SKILL.md (reported line 97)May include surrounding context.

REST API fallback:

bash
curl -X POST   "https://api.apify.com/v2/acts/apidojo~tiktok-scraper/runs?token=$APIFY_TOKEN"   -H "Content-Type: application/json"   -d '{
    "keywords": ["#skincarereviews", "#skincarehaul"],
    "maxItems": 200
  }'

External Transmission

Medium
Category
Data Exfiltration
Confidence
91% confidence
Finding

This REST example performs an outbound POST to Apify and includes user-provided search parameters, creating an external data transmission path. In context this is expected functionality, but it remains a real security/privacy concern because the skill does not prominently warn users that their inputs will be transmitted off-platform to a third party.

Content

Scanner excerpt · SKILL.md (reported line 97)May include surrounding context.

REST API fallback:

bash
curl -X POST   "https://api.apify.com/v2/acts/apidojo~tiktok-scraper/runs?token=$APIFY_TOKEN"   -H "Content-Type: application/json"   -d '{
    "keywords": ["#skincarereviews", "#skincarehaul"],
    "maxItems": 200
  }'

External Transmission

Medium
Category
Data Exfiltration
Confidence
92% confidence
Finding

This profile-enrichment REST example sends TikTok profile URLs to Apify, which is a third-party transfer of potentially identifying creator research data. The skill context makes external calls expected, but the absence of a clear disclosure and handling guidance increases the risk of unintended data sharing and compliance issues.

Content

Scanner excerpt · SKILL.md (reported line 119)May include surrounding context.

REST API fallback:

bash
curl -X POST   "https://api.apify.com/v2/acts/apidojo~tiktok-profile-scraper/runs?token=$APIFY_TOKEN"   -H "Content-Type: application/json"   -d '{"profiles": ["https://www.tiktok.com/@handle1"]}'

Step 3: Score UGC Fit

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
86% confidence
Finding

In this markdown file, the examples explicitly show writing output files containing creator handles, follower counts, engagement metrics, and content samples. The document does not include any user-facing warning about handling or storing scraped social-media data, which is a data-affecting behavior covered by the markdown warning criterion.

Content

No source excerpt is available for this finding.