I’m not familiar with Chrome/Firefox extensions, but for Safari Web Extensions you can indeed restrict extensions. [0]
Edit: Looks like this feature is present in Chrome/Firefox extensions as well but for all these platforms (Safari included I think), this needs to be implemented in the code itself[1]
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/Web...
WE are implemented both by Chromium and Firefox (with nuances)