On Wed, Jul 5, 2017 at 4:32 AM Gervase Markham via dev-security-policy < [email protected]> wrote:
> On 29/06/17 16:27, Ryan Sleevi wrote: > > Well, the current certdata.txt is a text file. Do you believe it's > human-readable, especially sans-comments? > > Human readability is, of course, a little bit of a continuum. You can > open it in a text editor and get some sense of what's going on, but it's > far from ideal. Unfortunately, your answers don't really help capture your goals - and thus make this a very difficult endeavor to satisfy. You haven't really established on what principles you believe JSON (which seems to be your preferred format, and which does not support comments) is more favorable than the current format. That is, the difference between, say: "label": "Verisign/RSA Secure Server CA" And CKA_LABEL "Verisign/RSA Secure Server CA" I would argue there isn't a meaningful difference for "human readability", and it's more a subjective preference. Before we fixate on those, I'm hoping we should get objective use cases nailed down. That's why I'm trying to understand how you're evaluating that spectrum. Is it because it's something you'd like to maintain, because you think it should be "readable" on a webpage, etc? > How it is sans-comments is irrelevant, because it has comments. :-) It isn't, because JSON can't. > Of course, those changing the root store might need access to the > compilation tool. But from a Mozilla PoV, that's just Kai normally. And > if people were used to editing and consuming certdata.txt, they could > continue to do it that way. I'm thinking you may have misunderstood? Are you suggesting certdata.txt is canonical or not? Otherwise, they can't continue doing it hat way - they would have to use whatever format you adopt, and whatever new tools. > > Thought experiment for you: if we decided to make the root store its own > thing with its own repo and its own release schedule, and therefore NSS > became a downstream consumer of it, where on occasion someone would > "take a release" by generating and checking in certdata.txt from > whatever format we decided to use, what problems would that cause? Would you see it being as independent, or subservient to Firefox? If you saw it as independent, then you would presumably need to ensure that - like today - Firefox-specific needs, like EV or trust restrictions, did not creep into the general code. Of course, it seems like your argument is you want to express the Firefox behaviors either directly in NSS (as some trust restrictions are, via code) or via some external, shared metafile, which wouldn't be relevant to non-Firefox consumers. More broadly, that proposal simply adds more work and moving parts, and arguably undermines your stated goals - because downstream parties like those identified are not interested in what the "upstream root store" is doing - they're interested in what Firefox is doing, and to get that, they would need to consume certdata.txt as well. I'm fairly certain we're not on the same page as to what problems consumers are facing in this space, and this may be contributing to the misunderstanding. If you look at major parties doing stuff in this space - Cloudflare's CFSSL, SSLLabs, Censys - the goal is generally "trusted by Firefox," as the goal is debugging and helping users properly configure. crt.sh is more interested in "trusted by NSS," due to the policy enforcement. That is - there are two separate problems - trusted by browser X, and trusted by root program Y. We should at least recognize these as related, but separable problems. The need to identify the former is why, for example, folks scrape the historic releases (or maintain copies, such as of the Microsoft CTLs). > > > So clearly, we get in situations where not all restrictions are > expressible. > > Sure. As I said, I'm not interested in an arbitrarily complex file > format, so it will always be possible to come up with restrictions we > can't encode. I'm still not sure I understand what you believe is arbitrarily complex. All restrictions can be encoded - it's a question of whether the complexity is useful. For example, you could encode a BPF like state machine for restrictions - which can be fully encoded and processed, but which would add code. But one could easily make the argument that a BPF like filter library is useful and worthwhile for any number of Root stores. It's very easy to get lost in this games, and so perhaps it may be useful if you could contemplate what your core goals are, for Mozilla. I'm not sure it would be fair to express hypothetical's for Apple or others, in their absence, but I hope you can appreciate why this feels like a lot of "ambiguous make work," as specified. But whatever format Apple chooses, unless they go the > "arbitrary complexity" path, they will have that problem, no? Are you familiar with how Apple currently expresses their root store and how applications consume it? I don't think it is necessary for Mozilla to do anything here, certainly not yet, certainly not without their involvement and a clearer set of requirements. Apple currently has a workflow - based on a Ruby script, Xcode, and processing files in a directory. If you want to know what a given macOS or iOS version supports, your options are to download the .tar.gz and attempt to do the same work, but even then, you may not get the updates a given security patch point release supports (they're generally documented in the release notes, but not always). Having them express that in any reliable form, consistent with any changes - with even a modicum of documentation - is a substantial improvement. The community already supports certdata.txt and authroots.stl fine - the issue isn't trying to support N formats (which is trivial relative to the complexity proposed here for NSS, at least based on the objectives shared so far), it's needing to support just a format. The two formats currently used by the industry are both binary - Microsoft's, which is documented (in the SDK headers) and PKCS#7, and Mozilla, which in distribution is an opaque PKCS#11 DLL that you have to execute methods on, or in source is a text file expression of a PKCS#11 attribute set. Both permit arbitrary complexity - but only one vendor (Microsoft) uses it to any great extent. Even if Apple switches to some unified format, its likely to imagine it will be a binary file, even if just a .plist (binary XML-ish), and so the same problems I mentioned will all still exist. _______________________________________________ dev-security-policy mailing list [email protected] https://lists.mozilla.org/listinfo/dev-security-policy

