Changeset 95

Show
Ignore:
Timestamp:
07/14/07 17:56:46
Author:
bbangert
Message:

Updating doc strings for 0.4. Patch from Yannick Gingras.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • AuthKit/branches/0.4/docs/manual.txt

    r59 r95  
    55 
    66:author: James Gardner 
    7 :date: 2006-08-31 
     7:date: 2007-07-12 
    88 
    99.. note:: 
    1010 
    11     This version of AuthKit is nothing like the old AuthKit 0.2 which used to be 
    12     hosted in the Pylons SVN. This version is a generic framework, the old  
    13     version was a specific implementation. 
     11    This version of AuthKit (0.4) is nothing like the old AuthKit 0.2 
     12    which used to be hosted in the Pylons SVN. This version is a 
     13    generic framework, the old version was a specific implementation. 
    1414 
    1515.. contents:: Table of Contents 
     
    110110 
    111111        authkit.enable = true 
    112         authkit.method = basic 
     112        authkit.setup.method = basic 
    113113        authkit.users = james:bananas       
    114114                        ben:apples 
     
    213213``_`` characters and it also strips off the ``prefix`` defined when inilialising 
    214214the middleware. If you don't set ``prefix`` it defaults to ``authkit.``. This  
    215 means that options such as ``cookie_signout`` used by AuthKit can be written in  
    216 the slightly more descriptive and clean form ``authkit.cookie.signout`` in the 
     215means that options such as ``cookie_signoutpath`` used by AuthKit can be written in  
     216the slightly more descriptive and clean form ``authkit.cookie.signoutpath`` in the 
    217217config file. 
    218218 
     
    318318    Use an OpenID passurl for authentication 
    319319 
    320 As mentioned before you can specify this in your code as ``method="basic"`` or 
    321 in your config file as ``authkit.method = basic``. If you try to specify the 
    322 same option using both methods an error is raised, otherwise AuthKit tries to 
    323 use all the options from both sources. 
     320As mentioned before you can specify this in your code as 
     321``method="basic"`` or in your config file as ``authkit.setup.method = 
     322basic``. If you try to specify the same option using both methods an 
     323error is raised, otherwise AuthKit tries to use all the options from 
     324both sources. 
    324325 
    325326Each of these options is described in detail in the following sections. 
     
    443444 
    444445The example also specifies a ``cookie_secret`` which is a string used to help 
    445 make the encryption on the cookie more random and a ``cookie_signout`` 
     446make the encryption on the cookie more random and a ``cookie_signoutpath`` 
    446447parameter which is a special path which should automatically sign the user out 
    447448when visited but will still display the resulting page so that your application 
     
    518519    environ['paste.auth_tkt.set_user'](username) 
    519520 
    520 If you specify a ``cookie_signout`` path when you set up the authentication 
     521If you specify a ``cookie_signoutpath`` path when you set up the authentication 
    521522middleware the user will be signed out automatically when visiting that path 
    522523but you will still need to display a "signed out" path at that URL or the user 
     
    575576 
    576577    authkit.enable = true 
    577     authkit.method = passurl 
     578    authkit.setup.method = passurl 
    578579    authkit.cookie.secret = some secret phrase 
    579580 
     
    616617incidentally the same as for form authentication or forward authentication. 
    617618 
    618 Remember that if you specify ``cookie_signout`` the cookie will be removed but if 
     619Remember that if you specify ``cookie_signoutpath`` the cookie will be removed but if 
    619620you do not handle the path in the application the user is likely to be shown a 
    620621"404 Not Found" page. See the documentation about the forward section for a  
     
    771772``form_and_email`` method:: 
    772773 
    773     authkit.method = form_and_email 
     774    authkit.setup.method = form_and_email 
    774775 
    775776Writing your own middleware can be slightly tricker than you might expect if 
     
    804805    used from a different IP address and hence to try to improve security. 
    805806 
    806 cookie_signout 
     807cookie_signoutpath 
    807808 
    808809    A path which when visited will cause the cookie to be removed and the  
     
    839840    # AuthKit Options 
    840841    authkit.enable = true 
    841     authkit.method = forward 
     842    authkit.setup.method = forward 
    842843    authkit.cookie.secret = random string 
    843844    authkit.cookie.name = test 
  • AuthKit/branches/0.4/docs/pylons.txt

    r59 r95  
    33 
    44:author: James Gardner 
    5 :date: 2008-08-30 
     5:date: 2007-07-12 
    66 
    77.. contents:: Table of Contents 
     
    154154can install it with this command:: 
    155155 
    156     easy_install -U "AuthKit==0.3
     156    easy_install -U "AuthKit==0.4
    157157     
    158158.. note:: 
    159159     
    160     Unitl AuthKit 0.3 is released you will need to use:: 
     160    Until AuthKit 0.4 is released you will need to use:: 
    161161     
    162162        easy_install -U http://authkit.org/svn/AuthKit/trunk#egg=AuthKit-dev 
     
    179179 
    180180    import authkit.authenticate 
    181     app = authkit.authenticate.middleware(app, config_paste=app_conf) 
     181    app = authkit.authenticate.middleware(app, app_conf=app_conf,  
     182                                               global_conf=global_conf) 
    182183 
    183184.. note:: 
     
    253254    ... 
    254255    authkit.enable = true 
    255     authkit.method = digest 
     256    authkit.setup.method = digest 
    256257    authkit.users.setup = user:pylons 
    257258 
     
    295296    ... 
    296297    authkit.enable = true 
    297     authkit.method = form 
     298    authkit.setup.method = form 
    298299    authkit.cookie.secret = a random string 
    299     authkit.cookie.signout = /hello/signout/ 
     300    authkit.cookie.signoutpath = /hello/signout/ 
    300301    authkit.users.setup = user:pylons 
    301302                          another:password 
     
    325326.. note :: 
    326327 
    327     The ``authkit.cookie.signout`` option should be the exact path you use  
     328    The ``authkit.cookie.signoutpath`` option should be the exact path you use  
    328329    for signing out. For example, if you choose ``/hello/signout/`` then  
    329330    ``/hello/signout`` and ``/hello/signout/page`` won't sign the user out,