That's the proper way to use OpenSSL and derivatives. Their C and assembly code for crypto primatives is good.
Protocol code and x.509 certficate handling will probably be better written in another language.