Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • webmonger 130 posts 285 karma points
    Sep 21, 2010 @ 16:22
    webmonger
    0

    Poet Patch Question/Problem

    I have a few sites that had custom 404 pages enabled in various different versions on Umbraco 4+

    I've worked through instructions as per the documentation in Scott Gu's blog and today the additional umbraco.PoetPatch patch but I'm a little confused.

    As I understand this issue all errors need to be mapped to the same page. Now having applied the patch to a site i'm now getting 3 different error pages returned.

    1. Generic Umbraco page error (http://siteurl/test.aspx) - returns Umbraco's Page not found error. The ugly one I'm sure you know it ;-)
    2. Custom 404 Error (http://siteurl/bin/test.aspx) - This returns me to the custom error I had setup before I implemented the customErrors On fix.
    3. customErrors On error page (http://siteurl/umbraco/plugins/test.aspx) - This returns me to the error page I have specified in the customErrors tag in the web.config

    Please could someone help me or explain why this is happening and how to fix it?

    Cheers

    Jon

  • David Conlisk 432 posts 1008 karma points
    Sep 21, 2010 @ 17:31
    David Conlisk
    0

    Hey,

    I've tested the urls on a site that I have 'patched':

     

    /umbraco/plugins/test.aspx - gives me the proper 404 page that I expect to see from the poet patcher. Also, nearly any other incorrect url you can think of gives me this page - hence I thought I'd patched the site correctly.

    /test.aspx gives me a totally empty page

    /bin/test.aspx gives me an XML parsing error (empty source).

    Weird. More info would be great.

    David

     

  • Wojciech Tengler 96 posts 199 karma points
    Sep 21, 2010 @ 18:36
    Wojciech Tengler
    0

    I have just instaled ASP.NET Security Vulnerability Patch and I think that it works bad beacause:

    It is no matter what we set in indefaultRedirect we allways are redirected to /umbraco/plugins/poetpathcer/CustomError.aspx

    <customErrors mode="On" redirectMode="ResponseRewrite" defaultRedirect="~/umbraco/plugins/poetpathcer/CustomError.aspx" />

    So we can't specify our cutom 404 page. We can only edit CustomError.aspx

  • Per Ploug 865 posts 3491 karma points MVP admin
    Sep 21, 2010 @ 19:03
    Per Ploug
    0

    @webmonger: you need to turn off the standard 404 handler, thats the one returning the "ugly page", remove that from the /config/404handlers.config file, the custom error on /bin/test.aspx should also be mapped to the same error

    @wtct: iit is important that all errors returned look exactly the same, so no you cannot set your own 404 page, it's a shame but this is the current workaround 

     

  • Wojciech Tengler 96 posts 199 karma points
    Sep 21, 2010 @ 19:23
    Wojciech Tengler
    0

    @Per Plough Hansen: I understand "ASP.NET Security Vulnerability" but it doesn't mean that the patch must work like this (not see at defaultRedirect attribute and allways redirect to path written in dll - Umbraco.PoetPatcher.dll).

  • Per Ploug 865 posts 3491 karma points MVP admin
    Sep 21, 2010 @ 19:46
    Per Ploug
    0

    Well, our goal was to create a patch the solved the security issue, not to spend alot of time of providing configuration options, this keeps things simple and we know the page at that specific hardcoded url has the right timing code and response code setup

  • webmonger 130 posts 285 karma points
    Sep 21, 2010 @ 20:05
    webmonger
    0

    Thanks for the response Per.

    The lack of configuration options is a bit of a ball ach for me as I implemented the standard fix (Scott Gu Blog fix) manually yesterday to over 50 sites we host for clients as I could not wait for the Umbraco Package. About 35 of them are Umbraco sites the others are a selection of MVC, Forms and web services. I applied the standard fix in the same way accross the board as it was easy to impement.

    I understand the need to get the fix out fast and believe me we a truly grateful. I'm just a little frustrated as this will require me to spend another 0.5 - 1 day getting this fixed on the sites again and changing the implementation on all the Umbraco sites.

    Ps. The site I was refering to had the standard 404 code removed from the 404handlers.config and replaced with the new Umbraco.PoetPatch implemented but i had not added the aspx file the the /plugins/poetpathcer/CustomError.aspx

    Guess what I get to do tomorrow ;)

    Cheers

    Jon

  • webmonger 130 posts 285 karma points
    Sep 22, 2010 @ 11:15
    webmonger
    0

    Hey Per

    I've done further tests and there is definatly an issue here although it may well be to do with my understanding of the issue.

    Here is an example a little closer to home heopefully we'll be able to wrap this up but I definatley think a step is missing from the guide.

    The "Correct" Generic error page is displayed when you navigate to http://our.umbraco.org/test.aspx

    The URL http://our.umbraco.org/bin/test.aspx provides a standard IIS 404 error that is as I understand it being incorrectly mapped and should be dealt with? I think this is set in IIS. Do we need to re-map these pages as well?

    The URL http://our.umbraco.org/plugins/test.aspx seems to be corretly mapped on this site.

    I'm now started from scratch and setup the site as per the instructions and i'm still recieveing the generic ugly page. This site is Umbraco 4.0.3 and I'm not really sure what more I can do to fix this issue. I've touched the web.config, restarted the App Pool and even stopped and started the website do you have any sugestions?

    Jon

     

  • webmonger 130 posts 285 karma points
    Sep 22, 2010 @ 12:18
    webmonger
    0

    UPDATE (4 sites updated, 32 to go!):

    I have now added the web.config settings and 404handlers.config settings as well as the new aspx Generic Error page.

    I have found an interesting bug in 4.0.X sites though that is rather frustrating.

    If you follow the 2. update the web.config instructions in the For Developers 1.2.pdf document it causes your error pages to be output is trace information visible no matter what the settings are in you web.config <trace /> tag.

    For sites running on IIS6 with 2.0 or 3.5 you should remove the attribute redirectMode="ResponseRewrite" and your page will display properly.

    Use:

    <customErrors mode="On" defaultRedirect="~/umbraco/plugins/poetpatcher/CustomError.aspx" />

    For sites running 3.5 SP1 + you should use the customErrors tag as directed in the pdf.

    Use:

    <customErrors mode="On" redirectMode="ResponseRewrite" defaultRedirect="~/umbraco/plugins/poetpatcher/CustomError.aspx" />

    Hope this helps others as it stumped me for a good half an hour.

    Jon

     

  • webmonger 130 posts 285 karma points
    Sep 22, 2010 @ 14:53
    webmonger
    2

    Update (7 sites updated, 29 to go!)

    It turns out there is a type in both of the PDFs explaining the updated 404handlers.config change.

    INCORRECT:

    <notFound assembly="umbraco.PoetPatcher" type="GenericError" />

    CORRECT:

    <notFound assembly="Umbraco.PoetPatcher" type="GenericError" />

    Notice the Umbraco namespace is spelt with a lower case u in the the PDF and it should be and Uppercase U.

    Jon

  • Per Ploug 865 posts 3491 karma points MVP admin
    Sep 22, 2010 @ 15:18
    Per Ploug
    0

    ah crap, sorry about that typo :( I've updated the documentation

  • webmonger 130 posts 285 karma points
    Sep 22, 2010 @ 15:20
    webmonger
    0

    Cheers Per.

    Spent 4hrs debugging it. Was totally confused then I started to install the Package and noticed the difference, could have kicked myself for missing it!

    Cheers for updating the docs.

    Jon

  • bproven 9 posts 26 karma points
    Sep 22, 2010 @ 17:34
    bproven
    0

    @webmonger - thanks for pointing out that issue in the documentation regarding the typo.  That was (part) of my problem too.

    See my thread here: http://our.umbraco.org/forum/core/general/12891-Strange-Issue-with-POET-patch

    I had 1 other issue regarding IIS7 hijacking error status for 404s (detailed here: http://our.umbraco.org/forum/using/ui-questions/8244-IIS7--404) that I had to correct by updating applicationHost.config, but once I did that and fixed this everything seems to work fine now using the POET workaround provided by Umbraco.  Thanks

    @Per - there is also another small typo in the docs regarding the web.config entry.  I'm guessing most people see it and make the change, but if you copy and paste it as instructed it could be missed:

    Correct:


    defaultRedirect="~/umbraco/plugins/poetpatcher/CustomError.aspx" />

     

    Incorrect (in the documentation) - "poetpatcher" typo:


    defaultRedirect="~/umbraco/plugins/poetpacther/CustomError.aspx" />

     

    Thanks all...

     

     

     

  • webmonger 130 posts 285 karma points
    Sep 23, 2010 @ 14:50
    webmonger
    0

    @bproven Glad I could be of help.

    Jon

  • funnyjokes 1 post 21 karma points
    Sep 24, 2010 @ 10:26
    funnyjokes
    0

    404 is my bad dream for my site

     

     

    ________________________________-

    Be happy with funny jokes every day

Please Sign in or register to post replies

Write your reply to:

Draft