nakagami / firebirdsql

Firebird RDBMS sql driver for Go (golang)
MIT License
227 stars 60 forks source link

Fix read and write when using wire encryption. #47

Closed thezbyg closed 6 years ago

thezbyg commented 6 years ago

Read and write functions work correctly only until read reads less bytes than requested or write writes less bytes than requested. Read function fails because it decrypts whole read buffer which is only partially filled with valid data. Write function fails because it encrypts whole buffer, but sends only part of encrypted bytes.

These commits fix both issues.

nakagami commented 6 years ago

Thanks