codekingpro/portable-devtools
114k
1���4 �sphinx.addnodes��document���)��}�(� rawsource�� ��children�]�(�docutils.nodes��target���)��}�(h�.. _mfa:�h]��2attributes�}�(�ids�]��classes�]��names�]��dupnames�]��backrefs�]��refid��mfa�u�tagname�h3�line�K�parent�h� _document�h�source��^D:\a\pgadmin-packaging-foundation\pgadmin-packaging-foundation\pgadmin4-8.6\docs\en_US\mfa.rst�ubh �section���)��}�(hhh]�(h �title���)��}�(h�1`Enabling two-factor authentication (2FA)`:index:�h]�(h �index���)��}�(hhh]�h}�(h]�h]�h]�h]�h]��entries�]�(�single��(Enabling two-factor authentication (2FA)��index-0�hNt�auhh/h"h#hKh h+ubh)��}�(hhh]�h}�(h]�h>ah]�h]�h]�h]�uhh4h h+ubh �Text����(Enabling two-factor authentication (2FA)�����}�(h h+h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhh)h h&h!hh"h#hKubh%)��}�(hhh]�(h*)��}�(h�About two-factor authentication�h]�hJ�About two-factor authentication�����}�(h hXh!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h hUh!hh"h#hKubh � paragraph���)��}�(h��Two-factor authentication (2FA) is an extra layer of security used when logging5into websites or apps. With 2FA, you have to log in with your username and6password and provide another form of authentication that only you know or have7access to.�h]�hJ��Two-factor authentication (2FA) is an extra layer of security used when logging8into websites or apps. With 2FA, you have to log in with your username and9password and provide another form of authentication that only you know or have10access to.�����}�(h hhh!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hK h hUh!hubeh}�(h]��about-two-factor-authentication�ah]�h]��about two-factor authentication�ah]�h]�uhh$h h&h!hh"h#hKubh%)��}�(hhh]�(h*)��}�(h�Setup two-factor authentication�h]�hJ�Setup two-factor authentication�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h h~h!hh"h#hKubhg)��}�(hXU To set up 2FA for pgAdmin 4, you must configure the Two-factor Authentication11settings in *config_local.py* or *config_system.py* (see the12:ref:`config.py <config_py>` documentation) on the system where pgAdmin is13installed in Server mode. You can copy these settings from *config.py* file and14modify the values for the following parameters.�h]�(hJ�ZTo set up 2FA for pgAdmin 4, you must configure the Two-factor Authentication15settings in �����}�(h h�h!hh"NhNubh �emphasis���)��}�(h�*config_local.py*�h]�hJ�config_local.py�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h h�ubhJ� or �����}�(h h�h!hh"NhNubh�)��}�(h�*config_system.py*�h]�hJ�config_system.py�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h h�ubhJ�16 (see the17�����}�(h h�h!hh"NhNubh �pending_xref���)��}�(h�:ref:`config.py <config_py>`�h]�h �inline���)��}�(hh�h]�hJ� config.py�����}�(h h�h!hh"NhNubah}�(h]�h]�(�xref��std��std-ref�eh]�h]�h]�uhh�h h�ubah}�(h]�h]�h]�h]�h]��refdoc��mfa�� refdomain�hЌreftype��ref��refexplicit���refwarn��� reftarget�� config_py�uhh�h"h#hKh h�ubhJ�j documentation) on the system where pgAdmin is18installed in Server mode. You can copy these settings from �����}�(h h�h!hh"NhNubh�)��}�(h�*config.py*�h]�hJ� config.py�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h h�ubhJ�9 file and19modify the values for the following parameters.�����}�(h h�h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhfh"h#hKh h~h!hubh �table���)��}�(hhh]�h �tgroup���)��}�(hhh]�(h �colspec���)��}�(hhh]�h}�(h]�h]�h]�h]�h]��colwidth�K#uhj20 h j ubj )��}�(hhh]�h}�(h]�h]�h]�h]�h]��colwidth�K7uhj21 h j ubh �thead���)��}�(hhh]�h �row���)��}�(hhh]�(h �entry���)��}�(hhh]�hg)��}�(h�
**Parameter**�h]�h �strong���)��}�(hj1 h]�hJ� Parameter�����}�(h j5 h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhj3 h j/ ubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j, ubah}�(h]�h]�h]�h]�h]�uhj* h j' ubj+ )��}�(hhh]�hg)��}�(h�**Description**�h]�j4 )��}�(hjS h]�hJ�Description�����}�(h jU h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhj3 h jQ ubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh jN ubah}�(h]�h]�h]�h]�h]�uhj* h j' ubeh}�(h]�h]�h]�h]�h]�uhj% h j" ubah}�(h]�h]�h]�h]�h]�uhj h j ubh �tbody���)��}�(hhh]�(j& )��}�(hhh]�(j+ )��}�(hhh]�hg)��}�(h�MFA_ENABLED�h]�hJ�MFA_ENABLED�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j� ubah}�(h]�h]�h]�h]�h]�uhj* h j ubj+ )��}�(hhh]�hg)��}�(h�VThe default value for this parameter is True.22To disable 2FA, set the value to *False*�h]�(hJ�OThe default value for this parameter is True.23To disable 2FA, set the value to �����}�(h j� h!hh"NhNubh�)��}�(h�*False*�h]�hJ�False�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h j� ubeh}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j� ubah}�(h]�h]�h]�h]�h]�uhj* h j ubeh}�(h]�h]�h]�h]�h]�uhj% h j| ubj& )��}�(hhh]�(j+ )��}�(hhh]�hg)��}�(h�SUPPORTED_MFA_LIST�h]�hJ�SUPPORTED_MFA_LIST�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j� ubah}�(h]�h]�h]�h]�h]�uhj* h j� ubj+ )��}�(hhh]�hg)��}�(h�.Set the authentication methods to be supported�h]�hJ�.Set the authentication methods to be supported�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j� ubah}�(h]�h]�h]�h]�h]�uhj* h j� ubeh}�(h]�h]�h]�h]�h]�uhj% h j| ubj& )��}�(hhh]�(j+ )��}�(hhh]�hg)��}�(h�MFA_EMAIL_SUBJECT�h]�hJ�MFA_EMAIL_SUBJECT�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j� ubah}�(h]�h]�h]�h]�h]�uhj* h j� ubj+ )��}�(hhh]�hg)��}�(h�A<APP_NAME> - Verification Code e.g. pgAdmin 4 -24Verification Code�h]�hJ�A<APP_NAME> - Verification Code e.g. pgAdmin 4 -25Verification Code�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j ubah}�(h]�h]�h]�h]�h]�uhj* h j� ubeh}�(h]�h]�h]�h]�h]�uhj% h j| ubj& )��}�(hhh]�(j+ )��}�(hhh]�hg)��}�(h�MFA_FORCE_REGISTRATION�h]�hJ�MFA_FORCE_REGISTRATION�����}�(h j8 h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh j5 ubah}�(h]�h]�h]�h]�h]�uhj* h j2 ubj+ )��}�(hhh]�hg)��}�(h�lForce the user to configure the authentication26method on login (if no authentication is already configured).�h]�hJ�lForce the user to configure the authentication27method on login (if no authentication is already configured).�����}�(h jO h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhfh"h#hKh jL ubah}�(h]�h]�h]�h]�h]�uhj* h j2 ubeh}�(h]�h]�h]�h]�h]�uhj% h j| ubeh}�(h]�h]�h]�h]�h]�uhjz h j ubeh}�(h]�h]�h]�h]�h]��cols�Kuhj h j ubah}�(h]�h]�(�colwidths-given�� longtable�eh]�h]�h]�uhj h h~h!hh"h#hNubhg)��}�(h��*NOTE: You must set the 'Mail server settings' in config_local.py or28config_system.py in order to use 'email' as two-factor authentication method29(see the* :ref:`config.py <config_py>` *documentation).*�h]�(h�)��}�(h��*NOTE: You must set the 'Mail server settings' in config_local.py or30config_system.py in order to use 'email' as two-factor authentication method31(see the*�h]�hJ��NOTE: You must set the ‘Mail server settings’ in config_local.py or32config_system.py in order to use ‘email’ as two-factor authentication method33(see the�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h j~ ubhJ� �����}�(h j~ h!hh"NhNubh�)��}�(h�:ref:`config.py <config_py>`�h]�h�)��}�(hj� h]�hJ� config.py�����}�(h j� h!hh"NhNubah}�(h]�h]�(hόstd��std-ref�eh]�h]�h]�uhh�h j� ubah}�(h]�h]�h]�h]�h]��refdoc�h܌ refdomain�j� �reftype��ref��refexplicit���refwarn��h� config_py�uhh�h"h#hK$h j~ ubhJ� �����}�h j~ sbh�)��}�(h�*documentation).*�h]�hJ�documentation).�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h j~ ubeh}�(h]�h]�h]�h]�h]�uhhfh"h#hK$h h~h!hubeh}�(h]��setup-two-factor-authentication�ah]�h]��setup two-factor authentication�ah]�h]�uhh$h h&h!hh"h#hKubh%)��}�(hhh]�(h*)��}�(h�#Configure two-factor authentication�h]�hJ�#Configure two-factor authentication�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h j� h!hh"h#hK*ubhg)��}�(hX� To configure 2FA for a user, you must click on 'Two-factor Authentication'34in the `User` menu in right-top corner. It will list down all the supported35multi factor authentication methods. Click on 'Setup' of one of those methods36and follow the steps for each authentication method. You will see the `Delete`37button for the authentication method, which is already been configured.38Clicking on `Delete` button will deregister the authentication method for the39current user.�h]�(hJ�VTo configure 2FA for a user, you must click on ‘Two-factor Authentication’40in the �����}�(h j� h!hh"NhNubh �title_reference���)��}�(h�`User`�h]�hJ�User�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhj� h j� ubhJ�� menu in right-top corner. It will list down all the supported41multi factor authentication methods. Click on ‘Setup’ of one of those methods42and follow the steps for each authentication method. You will see the �����}�(h j� h!hh"NhNubj� )��}�(h�`Delete`�h]�hJ�Delete�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhj� h j� ubhJ�U43button for the authentication method, which is already been configured.44Clicking on �����}�(h j� h!hh"NhNubj� )��}�(h�`Delete`�h]�hJ�Delete�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhj� h j� ubhJ�G button will deregister the authentication method for the45current user.�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhfh"h#hK+h j� h!hubh �image���)��}�(h�h.. image:: images/mfa_registration.png46 :alt: Configure two-factor authentication47 :align: center48�h]�h}�(h]�h]�h]�h]�h]��alt��#Configure two-factor authentication��align��center��uri��images/mfa_registration.png��49candidates�}��*�j< suhj+ h"h#hK3h j� h!hubhg)��}�(h��You can also force users to configure the two-factor50authentication methods on login by setting *MFA_FORCE_REGISTRATION* parameter51to *True*.�h]�(hJ�`You can also force users to configure the two-factor52authentication methods on login by setting �����}�(h j@ h!hh"NhNubh�)��}�(h�*MFA_FORCE_REGISTRATION*�h]�hJ�MFA_FORCE_REGISTRATION�����}�(h jH h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h j@ ubhJ� parameter53to �����}�(h j@ h!hh"NhNubh�)��}�(h�*True*�h]�hJ�True�����}�(h jZ h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh�h j@ ubhJ�.�����}�(h j@ h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhfh"h#hK7h j� h!hubeh}�(h]��#configure-two-factor-authentication�ah]�h]��#configure two-factor authentication�ah]�h]�uhh$h h&h!hh"h#hK*ubeh}�(h]�(�&enabling-two-factor-authentication-2fa�heh]�h]�(�(enabling two-factor authentication (2fa)��mfa�eh]�h]�uhh$h hh!hh"h#hK�expect_referenced_by_name�}�j� hs�expect_referenced_by_id�}�hhsubeh}�(h]�h]�h]�h]�h]��source�h#�translation_progress�}�(�total�K �54translated�K uuhh�current_source�N�current_line�N�settings��docutils.frontend��Values���)��}�(�output�Nh)N� generator�N� datestamp�N�root_prefix��/��source_link�N�55source_url�N�
toc_backlinks�j* �footnote_backlinks���
sectnum_xform���strip_comments�N�strip_elements_with_classes�N�
strip_classes�N�report_level�K�56halt_level�K�exit_status_level�K�debug�N�warning_stream�N� traceback���input_encoding�� utf-8-sig��input_encoding_error_handler��strict��output_encoding��utf-8��output_encoding_error_handler�j� �error_encoding��cp1252��error_encoding_error_handler��backslashreplace��
language_code��en��record_dependencies�N�config�N� id_prefix�h�auto_id_prefix��id��
dump_settings�N�dump_internals�N�dump_transforms�N�dump_pseudo_xml�N�expose_internals�N�strict_visitor�N�_disable_config�N�_source�h#�_destination�N�
_config_files�]��file_insertion_enabled���raw_enabled�K�line_length_limit�M'�pep_references�N�pep_base_url��https://peps.python.org/��pep_file_url_template��pep-%04d��rfc_references�N�rfc_base_url��&https://datatracker.ietf.org/doc/html/�� tab_width�K�trim_footnote_reference_space���syntax_highlight��long��smart_quotes���smartquotes_locales�]��character_level_inline_markup���doctitle_xform���
docinfo_xform���sectsubtitle_xform���
image_loading��link��embed_stylesheet���cloak_email_addresses���section_self_link���env�Nub�reporter�N�indirect_targets�]��substitution_defs�}��substitution_names�}��refnames�}��refids�}�h]�has�nameids�}�(j� hj j| h{hxj� j� jw jt u� nametypes�}�(j� �j �h{�j� �jw �uh}�(hh&j| h&hxhUj� h~jt j� u�
footnote_refs�}��
citation_refs�}��
autofootnotes�]��autofootnote_refs�]��symbol_footnotes�]��symbol_footnote_refs�]�� footnotes�]�� citations�]��autofootnote_start�K�symbol_footnote_start�K �57id_counter��collections��Counter���}���R��parse_messages�]��transform_messages�]�(h �system_message���)��}�(hhh]�hg)��}�(hhh]�hJ�)Hyperlink target "mfa" is not referenced.�����}�h j sbah}�(h]�h]�h]�h]�h]�uhhfh j ubah}�(h]�h]�h]�h]�h]��level�K�type��INFO��source�h#�line�Kuhj ubj )��}�(hhh]�hg)��}�(hhh]�hJ�-Hyperlink target "index-0" is not referenced.�����}�h j4 sbah}�(h]�h]�h]�h]�h]�uhhfh j1 ubah}�(h]�h]�h]�h]�h]��level�K�type�j. �source�h#�line�Kuhj ube�transformer�N�include_log�]��58decoration�Nh!hub.