Uploaded image for project: 'Help-Desk'
  1. Help-Desk
  2. HELP-13889

[Fiware-tech-help] Query - Commands and Encryption in Fiware

    Details

    • Type: extRequest
    • Status: Closed
    • Priority: Major
    • Resolution: Dismissed
    • Fix Version/s: 2021
    • Component/s: FIWARE-TECH-HELP
    • Labels:
      None

      Description

      Hi All,

      I am working on Smart Light App and using following Fiware GEs

      • Orion Context Broker
      • Iotagent-json
      • Mosquito

      I am able to send events/data on "/<service>/<deviceId>/attrs" topic which updates the context broker and one can subscribe to the same.

      Now I have below queries.

      1. Above case is for Events, means Device/Sensor sending data and it updates the same in Context Broker. I need to do other way also, means sending commands from some applications (say web application) towards Device and status of Device gets changed.

      How do we work with Commands in Fiware? I tried /cmd and /cmdexe topics but it did not work. Kindly give steps and example if possible.

      2. Now, my data coming from Device is Base64 encrypted (example given below). If I send the same directly to "/attrs" topic it is not updating attributes values due to encryption. I may add extra layer for decryption and then publish it on "/attrs" topic which would update ehe values in context broker. Is it the right approach? Does Fiware supports Encryption (Mainly Base64)?

      Example:

      Plain Text: Payload:

      {"command": "ON_OFF","switchInternalId":"S01", "action":"ON",,"requestId":"123"}

      Encrypted Message:

      On/Off Message:

      { "messageId": "onoffmsgId", "deviceId": "device-id", "commandId": " ON_OFF ", "encodingType": "Base64", "message":"ew0KCSJjb21tYW5kIjogIkVPTyIsDQoJInN3aXRjaEludGVybmFsSWQiOiAiUzAwMDAwMyIsDQoJIMTCIsDQoJInJlcXVlc3RJZCI6ICJFT09fdGVtcFJlcUlkIg0KfQ=" }

      Appreciate your help.

      Thanks & Regards,
      Krishan Babbar
      ============================================================================================================================

      Disclaimer: This message and the information contained herein is proprietary and confidential and subject to the Tech Mahindra policy statement, you may review the policy at http://www.techmahindra.com/Disclaimer.html <http://www.techmahindra.com/Disclaimer.html> externally http://tim.techmahindra.com/tim/disclaimer.html <http://tim.techmahindra.com/tim/disclaimer.html> internally within TechMahindra.

      ============================================================================================================================

      __________________________________________________________________________________________

      You can get more information about our cookies and privacy policies on the following links:

      Fiware-tech-help mailing list
      Fiware-tech-help@lists.fiware.org
      https://lists.fiware.org/listinfo/fiware-tech-help

      [Created via e-mail received from: Krishan Babbar <KB00449283@TechMahindra.com>]

        Activity

        Hide
        josegato Jose Gato Luis added a comment -

        The issue has been emailed:

        • Time sent: 24/Apr/18 8:17 AM
        • To: fernando.mendez.external@atos.net
        • with subject: *(HELP-13889) [Fiware-tech-help] Query - Commands and Encryption in Fiware *

        From FIWARE JIRA - Main Help Desk ----

        -------------------------------------------------------------------------------
        Comments:

        ------------------------
        Issue id: HELP-13889
        Description:
        Hi All,

        I am working on Smart Light App and using following Fiware GEs

        • Orion Context Broker
        • Iotagent-json
        • Mosquito

        I am able to send events/data on "/<service>/<deviceId>/attrs" topic which updates the context broker and one can subscribe to the same.

        Now I have below queries.

        1. Above case is for Events, means Device/Sensor sending data and it updates the same in Context Broker. I need to do other way also, means sending commands from some applications (say web application) towards Device and status of Device gets changed.

        How do we work with Commands in Fiware? I tried /cmd and /cmdexe topics but it did not work. Kindly give steps and example if possible.

        2. Now, my data coming from Device is Base64 encrypted (example given below). If I send the same directly to "/attrs" topic it is not updating attributes values due to encryption. I may add extra layer for decryption and then publish it on "/attrs" topic which would update ehe values in context broker. Is it the right approach? Does Fiware supports Encryption (Mainly Base64)?

        Example:

        Plain Text: Payload:

        {"command": "ON_OFF","switchInternalId":"S01", "action":"ON",,"requestId":"123"}

        Encrypted Message:

        On/Off Message:

        { "messageId": "onoffmsgId", "deviceId": "device-id", "commandId": " ON_OFF ", "encodingType": "Base64", "message":"ew0KCSJjb21tYW5kIjogIkVPTyIsDQoJInN3aXRjaEludGVybmFsSWQiOiAiUzAwMDAwMyIsDQoJIMTCIsDQoJInJlcXVlc3RJZCI6ICJFT09fdGVtcFJlcUlkIg0KfQ=" }

        Appreciate your help.

        Thanks & Regards,
        Krishan Babbar
        ============================================================================================================================

        Disclaimer: This message and the information contained herein is proprietary and confidential and subject to the Tech Mahindra policy statement, you may review the policy at http://www.techmahindra.com/Disclaimer.html <http://www.techmahindra.com/Disclaimer.html> externally http://tim.techmahindra.com/tim/disclaimer.html <http://tim.techmahindra.com/tim/disclaimer.html> internally within TechMahindra.

        ============================================================================================================================

        __________________________________________________________________________________________

        You can get more information about our cookies and privacy policies on the following links:

        Fiware-tech-help mailing list
        Fiware-tech-help@lists.fiware.org
        https://lists.fiware.org/listinfo/fiware-tech-help

        [Created via e-mail received from: Krishan Babbar <KB00449283@TechMahindra.com>]

        FIWARE Chapter:
        FIWARE GEri:

        Status: Open

        ---------------------
        This email was generated by FIWARE JIRA following an email received into the Main Help Desk.

        Show
        josegato Jose Gato Luis added a comment - The issue has been emailed: Time sent: 24/Apr/18 8:17 AM To: fernando.mendez.external@atos.net with subject: *( HELP-13889 ) [Fiware-tech-help] Query - Commands and Encryption in Fiware * From FIWARE JIRA - Main Help Desk ---- ------------------------------------------------------------------------------- Comments: ------------------------ Issue id: HELP-13889 Description: Hi All, I am working on Smart Light App and using following Fiware GEs Orion Context Broker Iotagent-json Mosquito I am able to send events/data on "/<service>/<deviceId>/attrs" topic which updates the context broker and one can subscribe to the same. Now I have below queries. 1. Above case is for Events, means Device/Sensor sending data and it updates the same in Context Broker. I need to do other way also, means sending commands from some applications (say web application) towards Device and status of Device gets changed. How do we work with Commands in Fiware? I tried /cmd and /cmdexe topics but it did not work. Kindly give steps and example if possible. 2. Now, my data coming from Device is Base64 encrypted (example given below). If I send the same directly to "/attrs" topic it is not updating attributes values due to encryption. I may add extra layer for decryption and then publish it on "/attrs" topic which would update ehe values in context broker. Is it the right approach? Does Fiware supports Encryption (Mainly Base64)? Example: Plain Text: Payload: {"command": "ON_OFF","switchInternalId":"S01", "action":"ON",,"requestId":"123"} Encrypted Message: On/Off Message: { "messageId": "onoffmsgId", "deviceId": "device-id", "commandId": " ON_OFF ", "encodingType": "Base64", "message":"ew0KCSJjb21tYW5kIjogIkVPTyIsDQoJInN3aXRjaEludGVybmFsSWQiOiAiUzAwMDAwMyIsDQoJIMTCIsDQoJInJlcXVlc3RJZCI6ICJFT09fdGVtcFJlcUlkIg0KfQ=" } Appreciate your help. Thanks & Regards, Krishan Babbar ============================================================================================================================ Disclaimer: This message and the information contained herein is proprietary and confidential and subject to the Tech Mahindra policy statement, you may review the policy at http://www.techmahindra.com/Disclaimer.html < http://www.techmahindra.com/Disclaimer.html > externally http://tim.techmahindra.com/tim/disclaimer.html < http://tim.techmahindra.com/tim/disclaimer.html > internally within TechMahindra. ============================================================================================================================ __________________________________________________________________________________________ You can get more information about our cookies and privacy policies on the following links: http://forge.fiware.org/plugins/mediawiki/wiki/fiware/index.php/FIWARE_Privacy_Policy http://forge.fiware.org/plugins/mediawiki/wiki/fiware/index.php/Cookies_Policy_FIWARE Fiware-tech-help mailing list Fiware-tech-help@lists.fiware.org https://lists.fiware.org/listinfo/fiware-tech-help [Created via e-mail received from: Krishan Babbar <KB00449283@TechMahindra.com>] FIWARE Chapter: FIWARE GEri: Status: Open --------------------- This email was generated by FIWARE JIRA following an email received into the Main Help Desk.
        Hide
        josegato Jose Gato Luis added a comment -

        Some respones were provided, but no answer by the user if solved.

        Show
        josegato Jose Gato Luis added a comment - Some respones were provided, but no answer by the user if solved.

          People

          • Assignee:
            josegato Jose Gato Luis
            Reporter:
            fw.ext.user FW External User
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: