applayerprotocols/httpservice/test/httpservicetest/ctesthttpserviceauthentication.cpp
branchRCL_3
changeset 5 337070b4fa18
child 12 f21293830889
equal deleted inserted replaced
3:5ee1d9ce5878 5:337070b4fa18
       
     1 // Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 #include <e32base.h>
       
    16 #include <f32file.h>  
       
    17 #include "ctesthttpserviceauthentication.h"
       
    18 
       
    19 _LIT(KAuthURL, "Passing credentials for URL %S, realm %S\n");
       
    20 _LIT(KAuthType, "Using %S authentication\n");
       
    21   
       
    22 CTestHttpServiceAuthentication::~CTestHttpServiceAuthentication()
       
    23     {  
       
    24     }
       
    25     
       
    26 CTestHttpServiceAuthentication::CTestHttpServiceAuthentication()
       
    27     {    
       
    28     }
       
    29     
       
    30 
       
    31 // From MHTTPServiceAuthentication
       
    32 TInt CTestHttpServiceAuthentication::OnAuthentication(const TDesC8& /*aUri*/, const TDesC8& /*aRealm*/, const TDesC8& /*aType*/, RBuf8& aUsername, RBuf8& aPassword)
       
    33     {
       
    34     //User credentials
       
    35     _LIT8(KUserName,  "username");
       
    36     _LIT8(KPassword,  "password");
       
    37    
       
    38     aUsername.Create(KUserName);
       
    39     aPassword.Create(KPassword);
       
    40     return KErrNone;
       
    41     }
       
    42