On Sun, Apr 20, 2014 at 09:22:12AM +0200, Kurt Roeckx wrote:
> On Sat, Apr 19, 2014 at 11:47:14PM +0200, Kurt Roeckx wrote:
> > I currently don't understand the test suite, so I have no idea
> > whether it's a problem or not that the error code changes.
> 
> I think it's actually an error in the ordering function and I'm
> looking at it.

It didn't end up being what I thought it was.  As far as I can see
the problem is this call:
          if (move == UP)
            {
              len2 = _asn1_strtol (p->value, NULL, 10);
              _asn1_set_value (p, NULL, 0);
              if ((type_field (p->type) == ASN1_ETYPE_SET_OF)
                  && (max_len - len2 > 0))
                {
                  _asn1_ordering_set_of (der + len2, max_len - len2, p);


Where maxlen - len2 == 1.  asn1_get_tag_der() checks for der_len < 2
and returns ASN1_DER_ERROR.

I don't understand enough about the code to know if this is all
normal or not.


Kurt


Reply via email to