internal override SecBuffer ToBuffer(DisposableList list) { SEC_CHANNEL_BINDINGS sec_channel_bind = new SEC_CHANNEL_BINDINGS(); sec_channel_bind.cbApplicationDataLength = _channel_binding_token.Length; sec_channel_bind.dwApplicationDataOffset = Marshal.SizeOf(typeof(SEC_CHANNEL_BINDINGS)); using (var binding = new SafeStructureInOutBuffer <SEC_CHANNEL_BINDINGS>(sec_channel_bind, _channel_binding_token.Length, true)) { binding.Data.WriteBytes(_channel_binding_token); return(SecBuffer.Create(SecurityBufferType.ChannelBindings | SecurityBufferType.ReadOnly, binding.ToArray(), list)); } }
internal override SecBuffer ToBuffer(DisposableList list) { return(SecBuffer.Create(_type, _size, list)); }