<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">Recently I have found, and fixed, a number of bugs in the DECnet for Linux kernel module. Some of</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">these bugs may be relevant for members of this mailing list who are using DECnet for Linux,</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">especially on a Raspberry Pi.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">Major bugs fixed:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Ethernet Listen Timer was not implemented</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>In addition, the check for an address change for the designated router (DR) was missing</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>although there was a check if the DR’s priority had changed.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span>Note: this code changes the format of /proc/net/decnet_dev to include the listen timer value.</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">   </span>          nml/nml2 needs to be rebuilt to understand the changed format.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- System panic when using the loopback device (lo)</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">   </span>The DECnet code was missing a destructor routine which is used to avoid data copying.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- The neighbour (adjacent node) code could be broken by kernel changes</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">   </span>The code made use of a now deprecated feature (zero length array at the end of a structure)</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">     </span>in order to access data in a surrounding structure. This happened to work “by chance”</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span>until kernel 5.4.42 on 32-bit processors.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Interrupt message flow control was broken</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>The flow control was a mixture of using the SEND/DONTSEND status of the data</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>subchannel and a message count. This seems to work between Linux systems but is broken</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>when communicating with other systems - during the life of a logical link, the remote system</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>could only send a single interrupt message while the Linux system could pretty much send</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">        </span>as many interrupts as it wanted possibly overrunning the remote systems buffers.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Optional data on received connect confirm message was corrupted</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">     </span>The code was getting the optional data from the wrong offset in the message.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Next hop cache problem</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>30 seconds after a logical link was taken down, the next hop cache entry was deleted. As</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">        </span>part of this deletion, the link was taken “down” which caused a neighbour entry to be</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span>created for the same node address but accessed via the loopback device. Sometimes this</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>would cause the designated router to become accessible via the loopback device and</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">      </span>subsequent connections would fail.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Intra-ethernet bit ignored</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">        </span>The intra-ethernet bit in the routing flags is ignored on inbound traffic. If there was a neighbour</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">     </span>entry for the remote node at connection time, everything would work correctly. If there wad no</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>entry, all outbound  traffic would be sent through the designated router for the duration of</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span>the logical link.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">- Promiscuous mode alters DECnet behaviour</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">   </span>If the ethernet NIC used for DECnet had promiscuous mode enabled (e.g. using tcpdump</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>for traffic tracing), the DECnet code would start seeing endnode hello’s, populating</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">  </span>neighbour structures and causing the problems described above for the intra-ethernet bit</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">        </span>to go away.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">New programs:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">DECnet Test Send and DECnet Test Receiver (DTS/DTR)</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>Test programs created via reverse engineering the protocol exchanges. Used to find a</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>number of the bugs described above.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">NML2</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span>New implementation of the Network Management Listener. Supports SUMMARY, STATUS</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>and CHARACTERISTICS for NODES, CIRCUITS and AREAS. It does not support LINKS</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>and OBJECTS which were in the old version but are system specific operations which</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">      </span>were only visible from DECnet-VMS systems.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">   </span>The old version is still the default during installation. The new version can be installed by:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">               </span>cd dnprogs/nml2</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">         </span>make</div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">            </span>sudo make install</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">    </span>which will overwrite the installed executable and man page.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class="">OS Support:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">        </span>As of 06/29/2020 the code has been tested with:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">              </span>Raspbian 2020-05-27 release with kernels 4.19.126 and 5.4.44 (32-bit only)</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">           </span>Pi OS 2020-05-27 32-bit release with kernel 4.19.126 and 5.4.44</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span class="Apple-tab-span" style="white-space:pre">              </span>pI OS 2020-05-27 (fully updated on 06/26/2020) with kernel 5.4.49</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class="">The source code and installation instructions are available at:</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><span class="Apple-tab-span" style="white-space:pre">       </span><<a href="https://github.com/JohnForecast/RaspbianDECnet" class="">https://github.com/JohnForecast/RaspbianDECnet</a>></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class="">  John.</div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 14px;" class=""><br class=""></div></body></html>