Skip to content

[Feature Request] Wildcard exception handling for more specific domains #1772

@brokoler

Description

@brokoler

Hello,

Issue description:
I have an issue with Blocky when trying to allow *.itunes.apple.com and block vpp.itunes.apple.com:

  • The rule *.itunes.apple.com is defined in my custom allowlist
  • The rule vpp.itunes.apple.com is defined in my custom denylist

Based on the official documentation, the allowlist is always prioritized above the denylist:

If the same group has both allow/denylists, allowlists take precedence. Meaning if a domain is both blocked and allowed, it will be allowed. If a group has only allowlist entries, only domains from this list are allowed, and all others be blocked.
Source: https://0xerr0r.github.io/blocky/latest/configuration/

Solution description:
Two possible solutions came to my mind:

  1. Prioritize specific subdomain entries over wildcard entries:
    More specific entries should always be prioritized over wildcard entries.
    If the wildcard is defined in the allowlist and the specific subdomain in the denylist, the denylist entry should be used.

  2. Add attribute to set a higher priority to a single entry
    For example Adguard offers such a solution, if the attribute "$important" is added to set the priority for a specific entry
    e.g. vpp.itunes.apple.com$important

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions