
Pat Knight writes:
Pat> Is RFC 2578 the correct reference for SMIv2 syntax?
Yes.
Pat> RFC 2578 allows mixed case descriptors in this place in the Pat> syntax, provided they start with a lower case letter. As I would Pat> expect from my limited use of your fine product, libsmi supports Pat> this correctly :-)
Thanks.
Pat> However, we're seeing various vendor MIBs that have the initial Pat> letter in upper case. Did SMIv1 allow this or are the vendors Pat> just wrong? I can't find an RFC that seems to document the SMIv1 Pat> syntax with the clarity of RFC 2578 for SMIv2.
The SMI has until now always inherited its syntax rules from ASN.1. Even if the SMIv1 specifications do not clearly says that a descriptor must start with a lower-case letter, the ASN.1 documents are pretty clear about this (but I guess most people did not read them).
Pat> As you'll appreciate, users object to having to modify the vendor Pat> MIBs to get them to compile. As a developer, I prefer the strict Pat> approach (if the source is wrong, fix it, don't accept Pat> it). However, I'm under some pressure from our customer support Pat> team to deliver what they term "a usability fix." We're not Pat> aiming at a technically sophisticated market.
One of the reasons for writing libsmi was to provide a MIB parser implementation that takes the language definition serious. I understand your concerns though from a practical marketing point of view. But even if you change the libsmi parser to accept upper-case descriptors, you should do so by automatically converting them to lower-case and sending a big warning to stderr.
Pat> Can anyone offer advice as to the consequences if I were to Pat> modify the SMI lexer/parser to allow these descriptors to start Pat> with an uppercase letter? Would it break valid MIBs?
It can't break valid MIBs since a MIB with an upper-case descriptor is invalid. What can happen in some corner cases is that you get interesting name clashes and/or broken imports if you automatically convert upper-case descriptors to lower-case descriptors.
/js