Skip to content

Commit

Permalink
Add strong name signing (octokit#2575)
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreyTretyak authored Oct 10, 2022
1 parent fa29939 commit 40b2111
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 3 deletions.
7 changes: 7 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<Project>
<PropertyGroup Label="Strong name signing">
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>$(MSBuildThisFileDirectory)\key.snk</AssemblyOriginatorKeyFile>
<StrongNameSuffix>, PublicKey=0024000004800000940000000602000000240000525341310004000001000100f1e6b635f0c0b44c03d712e4f2cf789ddb54d7f74a9b34e2ece3aafb6afbfd46ec2b033f4104ef88f6afec226c5c647f453852ba3847fd9e37727c7dcb54e24731a288a107457a2c3e8b26ab04c25b206797be48cfe7a2b2c427422d0b0dd18c82111f21798f997e5d33ecc25c677744709c3785e0e650d6e0456a034a31acc4</StrongNameSuffix>
</PropertyGroup>
</Project>
1 change: 1 addition & 0 deletions Octokit.Tests.Integration/Octokit.Tests.Integration.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<AssemblyTitle>Octokit.Tests.Integration</AssemblyTitle>
<Authors>GitHub</Authors>
<TargetFrameworks>net6.0;netcoreapp3.1;net462</TargetFrameworks>
<SignAssembly>false</SignAssembly>
<NoWarn>$(NoWarn);CS4014;CS1998</NoWarn>
<AssemblyName>Octokit.Tests.Integration</AssemblyName>
<PackageId>Octokit.Tests.Integration</PackageId>
Expand Down
5 changes: 5 additions & 0 deletions Octokit/Octokit.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,9 @@
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />
</ItemGroup>

<ItemGroup Label="InternalsVisibleTo attributes">
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
<_Parameter1>Octokit.Tests$(StrongNameSuffix)</_Parameter1>
</AssemblyAttribute>
</ItemGroup>
</Project>
3 changes: 0 additions & 3 deletions Octokit/Properties/AssemblyInfo.cs

This file was deleted.

1 change: 1 addition & 0 deletions build/Build.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<SignAssembly>false</SignAssembly>
<TargetFramework>netcoreapp3.1</TargetFramework>
<RunWorkingDirectory>$(MSBuildProjectDirectory)/..</RunWorkingDirectory>
</PropertyGroup>
Expand Down
Binary file added key.snk
Binary file not shown.

0 comments on commit 40b2111

Please sign in to comment.