Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb
Status: Accepted
Owner: [hidden email]
Labels: Type-Defect Priority-Medium GLASS-Server Version-1.0-beta.8

New issue 300 by [hidden email]: Gemstone Swazoo adapter does not  
respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

Retrieving a Seaside WAUrl from a SwazooUri in
WAServerAdaptor>>requestUrlFor: does not account for the possibility that
the uri might end in a slash.

This turned out to be a problem in a recent SqueakSource version where this
lead to an infinite redirect. The FastCGI-version does not seem to have  
this problem.

Solution: in WAServerAdaptor>>requestUrlFor:
a line "seasideUrl slash: swazooUri isDirectory." should be added.
See below.

WAServerAdaptor>>requestUrlFor: aNativeRequest
        | swazooUri seasideUrl |
        seasideUrl := WAUrl new.
        swazooUri := aNativeRequest uri.
        swazooUri identifierPath do: [ :each |
                "the first path element seems to always be '/'"
                each = '/' ifFalse: [
                        seasideUrl addToPath: each ] ].
        seasideUrl slash: swazooUri isDirectory.
        swazooUri queries do: [ :each |
                | value |
                value := each value.
                "non-existing values are implemented as ''"
                value isEmpty
                        ifTrue: [ seasideUrl addField: each key ]
                        ifFalse: [ seasideUrl addField: each key value: value ] ].

        aNativeRequest isEncrypted
                ifTrue: [ seasideUrl scheme: 'https' ].
               
        ^ seasideUrl decodedWith: self codec

Reply | Threaded
Open this post in threaded view
|

Re: Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb
Updates:
        Labels: Milestone-1.0-beta.8.7

Comment #1 on issue 300 by [hidden email]: Gemstone Swazoo adapter  
does not respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

(No comment was entered for this change.)

Reply | Threaded
Open this post in threaded view
|

Re: Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb
Updates:
        Labels: -GLASS-Server -Milestone-1.0-beta.8.7 GLASS-Seaside30

Comment #2 on issue 300 by [hidden email]: Gemstone Swazoo adapter  
does not respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

Tobias,

This appears to be a generic Seaside bug and not just pertaining to  
GemStone. So the bug needs to be reported against Seaside and the fix made  
there. I can check in the fix, if you report the bug against Seaside ...  
I'm working on a Seaside 3.0.6.1 which includes several GemStone bugfixes  
and aimed at SqueakSource3 so I'd incude this bugfix in 3.0.6.1

Reply | Threaded
Open this post in threaded view
|

Re: Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb
Updates:
        Status: Fixed

Comment #3 on issue 300 by [hidden email]: Gemstone Swazoo adapter  
does not respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

Philippe was listening:)

See http://code.google.com/p/seaside/issues/detail?id=694 for details ...  
when SqueakSource comes back online I'll check in a fix (unless Philippe  
beats me to that too:) ..



Reply | Threaded
Open this post in threaded view
|

Re: Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb

Comment #4 on issue 300 by [hidden email]: Gemstone Swazoo adapter  
does not respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

Thanks to you all. :)

Reply | Threaded
Open this post in threaded view
|

Re: Issue 300 in glassdb: Gemstone Swazoo adapter does not respect Request URIs ending in slash.

glassdb

Comment #5 on issue 300 by [hidden email]: Gemstone Swazoo adapter  
does not respect Request URIs ending in slash.
http://code.google.com/p/glassdb/issues/detail?id=300

faster :)