Authenticating against Openfire DB with PHP

i work at the moment on a small office server project for our company,

and we also want to use openfire as intern communication tool.

and no i want to use the Openfire DB (MySQL) also as “normal” userbackend

for the webservices on this server.

the only thing i found out, is that the passwords are encrypted with blowfish in some way

can somebody help me to understand the password encryption?

your better bet is to setup an LADP server for your office. openldap is fine. you can use the LDAP for the basis of your usernames and passwords. if you use an LDAP server that is compatible with your workstations you could even use it for authentication to the workstations.

Hi Martin,

I spent some time trying to figure out how to do this, but got in over my head

The hack I ended up with is using a Jabber PHP library and then just doing a test login to the openfire server with the account to test the credentials. This may not be the best idea if the user has offline messages waiting for them for example.

daryl

LDAP is overkill for our office

we just need the mysql auth.

Here we can switch password store to plain text and use database with php, but this is not a good idea… =) Need to create auth class with same encryption method like in openfire.