Omnigroup's frameworks include a regular expression engine. I've never tried it, though. If it works, I'd love to hear how well it works, and how easy to use it is. I tried another regular expression framework for Cocoa and it came with no documentation, so I gave up and wrote a perl program...