In the context of one MQ Queue servicing several consumers,
how does one guarantee security -
Consumer-1 must not be able to get messages of Consumer-2, etc.
Thanks in advance.
what is the message type?
Is it an java object or text/xml.
If java object then wrap the logic of notifying your customers in the object it self / if the message is simple text/xml then happy testing :-)
This is not the best way to do it, but here is what I think
1. Put the client id as the header parameter and make sure the consumers are listening on with the right filter installed on their end... That will make sure that the messages reach the intended client.
2. Consider setting up a keypair for each client. Each client should have the private key with himself/herself and send the public key with the client id to the server. The server should maintain the map of client id to pub key. When the server needs to send a message to client1, it encrypts the data with the client1's pub key. Even if client2 (a smart ass!) gets this message, he will not be able to decrypt this as he will not have the private key. This surely needs a lot of setup work to be done, but to get something u have to loose something too.