Re: [Twisted-Python] TCP startTLS() negotiation

2009-08-17 Thread exarkun
On 15 Aug, 04:49 pm, kgeo...@tcpsoft.com wrote: >I've noticed some behavior when negotiating TLS using startTLS(). I'm >starting TLS on both sides of the connection at the same time to >validate >peer certificates using a custom callback. If I call startTLS() >without >any subsequent writes to

Re: [Twisted-Python] twisted.spread PB over a ProcessProtocol

2009-08-17 Thread exarkun
On 15 Aug, 12:36 pm, tho...@apestaart.org wrote: >[snip] > >c) on hitting ctrl-c, tracebacks are generated, due to this block of >code: ># At least on OS X 10.4, exiting while stdout is non-blocking >can ># result in data loss. For some reason putting the file >descriptor >

Re: [Twisted-Python] Happy Twisted User

2009-08-17 Thread Glyph Lefkowitz
On Mon, Aug 17, 2009 at 3:04 PM, Reza Lotun wrote: > Hi Glyph, > > > As a matter of fact I already use TweetDeck! I'm happy to hear it uses > > Twisted :). > > That's great news! > Don't get too excited. Now I know I can blame you when it breaks! ;-) > If you're happy users, perhaps you'd lik

Re: [Twisted-Python] Happy Twisted User

2009-08-17 Thread Reza Lotun
Hi Glyph, > As a matter of fact I already use TweetDeck!  I'm happy to hear it uses > Twisted :). That's great news! > If you're happy users, perhaps you'd like to consider becoming a sponsor? > The minimum contribution is pretty modest ($500). I will definitely push for this. I've contributed

Re: [Twisted-Python] Ldaptor patch for Interfaces

2009-08-17 Thread Tommi Virtanen
On Mon, Aug 17, 2009 at 11:37:10AM +0200, Colin Alston wrote: > TV! Please fix Ldaptor. We discussed this on IM, replying here for anyone looking at the archives. The SVN repo is dead, long live saner version control.. http://eagain.net/gitweb/?p=ldaptor.git -- :(){ :|:&};: __

Re: [Twisted-Python] Happy Twisted User

2009-08-17 Thread Glyph Lefkowitz
On Mon, Aug 17, 2009 at 1:27 PM, Reza Lotun wrote: > Forgive this random spammy shoutout - but I work for TweetDeck (a > real-time web client offering), and we're happy users of Twisted for > our backend. More specifically we use it to handle our account signups > and syncing of client informati

[Twisted-Python] Happy Twisted User

2009-08-17 Thread Reza Lotun
Hi All, Forgive this random spammy shoutout - but I work for TweetDeck (a real-time web client offering), and we're happy users of Twisted for our backend. More specifically we use it to handle our account signups and syncing of client information. So...if you're a twitter or facebook user and ev

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Reza Lotun
Hi Chris, > Automatic daemonization and monitoring? This sounds like exactly what I'm > after. > > I've been calling twisted like so for a project: explicitly setting > the process id, logger and source file here. And relying on a separate > cron script to check if all is well: > > twistd --pidfi

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Chris Adams
Thanks Reza, > Generally it looks fine - but I should mention these random snippets > of code were given with the assumption that a .tac file is being used. > A .tac file is basically a "runner" script or driver for your twisted > program - it works in conjunction with the twistd command-line util

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Reza Lotun
Hi Chris, > My annotated example is also up on github - http://gist.github.com/169102 > > > The original on twisted matrix > http://twistedmatrix.com/projects/web/documentation/examples/webguard.py Generally it looks fine - but I should mention these random snippets of code were given with the as

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Chris Adams
Wow, thanks fo the quick replies guys. I've tried to combine this with the example earlier, with some annotations as to what I think is going on, but I'm on somewhat shaky ground here. Do these annotations sum up roughly what is going on here? My annotated example is also up on github - http://g

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Reza Lotun
Hi Colin, > Where is Portal and SimpleRealm in your example? Those are actually quite > large constructs which are crucial to guard doing anything useful at all. Sorry, this snippet of code I wrote tracked the webguard.py example that I linked to. from twisted.cred.portal import IRealm, Portal

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Colin Alston
On Mon, Aug 17, 2009 at 11:45 AM, Reza Lotun wrote: > The short answer is that you need to use twisted.cred. You don't need to do that at all, it just happens to be the best way. > wrapper = guard.HTTPAuthSessionWrapper( >Portal(SimpleRealm(), checkers), >

Re: [Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Reza Lotun
Hi Chris, > I'm using twisted-web on an openwrt computer, using busybox, and after > looking through the docs, I'm a little unclear about how to implement > something like apache's htpasswd style authentication. > > Using apache, I'd do something like: > > htpasswd -c passwrods admin topSecretPass

[Twisted-Python] Ldaptor patch for Interfaces

2009-08-17 Thread Colin Alston
TV! Please fix Ldaptor. Index: interfaces.py === --- interfaces.py (revision 1506) +++ interfaces.py (working copy) @@ -1,6 +1,6 @@ -from twisted.python import components +from zope.interface import Interface -class ILDAP

[Twisted-Python] How to do basic authentication on twisted web

2009-08-17 Thread Chris Adams
Hi there, I'm new to twisted, so please excuse the noobish question, but: I'm using twisted-web on an openwrt computer, using busybox, and after looking through the docs, I'm a little unclear about how to implement something like apache's htpasswd style authentication. Using apache, I'd do somet