browser Package

controlpanel Module

class collective.smsauthenticator.browser.controlpanel.SMSAuthenticatorSettingsControlPanel(context, request)[source]

Bases: plone.app.registry.browser.controlpanel.ControlPanelFormWrapper

Control panel.

form

alias of SMSAuthenticatorSettingsEditForm

class collective.smsauthenticator.browser.controlpanel.SMSAuthenticatorSettingsEditForm(context, request)[source]

Bases: plone.autoform.form.AutoExtensibleForm, z3c.form.form.EditForm

Control panel form.

buttons = <z3c.form.button.Buttons object at 0x55849d0>
control_panel_view = 'plone_control_panel'
description = u'SMS Authenticator configuration'
getContent()[source]
handleCancel = <Handler for <Button 'cancel' u'Cancel'>>[source]
handleSave = <Handler for <Button 'save' u'Save'>>[source]
handlers = <Handlers [<Handler for <Button 'save' u'Save'>>, <Handler for <Button 'cancel' u'Cancel'>>]>
label = u'SMS Authenticator'
render(*args, **kwargs)[source]
schema = <InterfaceClass collective.smsauthenticator.browser.controlpanel.ISMSAuthenticatorSettings>
schema_prefix = None
updateActions()[source]
updateFields()[source]
updateWidgets()[source]

disable_two_step_verification Module

class collective.smsauthenticator.browser.disable_two_step_verification.DisableTwoStepVerification(context, request)[source]

Bases: Products.Five.browser.BrowserView

Disabling the two-step verification.

disable()[source]

Disable the two-step verification for the user and redirect back to the @@personal-information.

disable_two_step_verification_for_all_users Module

class collective.smsauthenticator.browser.disable_two_step_verification_for_all_users.DisableTwoStepVerificationForAllUsers(context, request)[source]

Bases: Products.Five.browser.BrowserView

Disable the two-step verification for all users.

index()[source]

Disble the two-step verification for the user and redirect back to the @@sms-authenticator-settings.

enable_two_step_verification_for_all_users Module

class collective.smsauthenticator.browser.enable_two_step_verification_for_all_users.EnableTwoStepVerificationForAllUsers(context, request)[source]

Bases: Products.Five.browser.BrowserView

Enable the two-step verification for all users.

index()[source]

Enable the two-step verification for the user and redirect back to the @@sms-authenticator-settings.

helpers Module

Gets SMS authenticator app links.

list_user_ips Module

class collective.smsauthenticator.browser.list_user_ips.ListAllUserIPs(context, request)[source]

Bases: collective.smsauthenticator.browser.list_user_ips.ListUserIPs

BrowserView for List all user IPs.

get_all_ips()[source]
class collective.smsauthenticator.browser.list_user_ips.ListUniqueUserIPs(context, request)[source]

Bases: collective.smsauthenticator.browser.list_user_ips.ListUserIPs

BrowserView for List unique user IPs.

get_unique_ips()[source]
class collective.smsauthenticator.browser.list_user_ips.ListUserIPs(context, request)[source]

Bases: Products.Five.browser.BrowserView

List user IPS, generic view

View function to pass function along to actual helper

settings_helper Module

class collective.smsauthenticator.browser.settings_helper.SettingsHelper(context, request)[source]

Bases: Products.Five.browser.BrowserView

Helper view for accessing some conditions from portal actions (actions.xml).

is_two_step_verification_globally_enabled()[source]

Disable the two-step verification for the user and redirect back to the @@personal-information.

Indicates whether the disable two-step verification link should be shown.

The following conditions shall be met for True to be returned:

  • User hasn enabled the two-step verification for his account.
  • In app settings, the globally enable two-step verification is set to False.
Return bool:

Indicates whether the enable two-step verification link should be shown.

The following conditions shall be met for True to be returned:

  • User hasn’t enabled the two-step verification for his account.
  • In app settings, the globally enable two-step verification is set to False.
Return bool: