Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Implementing https rewrite support #97
I have implemented a https-rewrite support using the rewrite-rules from https-everywere. related with the issue #71.
I have tested the rules a little bit, and it look like that all is working.
I'm not sure about the licencing of the rules. I have fetched the rules from https://github.com/EFForg/https-
in future, it would be usefull to add a git submodule to include the current rules. But for that, it is required to extract the rules into a different repository
Parsing all https rewrite rules at startup require a few seconds (4seconds on my laptop)
using https_rewrite rules to parse search results, result in a delay of 1-10ms per result.
I think the best is deactivating https rewrite for default.
Furthermore, I have worked on algorithm to minimize the querry, but the performance go worser due it. But I found out that the performance were improved if we reverse the url and the regex (be care about special regex words), the performance could be improved by 10% or more, because many rules have a wildcard on the beginning of rule, which is difficult for the regex parser.
A other idea to improve performance is building a single tree of characters of the urls including a link to its special rules, but this would be more complicated.