powered by Jive Software

MUCEventDelegate joiningRoom : customize rejection message

Openfire 4.6.0

I’m building a custom plugin which adds controls on the users joining a MUC. To do that, I implemented a MUCEventDelegate and placed my controls on the joiningRoom function. Unfortunately this function can only return true or false. When I return false, Openfire always returns that the user has invalid credential which isn’t the right error.

A solution would be to throw a custom UnauthorizedException with a message describing the cause as it’s done for the PacketRejectedException in the PacketInterceptor.

Sounds reasonable to me, are you able to submit a github Pull Request with this suggested change?

I will try to come up with something in the following weeks.

1 Like