1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-29 21:47:30 +03:00
Volker Lendecke 6f81f07303 dbwrap_watch: Protect against corrupt records
If locking.tdb contains invalid records, "get_file_infos" called from directory
enumeration crashes in Samba 4.4. The reason is that if "dbwrap_watched_parse"
returns -1 due to record corruption, dbwrap_watched_parse_record returns
NT_STATUS_OK without having called the parse function. Before 66cba9939b76f
this led to "lck->data" to be uninitialized data, so smbd 4.4 would crash in
this case.  After 66cba9939b76f we implicitly initialize "state.lck" to NULL,
so we don't have this particular problem anymore

Apply the fix in master too, returning NT_STATUS_OK from parse_record without
having called the parser could lead to bugs in other cases too.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2017-05-01 10:40:21 +02:00
..
2014-01-03 05:04:44 +01:00
2017-02-22 08:26:22 +01:00
2017-02-22 08:26:22 +01:00
2017-02-22 08:26:22 +01:00
2017-02-22 08:26:22 +01:00
2013-05-18 16:32:38 +02:00
2015-03-17 11:30:52 +01:00
2017-04-20 14:23:14 +02:00