Вопрос

When I called GetNamedSecurityInfo API and it succeeded, the MSDN states that I need to call LocalFree on ppSecurityDescriptor, but what about ppDacl and ppSacl?

Это было полезно?

Решение

According to MSDN:

A pointer to a variable that receives a pointer to the owner SID in the security descriptor

A pointer to a variable that receives a pointer to the primary group SID in the returned security descriptor

A pointer to a variable that receives a pointer to the DACL in the returned security descriptor

A pointer to a variable that receives a pointer to the SACL in the returned security descriptor

those parameters will point to the corresponding parameters in the security descriptor returned in ppSecurityDescriptor.

You only need to free ppSecurityDescriptor as the other pointers point to the fields within the security descriptor.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top