[GH-ISSUE #1063] Unable to match requests with ' character in URL #1059

Open
opened 2026-03-03 19:24:10 +03:00 by kerem · 3 comments
Owner

Originally created by @markanderson4 on GitHub (Nov 12, 2021).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/1063

Originally assigned to: @NghiaTranUIT on GitHub.

Proxyman version?

2.35.0

macOS Version?

11.6

Steps to reproduce

  1. Attempt to set a map local or map remote for any network request containing the ' character - such as requests using sitecore's ODATA item service. Fake example request: http://myDomain/sitecore/api/ssc/aggregate/content/Items('/path/to/item/content')/Children
  2. Make network request that should match to map local/map remote

Expected behavior

Screenshots (optional)

Originally created by @markanderson4 on GitHub (Nov 12, 2021). Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/1063 Originally assigned to: @NghiaTranUIT on GitHub. ### Proxyman version? 2.35.0 ### macOS Version? 11.6 ### Steps to reproduce 1. Attempt to set a map local or map remote for any network request containing the ' character - such as requests using [sitecore's ODATA item service](https://doc.sitecore.com/en/developers/90/sitecore-experience-manager/the-odata-item-service.html). Fake example request: http://myDomain/sitecore/api/ssc/aggregate/content/Items('/path/to/item/content')/Children 2. Make network request that should match to map local/map remote ### Expected behavior * Items are successfully matched. However, they are not - to mitigate the solution I need to substitute a wildcard for the path containing the ' symbol, i.e. http://myDomain/sitecore/api/ssc/aggregate/content/*/Children ### Screenshots (optional)
Author
Owner

@NghiaTranUIT commented on GitHub (Nov 12, 2021):

It seems to be a bug when building an internal regex if the URL contains the ' character. I'm going to fix it 👍

To workaround, you can use the * or ? wildcard, like your mention:

http://myDomain/sitecore/api/ssc/aggregate/content/*/Children
<!-- gh-comment-id:967161361 --> @NghiaTranUIT commented on GitHub (Nov 12, 2021): It seems to be a bug when building an internal regex if the URL contains the `'` character. I'm going to fix it 👍 To workaround, you can use the `*` or `?` wildcard, like your mention: ``` http://myDomain/sitecore/api/ssc/aggregate/content/*/Children ```
Author
Owner

@NghiaTranUIT commented on GitHub (Nov 15, 2021):

Hey @markanderson4 Here is your beta build: https://proxyman.s3.us-east-2.amazonaws.com/beta/Proxyman_2.35.0_Fix_special_character_in_url_matching.dmg

Proxyman can properly match URL, which contains the ( or ) and ' character 👍

The problem was Proxyman accidentally parsed the () as a Group Regex.

Screen Shot 2021-11-15 at 16 38 18 Screen Shot 2021-11-15 at 16 38 40
<!-- gh-comment-id:968707652 --> @NghiaTranUIT commented on GitHub (Nov 15, 2021): Hey @markanderson4 Here is your beta build: https://proxyman.s3.us-east-2.amazonaws.com/beta/Proxyman_2.35.0_Fix_special_character_in_url_matching.dmg Proxyman can properly match URL, which contains the `(` or `)` and `'` character 👍 The problem was Proxyman accidentally parsed the `()` as a Group Regex. <img width="1704" alt="Screen Shot 2021-11-15 at 16 38 18" src="https://user-images.githubusercontent.com/5878421/141758376-6acb584e-db00-4c68-a057-1fdd9f507c84.png"> <img width="1015" alt="Screen Shot 2021-11-15 at 16 38 40" src="https://user-images.githubusercontent.com/5878421/141758350-46a149c9-72c7-4204-9481-ceac05d1e377.png">
Author
Owner

@markanderson4 commented on GitHub (Nov 15, 2021):

I can confirm the match succeeded for me using the beta. Cheers!

<!-- gh-comment-id:969109331 --> @markanderson4 commented on GitHub (Nov 15, 2021): I can confirm the match succeeded for me using the beta. Cheers!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Proxyman#1059
No description provided.