I want to have a permanent JID that is basically a GUID as the node part. This seems normal. But I want to be able to have the user login using an alternative username/JID that isn't their GUID (so they don't have to memorize this GUID). The XMPP server will be used mostly for automated non-human logins, but sometimes a human will login as well. Everyone has a GUID as their username but we don't want to force the humans to memorize a GUID.
- Fred's real JID is email@example.com, but he logs into the XMPP server as firstname.lastname@example.org.
- Jane can send messages to Fred via his real JID (the GUID-based one). Or optionally (not required for my needs, but would be nice) she could send messages to his login JID that isn't the GUID-based one. No matter what, I'd want the "from" address to be the GUID-based JID, not the "fake" login JID.
It seems like it could be done at login: receive the user's login JID during the login process and convert it into the proper GUID JID (discarding the login JID is fine). This would need to be done on the server side, not on the client side.
Could it be done with a stringprep processor? (I'm not totally clear on the stringprep's intent, but maybe?)