Open Gitoffthelawn opened 1 year ago
Looking closely at the code, I'm thinking the second option may be more efficient, because it looks like all globs/wildcards are converted to regex and then reprocessed: https://github.com/stoically/temporary-containers/blob/d66d9b601d44c36a57b7a91e7cc6db67f6c047f8/src/background/utils.ts#L40
Is that correct?
When specifying domain patterns for
per domain isolation
, one can specify patterns as literals, wildcards, or regexes. See https://github.com/stoically/temporary-containers/wiki/Per-Domain-IsolationTo prevent leakage, I find it best to isolate domains whether or not a host is specified. Thus, there are 2 choices:
example.com
and*.example.com
/^https?://(?:[^.]+\.|)example\.com/
Both options should match the same URLs. Based on how TC processes per-domain isolation patterns, which will be more efficient, the 1st or the 2nd?