[Repoze-checkins] r845 - in whoplugins/whoradius/trunk: . pamradius
Chris Shenton
chris.shenton at nasa.gov
Wed Mar 19 22:35:11 EDT 2008
Author: Chris Shenton <chris.shenton at nasa.gov>
Date: Wed Mar 19 22:35:11 2008
New Revision: 845
Log:
rename files and code from pam to who for clarity
Modified:
whoplugins/whoradius/trunk/CHANGES.txt
whoplugins/whoradius/trunk/README.txt
whoplugins/whoradius/trunk/pamradius/__init__.py
whoplugins/whoradius/trunk/pamradius/tests.py
whoplugins/whoradius/trunk/radiustest.ini
whoplugins/whoradius/trunk/setup.py
whoplugins/whoradius/trunk/version.txt
Modified: whoplugins/whoradius/trunk/CHANGES.txt
==============================================================================
--- whoplugins/whoradius/trunk/CHANGES.txt (original)
+++ whoplugins/whoradius/trunk/CHANGES.txt Wed Mar 19 22:35:11 2008
@@ -2,6 +2,10 @@
CHANGES
=========
+0.2 (2008-03-19)
+================
+* Change name to conform to pam -> who (authentication)
+
0.1 (2008-03-18)
========================
* Initial implementation by Chris Shenton and Chris McDonough
Modified: whoplugins/whoradius/trunk/README.txt
==============================================================================
--- whoplugins/whoradius/trunk/README.txt (original)
+++ whoplugins/whoradius/trunk/README.txt Wed Mar 19 22:35:11 2008
@@ -1,19 +1,34 @@
===========
- pamradius
+ whoradius
===========
-Plugin for repoze.pam that queries RADIUS backend for authentication.
+Plugin for repoze.who that queries RADIUS backend for authentication.
+
+There are plenty of ISP and enterprise-level RADIUS servers, and their
+number seems to be increasing as the demand for centralized
+authentication of WiFi access points grows.
+
+My motivation in writing this was to allow WSGI apps to authenticate
+against our RSA SecurID token based authentication service which is
+accessible thorugh a RADIUS interface, in addition to it's painful
+native mechanism.
+
+Popular RADIUS servers include FreeRADIUS, GNU RADIUS, and the
+venerable Cistron; I prefer FreeRADIUS these days. Commercial servers
+include Radiator and the delightfully named Steel Belted RADIUS
+server.
Non-functionality
=================
It doesn't do anything with RADIUS accounting.
-In order to avoid the need for full RADIUS dictionary, we define
-locally only the minimum we need for authentication. I've not been
-able to parse with pyrad dictionaries from FreeRADIUS-1.7,
-FreeRADIUS-2.0.3, GNU RADIUS, or Cistron RADIUS, but was able to parse
-one from an old version, perhaps FreeRADIUS-1.6 or earlier.
+In order to avoid the need for full RADIUS dictionary -- which maps
+protocol attribute numbers to names -- we define locally only the
+minimum we need for authentication. I've not been able to parse with
+pyrad dictionaries from FreeRADIUS-1.7, FreeRADIUS-2.0.3, GNU RADIUS,
+or Cistron RADIUS, but was able to parse one from an old version I had
+deployed elsewhere, perhaps FreeRADIUS-1.6 or earlier.
Lack of dictionary means we can't decode reply packets, which might
provide useful information for subsequent functionality.
Modified: whoplugins/whoradius/trunk/pamradius/__init__.py
==============================================================================
--- whoplugins/whoradius/trunk/pamradius/__init__.py (original)
+++ whoplugins/whoradius/trunk/pamradius/__init__.py Wed Mar 19 22:35:11 2008
@@ -1,5 +1,5 @@
from zope.interface import implements
-from repoze.pam.interfaces import IAuthenticator
+from repoze.who.interfaces import IAuthenticator
class RadiusPlugin(object):
@@ -70,11 +70,11 @@
import sys
import os
import logging
- from repoze.pam.plugins.form import FormPlugin
- from repoze.pam.plugins.auth_tkt import AuthTktCookiePlugin
- from repoze.pam.middleware import PluggableAuthenticationMiddleware
- from repoze.pam.classifiers import default_request_classifier
- from repoze.pam.classifiers import default_challenge_decider
+ from repoze.who.plugins.form import FormPlugin
+ from repoze.who.plugins.auth_tkt import AuthTktCookiePlugin
+ from repoze.who.middleware import PluggableAuthenticationMiddleware
+ from repoze.who.classifiers import default_request_classifier
+ from repoze.who.classifiers import default_challenge_decider
form = FormPlugin('__do_login', rememberer_name='auth_tkt')
auth_tkt = AuthTktCookiePlugin('secret squirrel',
@@ -86,7 +86,7 @@
authenticators = [('radius', radiusplugin)]
challengers = [('form', form) ]
log_stream = sys.stdout
- if os.environ.get('NO_PAM_LOG'):
+ if os.environ.get('NO_WHO_LOG'):
log_stream = None
middleware = PluggableAuthenticationMiddleware(
app,
Modified: whoplugins/whoradius/trunk/pamradius/tests.py
==============================================================================
--- whoplugins/whoradius/trunk/pamradius/tests.py (original)
+++ whoplugins/whoradius/trunk/pamradius/tests.py Wed Mar 19 22:35:11 2008
@@ -11,7 +11,7 @@
class RadiusMiddlewareTests(unittest.TestCase):
def _getTargetClass(self):
- from pamradius import RadiusPlugin
+ from whoradius import RadiusPlugin
return RadiusPlugin
def _makeOne(self, *arg, **kw):
@@ -19,7 +19,7 @@
return klass(*arg, **kw)
def test_implements(self):
- from repoze.pam.interfaces import IAuthenticator
+ from repoze.who.interfaces import IAuthenticator
from zope.interface.verify import verifyClass
klass = self._getTargetClass()
verifyClass(IAuthenticator, klass)
@@ -43,7 +43,7 @@
class RadiusServerTests(unittest.TestCase):
def _getTargetClass(self):
- from pamradius import Server
+ from whoradius import Server
return Server
def _makeOne(self, *arg, **kw):
Modified: whoplugins/whoradius/trunk/radiustest.ini
==============================================================================
--- whoplugins/whoradius/trunk/radiustest.ini (original)
+++ whoplugins/whoradius/trunk/radiustest.ini Wed Mar 19 22:35:11 2008
@@ -1,9 +1,9 @@
[app:app]
-paste.app_factory = repoze.pam.fixtures.testapp:make_app
+paste.app_factory = repoze.who.fixtures.testapp:make_app
[pipeline:main]
pipeline =
- egg:pamradius#test
+ egg:whoradius#test
app
[server:main]
Modified: whoplugins/whoradius/trunk/setup.py
==============================================================================
--- whoplugins/whoradius/trunk/setup.py (original)
+++ whoplugins/whoradius/trunk/setup.py Wed Mar 19 22:35:11 2008
@@ -24,7 +24,7 @@
here = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(here, 'README.txt')).read()
-setup(name='pamradius',
+setup(name='whoradius',
version=__version__,
description=('Repoze pluggable authentication middleware)'
'querying RADIUS back-end for authentication.'),
@@ -47,12 +47,12 @@
packages=find_packages(),
include_package_data=True,
zip_safe=False,
- tests_require = ['repoze.pam', 'pyrad>=1.1'],
- install_requires=['repoze.pam', 'pyrad>=1.1'],
- test_suite="pamradius.tests",
+ tests_require =['repoze.who', 'pyrad>=1.1'],
+ install_requires=['repoze.who', 'pyrad>=1.1'],
+ test_suite="whoradius.tests",
entry_points = """
[paste.filter_app_factory]
- test = pamradius:make_test_middleware
+ test = whoradius:make_test_middleware
"""
)
Modified: whoplugins/whoradius/trunk/version.txt
==============================================================================
--- whoplugins/whoradius/trunk/version.txt (original)
+++ whoplugins/whoradius/trunk/version.txt Wed Mar 19 22:35:11 2008
@@ -1 +1 @@
-0.1
+0.2
More information about the Repoze-checkins
mailing list