X509: create lib for generating keys and certs and testing them