Safari does not support the ruleset format of Chrome/Firefox, so a ruleset has to be maintained for it specifically. In practice this is always the AdGuard ruleset. I doubt a single adblocker doesn't use this as a base.
Beyond that is the custom JS they inject. It's hard to say how good it is but that is the only selling point:
- https://github.com/arjpar/WebShield/tree/cae7629f1c5fb79fe76...
AdGuard has its own too:
- https://github.com/AdguardTeam/AdGuardForSafari/tree/master/... (JS files)
They look similar in a lot of ways, because well they have to, but I haven't done any deep analysis.
Safari extensions will never match uBlock Origin because it simply does not provide the same APIs (webRequest blocking and DNS) that Firefox does. The ruleset format is also more limited.
I still feel like I need to performance test WebShield more to back my claims, so take it with a grain of salt, but based on what I've seen, it is comparable with or better than uBlock Origin in terms of performance/efficiency, not pure power, but again, please take it with a grain of salt, because I can't believe it.
[0]: https://en.wikipedia.org/wiki/Deterministic_finite_automaton [1]: https://github.com/WebKit/WebKit/tree/04edf7716a74170fb0967f...
It would be great if you did some benchmarking though!
Its also possible to extend WebKits rules, if you can prove minimal performance regression.