1
Vote

CruiseControl Web Part Exceptions

description

Hi,
 
I try to use the CruiseControl WebParts but got some problems with it. I take the Source code of the WebPart to see the exact reason why it don work (display "no connection could be made"). My investigation give me fallowing result:
 
When i set the rust level to minimal i got exception:
System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)
at System.Security.CodeAccessSecurityEngine.CheckSetHelper(CompressedStack cs, PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Assembly asm, SecurityAction action)
at ThoughtWorks.CruiseControl.Remote.RemotingServiceAdapter.Connect(Type proxyType, String uri)
at TamTam.SharePoint.CruiseControl.CCFarmInfo.GetProjectInfo()
at TamTam.SharePoint.CruiseControl.CCFarmInfo.RenderWebPart(HtmlTextWriter output)
The action that failed was:
LinkDemand
The type of the first permission that failed was:
System.Security.Permissions.SecurityPermission
The Zone of the assembly that failed was:
MyComputer
 
When i set the trust level to medium i got exception:
System.Security.SecurityException: That assembly does not allow partially trusted callers.
at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
at System.Reflection.MethodBase.PerformSecurityCheck(Object obj, RuntimeMethodHandle method, IntPtr parent, UInt32 invocationFlags)
at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
at System.Runtime.Remoting.RemotingConfigHandler.CreateChannelFromConfigEntry(ChannelEntry entry)
at System.Runtime.Remoting.RemotingConfigHandler.FindDelayLoadChannelForCreateMessageSink(String url, Object data, String& objectURI)
at System.Runtime.Remoting.RemotingServices.CreateChannelSink(String url, Object data, IMessageSink& chnlSink)
at System.Runtime.Remoting.RemotingServices.Unmarshal(Type classToProxy, String url, Object data)
at ThoughtWorks.CruiseControl.Remote.RemotingServiceAdapter.Connect(Type proxyType, String uri)
at TamTam.SharePoint.CruiseControl.CCFarmInfo.GetProjectInfo()
at TamTam.SharePoint.CruiseControl.CCFarmInfo.RenderWebPart(HtmlTextWriter output)
The action that failed was:
LinkDemand
 
I'm not mastered with the code security on that level that i could know what the problem exact is. I suppose that some security configuration changes need to be made or the code should be signed or partial trusted. I made the web part partial trusted but it don't make any difference. maybe i should do this with CCnet remoting file?
 
I suppose that you run the web part correctly so please give me some advise or example how to properly configure the webpart.

comments