Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Troubleshooting
  3. Software signing suddenly stop working

Software signing suddenly stop working

Scheduled Pinned Locked Moved Troubleshooting
28 Posts 3 Posters 4.8k Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • brendanlB Offline
    brendanlB Offline
    brendanl
    wrote on last edited by
    #3

    @sineverba said in Software signing suddenly stop working:

    MY_SIGNING_REQUEST_SIG

    Interestingly I'm working through a very similar issue myself just now. The garage door opener just stopped working a few days ago.

    I've pulled the Pro Mini out and onto a breadboard and have been doing the following this evening:

    • Updated it to 2.1.1 from 2.0.0 beta (no improvements)
    • Re applied the Security Personalizer / soft HMAC Key with the 2.1.1 core (no difference, nor was I expecting that)
    • Added #define MY_DEBUG_VERBOSE_SIGNING
    • Added #define MY_SIGNING_SOFT_RANDOMSEED_PIN A0 (I never had this line, but it made no difference)
    • Added a capacitor across the NRF24 (no difference)
    • Added additional debug statements to MyTransport.cpp but haven't discovered anything yet.
    • Disabled MY_SIGNING_SOFT (immediately fixes it, but I don't want that)

    My experience is that the messages either never get received (no trace output) or the output ends at "Transmitted nonce". Randomly, it will work.

    It used to work just fine and I'm reluctant to drop the signing. So I'm definitely interested in how you get along and I'll update too if I get my end sorted.

    Cheers

    S 1 Reply Last reply
    0
    • brendanlB brendanl

      @sineverba said in Software signing suddenly stop working:

      MY_SIGNING_REQUEST_SIG

      Interestingly I'm working through a very similar issue myself just now. The garage door opener just stopped working a few days ago.

      I've pulled the Pro Mini out and onto a breadboard and have been doing the following this evening:

      • Updated it to 2.1.1 from 2.0.0 beta (no improvements)
      • Re applied the Security Personalizer / soft HMAC Key with the 2.1.1 core (no difference, nor was I expecting that)
      • Added #define MY_DEBUG_VERBOSE_SIGNING
      • Added #define MY_SIGNING_SOFT_RANDOMSEED_PIN A0 (I never had this line, but it made no difference)
      • Added a capacitor across the NRF24 (no difference)
      • Added additional debug statements to MyTransport.cpp but haven't discovered anything yet.
      • Disabled MY_SIGNING_SOFT (immediately fixes it, but I don't want that)

      My experience is that the messages either never get received (no trace output) or the output ends at "Transmitted nonce". Randomly, it will work.

      It used to work just fine and I'm reluctant to drop the signing. So I'm definitely interested in how you get along and I'll update too if I get my end sorted.

      Cheers

      S Offline
      S Offline
      sineverba
      Hardware Contributor
      wrote on last edited by
      #4

      @brendanl as PHP developer, It is INCREDIBLE that a perfect working software, WITHOUT updates, suddenly crash. But It is. For now, I did disable the signing. Do you have inserted other nodes in the network? Changed some radio? I don know whats the failure. I did redownload library from github and tonight I Will reinstallare. I Will update the thread ASAP.

      1 Reply Last reply
      0
      • AnticimexA Offline
        AnticimexA Offline
        Anticimex
        Contest Winner
        wrote on last edited by
        #5

        Signing has an absolute requirement that the radio link works flawlessly. It will trow away or fail messages if any part of the exchange fails to reach the destination. So if you get any NACKs in the log, then those NACKs have to be resolved before signing can be expected to work.

        S 1 Reply Last reply
        1
        • AnticimexA Anticimex

          Signing has an absolute requirement that the radio link works flawlessly. It will trow away or fail messages if any part of the exchange fails to reach the destination. So if you get any NACKs in the log, then those NACKs have to be resolved before signing can be expected to work.

          S Offline
          S Offline
          sineverba
          Hardware Contributor
          wrote on last edited by
          #6

          @Anticimex I did see Your similar answer on another thread. I am in accord with you, but my / our nodes was working flawless from month.... I Will try also swapping radios, maybe a power failure that has broken them? But no Power failure in about 6 month in my home....

          AnticimexA 1 Reply Last reply
          0
          • S sineverba

            @Anticimex I did see Your similar answer on another thread. I am in accord with you, but my / our nodes was working flawless from month.... I Will try also swapping radios, maybe a power failure that has broken them? But no Power failure in about 6 month in my home....

            AnticimexA Offline
            AnticimexA Offline
            Anticimex
            Contest Winner
            wrote on last edited by
            #7

            @sineverba The log will show if your messages come through or not (you need them from both the node and the GW to verify that). It can be a power issue, or a noise issue, or a neighbour buying some radio equipment that disturb your comms, or birds just crossing at a bad time. Hard to say, but I am inclined to blame RF for this problem and not signing (for this very reason).
            And as I have said, in many threads (and also in the documentation) the fact that it "works without signing" does not automatically mean signing is not working. It is normally just because with signing enabled, the RF link is put on stress due to the messages being much bigger.

            S 1 Reply Last reply
            1
            • AnticimexA Anticimex

              @sineverba The log will show if your messages come through or not (you need them from both the node and the GW to verify that). It can be a power issue, or a noise issue, or a neighbour buying some radio equipment that disturb your comms, or birds just crossing at a bad time. Hard to say, but I am inclined to blame RF for this problem and not signing (for this very reason).
              And as I have said, in many threads (and also in the documentation) the fact that it "works without signing" does not automatically mean signing is not working. It is normally just because with signing enabled, the RF link is put on stress due to the messages being much bigger.

              S Offline
              S Offline
              sineverba
              Hardware Contributor
              wrote on last edited by
              #8

              @Anticimex ok, I Will investigate more and more.

              Question: if I leave the Heather without signing, or a generic relay, someone "malicious" how could "play" with my relay? Need to have a portable controller and gateway and sniff when I poweron or poweroff the relay itself tto have the node in his controller?

              AnticimexA 1 Reply Last reply
              0
              • S sineverba

                @Anticimex ok, I Will investigate more and more.

                Question: if I leave the Heather without signing, or a generic relay, someone "malicious" how could "play" with my relay? Need to have a portable controller and gateway and sniff when I poweron or poweroff the relay itself tto have the node in his controller?

                AnticimexA Offline
                AnticimexA Offline
                Anticimex
                Contest Winner
                wrote on last edited by
                #9

                @sineverba With enough knowledge, only a gateway is needed. You can just use a terminal to send commands to the gateway. If your node ID is known and your radio address, then anyone could just send commands to it. They will need to know what command your node reacts to, but that can be obtained from sniffing the traffic (assuming you don't encrypt your communications).

                S 1 Reply Last reply
                0
                • AnticimexA Anticimex

                  @sineverba With enough knowledge, only a gateway is needed. You can just use a terminal to send commands to the gateway. If your node ID is known and your radio address, then anyone could just send commands to it. They will need to know what command your node reacts to, but that can be obtained from sniffing the traffic (assuming you don't encrypt your communications).

                  S Offline
                  S Offline
                  sineverba
                  Hardware Contributor
                  wrote on last edited by
                  #10

                  @Anticimex If i live at 4th floor of a Palace and the family at 3rd use MySensor, on same Channel also (!), Is there the possibility that their Heather commands could be read and interpretated from mine ? (Or viceversa).... Thank you!

                  AnticimexA 1 Reply Last reply
                  0
                  • S sineverba

                    @Anticimex If i live at 4th floor of a Palace and the family at 3rd use MySensor, on same Channel also (!), Is there the possibility that their Heather commands could be read and interpretated from mine ? (Or viceversa).... Thank you!

                    AnticimexA Offline
                    AnticimexA Offline
                    Anticimex
                    Contest Winner
                    wrote on last edited by
                    #11

                    @sineverba That is up to you and how you validate the sender of the messages you receive and accept in your node. If you accept everything, then you accept everything ;)

                    S 1 Reply Last reply
                    0
                    • AnticimexA Anticimex

                      @sineverba That is up to you and how you validate the sender of the messages you receive and accept in your node. If you accept everything, then you accept everything ;)

                      S Offline
                      S Offline
                      sineverba
                      Hardware Contributor
                      wrote on last edited by
                      #12

                      @Anticimex so, we return to the whitelisting :-( ...

                      AnticimexA 1 Reply Last reply
                      0
                      • S sineverba

                        @Anticimex so, we return to the whitelisting :-( ...

                        AnticimexA Offline
                        AnticimexA Offline
                        Anticimex
                        Contest Winner
                        wrote on last edited by
                        #13

                        @sineverba Not necessarily. You can validate that the message is from "some gateway", and that it is specifically of the type you accept.
                        You can also enable encryption.

                        But essentially, if you want "security" you need signing. That is kind of the point of that feature ;)

                        S 1 Reply Last reply
                        0
                        • AnticimexA Anticimex

                          @sineverba Not necessarily. You can validate that the message is from "some gateway", and that it is specifically of the type you accept.
                          You can also enable encryption.

                          But essentially, if you want "security" you need signing. That is kind of the point of that feature ;)

                          S Offline
                          S Offline
                          sineverba
                          Hardware Contributor
                          wrote on last edited by sineverba
                          #14

                          @Anticimex
                          I'm re-studying the API and specifically the signature / signing section.

                          I did not understand something. I don't want open a new thread, ask here. If necessary, I will open a new one.

                          My questions (and thank you in advance for your time and time for all readers!)

                          From this page: https://www.mysensors.org/apidocs-beta/group__SigningSettingGrpPub.html#gaf75e26bdb90edd1230100ef160786e78

                          1. MY_SIGNING_REQUEST_SIGNATURES
                            It says "If used for a gateway, gateway will by default require signatures from ALL nodes[...]".
                            I did enable this on the gateway (Arduino UNO).
                            Q: In my network I have 2 nodes that transmit temp, hum and battery (atmega328). No signing at all in the sketch(es). Why they works without the SIGNING?

                          2. MY_SIGNING_NODE_WHITELISTING
                            I do not understand the explain. In effect, in my relay node (the only one of 3 nodes that did have the signing software enabled) I did have also:

                          #define MY_SIGNING_SOFT
                          #define MY_SIGNING_SOFT_RANDOMSEED_PIN 7
                          //#define MY_SIGNING_REQUEST_SIGNATURES
                          #define MY_SIGNING_NODE_WHITELISTING {{.nodeId = GATEWAY_ADDRESS,.serial = {0x3B,0xF4,0xF4,0xDF,0x1E,0x97,0xB1,0x2D,0xEC}}}
                          

                          What's a verifyng node cited on the explain? Another one node of my network is acting as a bridge beetween both?

                          1. You did mention that I could sniff the address of trasmitting (of the gateway). I did not find nothing on the library... Could you help me to perform this "sniff"? This is my receive function atm:
                          /**
                           * Receive function from gateway
                           * 
                           * @since 1.0
                           */
                          void receive(const MyMessage &message) {
                          
                            if ( !message.isAck() ) {
                          
                              if ( message.type == V_STATUS) {
                            
                                if (  message.getCommand() == 1 ) {
                            
                                  bool received_state = message.getBool();
                                  Serial.print("We did receive a new value. Received_state value is ");
                                  Serial.println(received_state);
                            
                                  if ( received_state == 1) {
                            
                                    digitalWrite(PIN_RELAY , RELAY_ON);
                                    
                                  } else {
                            
                                    digitalWrite(PIN_RELAY , RELAY_OFF);
                                    
                                  }
                                  
                                }
                                
                              }
                          
                            }
                          
                          }
                          
                          AnticimexA 2 Replies Last reply
                          0
                          • S sineverba

                            @Anticimex
                            I'm re-studying the API and specifically the signature / signing section.

                            I did not understand something. I don't want open a new thread, ask here. If necessary, I will open a new one.

                            My questions (and thank you in advance for your time and time for all readers!)

                            From this page: https://www.mysensors.org/apidocs-beta/group__SigningSettingGrpPub.html#gaf75e26bdb90edd1230100ef160786e78

                            1. MY_SIGNING_REQUEST_SIGNATURES
                              It says "If used for a gateway, gateway will by default require signatures from ALL nodes[...]".
                              I did enable this on the gateway (Arduino UNO).
                              Q: In my network I have 2 nodes that transmit temp, hum and battery (atmega328). No signing at all in the sketch(es). Why they works without the SIGNING?

                            2. MY_SIGNING_NODE_WHITELISTING
                              I do not understand the explain. In effect, in my relay node (the only one of 3 nodes that did have the signing software enabled) I did have also:

                            #define MY_SIGNING_SOFT
                            #define MY_SIGNING_SOFT_RANDOMSEED_PIN 7
                            //#define MY_SIGNING_REQUEST_SIGNATURES
                            #define MY_SIGNING_NODE_WHITELISTING {{.nodeId = GATEWAY_ADDRESS,.serial = {0x3B,0xF4,0xF4,0xDF,0x1E,0x97,0xB1,0x2D,0xEC}}}
                            

                            What's a verifyng node cited on the explain? Another one node of my network is acting as a bridge beetween both?

                            1. You did mention that I could sniff the address of trasmitting (of the gateway). I did not find nothing on the library... Could you help me to perform this "sniff"? This is my receive function atm:
                            /**
                             * Receive function from gateway
                             * 
                             * @since 1.0
                             */
                            void receive(const MyMessage &message) {
                            
                              if ( !message.isAck() ) {
                            
                                if ( message.type == V_STATUS) {
                              
                                  if (  message.getCommand() == 1 ) {
                              
                                    bool received_state = message.getBool();
                                    Serial.print("We did receive a new value. Received_state value is ");
                                    Serial.println(received_state);
                              
                                    if ( received_state == 1) {
                              
                                      digitalWrite(PIN_RELAY , RELAY_ON);
                                      
                                    } else {
                              
                                      digitalWrite(PIN_RELAY , RELAY_OFF);
                                      
                                    }
                                    
                                  }
                                  
                                }
                            
                              }
                            
                            }
                            
                            AnticimexA Offline
                            AnticimexA Offline
                            Anticimex
                            Contest Winner
                            wrote on last edited by
                            #15

                            @sineverba

                            1. I am not sure. I assume you run the 2.2.0-rc.1 version on all nodes and gw? The documentation you read is for that branch (development branch).

                            2. The verifying node is the node that verifies the signatures. That is, the node that require signatures. It can be both ends if both require signatures (node and GW)

                            3. No, I meant "someone" could sniff. The library itself does not offer sniffing APIs.

                            S 1 Reply Last reply
                            0
                            • S sineverba

                              @Anticimex
                              I'm re-studying the API and specifically the signature / signing section.

                              I did not understand something. I don't want open a new thread, ask here. If necessary, I will open a new one.

                              My questions (and thank you in advance for your time and time for all readers!)

                              From this page: https://www.mysensors.org/apidocs-beta/group__SigningSettingGrpPub.html#gaf75e26bdb90edd1230100ef160786e78

                              1. MY_SIGNING_REQUEST_SIGNATURES
                                It says "If used for a gateway, gateway will by default require signatures from ALL nodes[...]".
                                I did enable this on the gateway (Arduino UNO).
                                Q: In my network I have 2 nodes that transmit temp, hum and battery (atmega328). No signing at all in the sketch(es). Why they works without the SIGNING?

                              2. MY_SIGNING_NODE_WHITELISTING
                                I do not understand the explain. In effect, in my relay node (the only one of 3 nodes that did have the signing software enabled) I did have also:

                              #define MY_SIGNING_SOFT
                              #define MY_SIGNING_SOFT_RANDOMSEED_PIN 7
                              //#define MY_SIGNING_REQUEST_SIGNATURES
                              #define MY_SIGNING_NODE_WHITELISTING {{.nodeId = GATEWAY_ADDRESS,.serial = {0x3B,0xF4,0xF4,0xDF,0x1E,0x97,0xB1,0x2D,0xEC}}}
                              

                              What's a verifyng node cited on the explain? Another one node of my network is acting as a bridge beetween both?

                              1. You did mention that I could sniff the address of trasmitting (of the gateway). I did not find nothing on the library... Could you help me to perform this "sniff"? This is my receive function atm:
                              /**
                               * Receive function from gateway
                               * 
                               * @since 1.0
                               */
                              void receive(const MyMessage &message) {
                              
                                if ( !message.isAck() ) {
                              
                                  if ( message.type == V_STATUS) {
                                
                                    if (  message.getCommand() == 1 ) {
                                
                                      bool received_state = message.getBool();
                                      Serial.print("We did receive a new value. Received_state value is ");
                                      Serial.println(received_state);
                                
                                      if ( received_state == 1) {
                                
                                        digitalWrite(PIN_RELAY , RELAY_ON);
                                        
                                      } else {
                                
                                        digitalWrite(PIN_RELAY , RELAY_OFF);
                                        
                                      }
                                      
                                    }
                                    
                                  }
                              
                                }
                              
                              }
                              
                              AnticimexA Offline
                              AnticimexA Offline
                              Anticimex
                              Contest Winner
                              wrote on last edited by
                              #16

                              @sineverba actually, reading your first post, it would appear that you run the official release (2.1.1). The signing requirements work differently there, and the documentation is also different as you can see here: https://www.mysensors.org/apidocs/index.html as opposed to here: https://www.mysensors.org/apidocs-beta/index.html

                              1 Reply Last reply
                              0
                              • AnticimexA Anticimex

                                @sineverba

                                1. I am not sure. I assume you run the 2.2.0-rc.1 version on all nodes and gw? The documentation you read is for that branch (development branch).

                                2. The verifying node is the node that verifies the signatures. That is, the node that require signatures. It can be both ends if both require signatures (node and GW)

                                3. No, I meant "someone" could sniff. The library itself does not offer sniffing APIs.

                                S Offline
                                S Offline
                                sineverba
                                Hardware Contributor
                                wrote on last edited by
                                #17

                                @Anticimex No, I'm running the 2.1.1 on all nodes and gw.

                                In this moment I did re-enable the signature and signing software section on the gateway (but not in nodes, no nodes have signing enabled). All works. I can confirm.

                                For the 2 (whitelisting) I did enable only on the node that require signature, i.e. the relay node. Not in gw, not in no others nodes.

                                For the 3, maybe I was not clear. I did mean if I did have the possibility, on receive function, as following pseudo code:

                                if (message.getSenderSerial() == 0X01,0XAA, 0XBB) {
                                
                                    Serial.println("We did receive this message from our gateway... we can proceed");
                                   
                                }
                                
                                AnticimexA 2 Replies Last reply
                                0
                                • S sineverba

                                  @Anticimex No, I'm running the 2.1.1 on all nodes and gw.

                                  In this moment I did re-enable the signature and signing software section on the gateway (but not in nodes, no nodes have signing enabled). All works. I can confirm.

                                  For the 2 (whitelisting) I did enable only on the node that require signature, i.e. the relay node. Not in gw, not in no others nodes.

                                  For the 3, maybe I was not clear. I did mean if I did have the possibility, on receive function, as following pseudo code:

                                  if (message.getSenderSerial() == 0X01,0XAA, 0XBB) {
                                  
                                      Serial.println("We did receive this message from our gateway... we can proceed");
                                     
                                  }
                                  
                                  AnticimexA Offline
                                  AnticimexA Offline
                                  Anticimex
                                  Contest Winner
                                  wrote on last edited by
                                  #18
                                  This post is deleted!
                                  1 Reply Last reply
                                  0
                                  • S sineverba

                                    @Anticimex No, I'm running the 2.1.1 on all nodes and gw.

                                    In this moment I did re-enable the signature and signing software section on the gateway (but not in nodes, no nodes have signing enabled). All works. I can confirm.

                                    For the 2 (whitelisting) I did enable only on the node that require signature, i.e. the relay node. Not in gw, not in no others nodes.

                                    For the 3, maybe I was not clear. I did mean if I did have the possibility, on receive function, as following pseudo code:

                                    if (message.getSenderSerial() == 0X01,0XAA, 0XBB) {
                                    
                                        Serial.println("We did receive this message from our gateway... we can proceed");
                                       
                                    }
                                    
                                    AnticimexA Offline
                                    AnticimexA Offline
                                    Anticimex
                                    Contest Winner
                                    wrote on last edited by
                                    #19

                                    @sineverba your config seem correct.

                                    1 Reply Last reply
                                    0
                                    • S Offline
                                      S Offline
                                      sineverba
                                      Hardware Contributor
                                      wrote on last edited by sineverba
                                      #20

                                      A small update.
                                      1 - I did delete the library and re-downloaded from Github
                                      2 - I did clear the EEPROM of gateway
                                      3 - I did clear the EEPROM of a new Atmega328 (for relay / actuactor)
                                      4 - I did reinstall the Gateway sketch and the sketch for the relay heater, with signing.

                                      ..... it works......

                                      Yes, too many changes all together..... And fortunately I did receive today the PCBs for it, so in next days I will solder it on a firm base and not on breadboard.....

                                      After 30 min, no working anymore...... :( :( Fake alarm.... maybe some trouble with breadboard, maybe oxyde.... I will test in some day on PCB.

                                      AnticimexA 1 Reply Last reply
                                      0
                                      • S sineverba

                                        A small update.
                                        1 - I did delete the library and re-downloaded from Github
                                        2 - I did clear the EEPROM of gateway
                                        3 - I did clear the EEPROM of a new Atmega328 (for relay / actuactor)
                                        4 - I did reinstall the Gateway sketch and the sketch for the relay heater, with signing.

                                        ..... it works......

                                        Yes, too many changes all together..... And fortunately I did receive today the PCBs for it, so in next days I will solder it on a firm base and not on breadboard.....

                                        After 30 min, no working anymore...... :( :( Fake alarm.... maybe some trouble with breadboard, maybe oxyde.... I will test in some day on PCB.

                                        AnticimexA Offline
                                        AnticimexA Offline
                                        Anticimex
                                        Contest Winner
                                        wrote on last edited by
                                        #21

                                        @sineverba uhm, if you cleared the eeprom, you have erased your personalization data. So now you run without a signing key. So your signatures are worthless.
                                        You also still run 2.1.1 because that would not work on 2.2.0,iy has checks for such things.
                                        You will need to redo personalization if you erase the eeprom.

                                        S 1 Reply Last reply
                                        0
                                        • AnticimexA Anticimex

                                          @sineverba uhm, if you cleared the eeprom, you have erased your personalization data. So now you run without a signing key. So your signatures are worthless.
                                          You also still run 2.1.1 because that would not work on 2.2.0,iy has checks for such things.
                                          You will need to redo personalization if you erase the eeprom.

                                          S Offline
                                          S Offline
                                          sineverba
                                          Hardware Contributor
                                          wrote on last edited by
                                          #22

                                          @Anticimex I did forget a step. I did reinstall the personalization also, but after 20/30 mins, all stop works.

                                          I could try also the 2.2.0rc. Do I need every node and gw on same release or can I mix nodes and gw between 2.1.1 and 2.2.0 ?

                                          AnticimexA 1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          28

                                          Online

                                          11.7k

                                          Users

                                          11.2k

                                          Topics

                                          113.1k

                                          Posts


                                          Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • MySensors
                                          • OpenHardware.io
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular