29 references to StrongName
Microsoft.DotNet.SignTool (4)
src\Configuration.cs (1)
565
bool isAlreadyStrongNamed =
StrongName
.IsSigned(file.FullPath, snPath: _snPath, log: _log);
src\RealSignTool.cs (2)
73
StrongName
.ClearStrongNameSignedBit(assemblyPath);
94
return
StrongName
.IsSigned(fileFullPath, snPath:_snPath, log: _log) ? SigningStatus.Signed : SigningStatus.NotSigned;
src\SignTool.cs (1)
249
return
StrongName
.Sign(file.FullPath, file.SignInfo.StrongName, _args.SNBinaryPath, _log);
Microsoft.DotNet.SignTool.Tests (25)
SignToolTests.cs (25)
3031
StrongName
.IsSigned(GetResourcePath("AspNetCoreCrossLib.dll")).Should().BeFalse();
3032
StrongName
.IsSigned(GetResourcePath("CoreLibCrossARM.dll")).Should().BeFalse();
3033
StrongName
.IsSigned(GetResourcePath("EmptyPKT.dll")).Should().BeFalse();
3034
StrongName
.IsSigned(GetResourcePath("DelaySigned.dll")).Should().BeFalse();
3035
StrongName
.IsSigned(GetResourcePath("ProjectOne.dll")).Should().BeFalse();
3102
int checksumStart = peHeaders.PEHeaderStartOffset +
StrongName
.ChecksumOffsetInPEHeader;
3104
StrongName
.IsSigned(outputStream).Should().BeTrue();
3116
int checksumStart = peHeaders.PEHeaderStartOffset +
StrongName
.ChecksumOffsetInPEHeader;
3118
StrongName
.IsSigned(outputStream).Should().BeFalse();
3132
int checksumStart = peHeaders.PEHeaderStartOffset +
StrongName
.ChecksumOffsetInPEHeader;
3136
StrongName
.IsSigned(outputStream).Should().BeFalse();
3142
StrongName
.IsSigned(GetResourcePath("SignedLibrary.dll")).Should().BeTrue();
3143
StrongName
.IsSigned(GetResourcePath("StrongNamedWithEcmaKey.dll")).Should().BeTrue();
3149
StrongName
.IsSigned_Legacy(GetResourcePath("SignedLibrary.dll"), s_snPath).Should().BeTrue();
3150
StrongName
.IsSigned_Legacy(GetResourcePath("StrongNamedWithEcmaKey.dll"), s_snPath).Should().BeTrue();
3160
StrongName
.IsSigned(resourcePath).Should().Be(initiallySigned);
3161
StrongName
.Sign(resourcePath, GetResourcePath(key));
3162
StrongName
.IsSigned(resourcePath).Should().BeTrue();
3165
StrongName
.IsSigned_Legacy(resourcePath, s_snPath).Should().Be(
3177
StrongName
.IsSigned_Legacy(resourcePath, s_snPath).Should().Be(initiallySigned);
3179
StrongName
.ClearStrongNameSignedBit(resourcePath);
3180
StrongName
.Sign_Legacy(resourcePath, GetResourcePath(key), s_snPath).Should().BeTrue();
3181
StrongName
.IsSigned(resourcePath).Should().BeTrue();
3190
Action shouldFail = () =>
StrongName
.Sign(inputStream, GetResourcePath("OpenSignedCorrespondingKey.snk"));
3201
Action shouldFail = () =>
StrongName
.Sign(inputStream, GetResourcePath("OpenSignedCorrespondingKey.snk"));