I need to build a tcp frame with raw binary data, but all examples and tutorials I\'ve found talking about bytes always involve conversion from a string, and that\'s not wha
I think Scapy is what are you looking for.
http://www.secdev.org/projects/scapy/
you can build and send frames (packets) with it