Introducing pc_user - a user authentication library |
[eluser]PeeCee[/eluser]
I have created a user authentication library for my own purposes, since I thought that the authentication libraries currently available is lacking a couple of core features (they were when they began anyway - have not checked recently). The following introduction is taken from my website: Quote:pc_user is a lightweight authentication library for CodeIgniter. It focuses on simplicity and security. Using the library, you are able to create users, make them log in and out and use secure user hashes for table relations. Logins can be restricted by a maximum number of login retries, it is possible to log in using a cookie and it is possible to use both email and username as login-identifier. Also, user-authentication by email is supported, and the library will give you proper error codes, which you can handle the way you want. Feel free to give me comments and suggestions on the library. Link: http://sorenvind.dk/development/pc_user
[eluser]Unknown[/eluser]
Great library, thanks for sharing. I noticed that the sql dump that you have misses 'cookie_hash' field - easy to fix, just FYI. Also, I suggest you put some variable which indicates the folder of the controllers and views, right now every file should be placed to the root of controllers/ and views/ unless you want to hack the code.
[eluser]Majd Taby[/eluser]
is this transparent or do the controllers needs to include login logic as well?
[eluser]dawnerd[/eluser]
Pretty nifty. I would use it if I hadn't just finalized my user class, which is essentially exactly the same.
[eluser]PeeCee[/eluser]
Thank you very much for your responses. Saint: I will update the sql-dump soon. Thank you for mentioning it. It is correct that the controllers and views of the testsuite should be placed in the root of the corresponding folders. But since it is just that - a test-suite - I do not see a big problem in the lack of configuration. But I will consider changing the behaviour. jTaby: The controllers do not need to include login logic (actually, it do not make sense to do so). The library will report any errors encountered in the form of error-strings which the controller can respond to. The error-strings are retrieved using the function $this->pc_user->getError(). It is only necessary to retrieve errors when a function returns FALSE (obviously). dawnerd: Thank you ![]()
[eluser]Majd Taby[/eluser]
I could possibly incorporate this into CodeExtinguisher, the extra security couldn't hurt.
[eluser]Paul Wenzel[/eluser]
Thanks for sharing your excellent library. It works wonders! I was trying to tie in my database table prefix using dbprefix() function, as it seems the pc_usr library does not utilize that feature. You can usually use something like $this->db->dbprefix("pc_usr") to return "prefix_pc_usr". However, I get this error: Parse error: syntax error, unexpected T_VARIABLE... Might anyone provide some insight in to this one? Thanks!
[eluser]Référencement Google[/eluser]
Hi, I am actually implementing your pc_user library in one application. I can say it's a very nice library. I have some suggestions for next releases that can make it more "CodeIgniter'ish" and "MVC'ish": - Use of active record for the queries - Use of a model for the SQL stuff - Separate config options in a config file - Error handling is great, but need to humanize returned stuff to some language files so that will be again better
[eluser]trice22[/eluser]
Hello, are there any troubles with the last CI-update know about? I've been installing your test-suite (since the lib looks really promising) on my localhost, but I'm getting an error: Code: A PHP Error was encountered Any ideas anyone? Thanks, —trice |
Welcome Guest, Not a member yet? Register Sign In |