Viewing File: /usr/local/cpanel/base/frontend/jupiter/security/2fa/remove.html.tt
[%
SET CPANEL.CPVAR.dprefix = "../../";
USE ExpVar;
SET is_secpolicy_enabled = ExpVar.expand('$is_twofactorauth_sec_policy_enabled');
SET has_feature = CPANEL.feature('twofactorauth');
SET api_call_result = {};
SET return_link = "index.html";
IF CPANEL.FORM.defined('do_the_removal');
SET api_call_result = execute("TwoFactorAuth", "remove_user_configuration", {});
END;
%]
[% WRAPPER '_assets/master.html.tt'
app_key = 'two_factor_authentication'
include_legacy_stylesheets = 0
page_stylesheets = ['security/2fa/index.min.css']
%]
<div class="body-content">
[% IF is_secpolicy_enabled && has_feature %]
[% IF api_call_result.defined('status') %]
[% IF api_call_result.status && api_call_result.data.tfa_removed %]
<div id="success" class="alert alert-success">
<span id="successImg" class="glyphicon glyphicon-ok-sign"></span>
<div class="alert-message">
[% locale.maketext("[output,strong,Success:] The system removed two-factor authentication from your account.") %]
</div>
</div>
[% ELSE %]
<div id="error" class="alert alert-danger">
<span id="errorImg" class="glyphicon glyphicon-remove-sign"></span>
[% FOREACH msg = api_call_result.errors; %]
<div class="alert-message">
[% msg.html(); %]
</div>
[% END; %]
</div>
[% END %]
[% ELSE %]
<p>[% locale.maketext('Are you sure you want to remove two-factor authentication from your account?') %]</p>
<form method="post" action="remove.html" name="remove" id="remove">
<div class="form-group">
<button type="submit"
id="do_the_removal"
name="do_the_removal"
class="btn btn-primary"
value="1">[% locale.maketext('Remove') %]</button>
<a href=[% return_link %]
id="cancel"
class="btn btn-link">[% locale.maketext('Cancel') %]</a>
</div>
</form>
[% END %]
[% INCLUDE _assets/return_link.html.tt return_location=return_link return_link_text=locale.maketext('Go Back') %]
[% ELSE %]
<div class="alert alert-danger">
<span class="glyphicon glyphicon-remove-sign"></span>
<div class="alert-message">
[% locale.maketext('You do not have access to this feature. You must have the [asis,Two-factor Authentication] feature enabled for your account to use this interface.') %]
</div>
</div>
[% END %]
</div>
[% END #wrapper %]
Back to Directory
File Manager