but it tells me the certificate file is empty.
Have you checked if the file is really ok? You can do it on linux or OS X with openssl.
Check the certificate:
openssl x509 -in YourCertificate.crt -text -noout
Check the key:
openssl rsa -in YourPrivateKey.key -check