T09 · Insecure Skill Coding Practices
- Location
scripts/recovery_query_builder.py:76- Finding
Unredacted User-Provided Content May Be Disclosed Through Public Search Queries
- Content
View full analysis
List[str]: text_pool = " ".join([entity, title, snippet, extracted_text, *context]) tokens = extract_tokens(text_pool) hashtags = extract_hashtags(text_pool) quotes = quote_candidates(title, snippet or extracted_text, max_quotes=4) dates = extract_dates(text_pool) strong_tokens = [t for t in tokens if len(t) >= 2][:12] context_terms = dedupe(context + hashtags + dates)[:8] queries = [] if entity: queries.extend([ f'{entity} 小红书', f'site:xiaohongshu.com {entity}', f'site:www.xiaohongshu.com {entity}', ]) for quote in quotes: queries.append(quote) if entity: queries.append(f'{entity} {quote}') queries.append(f'site:xiaohongshu.com {quote}') for token in strong_tokens[:8]: if entity and token.casefold() != entity.casefold(): queries.append(f'{entity} {token}') queries.append(f'{entity} 小红书 {token}') if not entity or token.casefold() != entity.casefold(): queries.append(token) for term in context_terms: if entity: queries.append(f'{entity} {ter ...[truncated 5225 chars]- Remediation
View remediation
