i have a .PEM file that includes public key and a private key for SSL data transfer like this:
-----BEGIN RSA PRIVATE KEY-----
private key data
-----EN
I don't know .NET (but Java) but the answer should be the same.
Your pem file contains both the certificate and private key.
This is a usual export in OpenSSL.
To instantiate an object of X509Certificate in Java you would use only the part of the file that says:
-----BEGIN CERTIFICATE-----
certificate data
-----END CERTIFICATE-----
It should be the same in .NET.
Just load the file and load that part of PEM.
Do the same for private key.
In java you would use the corresponding object i.e. PrivateKey to load it.
Use the appropriate for .NET