HTTPTunnelUtils.pm ... encode_base64 (or the calls) is suspicious.
I wasn't able to do a binary transport. Wireshark and vbindiff have shown me that there are two 0x0's encoded at the end of the "chunk".
I was able to fix the function. However, I prefer calling encode_base64 from MIME:Base64, so I changed the calls mimic its behaviour.
Now when MIME:Base64 is present, it is used. Otherwise we fall back to "our" functions.
Patch is included.
Base64 padding bug patch