How to create automatic relashionship between users?

Hi,

I instaled OpenFire 3.7.0 with MySQL database.

All are working fine, registering users and groups.

But I would like to create automaticly the relations between users (Contacts), what users should be showed for others.

I don’t like that the users can add and view any kind of other users.

I want to do a program that:

  1. create the user

  2. put the user in some group

  3. add to the contact’s list only other users from the same group, and make this bi-directional, adding the new user for all others group users too

I think this is possible by managing the database directly, right?

Solved. I handled directly the database like this:

insert into ofGroup values(‘3’,‘RODOBELO’);

insert into ofGroupProp values(‘3’,‘sharedRoster.showInRoster’,‘onlyGroup’);

insert into ofGroupProp values(‘3’,‘sharedRoster.displayName’,‘3-RODOBELO’);

insert into ofGroupProp values(‘3’,‘sharedRoster.groupList’,‘IS-CBA,IS-CGR,IS-PIN,IS-ROO’);

Then, the group RODOBELO visualizes the users from IS-CBA,IS-CGR,IS-PIN and IS-ROO groups.

You can probably achieve the same by using the Shared groups in Openfire (check the group settings). Inserting directly into database is not a recommended way of doing this. Also, you have mentioned, that you don’t like that users can manually add contacts. Well, you haven’t ruled that out. They should still be ale to search and add users. You can try blocking this with Packet Filter plugin.

Hi,

The problem with “Shared groups” is that I have to handle manually the groups. But I did in my system a way to automatically create users and groups in the OpenFire server, without end user interference.