summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/librpc/idl/winreg.idl21
-rwxr-xr-xsource4/scripting/swig/torture/winreg.py34
2 files changed, 40 insertions, 15 deletions
diff --git a/source4/librpc/idl/winreg.idl b/source4/librpc/idl/winreg.idl
index 46fa8d0d67..d1b5fc5459 100644
--- a/source4/librpc/idl/winreg.idl
+++ b/source4/librpc/idl/winreg.idl
@@ -144,15 +144,30 @@
uint8 buffer[len];
} winreg_Uint8buf;
+ typedef struct {
+ uint32 max_len;
+ uint32 offset;
+ DATA_BLOB buffer;
+ } foo2;
+
+ typedef struct {
+ uint16 len;
+ uint16 max_len;
+ foo2 *buffer;
+ } foo1;
+
/******************/
/* Function: 0x0a */
WERROR winreg_EnumValue(
[in,ref] policy_handle *handle,
[in] uint32 enum_index,
- [out,ref] winreg_EnumValueName *name,
+ [in,out] foo1 foo,
+ /* [out,ref] winreg_EnumValueName *name, */
[in,out] uint32 *type,
- [in,out] winreg_Uint8buf *value,
- [in,out] uint32 *returned_len
+ [in,out] foo2 *foo2,
+ /* [in,out] winreg_Uint8buf *value, */
+ [in,out] uint32 *value1,
+ [in,out] uint32 *value2
);
/******************/
diff --git a/source4/scripting/swig/torture/winreg.py b/source4/scripting/swig/torture/winreg.py
index abc9fa2245..acf319d6f9 100755
--- a/source4/scripting/swig/torture/winreg.py
+++ b/source4/scripting/swig/torture/winreg.py
@@ -74,30 +74,40 @@ def test_Enum(pipe, handle, depth = 0):
# Enumerate values
- return
-
r = {}
r['handle'] = handle
- r['name'] = {}
- r['name']['len'] = 0
- r['name']['max_len'] = 0
- r['name']['name'] = {}
- r['name']['name']['max_len'] = 0
- r['name']['name']['offset'] = 0
- r['name']['name']['len'] = 0
- r['name']['name']['buffer'] = None
+
+ keyinfo['max_valnamelen'] = 18
+ keyinfo['max_valbufsize'] = 0x31f5
+
+ r['foo'] = {}
+ r['foo']['len'] = 0
+ r['foo']['max_len'] = keyinfo['max_valnamelen'] * 2
+ r['foo']['buffer'] = {}
+ r['foo']['buffer']['max_len'] = keyinfo['max_valnamelen']
+ r['foo']['buffer']['offset'] = 0
+ r['foo']['buffer']['len'] = 0
+ r['foo']['buffer']['buffer'] = ''
r['type'] = 0
r['value'] = {}
- r['value']['max_len'] = 0
+ r['value']['max_len'] = keyinfo['max_valbufsize']
r['value']['offset'] = 0
r['value']['len'] = 0
r['value']['buffer'] = []
r['returned_len'] = 0
+ r['foo2'] = {}
+ r['foo2']['max_len'] = keyinfo['max_valbufsize']
+ r['foo2']['offset'] = 0
+ r['foo2']['len'] = 0
+ r['foo2']['buffer'] = ''
+ r['value1'] = keyinfo['max_valbufsize']
+ r['value2'] = 0
for i in range(0, keyinfo['num_values']):
r['enum_index'] = i
-
+
+ print keyinfo
print dcerpc.winreg_EnumValue(pipe, r)
sys.exit(1)