]>
git.saurik.com Git - apple/security.git/blob - SecureTransport/sslBER_Dummy.cpp
5 Contains: stubs of routines in sslBER.cpp to enable standalone
6 build for indexing purposes. Unlike the real sslBER.cpp,
7 this version does not require the SecurityANS1 files
8 (which are not exported from Security.framework).
10 Written by: Doug Mitchell
12 Copyright: (c) 1999 by Apple Computer, Inc., all rights reserved.
17 #include "sslMemory.h"
24 * Given a PKCS-1 encoded RSA public key, extract the
25 * modulus and public exponent.
27 * RSAPublicKey ::= SEQUENCE {
28 * modulus INTEGER, -- n
29 * publicExponent INTEGER -- e }
32 OSStatus
sslDecodeRsaBlob(
33 const SSLBuffer
*blob
, /* PKCS-1 encoded */
34 SSLBuffer
*modulus
, /* data mallocd and RETURNED */
35 SSLBuffer
*exponent
) /* data mallocd and RETURNED */
41 * Given a raw modulus and exponent, cook up a
42 * BER-encoded RSA public key blob.
44 OSStatus
sslEncodeRsaBlob(
45 const SSLBuffer
*modulus
,
46 const SSLBuffer
*exponent
,
47 SSLBuffer
*blob
) /* data mallocd and RETURNED */