Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create NotesKeywordHighlighter.bambda #39

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions Proxy/HTTP/NotesKeywordHighlighter.bambda
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/**
* Finds entries with notes containing a specified keyword
* @author Tur24Tur / BugBountyzip (https://github.com/BugBountyzip)
* This Bambda filters Proxy HTTP history for entries with notes containing a specified keyword.
* It checks for a specific keyword within the notes and highlights the matching entries.
* Users can easily modify the 'keyword' variable to suit their specific search criteria.
**/

// User-defined keyword for filtering notes
String keyword = "High"; // Replace "High" with your desired keyword
boolean caseSensitive = true; // Set to true for case-sensitive search false for case-insensitive PortSwiggerWiener <3

// Check if there's a response and the response has notes
if (requestResponse.annotations().hasNotes()) {
// Retrieve the notes
String notes = requestResponse.annotations().notes();

// Adjust for case sensitivity
String processedNotes = caseSensitive ? notes : notes.toLowerCase();
String processedKeyword = caseSensitive ? keyword : keyword.toLowerCase();

// Check if the notes contain the specified keyword
if (processedNotes.contains(processedKeyword)) {
// If keyword is found, set highlight color and return true
requestResponse.annotations().setHighlightColor(HighlightColor.YELLOW);
return true;
}
}

// If the keyword is not found or there are no notes, return false
return false;
Loading