Open GoogleCodeExporter opened 9 years ago
Any plans to release a 2.6 binary for windows?
Original comment by justinhomi@gmail.com
on 7 May 2009 at 10:23
winpcap development is free.
http://www.winpcap.org/install/bin/WpdPack_4_0_2.zip
1) Download MinGW32. Install to c:\wingw32
2) path=%path%;c:\wingw32\bin
3) Download winpcap development pack from above. Unzip to c:\WpdPack
4) From pypcap-1.1 directory.
> python .\setup.py --with-pcap="C:\WpdPack"
> python .\setup.py build -cmingw32
> python .\setup.py install
Original comment by johannse...@gmail.com
on 19 May 2009 at 1:27
Sorry, this doesn't work.
First, the MinGW32 folder should be c:\MinGW.
Even so, second, there's no Python that gets installed with MinGW!!! Nor any
option
to do so. g++, etc., yes. Buy no python. I AM running the standard Python 2.6
however, but when I try
setup.py --with-pcap="C:\WpdPack"
it's clueless about --with, says bad option.
Appreciate any help you can give, I'm blocked.
Thanks in advance, -david
Original comment by davidsch...@gmail.com
on 7 Oct 2009 at 9:40
Try this (after installing MinGW, adding its \bin subdirectory to your PATH and
extracting WpdPack to C:\WpdPack as shown above):
python setup.py config --with-pcap="C:\WpdPack"
python setup.py build -cmingw32
python setup.py bdist_wininst
The installer will be put into the \dist subdirectory of pypcap.
An alternative way:
The default argument of --with-pcap is "..\WpdPack". So if you put WpdPack to a
sibling directory of your pypcap directory, you don't need to specify it
explicitly:
python setup.py config
Moreover, you can set the default compiler for distutils to MinGW by creatiing
a file
"C:\Python26\Lib\distutils\distutils.cfg" that has the following two lines:
[build]
compiler = mingw32
Then you do not need to specify the compiler:
python setup.py build
Hope that helps.
Regards
Dirk
Original comment by Dirk.L...@gmail.com
on 23 Oct 2009 at 9:15
(On WinXP/Python 2.6)
I've gotten a bunch of it to work by modifying the python 2.5 binaries in a hex
editor (after extracting pcap.pyd). This is obviously pretty dangerous, but it's
worked so far:
import pcap #with pcap.pyd in the current directory
#see http://www.monkey.org/~dugsong/pypcap/pcap.html for reference
int = pcap.pcap(pcap.lookupdev())
timestamp, pkt = int.next()
print timestamp
print str(pkt) #this gives you the actual contents of the buffer
Original comment by sam.m.bi...@gmail.com
on 12 Nov 2009 at 12:56
Attachments:
Hi,
I just build a windows installer distribute for Python 2.6. And it seems work
fine.
http://static.ez2learn.com/temp/pcap-1.1.win32-py2.6.exe
Hope this could be helpful.
Victor Lin.
Original comment by Borns...@gmail.com
on 4 Jan 2010 at 12:49
Hi Victor Lin, Is this the same as pcapy module?
Original comment by elar...@googlemail.com
on 4 Feb 2010 at 1:15
Just a quick note.
1) Download and install MinGW32.
2) add MinGW's "\bin" path to your PATH variable
3) Download winpcap development pack
http://www.winpcap.org/install/bin/WpdPack_4_0_2.zip. Unzip to c:\WpdPack
4) From pypcap-1.1 directory:
> python setup.py config --with-pcap="C:\WpdPack"
> python setup.py build -cmingw32
> python setup.py bdist_wininst
The installer will be put into the \dist subdirectory of pypcap.
This worked!
But a side note will be that your anti virus application will most likely
detect this
installer as a security-risk to your computer. I'm no security expert so i
don't know
why this happens but it will. Tried it with the latest Norton (as of date,
"Norton
Internet Security 2010") and McAfee.
Don't forget to install the rest of the demanded packages:
http://trac.secdev.org/scapy/wiki/WindowsInstallationGuide
Original comment by Anton.Do...@gmail.com
on 24 Mar 2010 at 4:11
There is one caveat in using MinGW to build Windows binaries for pypcap:
Just building it "as is" will result in a binary which uses two different C
libaries.
msvcrt and msvcr71 (or msvcr90 for Python 2.7). This can be shown a tool like
Dependency Walker.
This will cause crashes on Vista and Win7. XP does not seem to be affected.
msvcrt is included because of the strdup() function and the name mangling
MinGW's libmoldname does to convert strdup() to the "leading underscore"
_strdup() name Windows uses.
Workaround: After generating the pcap.c file with Pyrex or Cython, replace all
occurences of strdup() in pcap.c with _strdup(). Then rebuild. msvcrt should
not be used anymore.
If somebody has a better solution for this, please let me know.
Regards
Dirk
References:
http://lists-archives.org/mingw-users/09604-linking-against-msvcr71-dll.html
http://trac.secdev.org/scapy/ticket/166
http://code.google.com/p/pyproj/issues/detail?id=15
Original comment by Dirk.L...@gmail.com
on 14 Jul 2010 at 9:44
Hello,
I compiled the version for anyone who looks for it...
Python26: http://ul.to/j6wuam0n
Python27: http://uploaded.to/file/773pq95y
one has to unpack it into the site-packages manually since i donnot know how to
build a .msi
Regards,
Me
Original comment by niccokun...@googlemail.com
on 22 Nov 2011 at 12:33
for Python2.7
Original comment by 1000...@gmail.com
on 24 Jun 2012 at 12:27
Attachments:
hi,i download the pcap-1.1.win32-py2.7.exe ,and i found dpkt-1.7.win32.exe here:
http://code.google.com/p/dpkt/downloads/list.
It is for py2.6 and py2.7.
Original comment by ParoA...@gmail.com
on 12 Jul 2012 at 3:30
Attachments:
Any one can upload a pypcap exe for python2.6 windows 64bits
i am carzy for this sujet and i lost 3 days just for looking a library.
i tried seach in google. MinGW32 MinGW64.
Original comment by 1989caoy...@gmail.com
on 17 Oct 2013 at 3:45
Original issue reported on code.google.com by
gissehel@gmail.com
on 31 Dec 2008 at 10:19