pike.git / lib / modules / Standards.pmod / X509.pmod

version» Context lines:

pike.git/lib/modules/Standards.pmod/X509.pmod:960:    // 5759 4.5.1.   #define ADD(X,Y,Z) extensions+=({ make_extension(Identifiers.ce_ids->X,Y,Z) })       if(!extensions) extensions = ({});       // While RFC 3280 section 4.2.1.2 suggest to only hash the BIT    // STRING part of the subjectPublicKey, it is only a suggestion.    ADD(subjectKeyIdentifier,    OctetString( Crypto.SHA1.hash(c->pkcs_public_key()->get_der()) ),    0); + #if 0    ADD(keyUsage,    BitString()->    set_from_ascii(sprintf("%09b", keyCertSign|cRLSign|digitalSignature)),    1); -  + #endif    ADD(basicConstraints,    Sequence(({Boolean(1)})),    1);      #undef ADD       return sign_key(dn, c, h||Crypto.SHA256, dn, serial, ttl, extensions);   }      //! Decodes a certificate and verifies that it is structually sound.