5 Commits

Author SHA1 Message Date
3f21276ec5 Merge pull request 'Update README.md.' (#3) from develop into main
Reviewed-on: #3
2023-12-13 23:28:38 +06:00
01153867b3 Update README.md.
Fixed link to JavaScript GUI repository.
2023-12-13 23:27:45 +06:00
c3bfd4f920 Merge pull request 'Версия 0.7.1.' (#2) from develop into main
Reviewed-on: #2
2023-12-09 00:59:41 +06:00
172a9460df Fix https on prod.
Added the force_https parameter to env APP_FORCE_HTTPS. This will force https to be enabled.
2023-12-09 00:55:56 +06:00
a5ba9eb3f8 I added (int) to the configuration in the parameters, where we get the numbers through the env function. 2023-12-09 00:54:12 +06:00
6 changed files with 16 additions and 7 deletions

View File

@@ -4,6 +4,8 @@ APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost
APP_FORCE_HTTPS=false
APP_DEMO_MODE=false
APP_DEMO_EMAIL=
APP_DEMO_PASSWORD=

View File

@@ -23,7 +23,7 @@ Email: demo@tut-site.net
https://captcha-admin-demo.tut-site.net/api-docs/
## Javascript клиент для сайта
https://git.kor-elf.net/kor-elf/captcha-rule-for-laravel
https://git.kor-elf.net/kor-elf/service-captcha-gui
## Как проверять со стороны бэкенда
Для Laravel 10 есть готовый пакет: https://git.kor-elf.net/kor-elf/captcha-rule-for-laravel

View File

@@ -22,6 +22,7 @@ use App\Services\Search\Search;
use Illuminate\Contracts\Foundation\Application;
use Illuminate\Pagination\Paginator;
use Illuminate\Support\Facades\Blade;
use Illuminate\Support\Facades\URL;
use Illuminate\Support\ServiceProvider;
use Illuminate\Validation\Rules\Password;
@@ -70,6 +71,10 @@ final class AppServiceProvider extends ServiceProvider
return Helpers::isDemoMode();
});
if (config('app.force_https') === true) {
URL::forceScheme('https');
}
Password::defaults(function () {
$rule = Password::min(8);

View File

@@ -70,6 +70,8 @@ return [
'asset_url' => env('ASSET_URL'),
'force_https' => (bool) env('APP_FORCE_HTTPS', false),
/*
|--------------------------------------------------------------------------
| Application Timezone

View File

@@ -1,10 +1,10 @@
<?php
return [
'waiting_for_captcha_verification_in_seconds' => env('WAITING_FOR_CAPTCHA_VERIFICATION_IN_SECONDS', 900),
'validate_max_count_errors' => env('CAPTCHA_VALIDATE_MAX_COUNT_ERRORS', 3),
'max_info_display_count' => env('CAPTCHA_MAX_INFO_DISPLAY_COUNT', 1),
'verification_data_view_limit_in_minutes' => env('CAPTCHA_VERIFICATION_DATA_VIEW_LIMIT_IN_MINUTES', 60),
'waiting_for_captcha_verification_in_seconds' => (int) env('WAITING_FOR_CAPTCHA_VERIFICATION_IN_SECONDS', 900),
'validate_max_count_errors' => (int) env('CAPTCHA_VALIDATE_MAX_COUNT_ERRORS', 3),
'max_info_display_count' => (int) env('CAPTCHA_MAX_INFO_DISPLAY_COUNT', 1),
'verification_data_view_limit_in_minutes' => (int) env('CAPTCHA_VERIFICATION_DATA_VIEW_LIMIT_IN_MINUTES', 60),
'imageClass' => \App\Captcha\Images\Image::class,
'types' => [
'string' => [

View File

@@ -3,6 +3,6 @@ return [
/**
* Max limit of the hour.
*/
'login_max_request' => env('LOGIN_MAX_REQUEST', 50),
'login_max_email_request' => env('LOGIN_MAX_EMAIL_REQUEST', 10),
'login_max_request' => (int) env('LOGIN_MAX_REQUEST', 50),
'login_max_email_request' => (int) env('LOGIN_MAX_EMAIL_REQUEST', 10),
];