Your example message looks like the body is separated from the header by CRLF or some perhaps just LF. You could just read and throw away characters until you see a LF, then copy the body to your buffer. Does the body have a similar entry at the end of it?