On Thu, Apr 30, 2009 at 10:39 AM, Gustavo Narea <[email protected]> wrote:
>
> Hello, Alex.
>
> On Thursday, April 30 2009 01:18:03 [email protected] wrote:
>> it should be simpler than it shows. it's a function call on an accessible
>> object: server.ssl_context.
>> thus all i miss is the server object, and i'm
>> asking on this list as tg developers know where they invoke the server. my
>> action should take place after the server is up, but before any request.
>

Here is the kicker, the actual process is the other way around. when
you run paster serve development.ini you are doing
1- reading the config file
2- loading paste.http
3- loading PasteScript and PasteDeploy
4- the stuff from 3 tells 2 the wsgi app to use (your TGApp, it's a
class inside tg)
5- #2 calls TGApp to load it
6- requests come into the browser that are redirected to TGApp

So as you can see there is no way from within TG code to modify the
call to the server as the server calls TG. As gustavo was explaining
you can't do ssl auth after the call is made because ssl is needed for
the call to be made (chicken and egg).


That said I believe paste.http already has some facilities for SSL
please take a look at http://pythonpaste.org/modules/httpserver.html
sadly I don't know more about it as I have never used them.

> As I said in my previous email, you should get in touch with the Paste
> community.
>
> Neither Pylons or TG2 runs that server, it's the other way around: That server
> runs Pylons/TG2 or whatever WSGI application you want it to run.
>
> This is, it's more complex. :)
>
> Cheers,
> --
> Gustavo Narea <xri://=Gustavo>.
> | Tech blog: =Gustavo/(+blog)/tech  ~  About me: =Gustavo/about |
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to