BSTR is an OLE automation type for transferring length-prefixed strings, either Unicode or ANSI, as well as length-prefixed binary data.
The BSTR type defined in this section specifies the wire representation of a length-prefixed data block whose memory representation is specified in [MS-DTYP] section 2.2.5. To clarify, the memory specification will be referred to as the presented BSTR, and the wire specification will be referred to as the transmitted BSTR.
For any document referencing both [MS-DTYP] and [MS-OAUT], specifying BSTR in a wire representation context MUST be considered as a reference to the transmitted BSTR type, while specifying BSTR in a memory representation context MUST be considered as a reference to the presented BSTR type ([MS-DTYP] section 2.2.5). Reflecting the terminology used for presented BSTRs, a NULL BSTR, or NULL transmitted BSTR, is defined as the wire representation of a NULL presented BSTR; and an empty BSTR, or empty transmitted BSTR, is defined as the wire representation of a zero-length presented BSTR. Preserving this distinction in the wire representation enables clients and servers to distinguish between NULL presented BSTRs and zero-length presented BSTRs, and thus associate possibly different, application-specific semantics to these two values.