Magnus,
> There is a fixed buffer of 1024 bytes. I have a feeling ythat one has to
> be changed to dynamic.
>
You're quite right. The 'InfoBufferSize' denotes 1122 bytes after this call.
if(!GetTokenInformation(AccessToken,TokenGroups,InfoBuffer,1024,&InfoBufferSize))
Regards,
Thomas Hallgren