libinjection
libinjection copied to clipboard
Python 3 binding
Has anybody used libinjection with python 3.5? I didn't find any info about python 3 support. I built libinjection python version with -py3 swig option and got the module:
# pip3 show libinjection
---
Metadata-Version: 1.1
Name: libinjection
Version: 3.9.1
Summary: Wrapper around libinjection c-code to detect sqli
Home-page: https://libinjection.client9.com/
Author: Nick Galbreath
Author-email: [email protected]
License: UNKNOWN
Location: /usr/local/lib/python3.5/dist-packages/libinjection-3.9.1-py3.5-linux-x86_64.egg
Requires:
Classifiers:
Intended Audience :: Developers
License :: OSI Approved :: BSD License
Topic :: Database
Topic :: Security
Operating System :: OS Independent
Development Status :: 3 - Alpha
Topic :: Internet :: Log Analysis
Topic :: Internet :: WWW/HTTP
I can import the module without errors, but I can't use libinjection functions (from the docs):
Python 3.5.1+ (default, Mar 30 2016, 22:46:26)
[GCC 5.3.1 20160330] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from libinjection import *
>>> sqli_state()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'sqli_state' is not defined
The same code works well on python 2.7
Python 2.7.11+ (default, Apr 17 2016, 14:00:29)
[GCC 5.3.1 20160413] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from libinjection import *
>>> sqli_state()
<Swig Object of type 'libinjection_sqli_state *' at 0x7f1827952f48>
It will be really great if somebody can help me with this question. Thanks!
sorry, I don't really know what do here. I hope someone else can help with the python swig bindings!
@client9 does this support Python 3 yet?
@oxr463 working on it at: libinjection/libinjection#4