public unsafe static SecurityStatus SafeQueryContextAttributes(ref SafeCtxtHandle context, out string name) { SecPkgContext_Names[] array = new SecPkgContext_Names[1]; fixed(IntPtr *ptr = array) { SecurityStatus result = Sspi.SafeQueryContextAttributes(ref context, UlAttribute.SECPKG_ATTR_NAMES, (void *)ptr); name = Marshal.PtrToStringAnsi(array[0].sUserName); Secur32Dll.FreeContextBuffer(array[0].sUserName); return(result); } }
public unsafe static SecurityStatus SafeQueryContextAttributes(ref SafeCtxtHandle context, out SecPkgContext_Sizes packageSizes) { return(Sspi.SafeQueryContextAttributes(ref context, UlAttribute.SECPKG_ATTR_SIZES, (void *)(&packageSizes))); }