1279264Sdelphij/* ssl/srtp.h */ 2238384Sjkim/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3238384Sjkim * All rights reserved. 4238384Sjkim * 5238384Sjkim * This package is an SSL implementation written 6238384Sjkim * by Eric Young (eay@cryptsoft.com). 7238384Sjkim * The implementation was written so as to conform with Netscapes SSL. 8238384Sjkim * 9238384Sjkim * This library is free for commercial and non-commercial use as long as 10238384Sjkim * the following conditions are aheared to. The following conditions 11238384Sjkim * apply to all code found in this distribution, be it the RC4, RSA, 12238384Sjkim * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13238384Sjkim * included with this distribution is covered by the same copyright terms 14238384Sjkim * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15238384Sjkim * 16238384Sjkim * Copyright remains Eric Young's, and as such any Copyright notices in 17238384Sjkim * the code are not to be removed. 18238384Sjkim * If this package is used in a product, Eric Young should be given attribution 19238384Sjkim * as the author of the parts of the library used. 20238384Sjkim * This can be in the form of a textual message at program startup or 21238384Sjkim * in documentation (online or textual) provided with the package. 22238384Sjkim * 23238384Sjkim * Redistribution and use in source and binary forms, with or without 24238384Sjkim * modification, are permitted provided that the following conditions 25238384Sjkim * are met: 26238384Sjkim * 1. Redistributions of source code must retain the copyright 27238384Sjkim * notice, this list of conditions and the following disclaimer. 28238384Sjkim * 2. Redistributions in binary form must reproduce the above copyright 29238384Sjkim * notice, this list of conditions and the following disclaimer in the 30238384Sjkim * documentation and/or other materials provided with the distribution. 31238384Sjkim * 3. All advertising materials mentioning features or use of this software 32238384Sjkim * must display the following acknowledgement: 33238384Sjkim * "This product includes cryptographic software written by 34238384Sjkim * Eric Young (eay@cryptsoft.com)" 35238384Sjkim * The word 'cryptographic' can be left out if the rouines from the library 36238384Sjkim * being used are not cryptographic related :-). 37238384Sjkim * 4. If you include any Windows specific code (or a derivative thereof) from 38238384Sjkim * the apps directory (application code) you must include an acknowledgement: 39238384Sjkim * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40238384Sjkim * 41238384Sjkim * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42238384Sjkim * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43238384Sjkim * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44238384Sjkim * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45238384Sjkim * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46238384Sjkim * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47238384Sjkim * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48238384Sjkim * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49238384Sjkim * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50238384Sjkim * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51238384Sjkim * SUCH DAMAGE. 52238384Sjkim * 53238384Sjkim * The licence and distribution terms for any publically available version or 54238384Sjkim * derivative of this code cannot be changed. i.e. this code cannot simply be 55238384Sjkim * copied and put under another distribution licence 56238384Sjkim * [including the GNU Public Licence.] 57238384Sjkim */ 58238384Sjkim/* ==================================================================== 59238384Sjkim * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. 60238384Sjkim * 61238384Sjkim * Redistribution and use in source and binary forms, with or without 62238384Sjkim * modification, are permitted provided that the following conditions 63238384Sjkim * are met: 64238384Sjkim * 65238384Sjkim * 1. Redistributions of source code must retain the above copyright 66238384Sjkim * notice, this list of conditions and the following disclaimer. 67238384Sjkim * 68238384Sjkim * 2. Redistributions in binary form must reproduce the above copyright 69238384Sjkim * notice, this list of conditions and the following disclaimer in 70238384Sjkim * the documentation and/or other materials provided with the 71238384Sjkim * distribution. 72238384Sjkim * 73238384Sjkim * 3. All advertising materials mentioning features or use of this 74238384Sjkim * software must display the following acknowledgment: 75238384Sjkim * "This product includes software developed by the OpenSSL Project 76238384Sjkim * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" 77238384Sjkim * 78238384Sjkim * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 79238384Sjkim * endorse or promote products derived from this software without 80238384Sjkim * prior written permission. For written permission, please contact 81238384Sjkim * openssl-core@openssl.org. 82238384Sjkim * 83238384Sjkim * 5. Products derived from this software may not be called "OpenSSL" 84238384Sjkim * nor may "OpenSSL" appear in their names without prior written 85238384Sjkim * permission of the OpenSSL Project. 86238384Sjkim * 87238384Sjkim * 6. Redistributions of any form whatsoever must retain the following 88238384Sjkim * acknowledgment: 89238384Sjkim * "This product includes software developed by the OpenSSL Project 90238384Sjkim * for use in the OpenSSL Toolkit (http://www.openssl.org/)" 91238384Sjkim * 92238384Sjkim * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 93238384Sjkim * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 94238384Sjkim * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 95238384Sjkim * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 96238384Sjkim * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 97238384Sjkim * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 98238384Sjkim * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 99238384Sjkim * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 100238384Sjkim * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 101238384Sjkim * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 102238384Sjkim * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 103238384Sjkim * OF THE POSSIBILITY OF SUCH DAMAGE. 104238384Sjkim * ==================================================================== 105238384Sjkim * 106238384Sjkim * This product includes cryptographic software written by Eric Young 107238384Sjkim * (eay@cryptsoft.com). This product includes software written by Tim 108238384Sjkim * Hudson (tjh@cryptsoft.com). 109238384Sjkim * 110238384Sjkim */ 111238384Sjkim/* 112238384Sjkim DTLS code by Eric Rescorla <ekr@rtfm.com> 113238384Sjkim 114238384Sjkim Copyright (C) 2006, Network Resonance, Inc. 115238384Sjkim Copyright (C) 2011, RTFM, Inc. 116238384Sjkim*/ 117238384Sjkim 118238384Sjkim#ifndef HEADER_D1_SRTP_H 119238384Sjkim#define HEADER_D1_SRTP_H 120238384Sjkim 121279264Sdelphij#include <openssl/ssl.h> 122279264Sdelphij 123238384Sjkim#ifdef __cplusplus 124238384Sjkimextern "C" { 125238384Sjkim#endif 126238384Sjkim 127238384Sjkim 128238384Sjkim#define SRTP_AES128_CM_SHA1_80 0x0001 129238384Sjkim#define SRTP_AES128_CM_SHA1_32 0x0002 130238384Sjkim#define SRTP_AES128_F8_SHA1_80 0x0003 131238384Sjkim#define SRTP_AES128_F8_SHA1_32 0x0004 132238384Sjkim#define SRTP_NULL_SHA1_80 0x0005 133238384Sjkim#define SRTP_NULL_SHA1_32 0x0006 134238384Sjkim 135279264Sdelphij#ifndef OPENSSL_NO_SRTP 136279264Sdelphij 137238384Sjkimint SSL_CTX_set_tlsext_use_srtp(SSL_CTX *ctx, const char *profiles); 138238384Sjkimint SSL_set_tlsext_use_srtp(SSL *ctx, const char *profiles); 139238384SjkimSRTP_PROTECTION_PROFILE *SSL_get_selected_srtp_profile(SSL *s); 140238384Sjkim 141238384SjkimSTACK_OF(SRTP_PROTECTION_PROFILE) *SSL_get_srtp_profiles(SSL *ssl); 142238384Sjkim 143279264Sdelphij#endif 144279264Sdelphij 145238384Sjkim#ifdef __cplusplus 146238384Sjkim} 147238384Sjkim#endif 148238384Sjkim 149238384Sjkim#endif 150238384Sjkim 151