cgmartin / clj-wamp

WebSocket Application Messaging Protocol (WAMP) for Clojure and HTTP Kit
http://cljwamp.us
Eclipse Public License 1.0
54 stars 12 forks source link

WAMP-CRA permissions: Allow keyword ":all" for convenience #7

Closed cgmartin closed 11 years ago

cgmartin commented 11 years ago

Explicitly whitelisting all of the RPC/Pub/Sub topics in the CRA permissions map can be somewhat tedious.

Allow the map to contain a shorthand :all keyword:

{:all true}
;; or mix/match per type, using a boolean
{:rpc       true   ; all rpc calls are allowed
 :subscribe false  ; no subscriptions allowed
 :publish   {("http://chat") true}} ; one topic allowed for publish
cgmartin commented 11 years ago

Implemented in 1.0.0 release.