This is much needed, go Kevin!
My immediate thought is that when making the login methods for identity,
we could make that code a lot easier to follow. I have to admit, I found
figuring out how to get login/logout doing what I want in tg1 identity
much more troublesome than I expected.
That's a bit that could have a clearer api or maybe just way more
comments in the code, or something!
Thanks
Iain
This would be really great, I mean if the API would not change too
much relative to tg1.
> My goal is to eventually make it framework agnostic,
Any reason why you would want to do that? (apart from "let's be as
general as possible")
Being general is great but if all pieces of a software package are
uber-general with duct tape holding everything together then sometimes
the amount of duct tape is more than the actual stuff that needs to be
held together. Or you have a well defined target audience apart from
tg users?
Cheers,
Daniel
Sounds like a good approach to me. Ideally we want to attract
contributors outside of the TG2 world, and we want to make this
something that people want to contribute too (so that we can get
OpenID support, ect). This is more likely to happen if we make it
work with the tools they allready use. But, TurboGears defines one
of the most popular toolsets in the python community, so even if it's
TG specific it should attract people.
Here's my basic thoughts on the subject off framework independent
components: The trade-off between generality and framework
specificness should be handled on a case by case basis, depending on
who might end up wanting to use it, how much work it is to make it
framework independent, and how willing the authors of the component
are to work to support non TG2 users.
So, we definitely don't want our own ORM, or template system, and we
probably don't need our own authentication middleware, but I'd doubt
that a user-registration module would be worth making framework
neutral, since it will have to have templates, depend directly on the
ORM, and it would be very hard indeed to abstract all of that away.
And I doubt that the component would really grown non TG2 users. So,
it's all something that we have to deal with for each component we
create.
--Mark Ramm
This is really awesome work Kevin, and very timely. Are you
separating this work out as a googlecode project or is it part of the
tg svn?
Also, is it possible to run this if TG1 was running on WSGI? In terms
of support, it would be great if it was backwards compatible.
I am looking forward to using this on Grok.
-chris
Authority it self is going to need to have multiple providers
(obviously) and I think it will likely be usable outside of TG itself
(perhaps in Grok as Chris has suggested), so it should probably get
it's own repo. Now that apidya does google code wiki style output
for docs, I think google code is an pretty reasonable choice these
days, and it's certainly easy to get up and running.
--Mark
OMG, a question I can answer! ;-)
Use Twill and import the twill commands into a nose test suite. Running
functional tests with twill through nose is really easy and it does all
your cookie stashing for you and let's you pretend to be different
agents and stuff. Plus Titus and Gregio (sp?) are really helpful on the
twill and testing python mailing lists. And there would be no reason you
couldn't combine it with checks on what is in the raw db at the same
time ( though I haven't quite figured out the best way to do this yet,
baby steps for me).
It is really easy to run long progressions of login and outs. I could
actually help there, I've been writing twill tests of member sign up and
status changing and editing ad nauseum for the last four days.
Iain
It sounds like Kevin's plan is the way forward, but perhaps this code
(which was written for a specific project) will provide some useful
stuff that we can hack out.
BTW, the code I'm posting used Beaker middleware and provided a WSGI
authentication wrapper around a TG1 application. It's been used
against TG2 as well, and I'll try to get a bit of related
authorization code for TG2 up as well.
Hopefully this will be of some use to the Authority project, if only
as a reference.
BTW, if you want me to Kevin, I can set up a google code project for
Authority tonight as the same time I post this stuff.
--Mark
--
Mark Ramm-Christensen
email: mark at compoundthinking dot com
blog: www.compoundthinking.com/blog
Not yet, I had more trouble with the Routes stuff than expected, and
then I found a few places which needed to be cleaned up on wsgiauth
before I could post it. I do expect to have it up somewhere this
afternoon, I'll let you know as soon as it's there.
BTW, do you think you could add me as a project member on authority?
--Mark
I just don't understand why we're trying to replace Pylons. We chose
it, now build on top of it and improve it.
-Devin
Even with all that, I suggested that we try to make it work, and after
a couple of people did that, we ended up deciding that while we could
make it work, it would require a lot of work to get it into the kind
of shape we need it to be.
We really want an Auth solution that could be embraced by the Pylons
and TG communities, and could be accessable to the greater WSGI world,
and I have my doubts that AuthKit will become that solution. There's
already too much frustration and dissatisfaction, and very little
activity on the development side to answer any of those issues.
If however, we've been misinformed and AuthKit has a healthy and
vibrant community which is willing to help us, and which is willing to
take on some new developers who will fix things and turn it into a
viable solution for us, I'm sure the TG dev community is wiling to
re-open the issue, and I for one know I could be convinced to change
my mind. But, I don't think it's likely unless the AuthKit project
starts becoming more open, and more active.
--Mark Ramm
On Fri, Feb 22, 2008 at 10:10 AM, Devin Torres <devin....@gmail.com> wrote:
>
> I can't believe we're having this discussion on this mailing list. Use
> AuthKit. If you're having problems understanding it contact me and
> I'll try to help you, but we don't need to be reimplementing the wheel
> here. Pylons has already chosen the best of breedI packages for you, if
> you have a problem with one of them then improve it.You said "it needs
> a bit of continuing love to make it into all it could be." Well? Give
> it that bit of continuing love!
>
> I just don't understand why we're trying to replace Pylons. We chose
> it, now build on top of it and improve it.
>
> -Devin
>
>
>
> On Thu, Feb 21, 2008 at 4:00 PM, Kevin Horn <kevin...@gmail.com> wrote:
> >
> >
> > On Thu, Feb 21, 2008 at 3:13 PM, Mark Ramm <mark.mch...@gmail.com>
> > wrote:
> > >
> > >
> > > > BTW, Mark, did you have a chance to put your auth code up someplace?
> > >
> > > Not yet, I had more trouble with the Routes stuff than expected, and
> > > then I found a few places which needed to be cleaned up on wsgiauth
> > > before I could post it. I do expect to have it up somewhere this
> > > afternoon, I'll let you know as soon as it's there.
> > >
> > > BTW, do you think you could add me as a project member on authority?
> > >
> > > --Mark
> > >
> > >
> > >
> >
> > Will do.
> >
> > Kevin Horn
> >
> >
> >
> > >
> >
>
> >
>
--
I can't believe we're having this discussion on this mailing list. Use
AuthKit. If you're having problems understanding it contact me and
I'll try to help you, but we don't need to be reimplementing the wheel
here. Pylons has already chosen the best of breed packages for you, if
you have a problem with one of them then improve it.You said "it needs
a bit of continuing love to make it into all it could be." Well? Give
it that bit of continuing love!
I just don't understand why we're trying to replace Pylons. We chose
it, now build on top of it and improve it.
-Devin
I'm also not sure how TG1.x accomplished authentication (wasn't it just
forward authentication?), so if anyone could enlighten me on how TG1.x
authentication was performed I could probably provide a counter-example.
-Devin
While I did not look into TG2 (yet), I need a more flexible auth* solution
(compared to identity) for a mission-critical TG1-based project.
I tried AuthKit but I was not able to get AuthKit running with
TG1/CherryPy: Just sending a request and get a response (no auth* related
restrictions) but AuthKit sitting in between as a middleware. Maybe this is
a problem with CherryPy 2.x but I can't exchange that one.
Therefore I'm interested in another auth solution, independently if it is
used in TG2 (although that would be nice). I will make sure that a new
auth* solution will be usable in TG1 which will smooth the upgrade path for
some users.
fs
PS: I will do some coding on this during the sprint but my time is somewhat
limited today.
> While I did not look into TG2 (yet), I need a more flexible auth*
> solution (compared to identity) for a mission-critical TG1-based project.
Can everyone on this thread please document their requirements on this page:
http://docs.turbogears.org/2.0/AuthReqs
If we get a good set of use cases here, that will really help designing
a future auth* solution.
Paul
Hi,
I'll finish working on authority for today. I got my dev environment set up
and patched authority so that beaker is not required any more (this is
useful for auth schemes like HTTP Basic).
I don't have any commit rights to the repo, so I uploaded my patch to:
http://www.felix-schwarz.name/files/misc/2008/2008-02-23_authorize.patch
Furthermore I wrote a small unit test for HTTP basic auth (please have a
look at the disabled test which tests the handling of malformed headers):
http://www.felix-schwarz.name/files/misc/2008/test_basic_auth.py
Have fun,
--
Felix Schwarz
Dipl.-Informatiker
software development and consulting
www.schwarz.eu
The group is already up and running :)
http://groups.google.com/group/authority-wsgi/
--
Lee McFadden
blog: http://www.splee.co.uk
work: http://fireflisystems.com
skype: fireflisystems