python - Convert raw socket data into readable form -



python - Convert raw socket data into readable form -

i working on network analyzer. have used code available form http://www.binarytides.com/python-packet-sniffer-code-linux/. info section output of programme follows:

content-type: text/html; charset=iso-8859-1

m�ak�0 ���zo�aqz��▒�&e�� �s�эu���v:���� ����'qw�oձ.�u�up7/�~ ��}�v��*n�<���j&��w/�%mb��$7��a���i�����g���d�ryo�&�gx֗�uc▒~t�!b�7�.@ !� ��>�6��yԭ%��x9�7�i�i ��w���

�� o��?6�]��l���k��

i need convert raw info readable form , analyze data.i using using python 2.7.

if @ content-encoding header, says gzip. means web-page compressed using gzip algorithm. such it's binary info can't print out, have uncompress first.

you can utilize python gzip module that.

python sockets

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -