]> git.saurik.com Git - apple/security.git/blobdiff - libsecurity_smime/lib/cryptohi.h
Security-58286.1.32.tar.gz
[apple/security.git] / libsecurity_smime / lib / cryptohi.h
index 382c0048ea5650ad9a84b6c0deab3746e3f8d764..87f8e129c28bd2e9a8beed1af693959cc6916bf7 100644 (file)
 #include <security_asn1/seccomon.h>
 #include <Security/SecCmsBase.h>
 
+
 SEC_BEGIN_PROTOS
 
+
+/****************************************/
+/*
+** DER encode/decode DSA signatures
+*/
+
+/* ANSI X9.57 defines DSA signatures as DER encoded data.  Our DSA code (and
+ * most of the rest of the world) just generates 40 bytes of raw data.  These
+ * functions convert between formats.
+ */
+//extern SECStatus DSAU_EncodeDerSig(SecAsn1Item *dest, SecAsn1Item *src);
+//extern SecAsn1Item *DSAU_DecodeDerSig(SecAsn1Item *item);
+
+#if USE_CDSA_CRYPTO
+/*
+ * Return a csp handle able to deal with algorithm
+ */
+extern CSSM_CSP_HANDLE SecCspHandleForAlgorithm(CSSM_ALGORITHMS algorithm);
+
+/*
+ * Return a CSSM_ALGORITHMS for a given SECOidTag or 0 if there is none
+ */
+extern CSSM_ALGORITHMS SECOID_FindyCssmAlgorithmByTag(SECOidTag algTag);
+#endif
+
 /****************************************/
 /*
 ** Signature creation operations