Reputation: 199
can anyone explain how package System.Security.Cryptography.OpenSsl
(github: dotnet/corefix) calls OpenSSL nanive functions? I can't find brige from .net C# to OpenSSL C++.
Upvotes: 2
Views: 4251
Reputation: 25061
Take a look here:
The code you link to references those interop classes, which pinvoke into this code here:
https://github.com/dotnet/corefx/tree/master/src/Native/Unix/System.Security.Cryptography.Native
Which calls into OpenSSL.
Upvotes: 1
Reputation: 1196
The types in the directory you linked to are all partial
classes. The .csproj file in that directory includes a large number of files from elsewhere in the repo. These files contain most of the methods and [DllImport]
platform invoke declarations.
The referenced CryptoNative
(System.Security.Cryptography.Native.OpenSsl
) library is a native shim found at corefx/src/Native/Unix/System.Security.Cryptography.Native, and forwards the calls to the actual OpenSSL implementation.
Upvotes: 1