two_factor.html 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <title>Two-factor authentication &#8212; phpMyAdmin 4.8.5 documentation</title>
  7. <link rel="stylesheet" href="_static/classic.css" type="text/css" />
  8. <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
  9. <script type="text/javascript">
  10. var DOCUMENTATION_OPTIONS = {
  11. URL_ROOT: './',
  12. VERSION: '4.8.5',
  13. COLLAPSE_INDEX: false,
  14. FILE_SUFFIX: '.html',
  15. HAS_SOURCE: true
  16. };
  17. </script>
  18. <script type="text/javascript" src="_static/jquery.js"></script>
  19. <script type="text/javascript" src="_static/underscore.js"></script>
  20. <script type="text/javascript" src="_static/doctools.js"></script>
  21. <link rel="index" title="Index" href="genindex.html" />
  22. <link rel="search" title="Search" href="search.html" />
  23. <link rel="copyright" title="Copyright" href="copyright.html" />
  24. <link rel="top" title="phpMyAdmin 4.8.5 documentation" href="index.html" />
  25. <link rel="up" title="User Guide" href="user.html" />
  26. <link rel="next" title="Transformations" href="transformations.html" />
  27. <link rel="prev" title="Configuring phpMyAdmin" href="settings.html" />
  28. </head>
  29. <body role="document">
  30. <div class="related" role="navigation" aria-label="related navigation">
  31. <h3>Navigation</h3>
  32. <ul>
  33. <li class="right" style="margin-right: 10px">
  34. <a href="genindex.html" title="General Index"
  35. accesskey="I">index</a></li>
  36. <li class="right" >
  37. <a href="transformations.html" title="Transformations"
  38. accesskey="N">next</a> |</li>
  39. <li class="right" >
  40. <a href="settings.html" title="Configuring phpMyAdmin"
  41. accesskey="P">previous</a> |</li>
  42. <li class="nav-item nav-item-0"><a href="index.html">phpMyAdmin 4.8.5 documentation</a> &#187;</li>
  43. <li class="nav-item nav-item-1"><a href="user.html" accesskey="U">User Guide</a> &#187;</li>
  44. </ul>
  45. </div>
  46. <div class="document">
  47. <div class="documentwrapper">
  48. <div class="bodywrapper">
  49. <div class="body" role="main">
  50. <div class="section" id="two-factor-authentication">
  51. <span id="fa"></span><h1>Two-factor authentication<a class="headerlink" href="#two-factor-authentication" title="Permalink to this headline">¶</a></h1>
  52. <div class="versionadded">
  53. <p><span class="versionmodified">New in version 4.8.0.</span></p>
  54. </div>
  55. <p>Since phpMyAdmin 4.8.0 you can configure two-factor authentication to be
  56. used when logging in. To use this, you first need to configure the
  57. <a class="reference internal" href="setup.html#linked-tables"><span class="std std-ref">phpMyAdmin configuration storage</span></a>. Once this is done, every user can opt-in for second
  58. authentication factor in the <span class="guilabel">Settings</span>.</p>
  59. <p>When running phpMyAdmin from the Git source repository, the dependencies must be installed
  60. manually; the typical way of doing so is with the command:</p>
  61. <div class="highlight-sh"><div class="highlight"><pre><span></span>composer require pragmarx/google2fa bacon/bacon-qr-code
  62. </pre></div>
  63. </div>
  64. <p>Or when using a hardware security key with FIDO U2F:</p>
  65. <div class="highlight-sh"><div class="highlight"><pre><span></span>composer require samyoul/u2f-php-server
  66. </pre></div>
  67. </div>
  68. <div class="section" id="authentication-application-2fa">
  69. <h2>Authentication Application (2FA)<a class="headerlink" href="#authentication-application-2fa" title="Permalink to this headline">¶</a></h2>
  70. <p>Using application for authentication is quite common approach based on HOTP and
  71. <a class="reference external" href="https://en.wikipedia.org/wiki/Time-based_One-time_Password_Algorithm">TOTP</a>.
  72. It is based on transmitting private key from phpMyAdmin to the authentication
  73. application and the application is then able to generate one time codes based
  74. on this key.</p>
  75. <p>There are dozens of applications available for mobile phones to implement these
  76. standards, the most widely used include:</p>
  77. <ul class="simple">
  78. <li><a class="reference external" href="https://freeotp.github.io/">FreeOTP for iOS, Android and Pebble</a></li>
  79. <li><a class="reference external" href="https://authy.com/">Authy for iOS, Android, Chrome, OS X</a></li>
  80. <li><a class="reference external" href="https://itunes.apple.com/us/app/google-authenticator/id388497605">Google Authenticator for iOS</a></li>
  81. <li><a class="reference external" href="https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2">Google Authenticator for Android</a></li>
  82. <li><a class="reference external" href="https://lastpass.com/auth/">LastPass Authenticator for iOS, Android, OS X, Windows</a></li>
  83. </ul>
  84. </div>
  85. <div class="section" id="hardware-security-key-fido-u2f">
  86. <h2>Hardware Security Key (FIDO U2F)<a class="headerlink" href="#hardware-security-key-fido-u2f" title="Permalink to this headline">¶</a></h2>
  87. <p>Using hardware tokens is considered to be more secure than software based
  88. solution. phpMyAdmin supports <a class="reference external" href="https://en.wikipedia.org/wiki/Universal_2nd_Factor">FIDO U2F</a>
  89. tokens.</p>
  90. <p>There are several manufacturers of these tokens, for example:</p>
  91. <ul class="simple">
  92. <li><a class="reference external" href="https://www.yubico.com/solutions/fido-u2f/">youbico FIDO U2F Security Key</a></li>
  93. <li><a class="reference external" href="https://www.hypersecu.com/products/hyperfido">HyperFIDO</a></li>
  94. <li><a class="reference external" href="https://shop.trezor.io?a=572b241135e1">TREZOR Bitcoin wallet</a> can <a class="reference external" href="https://doc.satoshilabs.com/trezor-user/u2f.html">act as an U2F token</a></li>
  95. </ul>
  96. </div>
  97. <div class="section" id="simple-two-factor-authentication">
  98. <span id="simple2fa"></span><h2>Simple two-factor authentication<a class="headerlink" href="#simple-two-factor-authentication" title="Permalink to this headline">¶</a></h2>
  99. <p>This authentication is included for testing and demostration purposes only as
  100. it really does not provide two-factor authentication, it just asks user to confirm login by
  101. clicking on the button.</p>
  102. <p>It should not be used in the production and is disabled unless
  103. <span class="target" id="index-0"></span><a class="reference internal" href="config.html#cfg_DBG_simple2fa"><code class="xref config config-option docutils literal"><span class="pre">$cfg['DBG']['simple2fa']</span></code></a> is set.</p>
  104. </div>
  105. </div>
  106. </div>
  107. </div>
  108. </div>
  109. <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
  110. <div class="sphinxsidebarwrapper">
  111. <h3><a href="index.html">Table Of Contents</a></h3>
  112. <ul>
  113. <li><a class="reference internal" href="#">Two-factor authentication</a><ul>
  114. <li><a class="reference internal" href="#authentication-application-2fa">Authentication Application (2FA)</a></li>
  115. <li><a class="reference internal" href="#hardware-security-key-fido-u2f">Hardware Security Key (FIDO U2F)</a></li>
  116. <li><a class="reference internal" href="#simple-two-factor-authentication">Simple two-factor authentication</a></li>
  117. </ul>
  118. </li>
  119. </ul>
  120. <h4>Previous topic</h4>
  121. <p class="topless"><a href="settings.html"
  122. title="previous chapter">Configuring phpMyAdmin</a></p>
  123. <h4>Next topic</h4>
  124. <p class="topless"><a href="transformations.html"
  125. title="next chapter">Transformations</a></p>
  126. <div role="note" aria-label="source link">
  127. <h3>This Page</h3>
  128. <ul class="this-page-menu">
  129. <li><a href="_sources/two_factor.txt"
  130. rel="nofollow">Show Source</a></li>
  131. </ul>
  132. </div>
  133. <div id="searchbox" style="display: none" role="search">
  134. <h3>Quick search</h3>
  135. <form class="search" action="search.html" method="get">
  136. <div><input type="text" name="q" /></div>
  137. <div><input type="submit" value="Go" /></div>
  138. <input type="hidden" name="check_keywords" value="yes" />
  139. <input type="hidden" name="area" value="default" />
  140. </form>
  141. </div>
  142. <script type="text/javascript">$('#searchbox').show(0);</script>
  143. </div>
  144. </div>
  145. <div class="clearer"></div>
  146. </div>
  147. <div class="related" role="navigation" aria-label="related navigation">
  148. <h3>Navigation</h3>
  149. <ul>
  150. <li class="right" style="margin-right: 10px">
  151. <a href="genindex.html" title="General Index"
  152. >index</a></li>
  153. <li class="right" >
  154. <a href="transformations.html" title="Transformations"
  155. >next</a> |</li>
  156. <li class="right" >
  157. <a href="settings.html" title="Configuring phpMyAdmin"
  158. >previous</a> |</li>
  159. <li class="nav-item nav-item-0"><a href="index.html">phpMyAdmin 4.8.5 documentation</a> &#187;</li>
  160. <li class="nav-item nav-item-1"><a href="user.html" >User Guide</a> &#187;</li>
  161. </ul>
  162. </div>
  163. <div class="footer" role="contentinfo">
  164. &#169; <a href="copyright.html">Copyright</a> 2012 - 2018, The phpMyAdmin devel team.
  165. Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.4.9.
  166. </div>
  167. </body>
  168. </html>