GithubHelp home page GithubHelp logo

regit / pynetfilter_conntrack Goto Github PK

View Code? Open in Web Editor NEW
30.0 30.0 21.0 105 KB

Python binding of libnetfilter_conntrack

License: GNU General Public License v2.0

Makefile 3.70% C 23.34% Python 72.97%

pynetfilter_conntrack's People

Contributors

allfro avatar meteozond avatar regit avatar sskaje avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pynetfilter_conntrack's Issues

pynetfilter_conntrack examples

Hi,
I have cloned your project and want to use it. However, I'm stuck in using Filter.
For example, in case I want to get the result like: "conntrack -L -p tcp -s 127.0.0.1", how can I use your library?

Package available in pip3, but not ported to python 3

pynetfilter_conntrack can be installed with pip3.

$ sudo pip3 install pynetfilter_conntrack
Collecting pynetfilter_conntrack
Installing collected packages: pynetfilter-conntrack
Successfully installed pynetfilter-conntrack-0.7
$

The installed files are identical to what comes from pip (python 2) though:

$ DIR2="/usr/local/lib/python2.7/dist-packages/pynetfilter_conntrack"
$ DIR3="/usr/local/lib/python3.5/dist-packages/pynetfilter_conntrack"
$ find "${DIR2}" -name \*.py -printf "%f\n" | while read -r FILE; do diff -u "${DIR2}/${FILE}" "${DIR3}/${FILE}"; done
$ 

The code is not valid python3:

$ python3 -c 'import pynetfilter_conntrack'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/lib/python3.5/dist-packages/pynetfilter_conntrack/__init__.py", line 2, in <module>
    from pynetfilter_conntrack.tools import *
  File "/usr/local/lib/python3.5/dist-packages/pynetfilter_conntrack/tools.py", line 38
    shift = 0L
             ^
SyntaxError: invalid syntax
$

The code should either be forward-ported or be removed from pip3.

What is the status of of the project?

  1. Looks like Official page is down. Is it an official repo?
  2. setup.py points to the missing README (after the renaming it into the README.rst).
  3. 0.5 version is released but the latest the pypi repo version is 0.4.2.
  4. 0.5 version is trying to import missing nfct_conntrack_compare sysmbol.
  5. 0.4.2 randomly fails into the maximum recursion depth exceeded.

PyPi tarball misses some files

The following files are missing in the PyPi 0.6 tarball:

  • README.rst
  • INSTLL
  • ChangeLog
Traceback (most recent call last):
  File "setup.py", line 19, in <module>
    LONG_DESCRIPTION = open("README.rst").read() + open("INSTALL").read() + open("ChangeLog").read()
IOError: [Errno 2] No such file or directory: 'README.rst

Segfault after instantiation of class

I experience a segfault with pynetfilter_conntrack, reproducible with:

$ python -c "import pynetfilter_conntrack; pynetfilter_conntrack.Conntrack()"

Since issue #4 is specific regarding the call to catch() I believe this is not a duplicate.

Versions (Debian stretch):

  • pynetfilter-conntrack: 0.7 (from pip)
  • libnetfilter-conntrack: 1.0.6
  • linux: 4.9.0

Here are an example python file and the gdb 'backtrace full' after the segfault.

gdb-output.txt
ct.py.txt

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.