Further code abstraction and implementation of openssl casestudy