Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Unsolved QNetworkConfigurationManager does not recognise active wireless network when Cisco AnyConnect secure mobility client is enabled

    C++ Gurus
    2
    2
    691
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      DLHTS last edited by

      Hi,
      The issue I had been facing is - QNetworkConfigurationManager does not recognise active wireless network when Cisco AnyConnect secure mobility client(http://www.cisco.com/c/en/us/products/security/anyconnect-secure-mobility-client/index.html?stickynav=1) is enabled on my system. The QNetworkConfigurationManager detects the wired network but not the wireless. Also, when i try to connect to the wireless using VPN connection,
      then the QNetworkConfigurationManager detects it. I have recently migrated my application code from Qt 5.4 to Qt 5.9.1.The application works as intended on Qt 5.4,
      but not on Qt 5.9.1.

      Please find the code snippet as below,may be of some help.
      void CNetworkConnectionCheck::checkNetworkConnection()
      {
      m_bIsConnected = false;
      QNetworkConfigurationManager nwkMgr;
      QList<QNetworkConfiguration> activeConfigs = nwkMgr.allConfigurations(QNetworkConfiguration::Active);
      qDebug() << activeConfigs.count();
      if(activeConfigs.count() > 0 && nwkMgr.isOnline())
      {
      foreach(QNetworkConfiguration activeConfig, activeConfigs)
      {
      QNetworkSession session(activeConfig);
      if(session.state() == QNetworkSession::Connected)
      {
      m_bIsConnected = true;
      break;
      }
      }
      if(m_bIsConnected)
      setSSID();
      }
      else
      {
      m_bIsConnected = false;
      }
      }

      Here, CNetworkConnectionCheck is derived from QThread Class. activeConfigs.count() returns as 0 everytime when cisco anyConnect secure mobility client is enabled on the system.

      Can anyone please help to resolve the issue.
      Thanks.

      1 Reply Last reply Reply Quote 0
      • SGaist
        SGaist Lifetime Qt Champion last edited by

        Hi,

        Please don't post the exact same question on multiple sub-forum. One is enough.

        Duplicate

        Closing this one.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply Reply Quote 0
        • First post
          Last post