Error Creating Assembly Manifest Error Signing Assembly Access Is Denied
Contents |
Development > MSBuild error creating assembly manifest the system cannot find the file specified Question 1 Sign in to vote Hello, I'm having problems running a Team Build when I give my assemblies a strong name. The team build works great unless I sign my assemblies. When I do that I get a "vbc : error BC30140: Error creating assembly manifest: Access is denied." Here is the error text from the build log: Target Common:__________________________________________________Project "D:\Build\Flin Flon\Release\Sources\FlinFlon.sln" is building "D:\Build\Flin Flon\Release\Sources\Common\Common.vbproj" (default targets): Target PrepareForBuild:Creating directory "D:\Build\Flin Flon\Release\Binaries\Release\".Creating directory "obj\Release\".Target CoreResGen:Processing resource file "My Project\Resources.resx" into "obj\Release\IRC.FlinFlon.Common.Resources.resources".Target CoreCompile:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Vbc.exe /noconfig /imports:Microsoft.VisualBasic,System,System.Collections,System.Collections.Generic,System.Data,System.Diagnostics /nowarn:42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 /rootnamespace:IRC.FlinFlon.Common /doc:obj\Release\Common.xml /define:"CONFIG=\"Release\",TRACE=-1,_MyType=\"Windows\",PLATFORM=\"AnyCPU\"" /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Data.dll,C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll,C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /debug:pdbonly /keyfile:FlinFlonCommon.snk /optimize+ /out:obj\Release\Common.dll /resource:obj\Release\IRC.FlinFlon.Common.Resources.resources /target:library Common.vb "My Project\AssemblyInfo.vb" "My Project\Application.Designer.vb""My Project\Resources.Designer.vb" "My Project\Settings.Designer.vb" vbc : error BC30140: Error creating assembly manifest: Access is denied. Done building target "CoreCompile" in project "Common.vbproj" -- FAILED. Done building project "Common.vbproj" -- FAILED. Any help would be greatly appreciated, Joel Wednesday, May 24, 2006 8:52 PM Reply | Quote Answers 5 Sign in to vote Try running "sn -k keyPair.snk" if you get an e
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Strong Naming an assembly https://social.msdn.microsoft.com/Forums/vstudio/en-US/5fcb9fd2-90ad-4388-a688-9dbf1ea4e361/error-creating-assembly-manifest-access-is-denied?forum=msbuild using command line compile up vote 3 down vote favorite I am trying to use NAnt in order to compile and sign an assembly using the vbc compiler. I have a project set up and am able to successfully sign the assembly compiling with VS2010. When I try to sign it using the command line I get this error: vbc : error BC30140: Error creating http://stackoverflow.com/questions/2857955/strong-naming-an-assembly-using-command-line-compile assembly manifest: Error signing assembly -- The parameter is incorrect. I even created a trivially simple app (just an assemblyinfo.vb file) that will not compile and sign using vbc.exe What am I doing wrong? here is my assemblyinfo.vb: Option Strict Off Option Explicit On Imports System Imports System.Reflection
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of http://stackoverflow.com/questions/11887/sn-exe-fails-with-access-denied-error-message this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask http://forums.asp.net/t/335032.aspx?Signing+Assemblies+in+VB+NET Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign error creating up sn.exe fails with Access Denied error message up vote 12 down vote favorite 3 I get an Access is Denied error message when I use the strong name tool to create a new key to sign a .NET assembly. This works just fine on a Windows XP machine but it does not work on my Vista machine. PS C:\users\brian\Dev\Projects\BELib\BELib> sn -k keypair.snk error creating assembly Microsoft (R) .NET Framework Strong Name Utility Version 3.5.21022.8 Copyright (c) Microsoft Corporation. All rights reserved. Failed to generate a strong name key pair -- Access is denied. What causes this problem and how can I fix it? Are you running your PowerShell or Command Prompt as an Administrator? I found this to be the first place to look until you get used to User Access Control or by turning User Access Control off. Yes I have tried running PS and the regular command prompt as administrator. The same error message comes up. .net strongname sn.exe share|improve this question edited Jun 29 '12 at 11:06 Bill the Lizard 222k139447737 asked Aug 15 '08 at 2:01 Brian Ensink 8,78323656 add a comment| 5 Answers 5 active oldest votes up vote 23 down vote accepted Yes I have tried running PS and the regular command prompt as administrator. The same error message comes up. Another possible solution could be that you need to give your user account access to the key container located at C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\MachineKeys share|improve this answer edited Aug 15 '08 at 2
ASP.NET Community Standup Forums Help Home/ASP.NET Forums/Advanced ASP.NET/Enterprise Services Integration/Signing Assemblies in VB.NET Signing Assemblies in VB.NET RSS 6 replies Last post Sep 14, 2003 02:32 PM by angiras ‹ Previous Thread|Next Thread › Print Share Twitter Facebook Email Shortcuts Active Threads Unanswered Threads Unresolved Threads Support Options Advanced Search Reply webdevjeff Member 10 Points 39 Posts Signing Assemblies in VB.NET Sep 10, 2003 12:15 PM|webdevjeff|LINK I have a VB console application that needs to support transaction. To accomodate this I have created a vb class that usies the system.enterprise services namespace to enable this. However I need to sign this assembly to use it. I have used sn.exe to generate a key and it is in the app root and bin directories. I have also included the following lines in the class Imports System.EnterpriseServices Imports System.Runtime.CompilerServices Imports System.Reflection _ Public Class BOBOFileCreation Inherits ServicedComponent However when I compile I get the following error Error creating assembly manifest: Error reading key file 'myKey.snk' -- The system cannot find the file specified. Can anyone point me in the write direction, have looked on MSDN and the only thing I can see I may need to do is use al.exe but am unsure how to do this Thanks Jeff.................. Reply tomasr Member 30 Points 851 Posts Re: Signing Assemblies in VB.NET Sep 10, 2003 10:14 PM|tomasr|LINK The .snk file referenced in the AssemblyKeyFile attribute is resolved from the compilation directory. If you use the default VS.NET project setup, then you should be able to get it to work with: ... assuming the .snk file is in the project directory. Do notice, though, that to use EnterpriseServices you'll want your class in a DLL assembly, not inside your .EXE, which I'm not sure you're doing from the description you're presenting... Tomas Restrepo [MVP] tomasr@mvps.org Reply cnot None 0 Points 9 Posts Re: Signing Assemblies in VB.NET Sep 11, 2003 10:50 AM|cnot|LINK I had this problem signing : Cryptographic failure while signing assembly 'C:\cnot\dotnet\cnotTools\WSDLSolutionCS\obj\Debug\WSDLSolutionCS.dll' -- 'The key container name '..\\..\\MyKey.snk' does not exist' I could sign my VB.net project without any hassles, but for the C# assembly, I am missing something. I will just try some more today. Reply tomasr Member 30 Points 851 Posts Re: Signing Assemblies in VB.NET Sep 11, 2003 11:49 PM|tomasr|