#include "qicdengine.h"
#include "qnetworksession_impl.h"
#include <wlancond.h>
#include <wlan-utils.h>
#include <iapconf.h>
#include <iapmonitor.h>
#include "qicdengine.moc"
Go to the source code of this file.
◆ getNetworkAttrs()
Definition at line 367 of file qicdengine.cpp.
Referenced by QIcdEngine::addConfiguration(), and QIcdEngine::doRequestUpdate().
372 guint network_attr = 0;
373 dbus_uint32_t cap = 0;
375 if (iap_type ==
"WLAN_INFRA")
376 cap |= WLANCOND_INFRA;
377 else if (iap_type ==
"WLAN_ADHOC")
378 cap |= WLANCOND_ADHOC;
380 if (security_method.
isEmpty() && (cap & (WLANCOND_INFRA | WLANCOND_ADHOC))) {
382 security_method = saved_ap.value(
"wlan_security").toString();
385 if (!security_method.
isEmpty()) {
386 if (security_method ==
"WEP")
388 else if (security_method ==
"WPA_PSK")
389 cap |= WLANCOND_WPA_PSK;
390 else if (security_method ==
"WPA_EAP")
391 cap |= WLANCOND_WPA_EAP;
392 else if (security_method ==
"NONE")
393 cap |= WLANCOND_OPEN;
395 if (cap & (WLANCOND_WPA_PSK | WLANCOND_WPA_EAP)) {
397 bool wpa2_only = saved_iap.value(
"EAP_wpa2_only_mode").toBool();
399 cap |= WLANCOND_WPA2;
406 network_attr |= ICD_NW_ATTR_IAPNAME;
static guint cap2nwattr(dbus_uint32_t cap, guint *nwattrs)
bool isEmpty() const
Returns true if the string has no characters; otherwise returns false.
◆ network_attrs_to_security()
static QString network_attrs_to_security |
( |
uint |
network_attrs | ) |
|
|
inlinestatic |
Definition at line 321 of file qicdengine.cpp.
Referenced by QIcdEngine::doRequestUpdate().
325 if (cap & WLANCOND_OPEN)
327 else if (cap & WLANCOND_WEP)
329 else if (cap & WLANCOND_WPA_PSK)
331 else if (cap & WLANCOND_WPA_EAP)
static dbus_uint32_t nwattr2cap(guint nwattrs, dbus_uint32_t *cap)