On Fri, Jul 28, 2000 at 12:04:06PM +0530, Amit Chopra wrote:

>> SSL_write will send the data passed to it in a single record unless
>> unless the request is too large for one record.  So for efficiency,
>> avoid repeated calls to SSL_write with small (less than 16 KB)
>> payloads if you can; if you buffer the data until you have 16 KB, then
>> some network overhead will be avoided.

> The SSLPlainText record, the SSLCompressed record and the SSLCipherText
> record all have a length field. Then what does it mean to say that the 
> record size is 16 KB ? and which of the the above 3 records is 
> it? 
> 
> Lets say a server wants to write plaintext of just 1 KB ? Must OpenSSL 
> then, somehow buffer/encrypt this data to become 16 KB (becasue as 
> pointed out SSL_read won't return until it has a complete record)? 

No, the record payload can be smaller than 16 KB and the record won't
be padded (except as far as necessary for the cipher).  But each
record has a record header, and if you use smaller records, then a
larger percentage of network traffic will be record headers.
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to