diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2008-12-21 03:37:31 +0100 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2008-12-21 03:37:31 +0100 |
commit | bfb29e94b1e9cbbbca4dcfbbad171ba10e09ce07 (patch) | |
tree | 2727d3ff8933035a1890b4936264884c9196586d /source4/scripting | |
parent | 2e7a6cb6bf32a49682ccadc07244d3a6ae4058d3 (diff) | |
download | samba-bfb29e94b1e9cbbbca4dcfbbad171ba10e09ce07.tar.gz samba-bfb29e94b1e9cbbbca4dcfbbad171ba10e09ce07.tar.bz2 samba-bfb29e94b1e9cbbbca4dcfbbad171ba10e09ce07.zip |
Convert auth python module to "plain" C rather than using SWIG.
Diffstat (limited to 'source4/scripting')
-rw-r--r-- | source4/scripting/python/config.mk | 2 | ||||
-rw-r--r-- | source4/scripting/python/pyglue.c | 8 |
2 files changed, 8 insertions, 2 deletions
diff --git a/source4/scripting/python/config.mk b/source4/scripting/python/config.mk index 1f57294c59..71432042fc 100644 --- a/source4/scripting/python/config.mk +++ b/source4/scripting/python/config.mk @@ -17,7 +17,7 @@ python_uuid_OBJ_FILES = $(pyscriptsrcdir)/uuidmodule.o [PYTHON::python_glue] LIBRARY_REALNAME = samba/glue.$(SHLIBEXT) -PRIVATE_DEPENDENCIES = LIBNDR LIBLDB SAMDB CREDENTIALS swig_ldb python_dcerpc_misc python_dcerpc_security +PRIVATE_DEPENDENCIES = LIBNDR LIBLDB SAMDB CREDENTIALS swig_ldb python_dcerpc_misc python_dcerpc_security swig_auth python_glue_OBJ_FILES = $(pyscriptsrcdir)/pyglue.o diff --git a/source4/scripting/python/pyglue.c b/source4/scripting/python/pyglue.c index 381792b735..2d0af630c1 100644 --- a/source4/scripting/python/pyglue.c +++ b/source4/scripting/python/pyglue.c @@ -29,6 +29,7 @@ #include "libcli/util/pyerrors.h" #include "librpc/gen_ndr/py_misc.h" #include "librpc/gen_ndr/py_security.h" +#include "auth/pyauth.h" /* FIXME: These should be in a header file somewhere, once we finish moving * away from SWIG .. */ @@ -121,7 +122,12 @@ static PyObject *py_ldb_set_session_info(PyObject *self, PyObject *args) return NULL; PyErr_LDB_OR_RAISE(py_ldb, ldb); - /* FIXME: Magic py_session_info -> info */ + /*if (!PyAuthSession_Check(py_session_info)) { + PyErr_SetString(PyExc_TypeError, "Expected session info object"); + return NULL; + }*/ + + info = PyAuthSession_AsSession(py_session_info); ldb_set_opaque(ldb, "sessionInfo", info); |