Read CGLog with Groovy

If an app uses Jemalloc to manage space, there’s a security gap if you run Yosemity. Famouse apps using Jemalloc are e.g. Firefox and Thunderbird. So if you want to know you’re affected or not, just take a look at the /tmp dir and watch out for files like CGLog_Thunderbird* or CGLog_Firefox*.

I’m affacted and I wanted to know what mail content was logged. So here’s an example how sweet and easy groovy can handle jobs like that, including some code that cleans up the un-readable chars.