einaregilsson / Redirector

Browser extension (Firefox, Chrome, Opera, Edge) to redirect urls based on regex patterns, like a client side mod_rewrite.
http://einaregilsson.com/redirector/
MIT License
1.55k stars 163 forks source link

[bug] Doesn't work on Firefox 57+ (add support for multi-account containers) #117

Open guakamole opened 6 years ago

guakamole commented 6 years ago

Hello,

On nightly (61.0a1 at the time of this writing), everything works (menus, edit redirections,...) except the redirection themselves. I suspect that it might be related to the multi-account containers feature.

Here is the rule that I tried to enforce:

{
    "createdBy": "Redirector v3.1.1",
    "createdAt": "2018-03-20T13:06:09.600Z",
    "redirects": [
        {
            "description": "Force Facebook newsfeed in chronological order",
            "exampleUrl": "https://www.facebook.com",
            "exampleResult": "https://www.facebook.com/?sk=h_chr",
            "error": null,
            "includePattern": "https://www.facebook.com",
            "excludePattern": "",
            "redirectUrl": "https://www.facebook.com/?sk=h_chr",
            "patternType": "W",
            "processMatches": "noProcessing",
            "disabled": false,
            "appliesTo": [
                "main_frame"
            ]
        }
    ]
}
einaregilsson commented 6 years ago

Have you tried other rules, or just this one?

guakamole commented 6 years ago

Hello,

Thank you for your answer.

Here is another rule (that doesn't work either):

Note: this redirection is just for the sake of the example, nothing political underneath

{
    "createdBy": "Redirector v3.1.1",
    "createdAt": "2018-03-20T14:10:47.000Z",
    "redirects": [
        {
            "description": "Test",
            "exampleUrl": "https://edition.cnn.com",
            "exampleResult": "http://www.foxnews.com/",
            "error": null,
            "includePattern": "https://edition.cnn.com",
            "excludePattern": "",
            "redirectUrl": "http://www.foxnews.com/",
            "patternType": "W",
            "processMatches": "noProcessing",
            "disabled": false,
            "appliesTo": [
                "main_frame"
            ]
        },
        {
            "description": "Force Facebook newsfeed in chronological order",
            "exampleUrl": "https://www.facebook.com",
            "exampleResult": "https://www.facebook.com/?sk=h_chr",
            "error": null,
            "includePattern": "https://www.facebook.com",
            "excludePattern": "",
            "redirectUrl": "https://www.facebook.com/?sk=h_chr",
            "patternType": "W",
            "processMatches": "noProcessing",
            "disabled": false,
            "appliesTo": [
                "main_frame"
            ]
        }
    ]
}
einaregilsson commented 6 years ago

Ok, will try to look at this. Probably won't get to it until it reaches actual release though.

gkrishnaks commented 6 years ago

Not sure about the rules you pasted. I tried in Firefox quantum desktop and also firefox android - redirector works fine in both. @guakamole

knezi commented 5 years ago

This persists in 66. I turned on logging and the rule is sucessfully triggered. E.i. it says foo is redirected to bar. Nonetheless, the original page is loaded.

fcFn commented 1 year ago

I was just experiencing the same, turns out I forgot to add the URI scheme, e.g., https:// to the URL in the Redirect to: field. It was a bit confusing because the logs say "Redirecting", but nothing actually happens.