Pem written in C/C++