Category index for “oauth”

  • OAuth and django rest framework

    Star

    OAuth and django rest framework

    This is a well known topic, but i can’t find the existing solution that will fully satisfy me. So i write it by myself :).

    Assume we have a “single page” web site, that is talking with backend via REST API. Client side can be written with ember, angularjs or some like this. Backend - django rest framework (DRF). We’ve got a task - add social login (OAuth protocol).

    Comments Read More
  • OAuth step by step

    OAuth step by step

    OAuth protocol has two versions: 1.0 and 2.0.

    Most of services today use version 2.0, i suppose because it is easier to implement. Also, 2.0 can be realized in standalone applications (those, that don’t have a server).

    To understand the protocols very useful to have a look at their realisation. Here i’ll show several scripts that talk to OAuth providers of different versions. Scripts will implement client application functionality. Only standard python libraries are used. This help to overview the OAuth protocol - everything is on single screen and familiar. Of course, for production application we must use third party oauth libs, they handle many special cases and so on. Purpose of these scripts is just understanding of the protocol and nothing else. It is often hard to keep the protocol flow in production-ready library, because it is splitted in many modules, some other packages are used. And the full vision is slipping out of sight.

    Comments Read More