Age | Commit message (Collapse) | Author | Files | Lines |
|
Basically the same as REG_DWORD but these are eight byte long.
|
|
values
We need to support this as gd's WINREG torture test shows.
|
|
REG_SZ/REG_EXPAND_SZ values
We need to support this as gd's WINREG torture test shows.
|
|
|
|
Don't substitute existing data blobs with new ones and make sure, that the
result objects in the data blob don't have memory dependencies of the LDB value
input.
|
|
|
|
|
|
Break on errors and return NULL and otherwise the message pointer.
|
|
Move it into the REG_SZ/REG_EXPAND_SZ case block since it's used only there.
Plus convert it from static into dynamic talloc'ed.
|
|
|
|
This should let the new WINREG tests written by gd at least pass against us.
|
|
|
|
The previous logic was wrong since it tried to add empty data in some cases
which always ended in an error. This problem should be fixed with the new logic.
|
|
This to prevent segmentation faults, wrong server inputs ecc.
|
|
Also the s4 registry library has to have "unsigned" counters like the Windows
one.
|
|
Signed-off-by: Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de>
|
|
the registry tests were broken on big-endian systems
|
|
This allows us to reuse a ldb context if it is open twice, instead
of going through the expensive process of a full ldb open. We can
reuse it if all of the parameters are the same.
The change relies on callers using talloc_unlink() or free of a parent
to close a ldb context.
|
|
|
|
consistency with Samba 3.
|
|
list=""
list="$list event_context:tevent_context"
list="$list fd_event:tevent_fd"
list="$list timed_event:tevent_timer"
for s in $list; do
o=`echo $s | cut -d ':' -f1`
n=`echo $s | cut -d ':' -f2`
r=`git grep "struct $o" |cut -d ':' -f1 |sort -u`
files=`echo "$r" | grep -v source3 | grep -v nsswitch | grep -v packaging4`
for f in $files; do
cat $f | sed -e "s/struct $o/struct $n/g" > $f.tmp
mv $f.tmp $f
done
done
metze
|
|
|
|
make them wrappers around convert_string{,talloc}_convenience().
|
|
|
|
|
|
The original data pointer may go away so we do want to make copies in
this case.
This reverts commit 625359b2e266105022309df8985720108ecd6f67.
|
|
Conflicts:
source4/lib/registry/ldb.c
source4/rpc_server/winreg/rpc_winreg.c
|
|
|
|
With this patch the REG_BINARY type is saved directly in a LDB registry database rather than converted in a hex-string.
|
|
We should save data OS independent in the LDB files.
|
|
This fixes up the empty string problem in a better way without the need of changing the character conversion code.
|
|
and "QueryValue")
This prevents the server to segfault if the input data type is NULL.
|
|
doesn't has to be NULL
|
|
This reverts commit 82f50ea69f3aece4ac654ffdfa627babd8aadc25.
Cause: Windows (2000) doesn't accept the "data" pointer set to NULL
|
|
Prevent segfaults in some client applications (e.g. regdiff)
|
|
Cosmetic corrections
|
|
Some fixup's and assure, that we send only initialized values.
|
|
The return of the values of a certain key has been broken since I've introduced the default value.
Now the behaviour is correct: If no default value exists, start with index zero to fetch the other values. Otherwise let zero be the default value and enumerate the others starting with one.
|
|
It's better to use "CH_UNIX" for unpacking, because the system charset doesn't have to be UTF8 and we should be compatible with "reg_ldb_pack_value".
|
|
|
|
The REG_BINARY type is converted and stored in the LDB database as a leaf object with string-data.
The default attribute is saved directly in the hive object as the "data"-string.
|
|
The previous ldb_search() interface made it way too easy to leak results,
and being able to use a printf-like expression turns to be really useful.
|
|
(This used to be commit b4e1ae07a284c044704322446c94351c2decff91)
|
|
(This used to be commit f98b59021a5ea39c7970ebc5520d17775e500b8c)
|
|
When deleting a registry key that contains subkeys or values, Windows performs a
recursive deletion that removes any subkeys or values. This update makes
deletes for an ldb-backed registry consistent with Windows.
Under ldb, the deletion is done using an explicit transaction. If an error
occurs during the deletion the entire transaction is cancelled, leaving the
registry as it was before the deletions started.
(This used to be commit ca796c8fb10598674a5eef31d15863e79bcf3db8)
|
|
(This used to be commit a1280252ce924df69d911e597b7f65d8038abef9)
|
|
(This used to be commit dad809030478a85ac13a73bce9c07314792f01c2)
|
|
(This used to be commit 98ebdbe52fd615ea62a3caa17acfe8bb31b8f85d)
|
|
starting with "New Key #1" and iterating up to "New Key #99" before giving up.
ldb_open_key() calls reg_path_to_ldb() to build the appropriate dn from the key
name. reg_path_to_ldb() was not catching the error returned by
ldb_dn_add_base_fmt() due to the unescaped '#' character, causing the returned
dn to be that of the parent key, not the potential new key. Additionally,
Windows expects a return value of WERR_BADFILE when a key does not exist, but
WERR_NOT_FOUND was being returned instead. Correcting the building of the dn
and the providing the expected return value allows new key creation to succeed.
When attempting to delete a key, Windows passes the complete path to the key,
not just the name of the child key to be deleted. Using reg_path_to_ldb() to
build the correct dn allows key deletion to succeed.
(This used to be commit d57792d67b865ef43e7f21640b158862627f4b45)
|
|
Rather than map the error returned by the registry to the correct error,
return the correct error in the first place.
Also deal with the fact that the right error code is now returned in a
couple of places.
(This used to be commit 1e31fcb8a097810a97e2d4bb1f243f1b34cc2415)
|