4 Replies Latest reply on Jun 19, 2007 7:48 AM by Tim Fox

    1.3.0 Temporary Destination - Full security

    Aslak Knutsen Master

      Hi

      I have a JMS Client sending to a destination(write-only permission), and using a temp destination as a replyto channel.

      My first problem is that the temp destination seems to be handled through the same security model as any normal destination.
      To work around this, one could setup a role with read permissions true as Default, but that would give the client read access to the sending destination as well.

      As far as I can see from the JMS Spec.. A temp destination is unique pr connection, and only consumers from the owning connection is allowed.

      I've been trying to look through some code to see what is going on, and found something a bit strange..

      In ServerSessionEndpoint.addTemporaryDestination it creates a new ManagedTopic/ManagedQueue based on the incoming Destination name, but
      ManagedTopic.setTemporary(true) is never called. Then when DestinationJNDIMapper.registerDestination is called, the temporary flag is lost.

      DestinationJNDIMapper.registerDestination checks to see if the destination is temporary or not. If it is not temporary, it should be bound to JNDI.
      Then there is a new check to see if it is temporary or not, to bind either JbossTemporaryQueue/Topic or JbossTopic/Queue to jndi..

      Any thoughts?


      -aslak-