Problems with caching dynamic authorizer results

#1

Hi!

I’ve got a ruby method registered as a dynamic authorizer for my Autobahn-JS clients. The crossbar server logs my scripts response:

TX: YIELD > [70, 23, {}, [{:allow=>true, :disclose=>true, :cache=>true}]]

It seems to honor the :allow result, blocking invocation if I return false. But the :cache mechanism does not appear to be working. If I invoke the same method, it gets authorized again.

My understanding is that the cache should prevent subsequent calls to the authorize method for the same URI + method pair. Am I missing something?

Thanks!

Norman

0 Likes

#2

This bug …

https://github.com/crossbario/crossbar/issues/212

… seems to indicate this feature has not yet been implemented. Not entirely sure why it’s documented if it doesn’t exist, but if this is the case, I’ll work around the omission.

Thanks

Norman

···

On Friday, August 31, 2018 at 10:49:11 AM UTC-4, nor...@gmail.com wrote:

Hi!

I’ve got a ruby method registered as a dynamic authorizer for my Autobahn-JS clients. The crossbar server logs my scripts response:

TX: YIELD > [70, 23, {}, [{:allow=>true, :disclose=>true, :cache=>true}]]

It seems to honor the :allow result, blocking invocation if I return false. But the :cache mechanism does not appear to be working. If I invoke the same method, it gets authorized again.

My understanding is that the cache should prevent subsequent calls to the authorize method for the same URI + method pair. Am I missing something?

Thanks!

Norman

0 Likes