internal FirewallTokenInformation(FWP_TOKEN_INFORMATION token_info) { Sids = ReadSids(token_info.sids, token_info.sidCount); RestrictedSids = ReadSids(token_info.restrictedSids, token_info.restrictedSidCount); Capabilities = new List <UserGroup>(); UserSid = null; AppContainerSid = null; }
internal FWP_TOKEN_INFORMATION ToStruct(DisposableList list) { var ret = new FWP_TOKEN_INFORMATION(); var sids = list.CreateSidAndAttributes(Sids); ret.sidCount = Sids.Count; ret.sids = list.AddResource(sids.ToBuffer()).DangerousGetHandle(); ret.restrictedSidCount = RestrictedSids.Count; sids = list.CreateSidAndAttributes(RestrictedSids); ret.restrictedSids = list.AddResource(sids.ToBuffer()).DangerousGetHandle(); return(ret); }
internal FirewallTokenInformation(FWP_TOKEN_INFORMATION token_info) { Sids = ReadSids(token_info.sids, token_info.sidCount); RestrictedSids = ReadSids(token_info.restrictedSids, token_info.restrictedSidCount); }