00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef _PY_COMMON_H
00022 #define _PY_COMMON_H
00023
00024 #include "includes.h"
00025
00026
00027
00028
00029 #ifdef HAVE_FSTAT
00030 #undef HAVE_FSTAT
00031 #endif
00032
00033 #include "Python.h"
00034
00035
00036
00037 PyObject *py_werror_tuple(WERROR werror);
00038 PyObject *py_ntstatus_tuple(NTSTATUS ntstatus);
00039 void py_samba_init(void);
00040 PyObject *get_debuglevel(PyObject *self, PyObject *args);
00041 PyObject *set_debuglevel(PyObject *self, PyObject *args);
00042 PyObject *py_setup_logging(PyObject *self, PyObject *args, PyObject *kw);
00043 BOOL py_parse_creds(PyObject *creds, char **username, char **domain,
00044 char **password, char **errstr);
00045 struct cli_state *open_pipe_creds(char *server, PyObject *creds,
00046 int pipe_idx, char **errstr);
00047 BOOL get_level_value(PyObject *dict, uint32 *level);
00048
00049
00050
00051 BOOL py_from_SID(PyObject **obj, DOM_SID *sid);
00052 BOOL py_to_SID(DOM_SID *sid, PyObject *obj);
00053 BOOL py_from_ACE(PyObject **dict, SEC_ACE *ace);
00054 BOOL py_to_ACE(SEC_ACE *ace, PyObject *dict);
00055 BOOL py_from_ACL(PyObject **dict, SEC_ACL *acl);
00056 BOOL py_to_ACL(SEC_ACL *acl, PyObject *dict, TALLOC_CTX *mem_ctx);
00057 BOOL py_from_SECDESC(PyObject **dict, SEC_DESC *sd);
00058 BOOL py_to_SECDESC(SEC_DESC **sd, PyObject *dict, TALLOC_CTX *mem_ctx);
00059
00060 #endif