Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@MagMueller
Copy link
Collaborator

@MagMueller MagMueller commented Nov 13, 2025

Add automatic API key sanitization to prevent sensitive data exposure in error messages and logs.

This addresses a security vulnerability where LLM API keys were previously exposed, reducing the blast radius if logs are shared or leaked.


Slack Thread

Open in Cursor Open in Web


Summary by cubic

Adds automatic sanitization of API keys and other sensitive fields in exceptions, logs, and background task errors to prevent credential exposure. Introduces a sanitize_sensitive_data utility and enables redaction by default across the library.

  • New Features

    • Sanitizes error messages in LLMException and ModelProviderError.
    • Sanitizes all log messages and arguments via BrowserUseFormatter.
    • Sanitizes background task exceptions in create_task_with_error_handling.
    • Exposes sanitize_sensitive_data in the public API for manual use.
    • Adds docs, example, and tests for sanitization.
  • Migration

    • No changes required; sanitization is automatic.

Written for commit 12384ce. Summary will update automatically on new commits.

@cursor
Copy link

cursor bot commented Nov 13, 2025

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@github-actions
Copy link

Agent Task Evaluation Results: 2/2 (100%)

View detailed results
Task Result Reason
amazon_laptop ✅ Pass Skipped - API key not available (fork PR or missing secret)
browser_use_pip ✅ Pass Skipped - API key not available (fork PR or missing secret)

Check the evaluate-tasks job for detailed task execution logs.

@MagMueller
Copy link
Collaborator Author

Evaluation Results

Commit: 12384ceScore: ✅ 97.0%

📊 View Details

Summary

  • Success Rate: ✅ 97.0%
  • Average Steps: 5.7 steps/task
  • Average Time: 12.2 sec/task
  • Average Time per Step: 2.1s/step

Automated evaluation by browser-use

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants