Yahoo search + no rewriting = broken archive links

Found a bug? Tell us!!
Post Reply
sapphirecat
Regular
Posts: 7
Joined: Thu May 03, 2007 2:19 am

Yahoo search + no rewriting = broken archive links

Post by sapphirecat »

When a link in the Yahoo search results points to a single entry on an s9y install with rewriting set to 'None', the slashes in the archive path are URL-encoded. That is, $_SERVER['QUERY_STRING'] contains '%2Farchive%2F42-the-entry-title-etc.html'.

However, the bundled Net_URL library doesn't convert the '%2F' sequences back into '/' characters, so s9y proceeds to display the current index (as if no query string were present) instead of the entry Yahoo so carefully linked to.

This bug was observed on 1.1.2 and is still present in 1.2-beta1.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Yahoo search + no rewriting = broken archive links

Post by garvinhicking »

Hi!

Serendipity should not recode URLs to prevent XSS and other abuse. What instead should be done is that any page linking to your blog uses proper characters, not encoding '/' to '%2f'. Why does yahoo do that? They should change that behaviour. :)

It's not really a bug, because serendipity properly recognizes the proper URLs - in your case the recoding would be a new feature that is simply not implemented because of security risks.

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
sapphirecat
Regular
Posts: 7
Joined: Thu May 03, 2007 2:19 am

Post by sapphirecat »

Interesting. Yahoo's fixed it now.
Post Reply