I'm having some problems with secure connections in my implementation (
tedious <http://github.com/pekim/tedious>) of TDS. Under some conditions I 
don't get any response from the SQL Server instance to a TDS login packet 
sent to it.

If I use RC4-MD5 everything works fine. However if I use DES-CBC3-SHA then 
I experience the absence of a response from the server.
Enabling tls and net debug (NODE_DEBUG="tls net") sheds some light on the 
problem, assuming that I'm interpreting the messages correctly.

When using DES-CBC3-SHA, the data (for the TDS Login packet) is written to 
the cleartext stream, but nothing seems to come out of the encrypted 
stream. As this is a block cipher, I'm guessing that the problem is that 
there's not enough data to complete a block.
If that's the case, how can I tell the cleartext stream to 'flush' the 
data, and result in a padded-out block to be encrypted and written?

Bear in mind that there will be more requests sent over the same connection 
once the response has been received. So closing the stream and the TCP 
connection isn't practical.

Should BIO_flush be involved somewhere in node_crypto.cc?

Is it even a reasonable expectation to be able to use a block cipher for a 
request/response protocol like TDS? Is the problem really likely to be 
anything to do with stream vs. block ciphers?

If this is all rubish, and I'm barking up the wrong tree, What should my 
next steps in understanding the problem be?

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to