Mosquitto and IBM MessageSight implement this nifty scheme to control who can subscribe and publish to which topics. First, we can specify allowable topic strings and patterns like animals/dogs, animals/cats, animals/#, animals/fourlegged/#, etc. Second, we can use substitutions to reflect client id and authenticated use id (%c and %u respectively in Mosquitto), e.g. we can limit the user to subscribe only to "own" topics like stuff/%u/# .
Both are very similar, but I don't believe are part of MQTT spec. Is this a de-facto standard or is there work to standardize this at OASIS?