vpnengine/ikev1lib/src/ikev1pluginsession.cpp
branchRCL_3
changeset 49 5960d2d03390
parent 46 29c8f9bc68e1
equal deleted inserted replaced
46:29c8f9bc68e1 49:5960d2d03390
   900 // Handles completion of authentication dialog processing.
   900 // Handles completion of authentication dialog processing.
   901 // ---------------------------------------------------------------------------
   901 // ---------------------------------------------------------------------------
   902 //    
   902 //    
   903 TInt CIkev1PluginSession::AuthDialogCompletedL( CAuthDialogInfo* aUserInfo )
   903 TInt CIkev1PluginSession::AuthDialogCompletedL( CAuthDialogInfo* aUserInfo )
   904     {
   904     {
   905     CIkev1Negotiation* negotiation = aUserInfo->iNegotiation;
   905     CIkev1Negotiation* negotiation = FindNegotiation( aUserInfo->SAId() );
   906     if ( negotiation )
   906     if ( negotiation )
   907         {
   907         {
   908         DEBUG_LOG1( _L("Dialog completed for SAID: %d"),
   908         DEBUG_LOG1( _L("Dialog completed for SAID: %d"),
   909                 aUserInfo->SAId() );
   909                 aUserInfo->SAId() );
   910         
   910         
   918     DEBUG_LOG1( _L("Dialog completed, no negotiation found for SAID: %d"),
   918     DEBUG_LOG1( _L("Dialog completed, no negotiation found for SAID: %d"),
   919             aUserInfo->SAId() );
   919             aUserInfo->SAId() );
   920     return KErrNotFound;
   920     return KErrNotFound;
   921     }
   921     }
   922 
   922 
   923 // ---------------------------------------------------------------------------
       
   924 // Handles completion of error dialog processing.
       
   925 // ---------------------------------------------------------------------------
       
   926 //    
       
   927 TInt CIkev1PluginSession::ErrDialogCompletedL( CAuthDialogInfo* aUserInfo )
       
   928     {
       
   929     
       
   930     CIkev1Negotiation* negotiation = aUserInfo->iNegotiation;
       
   931     if ( negotiation )
       
   932         {
       
   933         DEBUG_LOG1( _L("Dialog completed for SAID: %d"),
       
   934                 aUserInfo->SAId() );
       
   935         
       
   936         negotiation->ErrDialogCompletedL();
       
   937         if ( negotiation->Finished() )
       
   938             {
       
   939             DeleteNegotiation( negotiation );
       
   940             }   
       
   941         return KErrNone;
       
   942         }   
       
   943     DEBUG_LOG1( _L("Dialog completed, no negotiation found for SAID: %d"),
       
   944             aUserInfo->SAId() );
       
   945             
       
   946     return KErrNotFound;    
       
   947     }
       
   948 
   923 
   949 // ---------------------------------------------------------------------------
   924 // ---------------------------------------------------------------------------
   950 // Handles change of internal address.
   925 // Handles change of internal address.
   951 // ---------------------------------------------------------------------------
   926 // ---------------------------------------------------------------------------
   952 //    
   927 //    
  1076 // ---------------------------------------------------------------------------
  1051 // ---------------------------------------------------------------------------
  1077 //
  1052 //
  1078 MKmdEventLoggerIf& CIkev1PluginSession::EventLogger()
  1053 MKmdEventLoggerIf& CIkev1PluginSession::EventLogger()
  1079     {
  1054     {
  1080     return iPlugin.EventLogger();
  1055     return iPlugin.EventLogger();
  1081     }
       
  1082 
       
  1083 // ---------------------------------------------------------------------------
       
  1084 // Returns SoftToken interface.
       
  1085 // ---------------------------------------------------------------------------
       
  1086 //
       
  1087 //MSoftTokenPluginIf* CIkev1PluginSession::SoftToken()
       
  1088 CSoftTokenPluginIf* CIkev1PluginSession::SoftToken()
       
  1089     {
       
  1090     return iPlugin.SoftToken();
       
  1091     }      
  1056     }      
  1092 
  1057 
  1093 // ---------------------------------------------------------------------------
  1058 // ---------------------------------------------------------------------------
  1094 // Returns internal address (NULL if does not exist). 
  1059 // Returns internal address (NULL if does not exist). 
  1095 // ---------------------------------------------------------------------------
  1060 // ---------------------------------------------------------------------------
  1569         // Store buffer into send queue for later sending.
  1534         // Store buffer into send queue for later sending.
  1570         TIkeSendQueueItem item = TIkeSendQueueItem( aUdpData,
  1535         TIkeSendQueueItem item = TIkeSendQueueItem( aUdpData,
  1571                                                     aDestAddr,
  1536                                                     aDestAddr,
  1572                                                     aLocalPort,
  1537                                                     aLocalPort,
  1573                                                     aDscp );
  1538                                                     aDscp );
  1574         iSendQueue.AppendL( item );  
  1539         iSendQueue.Append( item );                
  1575         }        
  1540         }        
  1576     }
  1541     }
  1577 
  1542 
  1578 // ---------------------------------------------------------------------------
  1543 // ---------------------------------------------------------------------------
  1579 // Sends UDP data. 
  1544 // Sends UDP data.