Hi all,

i want to set accessrights for a shared folder.

What I try to do is:

Code:
SHARE_INFO_502* pBuff = NULL;
long nRes = NetShareGetInfo( NULL, _T("public"), 502, (BYTE**)&pBuff );

BOOL bPresent=0;
BOOL bDefault=0;
PACL	acl = NULL;
 if (!GetSecurityDescriptorDacl(pBuff->shi502_security_descriptor, 
            &bPresent,     // bDaclPresent flag   
            &acl, 
            &bDefault))   // not a default DACL 
    {
        printf("GetSecurityDescriptorDacl Error %u\n",
                GetLastError());
    }
The call to GetSecurityDescriptorDacl blocks seemingliy forever. When I try to call SetSecurityDescriptorDacl it retuns 'The Security Descriptor is invalid'...

Any Ideas??

Regards,
Christoph