upload binary data or file from memory using python http post
<p>I have seen the receipes for uploading files via <a href="http://code.activestate.com/recipes/146306-http-client-to-post-using-multipartform-data/" rel="nofollow">multipartform-data</a> and <a href="http://code.activestate.com/recipes/576422/" rel="nofollow">pycurl</a>. <br> Both methods seem to require a file on disk.  <br> Can these recipes be modified to supply binary data from memory instead of from disk ? <br>I guess I could just use a <a href="http://docs.python.org/library/xmlrpclib.html#binary-objects" rel="nofollow">xmlrpc server</a> instead.<br>I wanted to get around having to encode and decode the binary data and send it raw...  <br>Do pycurl and mutlipartform-data work with raw data ? </p>
