Codeigniter: Password Generation Component

Created on 21 Dec 2014  路  5Comments  路  Source: bcit-ci/CodeIgniter

In lieu of rolling our own, let's decide on a third party to incorporate.

I'm envisioning something similar to ircmaxell/password_compat being included in system/core/compat, thought we may want to plan third-party components to be in a more obvious location.

Most helpful comment

random_string can (and probably should only) be used for non-password scenarios. It's a string helper and not a password helper. I use it for example to generate order ids.

All 5 comments

I'm against _shipping_ a third-party component together with CI.

The goal of using a third-party component is to avoid duplicating code and maintenance efforts. Including a copy of a third-party library in the framework's codebase means that the library is maintained _as a part_ of the framework and then you fail to meet that goal.

I'd rather recommend a popular library in the documentation instead.

Why not use composer to manage third party package?

composer not work in china. CI is good for phper who in china. thank you for you effort

https://github.com/bcit-ci/CodeIgniter/blob/21898a45f323bb74ef6e5ee8cf21c3397467665b/system/helpers/string_helper.php#L195-L240

Also, we really ought to deprecate this and wrap the password library instead.

https://github.com/ircmaxell/RandomLib is a very solid choice. @ircmaxell

random_string can (and probably should only) be used for non-password scenarios. It's a string helper and not a password helper. I use it for example to generate order ids.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

al-ramadhan picture al-ramadhan  路  6Comments

Rverm picture Rverm  路  6Comments

monski picture monski  路  4Comments

rmdhfz picture rmdhfz  路  3Comments

vahidvdn picture vahidvdn  路  4Comments