[Catalyst] Use SessionId from HTTP header
Christiaan Kras
c.kras at pcc-online.net
Sun Feb 14 16:08:15 GMT 2010
Tomas Doran schreef:
>
> On 14 Feb 2010, at 11:43, Christiaan Kras wrote:
>
>> In a RESTful application I'm working I'd like to be able to load a =
>> session based on the sessionid which is sent with the HTTP headers.
>
> It's perfectly arguable that you just failed at REST.
>
> http://www.prescod.net/rest/mistakes/
Thanks for the link and preventing me from some big mistakes in the =
beginning of my application. Not using sessions makes a lot more sense =
indeed.
>
>> The application will, at a later stadium, get a webinterface as well =
>> so I'd still like to use cookies, except for the RESTful part I want =
>> to be able to choose.
>
> Do HTTP auth (Catalyst::Authentication::Credential::HTTP) in the =
> RESTful part, and use standard password & cookies for the non-restful =
> part.
>
> You just configure 2 different realms in your authentication config, =
> and call $c->authenticate with a realm parameter..
Will do! This will actually make things easier.
>
> Cheers
> t0m
>
>
> _______________________________________________
> List: Catalyst at lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive: =
> http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
> Dev site: http://dev.catalyst.perl.org/
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 5245 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.scsys.co.uk/pipermail/catalyst/attachments/20100214/e2e9=
7275/smime.bin
More information about the Catalyst
mailing list