IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
Port parts of Wireshark commit a58c986f to the samba repo.
Signed-off-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Sort of re-apply Wireshark commit 79cd356 which was never sync with
samba. It was reverted then reintroduced in the WS repo (yes this is
quite convulted).
Original commit message:
Author: Michael Mann <mmann78@netscape.net>
Date: Wed Nov 6 12:36:09 2013 +0000
Remove pinfo->private_data from DCERPC dissectors. Bug 9387 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9387)
This is the PIDL input file changes necessary to support removing pinfo->private_data from the DCERPC dissectors in favor of passing it through function parameters. I didn't regenerate the dissector source, so this is just a "good faith" effort to mimic the manual changes.
svn path=/trunk/; revision=53098
Signed-off-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Port Wireshark commit 499d959
Author: Guy Harris <guy@alum.mit.edu>
Date: Tue Mar 3 02:47:53 2015 -0800
Eliminate e_uuid_t in favor of e_guid_t.
That eliminates a redundant and confusing data type, and avoids issues
with one piece of code using e_uuid_t but wanting to use routines
expecting an e_guid_t.
Change-Id: I95e172d46d342ab40f6254300ecbd2a0530cde60
Reviewed-on: https://code.wireshark.org/review/7506
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Signed-off-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Port Wireshark commit 683d657
Author: Alexis La Goutte <alexis.lagoutte@gmail.com>
Date: Sun Oct 5 19:27:15 2014 +0200
PIDL (DCERPC): fix Assigned value is garbage or undefined found by Clang Analyzer
packet-dcerpc-dnsserver.c:1002:12: warning: Assigned value is garbage or undefined
packet-dcerpc-frstrans.c:1137:12: warning: Assigned value is garbage or undefined
packet-dcerpc-lsa.c:6345:12: warning: Assigned value is garbage or undefined
packet-dcerpc-nspi.c:7805:12: warning: Assigned value is garbage or undefined
packet-dcerpc-dfs.c:3245:11: warning: Function call argument is an uninitialized value
packet-dcerpc-dfs.c:3245:9: warning: 'level' may be used uninitialized in this function [-Wmaybe-uninitialized]
Change-Id: Ife6a2f565ae215535d0e3d72ef50800114240e3f
Reviewed-on: https://code.wireshark.org/review/4478
Reviewed-by: Evan Huus <eapache@gmail.com>
Signed-off-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Port Wireshark commit f6b9e7a
Author: Alexis La Goutte <alexis.lagoutte@gmail.com>
Date: Sun Sep 28 20:57:13 2014 +0200
PIDL: Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: Ibae478771b30d6e9ae07315985f1e71bc6b65423
Reviewed-on: https://code.wireshark.org/review/4350
Reviewed-by: Michael Mann <mmann78@netscape.net>
Signed-off-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Deleting an attribute in Python (using the "del" statement) is (at
some stages along a winding path, for C objects) converted into
setting the attribute to NULL. Not None, actual NULL. The way we
handled this NULL was to dereference it. This changes the behaviour to
raising an AttributeError, which is more or less what Python does in
similar situations with builtin objects.
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
The previous string handling assumed the python variables referenced
by PyString_AS_STRING had infinite life. When they were re-used
the C structure started to point at unexpected things.
We now check correctly for Unicode in every case, and we always
duplicate the string with talloc_strdup()
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
When pulling complex structures like nt-acls, a long list of tokens may
be produced. By removing tokens along the way with ndr_token_steal,
future calls to retrieve from the token list are not as expensive.
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
When pulling complex structures like nt-acls, a long list of tokens
may be produced. This change means the token list won't be walked in the
buffers case if the switch value is not needed.
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
This is so we free the ndr_push_struct_blob() return value after
we make it into a string
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
This is already set to pytalloc_get_mem_ctx(py_obj)
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
The new talloc.BaseObject allow us to hold a talloc context per
python object (there may be many referring to the same C object)
and the talloc context that the actual object pointer is under.
Another advantage is that talloc.BaseObject(), has less of
an ABI surface.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
This changes the type used for # arguments to PyArg_ParseTupleAndKeywords
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
This should isolate any coverity warnings on 64-bit platforms
(where LONG_MAX is larger than any possible 32 bit value) to
a single spot, or possibly eliminate it.
This is needed for the unsigned 64 bit case, and on 32 bit
systems, as PyInt_FromLong is limited to a signed "long" int.
The compiler should be able to eliminate many of these calls
with the embedded type knowlege.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
This avoids a << of 64 bits in the unused end of the conditional expression.
This was flagged by Coverity and the fix was suggested by metze.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429
Andrew Bartlett
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
We do not write network services in Python, so this is not a security issue, but would cause
a crash or other odd behaviour if the length was changed
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11430
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
In particular, it is critical that we use unsigned integers of
sufficient size in python for unsigned C integers, and it is
critical that we check for overflow at both the python and C
level.
Otherwise, we may both represent and sort these incorrectly,
in particular when sorting attributeID values from DRSUAPI
which are represented as an signed enum in C and a uint32_t in IDL,
but which often has the high bit set (in schema extensions).
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
We now pass multiple callbacks $check, $cleanup, $return
down to AllocOutVar().
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
This follows their treatment in librpc/ndr/ndr_basic.c.
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue Jul 7 07:19:49 CEST 2015 on sn-devel-104
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This caused a compilation error on i386:
default/librpc/gen_ndr/py_server_id.c:216:75: error: overflow in implicit constant conversion [-Werror=overflow]
PyModule_AddObject(m, "SERVERID_UNIQUE_ID_NOT_TO_VERIFY", PyInt_FromLong(0xFFFFFFFFFFFFFFFFULL));
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This was reported by Coverity as
CID 1288527: Null pointer dereferences (REVERSE_INULL)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
This changes
for (value_cntr_1 = 0; value_cntr_1 < r->out.length?*r->out.length:0; value_cntr_1++) {
into:
for (value_cntr_1 = 0; value_cntr_1 < (r->out.length?*r->out.length:0); value_cntr_1++) {
it fixes a possible endless loop resulting in a crash.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
This changes
for (value_cntr_1 = 0; value_cntr_1 < r->out.length?*r->out.length:0; value_cntr_1++) {
into:
for (value_cntr_1 = 0; value_cntr_1 < (r->out.length?*r->out.length:0); value_cntr_1++) {
it fixes a possible endless loop resulting in a crash.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri May 15 22:19:38 CEST 2015 on sn-devel-104
This stops emmiting hundreds of warnings when compiling with
-Wmissing-prototypes.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Mar 25 20:45:01 CET 2015 on sn-devel-104
This is necessary since Server.pm generates calls to DEBUG().
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Mar 24 02:40:00 CET 2015 on sn-devel-104
This macro was used for compatibility with broken compilers.
Since Python 2.3, it is always defined as `static`, and only exists
"for source compatibility with old C extensions".
Signed-off-by: Petr Viktorin <pviktori@redhat.com>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Matthieu Patou <mat@matws.net>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Fri Oct 24 01:39:16 CEST 2014 on sn-devel-104