* Netromd ssid-0 broadcasts being ignored
@ 2015-05-15 8:14 Paul Lewis
2015-05-16 15:50 ` David Ranch
2015-05-17 20:04 ` Richard Stearn
0 siblings, 2 replies; 5+ messages in thread
From: Paul Lewis @ 2015-05-15 8:14 UTC (permalink / raw)
To: linux-hams
Hi All
Since I moved to the latest netromd code in 2013-2015
I have notice that there have been changes to the ssid-0 of
nodes.
Examples
1) issuing a C GB7BA fails. GB7BA-0 works
C GB7CIP fails GB7CIP-0 works
Never us to behave this way on my old Slackware system (1994-2014)
2) Setting a locked Route
nrparms -routes axu1 MB7NUQ-0 + 70
nrparms -routes axu1 G3LDI-0 + 75
the node broadcast received from MB7NUQ-0
gets ignored
Callsign Device Packets Date & Time Frame Type(s)
--------- ------ -------- --------------- -------------
MB7NUQ axu1 17593 May 15 08:47:54 NetRom
G3LDI axu1 691 May 13 11:04:48 NetRom
Just a couple of examples
Have tested with the ax25 app/tools/ax25 0.0.# and 1.0.# series of
code.
Binaries complied from source code.
I find this very frustrating when setting up static routing tables in
the past 14 months, after my updated system went live.
Is their a patch that can be applied to get the code to behave as it use
to.
Why was it changed??
73 de Paul G4APL (GB7CIP/MB7NCR)
--
paul@skywaves.demon.co.uk
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: Netromd ssid-0 broadcasts being ignored 2015-05-15 8:14 Netromd ssid-0 broadcasts being ignored Paul Lewis @ 2015-05-16 15:50 ` David Ranch 2015-05-16 19:46 ` Richard Stearn 2015-05-17 20:04 ` Richard Stearn 1 sibling, 1 reply; 5+ messages in thread From: David Ranch @ 2015-05-16 15:50 UTC (permalink / raw) To: linux-hams Hello Paul, Are you using the CVS version of the "Official AX.25" sources? If so, this is a known issue and why VE7FET put together his repo with help from Bernard F6BVP. Read this URL to understand some of the key differences: https://code.google.com/p/linuxax25/ -- In the linux-ax25.org source, the ax25_ntoa function in axutils.c was changed so that it mangles callsigns. Specifically, if the callsign has a SSID of -0, it strips it. . . . NOTE: It appears (as of Nov 2014), that this bad behaviour of the Official Source may have been reverted. Patches have been noted in the Official Source that seem to get rid of stripping the SSID-0 -- Check out https://code.google.com/p/linuxax25/w/list to understand some of the other current differences between the two repos. I personally have been running the VE7FET version of AX25 app/lib/tools with good luck. --David KI6ZHD ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Netromd ssid-0 broadcasts being ignored 2015-05-16 15:50 ` David Ranch @ 2015-05-16 19:46 ` Richard Stearn 0 siblings, 0 replies; 5+ messages in thread From: Richard Stearn @ 2015-05-16 19:46 UTC (permalink / raw) To: Linux Hams Hi David Whilst I have a working test environment I had a look at this with the following results: ax25-apps ax25-tools libax25 node 0.0.6 0.0.8 0.0.11 0.3.3 works 0.0.8-rc4 0.0.10-rc4 0.0.12-rc4 0.3.3 does not work 1.0.5 1.0.3 1.0.5 0.3.3 does not work ("works"/"does not work" is in terms of Paul's original issue) A look at this site https://code.google.com/p/linuxax25/w/list indicates that libax25 code is identical between 0.0.12-rc4 and 1.0.5, the difference being the directory tree layout. -- Regards Richard ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Netromd ssid-0 broadcasts being ignored 2015-05-15 8:14 Netromd ssid-0 broadcasts being ignored Paul Lewis 2015-05-16 15:50 ` David Ranch @ 2015-05-17 20:04 ` Richard Stearn 2015-05-17 20:34 ` Paul Lewis 1 sibling, 1 reply; 5+ messages in thread From: Richard Stearn @ 2015-05-17 20:04 UTC (permalink / raw) To: linux-hams Paul Lewis did scribe: > > Hi All > > Since I moved to the latest netromd code in 2013-2015 > I have notice that there have been changes to the ssid-0 of > nodes. > > Examples > > 1) issuing a C GB7BA fails. GB7BA-0 works > C GB7CIP fails GB7CIP-0 works > Hi Paul Try this patch against libax25-1.0.5, it is my attempt a reverting the "strip -0" change in recent versions of libax25 : ---------------------------------------------------------------------------- diff -ru reference/libax25-1.0.5/lib/ax25/axconfig.c modified/libax25-1.0.5/lib/ax25/axconfig.c --- reference/libax25-1.0.5/lib/ax25/axconfig.c 2014-11-07 17:41:26.000000000 +0000 +++ modified/libax25-1.0.5/lib/ax25/axconfig.c 2015-05-16 19:03:27.000000000 +0100 @@ -238,8 +238,8 @@ strupr(call); found = 0; char *cp; - if ((cp = strstr(call, "-0")) != NULL) - *cp = '\0'; + + for (;ifcalls && *ifcalls; ++ifcalls, ++ifdevs) { if (strcmp(call, *ifcalls) == 0) { found = 1; diff -ru reference/libax25-1.0.5/lib/ax25/axutils.c modified/libax25-1.0.5/lib/ax25/axutils.c --- reference/libax25-1.0.5/lib/ax25/axutils.c 2014-11-07 17:41:26.000000000 +0000 +++ modified/libax25-1.0.5/lib/ax25/axutils.c 2015-05-15 17:22:35.000000000 +0100 @@ -199,17 +199,14 @@ *s++ = c; } - /* Convention is: -0 suffixes are NOT printed */ - if (a->ax25_call[6] & 0x1E) { - *s++ = '-'; - - if ((n = ((a->ax25_call[6] >> 1) & 0x0F)) > 9) { - *s++ = '1'; - n -= 10; - } - *s++ = n + '0'; - } + *s++ = '-'; + if ((n = ((a->ax25_call[6] >> 1) & 0x0F)) > 9) { + *s++ = '1'; + n -= 10; + } + + *s++ = n + '0'; *s++ = '\0'; return buf; diff -ru reference/libax25-1.0.5/lib/ax25/nrconfig.c modified/libax25-1.0.5/lib/ax25/nrconfig.c --- reference/libax25-1.0.5/lib/ax25/nrconfig.c 2014-11-07 17:41:26.000000000 +0000 +++ modified/libax25-1.0.5/lib/ax25/nrconfig.c 2015-05-16 19:03:45.000000000 +0100 @@ -216,8 +216,8 @@ strupr(alias); char *cp; - if ((cp = strstr(call, "-0")) != NULL) - *cp = 0; + + found = 0; for (;ifcalls && *ifcalls; ++ifcalls, ++ifdevs) { diff -ru reference/libax25-1.0.5/lib/ax25/procutils.c modified/libax25-1.0.5/lib/ax25/procutils.c --- reference/libax25-1.0.5/lib/ax25/procutils.c 2014-11-07 17:41:26.000000000 +0000 +++ modified/libax25-1.0.5/lib/ax25/procutils.c 2015-05-16 19:58:44.000000000 +0100 @@ -70,6 +70,15 @@ return buf; } +static char *strip_zero_ssid(char *call) +{ + char *cp; + + if ((cp = strstr(call, "-0")) != NULL) + *cp = 0; + return call; +} + struct proc_ax25 *read_proc_ax25(void) { FILE *fp; @@ -336,6 +345,8 @@ cp = buffer; safe_strncpy(new->call, token(&cp, space), 9); + strip_zero_ssid(new->call); + safe_strncpy(new->alias, token(&cp, space), 6); new->w = safe_atoi(token(&cp, space)); @@ -375,6 +386,7 @@ break; if ((cp = nr_config_get_addr(name)) == NULL) break; + strip_zero_ssid(cp); safe_strncpy(new->call, cp, 9); if ((cp = nr_config_get_alias(name)) == NULL) break; @@ -658,6 +670,7 @@ static struct proc_nr_nodes n; struct proc_nr_nodes *p, *list; + strip_zero_ssid(addr); list = nodes ? nodes : read_proc_nr_nodes(); for (p = list; p != NULL; p = p->next) { if (!strcasecmp(addr, p->call) || !strcasecmp(addr, p->alias)) { ---------------------------------------------------------------------------- To apply to libax25-1.0.5 "cd" into libax25-1.0.5 and use patch -p2 < <filename> -- Regards Richard ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Netromd ssid-0 broadcasts being ignored 2015-05-17 20:04 ` Richard Stearn @ 2015-05-17 20:34 ` Paul Lewis 0 siblings, 0 replies; 5+ messages in thread From: Paul Lewis @ 2015-05-17 20:34 UTC (permalink / raw) To: Richard Stearn; +Cc: linux-hams Hello Richard Many THANKS for taking the time and interest in fixing this callsign-0 (ssid 0 issue that I and others have. In applying the patch on my ubuntu 14.4.1 to the unoffical source release of libax25-1.0.5 the C callsign (-0) now works also the static routes for the -0 callsign entries are NOW being updated correctly. Patch installed today at 11:15 UK time and been running correctly for the past 9 hours. I am happy now. Next! Now back to checking why Xrouter node links fails to connect my system for the past many months, Pings replies work, 73 de Paul G4APL SysOP GB7CIP MB7NCR In message <201505172004.t4HK4BQQ022187@ux4.g1sog>, Richard Stearn <richard@rns-stearn.demon.co.uk> writes >Paul Lewis did scribe: >> >> Hi All >> >> Since I moved to the latest netromd code in 2013-2015 >> I have notice that there have been changes to the ssid-0 of >> nodes. >> >> Examples >> >> 1) issuing a C GB7BA fails. GB7BA-0 works >> C GB7CIP fails GB7CIP-0 works >> > >Hi Paul > >Try this patch against libax25-1.0.5, it is my attempt a reverting the >"strip -0" change in recent versions of libax25 : > >---------------------------------------------------------------------------- >diff -ru reference/libax25-1.0.5/lib/ax25/axconfig.c >modified/libax25-1.0.5/lib/ax25/axconfig.c >--- reference/libax25-1.0.5/lib/ax25/axconfig.c 2014-11-07 >17:41:26.000000000 +0000 >+++ modified/libax25-1.0.5/lib/ax25/axconfig.c 2015-05-16 >19:03:27.000000000 +0100 >@@ -238,8 +238,8 @@ > strupr(call); > found = 0; > char *cp; >- if ((cp = strstr(call, "-0")) != NULL) >- *cp = '\0'; >+ >+ > for (;ifcalls && *ifcalls; ++ifcalls, ++ifdevs) { > if (strcmp(call, *ifcalls) == 0) { > found = 1; >diff -ru reference/libax25-1.0.5/lib/ax25/axutils.c >modified/libax25-1.0.5/lib/ax25/axutils.c >--- reference/libax25-1.0.5/lib/ax25/axutils.c 2014-11-07 >17:41:26.000000000 +0000 >+++ modified/libax25-1.0.5/lib/ax25/axutils.c 2015-05-15 >17:22:35.000000000 +0100 >@@ -199,17 +199,14 @@ > *s++ = c; > } > >- /* Convention is: -0 suffixes are NOT printed */ >- if (a->ax25_call[6] & 0x1E) { >- *s++ = '-'; >- >- if ((n = ((a->ax25_call[6] >> 1) & 0x0F)) > 9) { >- *s++ = '1'; >- n -= 10; >- } >- *s++ = n + '0'; >- } >+ *s++ = '-'; > >+ if ((n = ((a->ax25_call[6] >> 1) & 0x0F)) > 9) { >+ *s++ = '1'; >+ n -= 10; >+ } >+ >+ *s++ = n + '0'; > *s++ = '\0'; > > return buf; >diff -ru reference/libax25-1.0.5/lib/ax25/nrconfig.c >modified/libax25-1.0.5/lib/ax25/nrconfig.c >--- reference/libax25-1.0.5/lib/ax25/nrconfig.c 2014-11-07 >17:41:26.000000000 +0000 >+++ modified/libax25-1.0.5/lib/ax25/nrconfig.c 2015-05-16 >19:03:45.000000000 +0100 >@@ -216,8 +216,8 @@ > strupr(alias); > > char *cp; >- if ((cp = strstr(call, "-0")) != NULL) >- *cp = 0; >+ >+ > > found = 0; > for (;ifcalls && *ifcalls; ++ifcalls, ++ifdevs) { >diff -ru reference/libax25-1.0.5/lib/ax25/procutils.c >modified/libax25-1.0.5/lib/ax25/procutils.c >--- reference/libax25-1.0.5/lib/ax25/procutils.c 2014-11-07 >17:41:26.000000000 +0000 >+++ modified/libax25-1.0.5/lib/ax25/procutils.c 2015-05-16 >19:58:44.000000000 +0100 >@@ -70,6 +70,15 @@ > return buf; > } > >+static char *strip_zero_ssid(char *call) >+{ >+ char *cp; >+ >+ if ((cp = strstr(call, "-0")) != NULL) >+ *cp = 0; >+ return call; >+} >+ > struct proc_ax25 *read_proc_ax25(void) > { > FILE *fp; >@@ -336,6 +345,8 @@ > cp = buffer; > > safe_strncpy(new->call, token(&cp, space), 9); >+ strip_zero_ssid(new->call); >+ > safe_strncpy(new->alias, token(&cp, space), 6); > > new->w = safe_atoi(token(&cp, space)); >@@ -375,6 +386,7 @@ > break; > if ((cp = nr_config_get_addr(name)) == NULL) > break; >+ strip_zero_ssid(cp); > safe_strncpy(new->call, cp, 9); > if ((cp = nr_config_get_alias(name)) == NULL) > break; >@@ -658,6 +670,7 @@ > static struct proc_nr_nodes n; > struct proc_nr_nodes *p, *list; > >+ strip_zero_ssid(addr); > list = nodes ? nodes : read_proc_nr_nodes(); > for (p = list; p != NULL; p = p->next) { > if (!strcasecmp(addr, p->call) || !strcasecmp(addr, p->alias)) { >---------------------------------------------------------------------------- > >To apply to libax25-1.0.5 "cd" into libax25-1.0.5 and use > patch -p2 < <filename> > -- paul@skywaves.demon.co.uk ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-05-17 20:34 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2015-05-15 8:14 Netromd ssid-0 broadcasts being ignored Paul Lewis 2015-05-16 15:50 ` David Ranch 2015-05-16 19:46 ` Richard Stearn 2015-05-17 20:04 ` Richard Stearn 2015-05-17 20:34 ` Paul Lewis
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.