Hi,

On 27 Dec 2017, at 21:53, teor <teor2345@gmail.com> wrote:

On 26 Dec 2017, at 18:47, teor <teor2345@gmail.com> wrote:

On 25 Dec 2017, at 07:26, Iain Learmonth <irl@torproject.org> wrote:

As we are planning to also add a parser to metrics-lib (#24434), would
it be possible to get a full description of the format of the file
possibly in RFC5234 format so that we can check that the generator and
parsers all match up to that specification?

I have written up a format in the standard torspec style:

https://github.com/teor2345/torspec/blob/fallback-format-2/fallback-spec.txt

It is deliberately under-specified, please let me know if this causes
any trouble when writing the parser, and I will tighten it up.

It's not ABNF/RFC5234, it's rather restrictive, and strict ABNF is
unreadable for case sensitive strings. I am happy to put an ABNF spec in
an appendix, if someone wants to write one.

We've added separators to each section, and a timestamp field in the header.

The revised spec is here:

https://github.com/teor2345/torspec/blob/fallback-format-2/fallback-spec.txt

The revised sample file is here:

https://trac.torproject.org/projects/tor/attachment/ticket/22759/fallback_dirs_new_format_version.4.inc

We're tracking the details in this ticket:

https://trac.torproject.org/projects/tor/ticket/24742

We have merged the list format change to Tor's master branch.

The fallback 2.0.0 spec hasn't been merged yet, but atagar has reviewed it.
It's at:
https://github.com/teor2345/torspec/blob/fallback-format-2-v2/fallback-spec.txt

The fallback list is now in the 2.0.0 format, but it has exactly the same fallbacks in it:
https://gitweb.torproject.org/tor.git/tree/src/or/fallback_dirs.inc

Some time over the next few days, we will generate a new list of fallbacks in
the 2.0.0 format, and backport it to Tor 0.2.9 and later.

T