Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: Demian Brecht Newsgroups: comp.lang.python Subject: OAuth 2.0 implementation Date: Mon, 26 Mar 2012 19:42:38 -0700 (PDT) Organization: http://groups.google.com Lines: 34 Message-ID: <1973354.3.1332816158529.JavaMail.geo-discussion-forums@pbae2> NNTP-Posting-Host: 159.153.138.55 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: posting.google.com 1332816163 10010 127.0.0.1 (27 Mar 2012 02:42:43 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 27 Mar 2012 02:42:43 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=159.153.138.55; posting-account=US_9zQoAAABOtpKbrs9cDfYpbT6eMPnL User-Agent: G2/1.0 X-Received-Bytes: 2788 Xref: csiph.com comp.lang.python:22222 Hi all, I'm getting close to an alpha release of an OAuth 2.0 implementation (https://github.com/demianbrecht/py-sanction). High level features include: * Support for multiple providers (protocol deviations). This didn't seem to be supported by any library. * Actually an OAuth 2.0 implementation (python-oauth2 is a 2nd version of python-oauth, not an OAuth 2.0 implementation) * Support for the entire OAuth 2.0 spec. Most provide support for the authorization code grant flow (employed by all web server providers), but lacked support or extensibility for any other flows, credentials or other provider extensions) * 100% unit test coverage. Some employ TDD, others didn't. Current implementation includes support for Authorization Code Grant flow but can be extended to support others (including extensions) quite trivially. Current adapter implementations include: * Google * Facebook * Stack Exchange * Deviant Art * Foursquare It has yet to be heavily used or functionally tested (basic tests have been done in example/server.py) and documentation is being worked on. Just wanted to share some of my work and hopefully someone other than me can find some use for it :) P.S. For those interested, cloc stats are: http://cloc.sourceforge.net v 1.53 T=0.5 s (28.0 files/s, 1818.0 lines/s) ------------------------------------------------------------------------------- Language files blank comment code ------------------------------------------------------------------------------- Python 14 239 196 474 ------------------------------------------------------------------------------- SUM: 14 239 196 474 -------------------------------------------------------------------------------