You can achieve this if you are using the Netcentric AC Tool https://github.com/Netcentric/accesscontroltool/blob/develop/docs/Configuration.md
A repGlob expression like "/jcr:*". Please note that repGlobs do not play well together with actions. Use privileges instead (e.g. "jcr:read" instead of read action). See issue #48. If the globbing expression starts with an asterisk, it has to be put between quotes. Using repGlob is a shortcut for rep:glob in sub element restrictions
For example, if access to /conf/we-retail/settings/wcm/templates/hero-page/thumbnail.png file is required then
- [principal]
- path:/conf/we-retail/settings/wcm/templates
permission: allow
actions: read
repGlob: *thumbnail.png*