The article describes a technical vulnerability involving the potential exposure of sensitive reasoning traces and credentials within proprietary LLM API interactions. Specifically, the researcher identifies that sensitive information, such as AWS access keys (e.g., AKIA1234567890123456), GitHub tokens (ghp_...), and Hugging Face tokens (hf_...), can be leaked through various data artifacts. The investigation reveals that these secrets are often embedded within complex structures, such as git diff strings stored inside large JSON datasets (e.g., in the "dcnlp_diff" field of tokenized datasets). The methodology for sanitizing these leaks involves scanning the repository using regex patterns to identify specific credential formats, including AWS temporary credentials (ASIA) and common environment variable assignments like "AWS_SECRET_ACCESS_KEY" or "HF_TOKEN". The findings highlight a significant risk where tokenized datasets used for training or evaluation might inadvertently capture and preserve actual authentication tokens within their embedded text or diff segments, necessitating rigorous sanitization via targeted string replacement with placeholders like <your-huggingface-token> to prevent unauthorized access to cloud and version control services.

Read original