[Bug] Stray fmt.Printf in portainertoken detector pollutes standard output
Author: Gracy769Created Sep 21, 2026Updated Sep 22, 2026
The portainertoken detector contains a stray mt.Printf(\nINVALID URL\n) statement that was likely left over from debugging. When running TruffleHog on a codebase that contains a portainer keyword near an invalid URL, this causes INVALID URL to be repeatedly printed to stdout, polluting the tool's standard output and disrupting structured logging.
To Reproduce
- Create a file containing portainertoken https://this-is-not-a-valid-url:
- Run trufflehog on the file.
- Observe INVALID URL printed to stdout.
Expected behavior The detector should silently ignore invalid URLs and continue scanning, or use the configured logger at a debug level.
Source: trufflesecurity/trufflehog