[CLOSED] Customer Self Generate 2FA Secret Key

Moderator: crythias

Post Reply
skullz
Znuny superhero
Posts: 618
Joined: 24 Feb 2012, 03:58
Znuny Version: LTS and Features
Real Name: Mo Azfar
Location: Kuala Lumpur, MY
Contact:

[CLOSED] Customer Self Generate 2FA Secret Key

Post by skullz »

Hi all,

i'm enabling 2fa for both agent and customer..
for agent profile, we have the generate button for shared key while customer-user dont have this..

Image Image


im looking through Kernel/Output/HTML/Preferences/Generic.pm just try to replicate this 'generate' button on customer profile page.
However, cant seem to find the possible / responsible file for this.

Any pointer will be great. Thanks
Last edited by skullz on 11 Dec 2020, 03:54, edited 1 time in total.
root
Administrator
Posts: 3934
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: [Help] Customer Self Generate 2FA Secret Key

Post by root »

Hi Skullz,

In the agent interface, it's the Javascript file var/httpd/htdocs/js/Core.Agent.SharedSecretGenerator.js which is added via Loader::Module::AgentPreferences###001-Framework to the preferences screen.

The button is added via Javascript :

Code: Select all

$("#UserGoogleAuthenticatorSecretKey").parent().append("<button...
You have to create sth similar for the customer interface.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
skullz
Znuny superhero
Posts: 618
Joined: 24 Feb 2012, 03:58
Znuny Version: LTS and Features
Real Name: Mo Azfar
Location: Kuala Lumpur, MY
Contact:

Re: [Help] Customer Self Generate 2FA Secret Key

Post by skullz »

root wrote: 10 Dec 2020, 19:08 Hi Skullz,

In the agent interface, it's the Javascript file var/httpd/htdocs/js/Core.Agent.SharedSecretGenerator.js which is added via Loader::Module::AgentPreferences###001-Framework to the preferences screen.

The button is added via Javascript :

Code: Select all

$("#UserGoogleAuthenticatorSecretKey").parent().append("<button...
You have to create sth similar for the customer interface.

- Roy
Hi Roy,

Big thanks . Got it
Post Reply