XMPP loopback bug

We have an Openfire server running with the latest 1.2.3a gateway plugin. We have enabled the XMPP transport with * as the domain, so our users are allowed to log in to any other jabber server.

We are having problems with users registering their own JID on the XMPP transport. (i.e. user@jabber.host.com tries to register user@jabber.host.com on the XMPP transport). This brings the whole Openfire server down (100% CPU plus high memory load).

I think the easiest fix would be to change the gateway plugin so a user cannot register his own JID on the XMPP transport (preferably case insensitive, as we have seen a few users registering User@jabber.host.com for user@jabber.host.com)?