mirror of
https://github.com/ProxymanApp/Proxyman.git
synced 2026-04-25 16:15:55 +03:00
[GH-ISSUE #540] Breakpoint Rules with regEx-like abilities #536
Labels
No labels
Discussion
Feature request
In Progress...
Plugins
Waiting response
Windows
Windows
bug
duplicate
enhancement
feature
good first issue
iOS
macOS 10.11
question
wontfix
✅ Done
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Proxyman#536
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @2bitmarv on GitHub (Jul 1, 2020).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/540
Originally assigned to: @NghiaTranUIT on GitHub.
Proxyman Version: 2.0.1
Mac OS Version: 10.15.4 (catalina)
How to reproduce:
creating a breakpoint rule like *://rp-online.de/ with subdirectories excluded because this would trigger the breakpoint by nearly EVERY type of call (doc, css and js files, images, etc). But now you have to create a rule for EVERY page call you want to trigger the breakpoint.
Expected behavior
I suggest to implement a more specific regex like possibility to create a single rule that can handle a pattern of a URL to trigger the breakpoint. In my case *://rp-online.de/ triggers on the homepage wether it its http or https. but with a more specific regex like pattern it could trigger also:
*://rp-online.de/panorama/deutschland/drama-in-vorpommern-mann-rettet-kinder-aus-ostsee-und-ertrinkt-dann-selbst_aid-51976133
which means a URL with lots of slashes and predictable patterns at the end. I want these URL to trigger, but I don't want URLs to trigger the breakpoint when its a JS or CSS or a media file.
I do understand that a full fledged regex engine is a pain for performance. But eventually I could be something in between.
@NghiaTranUIT commented on GitHub (Jul 2, 2020):
I'm not sure if I understand your mean, but:
It's possible to achieve your need by specifying the exact path that you need for the breakpoint
For instance,
*://rp-online.de/panorama/deutschland/drama-in-vorpommern-mann-rettet-kinder-aus-ostsee-und-ertrinkt-dann-selbst_aid-51976133will trigger the breakpoint on the HTML page, but not for JS/CSSYou can combine wildcard (* and ?) like:
*://rp-online.de/panorama/deutschland/drama-in-vorpommern-mann-rettet-kinder-aus-ostsee-und-ertrinkt-dann-selbst_aid-51976133/*.js-> trigger only JS file@2bitmarv commented on GitHub (Jul 2, 2020):
Hi Nghia,
yes I probably did describe it not clear. what I meant is that I would find it very helpful to achieve as many matches as possible from one rule but ignore some of those (like JS or CSS files for example. So this would be like this URLs and its "subdirs":
pattern: ^.(http|https)://rp-online.de/.*
but not these URLs that have a "/assets/":
It would be like this regex
@NghiaTranUIT commented on GitHub (Jul 2, 2020):
It totally makes sense @2bitmarv. I will consider to support Regex for URL matching in the next releases 👍
@NghiaTranUIT commented on GitHub (Jul 19, 2020):
Hi @2bitmarv, if you have free time, let check out this BETA build: https://proxyman.s3.us-east-2.amazonaws.com/beta/Proxyman_2.2.0_Regex_For_All_Tools_v2.dmg
This build supports full-matching Regex for all tools (Breakpoint, Map Local, Map Remote, Block and Allow Tool). Therefore, you can write specific Regex to match requests that you need.
Document here: Regex
@2bitmarv commented on GitHub (Jul 21, 2020):
Hi @NghiaTranUIT, it works like a charm 👍. I just took a glance and will dig deeper into it. But for now I could replace 10 Rules with just ONE :) Awesome!
@NghiaTranUIT commented on GitHub (Jul 22, 2020):
Glad to hear that 🙌