SharpCrafters Forum – Signing DLL using Potharp (Cannot locate the utility sn.exe)

SharpCrafters Support Forum

        


Signing DLL using Potharp (Cannot locate the... Expand / Collapse
Author
Message
Posted 1/5/2010 8:45:55 AM


Community Member
Hello,
I still have a problem signing DLLs wic are using PostSharp 1.5RTM. I always get the error "Cannot locate the utility sn.exe" (see Error 1 below), which is installed in the default folder from the SDK (C:\Program Files\Microsoft SDKs\Windows\v6.1\Bin, registry path HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v6.1
"InstallationFolder"="C:\\Program Files\\Microsoft SDKs\\Windows\\v6.1\\").

If I try delayed signing I get another error (see Error2 below).

I found an old entry in this forum to this topic, but still have no idea,maybe someone can gv me a hint on this.

Thanks,
Chris

Error 1:
------ Neues Erstellen gestartet: Projekt: CanObj, Konfiguration: Debug Any CPU ------
C:\Windows\Microsoft.NET\Framework\v3.5\Csc.exe /noconfig /nowarn:1701,1702 /platform:AnyCPU /errorreport:prompt /warn:4 /doc:..\CanberraMain\bin\Debug\CanObj.XML /define:POSTSHARP;DEBUG;TRACE /reference:"C:\Program Files\PostSharp 1.5\Reference Assemblies\.NET Framework 2.0\PostSharp.Laos.dll" /reference:"C:\Program Files\PostSharp 1.5\Reference Assemblies\.NET Framework 2.0\PostSharp.Public.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\PresentationCore.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\PresentationFramework.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Core.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Data.DataSetExtensions.dll" /reference:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Data.dll /reference:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll /reference:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll /reference:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Xml.Linq.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\WindowsBase.dll" /debug+ /debug:full /filealign:512 /keycontainer:VS_KEY_E5D5F7E706BCC80B /optimize- /out:obj\Debug\CanObj.dll /resource:obj\Debug\DE.Coe.Application.Canberra.Objects.Properties.Resources.resources /target:library clsDBHelper.cs clsExcel.cs clsExtensions.cs clsGlobalizedObject.cs clsImaging.cs clsLogger.cs clsObjCache.cs clsObjects.cs clsPostSharpTrace.cs clsSession.cs Properties\AssemblyInfo.cs Properties\Resources.Designer.cs

Kompilierung abgeschlossen -- 0 Fehler, 0 Warnungen
PostSharp 1.5 [1.5.6.627] - Copyright (c) Gael Fraiteur, 2005-2009.
C:\Program Files\PostSharp 1.5\PostSharp-1.5.targets(281,5): error : Cannot locate the utility sn.exe.
Erstellen des Projekts CanObj.csproj beendet - Fehler beim Erstellen.
========== Alles neu erstellen: 0 erfolgreich, Fehler bei 1, 0 übersprungen ==========




Error 2:
Fehler 1 Unhandled exception: PostSharp.CodeModel.BindingException: Error while loading the assembly "D:\Projekte\Canberra\CanObj\obj\Debug\Before-PostSharp\CanObj.dll": Die Datei oder Assembly "CanObj, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1bc59d250d1b5201" oder eine Abhängigkeit davon wurde nicht gefunden. Fehler bei der Strong Name-Überprüfung. (Ausnahme von HRESULT: 0x8013141A)
===== PostSharp Assembly Binder =================
Loading assembly from file {D:\Projekte\Canberra\CanObj\obj\Debug\Before-PostSharp\CanObj.dll}.
System.IO.FileLoadException: Die Datei oder Assembly "CanObj, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1bc59d250d1b5201" oder eine Abhängigkeit davon wurde nicht gefunden. Fehler bei der Strong Name-Überprüfung. (Ausnahme von HRESULT: 0x8013141A)
Dateiname: "CanObj, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1bc59d250d1b5201" ---> System.Security.SecurityException: Fehler bei der Strong Name-Überprüfung. (Ausnahme von HRESULT: 0x8013141A)
Die Zone der Assembly, bei der ein Fehler aufgetreten ist:
MyComputer
  bei System.Reflection.Assembly.nLoadFile(String path, Evidence evidence)
  bei System.Reflection.Assembly.LoadFile(String path)
  bei PostSharp.CodeModel.AssemblyLoadHelper.LoadAssemblyFromFile(String fileName, Evidence assemblySecurity)



=================================================

   
  bei PostSharp.CodeModel.AssemblyLoadHelper.ManageAssemblyLoadException(String assemblyName, Exception e)
  bei PostSharp.CodeModel.AssemblyLoadHelper.LoadAssemblyFromFile(String fileName, Evidence assemblySecurity)
  bei PostSharp.Extensibility.ModuleLoadReflectionFromFileStrategy.LoadAssembly()
  bei PostSharp.Extensibility.ModuleLoadReflectionStrategy.Load(Domain domain)
  bei PostSharp.Extensibility.Project.LoadSourceModule(ModuleLoadStrategy moduleLoadStrategy)
  bei PostSharp.Extensibility.Project.CreateInstance(String projectFileName, Domain domain, ModuleLoadStrategy moduleLoadStrategy, PropertyCollection properties, TagCollection tags)
  bei PostSharp.Extensibility.PostSharpObject.InvokeProject(ProjectInvocation projectInvocation)
  bei PostSharp.MSBuild.PostSharpRemoteTask.Execute(PostSharpTaskParameters parameters, TaskLoggingHelper log) CanObj
Post #2628
« Prev Topic | Next Topic »


All times are GMT +1:00, Time now is 11:35am

Powered By InstantForum.NET v4.1.4 © 2010
Execution: 0.016. 8 queries. Compression Disabled.