Error during adding Webpart: Webpart is not registered as 'safe' !

Topics: User Forum
May 24, 2006 at 12:58 PM
Well, the title explains most of it...

I worked through the install guide, checked everything three times. Still getting this error.

I had some problems with adding the .dll file to the assembly map. Drag/Drop did not work, i had to put the dll file in the Windows.net\Framwork\v1.1.4322 directory and run the gacutil.exe there.

Furthermore: I'm running the Dutch version of SPS and WSS (not language packs, full installation language), don't know if this is of any influence.

I've very little knowledge of these kind of things, so i'd be very glad if someone would be able to help me out :)

Thnx in Advance!

Fearandir
May 25, 2006 at 2:29 PM
Okay, I got it solved.

After rerunning the procedure three times i discovered that you really needed to create the wwwroot/bin directory and put them in there, not in the root dir! Also added safe=yes to the safecontrol lines in the web.config file.

On to the next error! I now add the pluging, but upon viewing the page i get an error. Event viewer claims its a 'security error' with no further info. Anyone who had encountered the same thing?

Fearandir
May 26, 2006 at 4:14 PM
I was getting the "not registered as 'safe'" error, but it went away after I placed all 3 dll's into the "\windows\assembly" folder and added the following code to "\inetpub\wwwroot\web.config":

<SafeControl
Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32"
Namespace="BilSimser.SharePoint.WebParts.Forums.Controls" TypeName="*" />
<SafeControl
Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32"
Namespace="BilSimser.SharePoint.WebParts.Forums" TypeName="*" />
<SafeControl
Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32"
Namespace="BilSimser.SharePoint.WebParts.Forums.Controls.Common" TypeName="*" />
<SafeControl
Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32"
Namespace="BilSimser.SharePoint.WebParts.Forums.Controls.Base" TypeName="*" />


I tried the same with SharePoint 2007 Beta, but it didn't work there :(
May 28, 2006 at 11:32 AM
Okay, issue resolved. What you need to do is add allt hree dll's to the GAC to byupass the security error, in my case anyhow.
Jun 26, 2006 at 3:25 PM
Adding the 3 .dlls to cache worked for me too!! Thanks for your post.