Skip to content

Commit

Permalink
feat: sign assemblies with strong name (#47)
Browse files Browse the repository at this point in the history
  • Loading branch information
bednar authored Nov 19, 2019
1 parent e60c12c commit 8720a68
Show file tree
Hide file tree
Showing 13 changed files with 42 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
### API
1. [#46](https://github.com/influxdata/influxdb-client-csharp/pull/46): Updated swagger to latest version

### Bugs
1. [#45](https://github.com/influxdata/influxdb-client-csharp/issues/45): Assemblies are strong-named

## 1.2.0 [2019-11-08]

### Features
Expand Down
3 changes: 3 additions & 0 deletions Client.Core.Test/Client.Core.Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
<IsPackable>false</IsPackable>
<AssemblyName>InfluxDB.Client.Core.Test</AssemblyName>
<RootNamespace>InfluxDB.Client.Core.Test</RootNamespace>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
3 changes: 3 additions & 0 deletions Client.Core/Client.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
<PackageReleaseNotes>https://github.com/influxdata/influxdb-client-csharp/blob/master/CHANGELOG.md</PackageReleaseNotes>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RootNamespace>InfluxDB.Client.Core</RootNamespace>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
6 changes: 5 additions & 1 deletion Client.Core/Flux/Internal/FluxResultMapper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@
using InfluxDB.Client.Core.Flux.Domain;
using NodaTime;

[assembly: InternalsVisibleTo("Client.Legacy.Test")]
[assembly: InternalsVisibleTo("Client.Legacy.Test, PublicKey=00240000048000009400000006020000002400005" +
"25341310004000001000100efaac865f88dd35c90dc548945405aae34056eedbe42cad60971f89a861a78" +
"437e86d95804a1aeeb0de18ac3728782f9dc8dbae2e806167a8bb64c0402278edcefd78c13dbe7f8d13de" +
"36eb36221ec215c66ee2dfe7943de97b869c5eea4d92f92d345ced67de5ac8fc3cd2f8dd7e3c0c53bdb0c" +
"c433af859033d069cad397a7")]
namespace InfluxDB.Client.Core.Flux.Internal
{
internal class FluxResultMapper
Expand Down
3 changes: 3 additions & 0 deletions Client.Legacy.Test/Client.Legacy.Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
<TargetFramework>netcoreapp2.2</TargetFramework>

<IsPackable>false</IsPackable>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
3 changes: 3 additions & 0 deletions Client.Legacy/Client.Legacy.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
<PackageReleaseNotes>https://github.com/influxdata/influxdb-client-csharp/blob/master/CHANGELOG.md</PackageReleaseNotes>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RootNamespace>InfluxDB.Client.Flux</RootNamespace>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
3 changes: 3 additions & 0 deletions Client.Test/Client.Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

<IsPackable>false</IsPackable>
<RootNamespace>InfluxDB.Client.Test</RootNamespace>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
3 changes: 3 additions & 0 deletions Client/Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
<PackageReleaseNotes>https://github.com/influxdata/influxdb-client-csharp/blob/master/CHANGELOG.md</PackageReleaseNotes>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RootNamespace>InfluxDB.Client</RootNamespace>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
6 changes: 5 additions & 1 deletion Client/Internal/MeasurementMapper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@
using InfluxDB.Client.Writes;
using NodaTime;

[assembly: InternalsVisibleTo("Client.Test")]
[assembly: InternalsVisibleTo("Client.Test, PublicKey=002400000480000094000000060200000024000052534131" +
"0004000001000100efaac865f88dd35c90dc548945405aae34056eedbe42cad60971f89a861a78437e86d" +
"95804a1aeeb0de18ac3728782f9dc8dbae2e806167a8bb64c0402278edcefd78c13dbe7f8d13de36eb362" +
"21ec215c66ee2dfe7943de97b869c5eea4d92f92d345ced67de5ac8fc3cd2f8dd7e3c0c53bdb0cc433af8" +
"59033d069cad397a7")]
namespace InfluxDB.Client.Internal
{
internal class MeasurementMapper
Expand Down
3 changes: 3 additions & 0 deletions Examples/Examples.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<TargetFramework>netcoreapp2.2</TargetFramework>
<Version>1.3.0-preview</Version>
<IsPackable>false</IsPackable>

<AssemblyOriginatorKeyFile>../Keys/Key.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
</PropertyGroup>

<ItemGroup>
Expand Down
Binary file added Keys/Key.public.snk
Binary file not shown.
Binary file added Keys/Key.snk
Binary file not shown.
8 changes: 8 additions & 0 deletions Keys/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Contents
--------

- Key.public.snk: Public key to verify strong name of `influxdb-client-csharp`.
- Key.snk: Signing key to provide strong name of `influxdb-client-csharp`.


[Microsoft guidance: Strong-named assemblies](https://msdn.microsoft.com/en-us/library/wd40t7ad(v=vs.110).aspx)

0 comments on commit 8720a68

Please sign in to comment.