Skip to content

Commit

Permalink
CSHARP-5182: Provide Strong-Named Assembly of libmongocrypt (#864)
Browse files Browse the repository at this point in the history
  • Loading branch information
sanych-sun authored Jul 17, 2024
1 parent 239aae0 commit 1fdb35f
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 6 deletions.
8 changes: 4 additions & 4 deletions .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1093,7 +1093,7 @@ buildvariants:
- build-and-test-and-upload
- build-and-test-shared-bson
- build-and-test-asan-mac
- build-and-test-csharp
# - build-and-test-csharp // temporary removed to make strong named release.
- test-java
- name: rhel72-zseries-test
display_name: "RHEL 7.2 on zSeries"
Expand Down Expand Up @@ -1134,7 +1134,7 @@ buildvariants:
tasks:
- build-and-test-and-upload
- build-and-test-shared-bson
- build-and-test-csharp
# - build-and-test-csharp // temporary removed to make strong named release.
- test-java
- name: windows-test-python
display_name: "Windows Python"
Expand Down Expand Up @@ -1447,7 +1447,7 @@ buildvariants:
- build-and-test-and-upload
- build-and-test-shared-bson
- build-and-test-asan
- build-and-test-csharp
# - build-and-test-csharp // temporary removed to make strong named release.
- test-java
- name: publish-packages
distros:
Expand Down Expand Up @@ -1489,7 +1489,7 @@ buildvariants:
- build-and-test-and-upload
- build-and-test-shared-bson
- build-and-test-asan
- build-and-test-csharp
# - build-and-test-csharp // temporary removed to make strong named release.
- test-java
- upload-java
- publish-packages
Expand Down
1 change: 1 addition & 0 deletions bindings/cs/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@

configure_file(cs.sln cs.sln COPYONLY)
configure_file(MongoDB.Driver.snk MongoDB.Driver.snk COPYONLY)

configure_file(MongoDB.Libmongocrypt/MongoDB.Libmongocrypt.csproj MongoDB.Libmongocrypt/MongoDB.Libmongocrypt.csproj COPYONLY)
configure_file(MongoDB.Libmongocrypt/Package.include.template.csproj MongoDB.Libmongocrypt/Package.csproj.include)
Expand Down
Binary file added bindings/cs/MongoDB.Driver.snk
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

<Platforms>AnyCPU</Platforms>
<IsPackable>false</IsPackable>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\MongoDB.Driver.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<TargetFrameworks>net472;netcoreapp2.1;netcoreapp3.0</TargetFrameworks>
<TargetFrameworks Condition="'$(OS)' != 'Windows_NT'">netcoreapp2.1;netcoreapp3.0</TargetFrameworks>
<IsPackable>false</IsPackable>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\MongoDB.Driver.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions bindings/cs/MongoDB.Libmongocrypt/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System.Runtime.CompilerServices;

[assembly: InternalsVisibleTo("MongoDB.Libmongocrypt.Test")]
[assembly: InternalsVisibleTo("MongoDB.Libmongocrypt.Test32")]
[assembly: InternalsVisibleTo("MongoDB.Libmongocrypt.Test, PublicKey=002400000480000094000000060200000024000052534131000400000100010035287f0d3883c0a075c88e0cda3ce93b621003ecbd5e920d4a8c7238564f4d2f4f68116aca28c9b21341dc3a877679c14556192b2b2f5fe2c11d624e0894d308ff7b94bf6fd72aef1b41017ffe2572e99019d1c61963e68cd0ed67734a42cb333b808e3867cbe631937214e32e409fb1fa62fdb69d494c2530e64a40e417d6ee")]
[assembly: InternalsVisibleTo("MongoDB.Libmongocrypt.Test32, PublicKey=002400000480000094000000060200000024000052534131000400000100010035287f0d3883c0a075c88e0cda3ce93b621003ecbd5e920d4a8c7238564f4d2f4f68116aca28c9b21341dc3a877679c14556192b2b2f5fe2c11d624e0894d308ff7b94bf6fd72aef1b41017ffe2572e99019d1c61963e68cd0ed67734a42cb333b808e3867cbe631937214e32e409fb1fa62fdb69d494c2530e64a40e417d6ee")]
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
<PackageTags>mongodb;mongo;nosql</PackageTags>
<PackageLanguage>en-US</PackageLanguage>
<IncludeSymbols>true</IncludeSymbols>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\MongoDB.Driver.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<PropertyGroup>
Expand Down

0 comments on commit 1fdb35f

Please sign in to comment.