D17834: Allow the use of One-Time Password

Jan Grulich noreply at phabricator.kde.org
Fri Jan 4 07:57:35 GMT 2019


jgrulich added inline comments.

INLINE COMMENTS

> fortisslvpnauth.cpp:44
> +    const NetworkManager::Setting::SecretFlags otpFlag = static_cast<NetworkManager::Setting::SecretFlags>(data.value(NM_FORTISSLVPN_KEY_OTP"-flags").toInt());
> +    if (otpFlag == NetworkManager::Setting::None){
> +        d->ui.otpFrame->setVisible(false);

I think you should check for NetworkManager::Setting::NotSaved only, if it's this case, make it visible, if not, make it hidden. It's a one-time password so it won't be saved.

> fortisslvpnauth.cpp:46
> +        d->ui.otpFrame->setVisible(false);
> +    }
> +    else {

Coding style.

> fortisslvpnwidget.cpp:202
> +        data.insert(QLatin1String(NM_FORTISSLVPN_KEY_OTP"-flags"), QString::number(NetworkManager::Setting::NotSaved);
> +    }
> +    else {

Coding style.

> fortisslvpnwidget.cpp:204
> +    else {
> +        data.insert(QLatin1String(NM_FORTISSLVPN_KEY_OTP"-flags"), QString::number(NetworkManager::Setting::None);
> +    }

Shouldn't it be NetworkManager::Setting::NotRequired? Using NetworkManager::Setting::None says the one-time password should be saved to NetworkManager.

REPOSITORY
  R116 Plasma Network Management Applet

REVISION DETAIL
  https://phabricator.kde.org/D17834

To: enriquem, jgrulich
Cc: plasma-devel, jraleigh, GB_2, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20190104/b8b2cfd7/attachment-0001.html>


More information about the Plasma-devel mailing list