.tlspeekdata Method


For the currently selected socket (selection is made through sock.num), returns a string that contains a "preview" of the data in the TLS RX buffer. The data is NOT deleted from the TLS RX buffer.


sock.tlspeekdata(maxinplen as word) as string


String containing the data from the TLS RX buffer.

See Also:

Transport Layer Security (TLS), Sending and Receiving Data, sock.tlsgetdata




The maximum number of data bytes to preview (word).


The length of returned data is limited by one of the three factors (whichever is smaller): the amount of data in the TLS RX buffer itself, the capacity of the "receiving" string variable, and the limit set by the maxinplen argument. String variables can hold up to 255 bytes of data, so this method will only allow you to preview up to 255 "next" bytes from the TLS RX buffer.