UrlChecker icon indicating copy to clipboard operation
UrlChecker copied to clipboard

More decoding options (Base64)

Open PabloOQ opened this issue 1 year ago • 0 comments

Describe a related problem (optional)

So lately google has been using base64 for encoding instead of the percent encoding, here is an example from an issue of ClearURLs.

This has happened to me too, but I didn't keep the URL as I didn't know it was base64, but I remember that the URL Cleaner module totally butchered the URL as it was expecting a query with percent encoding instead of base64, so some rules are affected by this.

Describe your suggested feature

Options to decode on base 64 on multiple modules:

  • URL Cleaner: Tricky, I don't think breaking the spec and adding custom fields ourselves to the rule catalog is an option. The other alternative, would be to have the decodeURIComponent(String text) be smart enough to know which of the different decoding options results in gibberish and which one results in valid URLs.

  • Pattern Checker: Maybe an additional field like decodeMethod in which you choose percent, base64 and any other that might pop in the future.

  • URI Parts: As proposed with URL Cleaner a "smart decoder" would fit best if it has a perfect accuracy, which I don't know if it is possible, as the decoded component might not result in a complete valid URL. The other (bad) alternative is to show both decoded options. This module would benefit a lot of the possibility to see those base64 decoded components because it will make easy to spot when a URL has an encoded component or not like just ID numbers for tracking, a reference to the database of a shortener service or anything that doest not give us any useful information.

Describe alternatives you've considered for your suggested feature

No response

Other details

#10 mentions base64

Acknowledgements

  • [X] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open issue.
  • [X] I have written a short but informative title.
  • [X] I will fill out all of the requested information in this form.

PabloOQ avatar Jul 20 '24 16:07 PabloOQ