I'm having trouble with the openssl_x509_parse() function
$parsed_cert = openssl_x509_parse(file_get_contents('/home/my_location/aaa010101aaa__csd_01.cer'));
the function is returning a false and I'm unsure about the reasons. Maybe the certificate file must be in .pem
or .crt
?
EDIT: the code was ok, but the format of the file was the issue, so i had to transform it into a .crt from the .cer original.