Changed the wildcard matching to use regex and support * and _ as wildcards