Non-ASCII used in Caster Table

A minor bug is the way SNIP creates the Caster Table header when using non-Latin fonts has been discovered and is now corrected.  We have had no reports of this issue causing end user connection problems.  The patch is present in SNIP release 1.11.7 and thereafter (production release 1.12 on-wards).

Background

As a general rule SNIP will use the machines local language and conventions to represent numbers, dates, times, and other textual objects.  So a user in France sees french and one in Japan sees Japanese and in the correct local font.  Because SNIP represents strings in UTF8, that works fine for languages that use the “Latin” font and it also works transparently for most of the world other fonts including Kanji, Cyrillic , Greece, Simplified Cheese, etc.

The problem occurs when a the Caster Table is created.  Every time this table is requested, the current UTC time stamp is used (and also the build date of the SNIP release).   Here is a typical example showing the issue taken from a SNIP deployment located in Asia (some detail obscured for privacy):

SOURCETABLE 200 OK
Server: SubCarrier Systems Corp SNIP simpleNTRIP_Caster_R1.10.0/of:七月 11 2017
Date: 週五, 17 十一月 2017 11:57:03 UTC
Content-Type: text/plain
Content-Length: 257

STR;PLxxx_5700_Ba;Penghu;RTCM 3;1004(1),1005(10),1007(10);2;GPS;SNIP;TWN;2x.57;1x9.5x;0;0;sNTRIP;;;;1150;;
STR;PLxxx_RTK;Penghu;RTCM 3;1004(1),1006(10),1007(10),1013(10);2;GPS;SNIP;TWN;2x.57;1x9.5x;0;0;sNTRIP;;;;1237;;
NET;SNIP;;;;;220.1.xxx.xxx:81;;;
ENDSOURCETABLE

The above table follows the RTCM NTRIP protocol recommendations (where in fact the time line is not required).  But is does not follow the general guidelines of HTML.  Here are two (of the three) conflicting lines:

Date: 週五, 17 十一月 2017 11:57:03 UTC
Content-Type: text/plain

The first line is not plain text.  And “plain text” in is case is taken to mean “us-ascii” as noted by:

7.1 The Text ContentType. … A “charset” parameter may be used to indicate the character set of the body text. The primary subtype of text is “plain“. This indicates plain (unformatted) text. The default ContentType for Internet mail is “text/plain; charset=us-ascii”.

So we could try to express the time in other ways…

Date: 週五, 17 十一月 2017 11:57:03 UTC                      might be expressed as:
Dēta: Shū go, 17 11gatsu 2017 11: 57: 03 UTC               or as:
Date: Week 5, 17 November 2017 11: 57: 03 UTC           (which is all ASCII)

But the html plain-text rule means we need to stick with ASCII.  So the various diacritical and accent marks found in the above (the ū in Shū) and also in most European languages using the Latin1 font, are also prohibited here.   [Aside: One of the primary reasons that the NTRIP protocol uses only ASCII is to  support having ‘dumb’ NTRIP Clients to be able to parse the table, so these characters are also not allowed in the mountPt names]

So we have added some additional code to ensure that regardless of what local language the machine running SNIP is set to, the two instances of time in the header will be expressed in 8-bit ASCII characters only.

To repeat:  We have had no reports of this issue actually
causing any end user connection problems at this time.

 

 

Related Articles