Question

I would like to use the hash algorithm from FOSUserBundle in a standalone app.

Here's what I want to do:

-Copy the user table into a standalone app -Let users use their symfony2 login in my separate app In order to do this, I need to code a copy of the FOSUserBundles authentication in my app.

So my question is - where can I find this algorithm in the FOSUserBundle codebase? Is it just a md5() together with the user specific salt or how is it constructed?

Thanks!

* UPDATE *

So while this would certainly be interesting to know how to do, I am now faced instead with changing the algorithm in FOSUserBundle, so I will have to do it the other way around. And I will open a different topic for that.

Was it helpful?

Solution

To answer your original question:

Password encoders are part of the Synfony's core, not FOSUserBundle. You may find them in vendor/symfony/symfony/src/Symfony/Component/Security/Core/Encoder. To find the correct encoder to use in your custom script look what you have configured for FOSUserBundle.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top