NetUserModalsGet call to samba 2.2.2 fails

Tyler, Ross E retyler at
Thu Nov 15 06:09:02 GMT 2001

the following code, in the context of an anonymous session with a samba
2.2.2 machine, fails.
(actually the code has failed since samba ~1.19 - it used to give an
access violation).

    static wchar_t sambaMachine[] = L"\\\\";    // IP
address of my samba machine
    USER_MODALS_INFO_2 * domainIdInfo = 0;
    long error = NetUserModalsGet(sambaMachine, 2, (BYTE **)

the error is

    0x57: The parameter is incorrect

i have traced the problem on the smbd side using gdb and have found that

    rpc_server/srv_samr_nt.c : _samr_query_dom_info




    q_u->switch_value == 5

any ideas?
-------------- next part --------------
An embedded message was scrubbed...
From: "Tyler, Ross E" <retyler at>
Subject: NetUserModalsGet call to samba 2.2.2 fails
Date: Wed, 14 Nov 2001 11:54:57 -0800
Size: 1244

More information about the samba-ntdom mailing list