On Wed, 8 Apr 1998 [EMAIL PROTECTED] wrote:
> > > Somewhere within SSLeay is a way to get object IDs. For example, for RSA
> > > signed MD5 uses the following set of bytes:
> > PS I talk about the ASN1. Object identifier bytes and the DER header
> > as seperate things because they are. Internally, when stored
> > in ASN1_STRING or ASN1_OBJECT, the header is missing.
>
> Does this explain the length problem?
yup. The ASN.1 object identifier has a special way of encoding the numbers,
while the DER header on the object can be encoded in several different
ways.
using 'ssleay asn1parse' on a certificate, I get
13:d=3 hl=2 l= 9 prim: OBJECT :md5WithRSAEncryption
In this case, the header is 2 bytes, the OBJECT is 9, and by doing
the relevent OBJ_nid2ln(OBJ_obj2nid(obj)) call I end up with
md5WithRSAEncryption.
In theory, you could encode the object in BER, and have it chopped up
into multiple little chunks.
+-------------------------------------------------------------------------+
| Administrative requests should be sent to [EMAIL PROTECTED] |
| List service provided by Open Software Associates, http://www.osa.com/ |
+-------------------------------------------------------------------------+