Like #1 the regex doesn't support the `.` character on MIME types, for example the type `image/vnd.dxf` that my code received.