made more configurable and added white/blacklist