]>
git.saurik.com Git - apple/security.git/blob - SecureTransport/privateInc/SecureTransportPriv.h
2 * Copyright (c) 2000-2001 Apple Computer, Inc. All Rights Reserved.
4 * The contents of this file constitute Original Code as defined in and are
5 * subject to the Apple Public Source License Version 1.2 (the 'License').
6 * You may not use this file except in compliance with the License. Please obtain
7 * a copy of the License at http://www.apple.com/publicsource and read it before
10 * This Original Code and all software distributed under the License are
11 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS
12 * OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, INCLUDING WITHOUT
13 * LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
14 * PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. Please see the License for the
15 * specific language governing rights and limitations under the License.
20 File: SecureTransportPriv.h
22 Contains: Apple-private exported routines
24 Copyright: (c) 1999 by Apple Computer, Inc., all rights reserved.
28 #ifndef _SECURE_TRANSPORT_PRIV_H_
29 #define _SECURE_TRANSPORT_PRIV_H_ 1
31 #include <Security/SecureTransport.h>
37 /* The size of of client- and server-generated random numbers in hello messages. */
38 #define SSL_CLIENT_SRVR_RAND_SIZE 32
40 /* The size of the pre-master and master secrets. */
41 #define SSL_RSA_PREMASTER_SECRET_SIZE 48
42 #define SSL_MASTER_SECRET_SIZE 48
45 * For the following three functions, *size is the available
46 * buffer size on entry and the actual size of the data returned
47 * on return. The above consts are for convenience.
49 OSStatus
SSLInternalMasterSecret(
50 SSLContextRef context
,
51 void *secret
, // mallocd by caller, SSL_MASTER_SECRET_SIZE
52 size_t *secretSize
); // in/out
54 OSStatus
SSLInternalServerRandom(
55 SSLContextRef context
,
56 void *rand
, // mallocd by caller, SSL_CLIENT_SRVR_RAND_SIZE
57 size_t *randSize
); // in/out
59 OSStatus
SSLInternalClientRandom(
60 SSLContextRef context
,
61 void *rand
, // mallocd by caller, SSL_CLIENT_SRVR_RAND_SIZE
62 size_t *randSize
); // in/out
64 OSStatus
SSLInternal_PRF(
65 SSLContextRef context
,
72 void *out
, // mallocd by caller, length >= outLen
79 #endif /* _SECURE_TRANSPORT_PRIV_H_ */