MICHELVANDERVLUGT.NET RSS 2.0
 Sunday, June 17, 2007

In my last post I explained the problems I had running dasBlog in a Partial/Medium Trust environment. There where two problems left, the web.config sections UrlMapper and httpCompress had to be removed and the admin pages return errors.

The first problem can be solved easily by adding the attribute requirePermission="false" to the section declarations (only .NET 2.0), including newtelligence.ControlImages:

<section name="newtelligence.ControlImages" type="newtelligence.DasBlog.Web.Core.WebControls.ControlImageModuleSectionHandler, newtelligence.DasBlog.Web.Core" requirePermission="false"/> <section name="newtelligence.DasBlog.UrlMapper" type="newtelligence.DasBlog.Web.Core.UrlMapperModuleSectionHandler, newtelligence.DasBlog.Web.Core" requirePermission="false"/> <sectionGroup name="blowery.web"> <section name="httpCompress" type="blowery.Web.HttpCompress.SectionHandler, blowery.Web.HttpCompress" requirePermission="false"/> </sectionGroup>

The second problem is caused by a line in site.config. In this file there is an entry that references the assembly newtelligence.DasBlog.Web with a public key token of null. However, since all assemblies are now have a Strong Name the public key token has to be filled.

<EntryEditControl>newtelligence.DasBlog.Web.FreeTextBoxAdapter, newtelligence.DasBlog.Web, Version=1.9.6264.0, Culture=neutral, PublicKeyToken=123ABC</EntryEditControl>

The public key token can be retrieved from a dll using the sn.exe utility in a command shell:

sn -T newtelligence.DasBlog.Web.dll

At this moment all seems to be working, finally...

Sunday, June 17, 2007 8:14:11 PM (W. Europe Standard Time, UTC+01:00)  #    Comments [0] -

 Saturday, June 16, 2007

... and that was not easy.

My first experience with dasBlog was a setup on Windows Vista, this didn't work. The main problem I ran into is described in a blog post of Daddy Starr and might be fixed in the next version of dasBlog, which will be released very soon (DasBlog June 2007 Release). So instead of using one of the latest daily builds I've installed the official community edition (version 1.9.6264.0) on a Windows XP virtual machine and configured it. Now I only had to wait for my host provider creating my new domain, thinking that a copy to my host provider would be all.

I was terribly wrong... The environment of my host provider is secured using Partial Trust and Code Access Security, and that is not a good thing when you want to run dasBlog out of the box. The only was solving the problem was downloading the source code and make the following changes:

  • Remove the usage of XmlNamespaceUpgradeReader to deserialize configuration files like site.config. The implementation is not allowed with Medum Trust and it doesn't seem to be quite necessary (anymore);
  • Compile all the assemblies, including all referenced, with a strong name and the attribute AllowPartiallyTrustedCallers.

Now it ran on my XP box with a medium trust but still not at my host provider, I still got security exceptions. To get it finally running I had to remove sections UrlMapper and httpCompress from the web.config. What the consequences will be exactly and why they are not allowed I don't know yet, I will figure it out later. For now the 'outside' of my blog runs, although I do experience some problems with the administrator pages after logging in.

BTW. The theme I use is 'business' from a daily build. This theme is designed by Christoph De Baene (delarou), who has done a great job I think.

Saturday, June 16, 2007 7:03:19 PM (W. Europe Standard Time, UTC+01:00)  #    Comments [0] -

Categories
Archive
<November 2008>
SunMonTueWedThuFriSat
2627282930311
2345678
9101112131415
16171819202122
23242526272829
30123456
About the author/Disclaimer

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008
Michel van der Vlugt
Sign In
All Content © 2008, Michel van der Vlugt
DasBlog theme 'Business' created by Christoph De Baene (delarou)