fortify.php 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. <?php
  2. use App\Providers\RouteServiceProvider;
  3. use Laravel\Fortify\Features;
  4. return [
  5. /*
  6. |--------------------------------------------------------------------------
  7. | Fortify Guard
  8. |--------------------------------------------------------------------------
  9. |
  10. | Here you may specify which authentication guard Fortify will use while
  11. | authenticating users. This value should correspond with one of your
  12. | guards that is already present in your "auth" configuration file.
  13. |
  14. */
  15. 'guard' => 'web',
  16. /*
  17. |--------------------------------------------------------------------------
  18. | Fortify Password Broker
  19. |--------------------------------------------------------------------------
  20. |
  21. | Here you may specify which password broker Fortify can use when a user
  22. | is resetting their password. This configured value should match one
  23. | of your password brokers setup in your "auth" configuration file.
  24. |
  25. */
  26. 'passwords' => 'users',
  27. /*
  28. |--------------------------------------------------------------------------
  29. | Username / Email
  30. |--------------------------------------------------------------------------
  31. |
  32. | This value defines which model attribute should be considered as your
  33. | application's "username" field. Typically, this might be the email
  34. | address of the users but you are free to change this value here.
  35. |
  36. | Out of the box, Fortify expects forgot password and reset password
  37. | requests to have a field named 'email'. If the application uses
  38. | another name for the field you may define it below as needed.
  39. |
  40. */
  41. 'username' => 'email',
  42. 'email' => 'email',
  43. /*
  44. |--------------------------------------------------------------------------
  45. | Home Path
  46. |--------------------------------------------------------------------------
  47. |
  48. | Here you may configure the path where users will get redirected during
  49. | authentication or password reset when the operations are successful
  50. | and the user is authenticated. You are free to change this value.
  51. |
  52. */
  53. 'home' => RouteServiceProvider::HOME,
  54. /*
  55. |--------------------------------------------------------------------------
  56. | Fortify Routes Prefix / Subdomain
  57. |--------------------------------------------------------------------------
  58. |
  59. | Here you may specify which prefix Fortify will assign to all the routes
  60. | that it registers with the application. If necessary, you may change
  61. | subdomain under which all of the Fortify routes will be available.
  62. |
  63. */
  64. 'prefix' => '',
  65. 'domain' => null,
  66. /*
  67. |--------------------------------------------------------------------------
  68. | Fortify Routes Middleware
  69. |--------------------------------------------------------------------------
  70. |
  71. | Here you may specify which middleware Fortify will assign to the routes
  72. | that it registers with the application. If necessary, you may change
  73. | these middleware but typically this provided default is preferred.
  74. |
  75. */
  76. 'middleware' => ['web'],
  77. /*
  78. |--------------------------------------------------------------------------
  79. | Rate Limiting
  80. |--------------------------------------------------------------------------
  81. |
  82. | By default, Fortify will throttle logins to five requests per minute for
  83. | every email and IP address combination. However, if you would like to
  84. | specify a custom rate limiter to call then you may specify it here.
  85. |
  86. */
  87. 'limiters' => [
  88. 'login' => 'login',
  89. 'two-factor' => 'two-factor',
  90. ],
  91. /*
  92. |--------------------------------------------------------------------------
  93. | Register View Routes
  94. |--------------------------------------------------------------------------
  95. |
  96. | Here you may specify if the routes returning views should be disabled as
  97. | you may not need them when building your own application. This may be
  98. | especially true if you're writing a custom single-page application.
  99. |
  100. */
  101. 'views' => true,
  102. /*
  103. |--------------------------------------------------------------------------
  104. | Features
  105. |--------------------------------------------------------------------------
  106. |
  107. | Some of the Fortify features are optional. You may disable the features
  108. | by removing them from this array. You're free to only remove some of
  109. | these features or you can even remove all of these if you need to.
  110. |
  111. */
  112. 'features' => [
  113. Features::registration(),
  114. Features::resetPasswords(),
  115. // Features::emailVerification(),
  116. Features::updateProfileInformation(),
  117. Features::updatePasswords(),
  118. Features::twoFactorAuthentication([
  119. 'confirmPassword' => true,
  120. ]),
  121. ],
  122. ];