I've submitted some initial support for this. The details may change, but basically if you subscribe to "hostname/#", messenger will set the source to dynamic. You can access the remote address by querying the subscription object returned from the subscribe method. In C this can be done by using pn_subscription_address(), and in python you can simply use the address attribute of the subscription object. In both cases the query will block until the dynamically created address is available, unless of course the messenger is configured to be non blocking.
Messenger itself doesn't support dynamically created addresses on the incoming side, so I can't test this directly, however I've successfully tested against the C++ broker.