PyMOTW: fnmatch

The fnmatch module is used to compare filenames against glob-style patterns such as used by Unix shells.

Read more at pymotw.com: fnmatch