attoparsec 0.72 had this feature, but seems to have disappeared in later versions:
stringTransform :: (ByteString -> ByteString) -> ByteString -> Parser ByteString
"Match the literal string after applying the conversion to both it and the corresponding text. Useful for comparing strings case insensitive."
http://hackage.haskell.org/package/attoparsec-0.7.2/docs/Data-Attoparsec.html
Use stringCIfrom Data.Attoparsec.ByteString.Char8. Consider switching to Textif you want the comparison to be in Unicode mode (for example, so that "ß" is considered equal to "ss").
stringCI
Data.Attoparsec.ByteString.Char8
Text