🎄 Happy Holidays! 🥳

Most of Solace is closed December 24–January 1 so our employees can spend time with their families. We will re-open Thursday, January 2, 2024. Please expect slower response times during this period and open a support ticket for anything needing immediate assistance.

Happy Holidays!

Please note: most of Solace is closed December 25–January 2, and will re-open Tuesday, January 3, 2023.

mqtt subscribe disallow does not trigger disconnect

Matthias
Matthias Member Posts: 4

Hello,


i defined such a "subscribe acl" .


I tested with paho mqtt client and can subscribe also not allowed topic without disconnect.


Can anyone say, why i'm not disconnected during subscibe not allowed topic ? 


(i expect a disconnect, but this does not occur.)


...because if i try publish not allowed topic, there is a disconnect from solace broker, as i expect.



> show acl-profile **** message-vpn **** detail


Profile Name : vehicle_prod_ap


Vpn Name   : vpn

 Client Connect Default Action : allow

  Exceptions : 0

 Publish Topic Default Action : disallow

  Exceptions : 1


  Syntax Topics

  ------ --------------------------------------------------------------------

  SMF  TEST>



 Subscribe Topic Default Action : disallow

  Exceptions : 1


  Syntax Topics

  ------ --------------------------------------------------------------------

  SMF  TEST>


 Subscribe Share Name Default Action : allow

  Exceptions : 0


Regards,

Matthias

Answers

  • mstobo
    mstobo Member, Employee Posts: 26 Solace Employee

    Hi Matthias,

    As you are using a Paho client, you should switch the syntax of your ACL exception to MQTT from SMF. Notice the syntax of the expression as well as the MQTT choice in the syntax dropdown.

    regards,


    Matthew

  • Matthias
    Matthias Member Posts: 4

    Hello,

    Thx Matthew.

    I can see all my things work, except disconnect on fail topic subscribe.

    How can i trigger also a disconnect on "not correct topic" subscribe ?

    ...that's the question.

    let's make as joke: to be or not to be... incl. disconnect - Howto ?

    ;)

    Regards

    Matthias

  • mstobo
    mstobo Member, Employee Posts: 26 Solace Employee

    Hi Matthias,

    You won't be disconnected on the "not correct topic" subscribe. An exception will be thrown back to the client, and you can choose how to handle it such as "disconnect."


    Matthew