I need to work with certificates. We have an existing code base .NET standard compliant and we would like to use it.
I did some tests but i'm encountering some problems;
Our implementation is based around the
X509Certificate2 class which is present in the API with associated classes
I can't post link with this new account but the doc is easily found
This compile but problem is on runtime. I try to access the "store" with, for example, this code :
var store = new X509Store(storeName, storeLocation)
Here we're just trying to read the certificates from the store (which should be the keychain on macos ?).
My probem is that, without error or even warning, the store is empty and nothing is found inside it.
I use the StoreName
My and the storeLocation
I tried with a Console Application in .NET Core, and the very same code is working : I get a listing of my installed certificate, but my xamarin mac app doesn't find anything.
Now, I have theories about this. Xamarin.Mac looks heavily inspired from Xamarin.Ios too me, and I read that accessing certificates this way in Ios doesn't work this way. Do you think this could be a consequence from the similarities between the two frameworks ?
Could there be something I'm missing ? is the function just not implemented ?
I would like to know if you think I could manage accessing the keychain with xamarin.mac without too much trouble or if I need to use something else.
Thanks for you inputs