IVisualizerObjectProvider2.Deserialize(Stream) Method

Definition

Legacy helper method used by old visualizers that makes it easier to write deserialization code. It uses default binary serialization to read the given object from the stream. However, due to security vulnerabilities with its usage, it should no longer be used, and will throw on newer versions of .NET like ASP.NET Core 5.0.

If called on a target app that supports Binary Serialization, after the method finishes the stream is read and we return the underlying object.

public:
 System::Object ^ Deserialize(System::IO::Stream ^ stream);
public object Deserialize (System.IO.Stream stream);
abstract member Deserialize : System.IO.Stream -> obj
Public Function Deserialize (stream As Stream) As Object

Parameters

stream
Stream

The stream from which to read the object

Returns

Object

An object which was previously serialized into the stream

Exceptions

Will throw when the target app does not support serialization through BinaryFormatter.

Applies to