git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b206816
)
s3-passdb: Convert lm_pw and nt_pw to python string using length
author
Amitay Isaacs
<amitay@gmail.com>
Thu, 25 Aug 2011 06:48:40 +0000
(16:48 +1000)
committer
Andrew Bartlett
<abartlet@samba.org>
Fri, 26 Aug 2011 00:06:32 +0000
(10:06 +1000)
lm_pw and nt_pw are fixed length strings and convert them to python
strings as fixed length strings.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
source3/passdb/py_passdb.c
patch
|
blob
|
history
diff --git
a/source3/passdb/py_passdb.c
b/source3/passdb/py_passdb.c
index e23f47578e8d0ce89f97d52f82bdb9f25a393351..cc59b64608e958375de2d509ea47a13db757c5ed 100644
(file)
--- a/
source3/passdb/py_passdb.c
+++ b/
source3/passdb/py_passdb.c
@@
-613,7
+613,7
@@
static PyObject *py_samu_get_lanman_passwd(PyObject *obj, void *closure)
Py_RETURN_NONE;
}
- py_lm_pw = PyString_FromString
(lm_pw
);
+ py_lm_pw = PyString_FromString
AndSize(lm_pw, LM_HASH_LEN
);
return py_lm_pw;
}
@@
-639,7
+639,7
@@
static PyObject *py_samu_get_nt_passwd(PyObject *obj, void *closure)
Py_RETURN_NONE;
}
- py_nt_pw = PyString_FromString
(nt_pw
);
+ py_nt_pw = PyString_FromString
AndSize(nt_pw, NT_HASH_LEN
);
return py_nt_pw;
}