My current method isn't working, because as far as I can tell the headers aren't always the first bytes received? It's simple enough to do in Python/PHP/etc.
(Backstory: you can change the headers you send to request metadata, which will include an ice-metaint field. Every $metaint bytes will be a metadata string with server name, song title, etc. Well, there will be a byte that you multiply by 16 to see how long the metadata is, and it can be 0.)