Devessier / ssl

Clone of openssl in C for 42 School
GNU General Public License v3.0
0 stars 0 forks source link

Create buffer and file reader #7

Closed Devessier closed 3 years ago

Devessier commented 3 years ago

The implementation permits to read from a buffer or from a file. To read from a buffer, we should call create_reader_buffer. For a file it's create_reader_fd. The underlying method called to effectively read from the source is hidden. To read with a t_reader we just may call reader_read with a pointer to the t_reader, the destination buffer in which we want to write the data, and the length of data we want to put in destination buffer.

We wrote tests to assert implementation quality.

It closes #2 issue.