diff -r 000000000000 -r 1bce908db942 ipappsrv_plat/multimedia_comms_api/inc/mcesecuresession.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ipappsrv_plat/multimedia_comms_api/inc/mcesecuresession.h Tue Feb 02 01:04:58 2010 +0200 @@ -0,0 +1,80 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + + + +#ifndef CMCESECURESESSION_H +#define CMCESECURESESSION_H + +// INCLUDES +#include +#include +#include +#include +#include +#include + +// CONSTANTS +const TMceSessionType KMceSessionSecure = 2; + +enum TMceCryptoContext + { + // Counter Mode cipher HMAC-SHA1 message authentication, 32-bit authentication tag + EAES_CM_128_HMAC_SHA1_32, + // Counter Mode cipher HMAC-SHA1 message authentication, 80-bit authentication tag + EAES_CM_128_HMAC_SHA1_80, + }; + +// CLASS DECLARATION + +/** +* Base class for secure MCE sessions, inherited by both CMceSecureInSession +* and CMceSecureOutSession. +* +* @lib mceclient.lib +*/ +class MMceSecureSession + { +public: // Crypto contexts + + +public: // Functions + + /* + * Get the supported crypto contexts of the terminal. + * @return supported crypto contexts. + */ + virtual const RArray& SupportedCryptoContextsL() const = 0; + + /* + * Get the used crypto contexts in the session. + * @return used crypto contexts. + */ + virtual const RArray& CryptoContexts() const = 0; + + /* + * Set the used crypto contexts in the session. + * @pre State() == CMceSession::EIdle || + * State() == CMceSession::EIncoming || + * State() == CMceSession::EEstablished + * @param aArray Array of crypto contexts to be used in session. + */ + virtual void SetCryptoContextsL( const RArray& aArray ) = 0; + }; + +#endif