From d020b4fcc878dee59b3fbe4d14ec755169c74729 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:17:39 +0800 Subject: [PATCH 01/16] Delete recaptcha.php --- config/recaptcha.php | 66 -------------------------------------------- 1 file changed, 66 deletions(-) delete mode 100644 config/recaptcha.php diff --git a/config/recaptcha.php b/config/recaptcha.php deleted file mode 100644 index 049af6d52..000000000 --- a/config/recaptcha.php +++ /dev/null @@ -1,66 +0,0 @@ - env('RECAPTCHA_PUBLIC_KEY', ''), - 'private_key' => env('RECAPTCHA_PRIVATE_KEY', ''), - - /* - |-------------------------------------------------------------------------- - | Template - |-------------------------------------------------------------------------- - | - | Set a template to use if you don't want to use the standard one. - | - */ - 'template' => '', - - /* - |-------------------------------------------------------------------------- - | Driver - |-------------------------------------------------------------------------- - | - | Determine how to call out to get response; values are 'curl' or 'native'. - | Only applies to v2. - | - */ - 'driver' => 'curl', - - /* - |-------------------------------------------------------------------------- - | Options - |-------------------------------------------------------------------------- - | - | Various options for the driver - | - */ - 'options' => [ - - 'curl_timeout' => 1, - 'curl_verify' => true, - - ], - - /* - |-------------------------------------------------------------------------- - | Version - |-------------------------------------------------------------------------- - | - | Set which version of ReCaptcha to use. - | - */ - - 'version' => 2, - -]; From 64c7a8ceaee376ab74ddb320d2f5aa73c67aff66 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:19:35 +0800 Subject: [PATCH 02/16] Update FederationController.php --- app/Http/Controllers/FederationController.php | 1 - 1 file changed, 1 deletion(-) diff --git a/app/Http/Controllers/FederationController.php b/app/Http/Controllers/FederationController.php index ccba79d20..b6918fc42 100644 --- a/app/Http/Controllers/FederationController.php +++ b/app/Http/Controllers/FederationController.php @@ -118,7 +118,6 @@ class FederationController extends Controller 'homepage' => 'https://pixelfed.org', 'repo' => 'https://github.com/pixelfed/pixelfed', ], - 'captcha' => (bool) config('pixelfed.recaptcha'), ], 'protocols' => [ 'activitypub', From 7953be29fe23793850a47c434a986b4687f5c939 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:20:26 +0800 Subject: [PATCH 03/16] Update LoginController.php --- app/Http/Controllers/Auth/LoginController.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/Http/Controllers/Auth/LoginController.php b/app/Http/Controllers/Auth/LoginController.php index 6cea5e8a3..c47bf9ab7 100644 --- a/app/Http/Controllers/Auth/LoginController.php +++ b/app/Http/Controllers/Auth/LoginController.php @@ -53,10 +53,6 @@ class LoginController extends Controller 'password' => 'required|string|min:6', ]; - if (config('pixelfed.recaptcha')) { - $rules['g-recaptcha-response'] = 'required|recaptcha'; - } - $this->validate($request, $rules); } From b2e79b9bc63b705018dd10f1198e06906662c2e5 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:21:55 +0800 Subject: [PATCH 04/16] Update pixelfed.php --- config/pixelfed.php | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/config/pixelfed.php b/config/pixelfed.php index 10df33777..2e1286536 100644 --- a/config/pixelfed.php +++ b/config/pixelfed.php @@ -74,15 +74,15 @@ return [ /* |-------------------------------------------------------------------------- - | Enable Google Recaptcha v2 + | ActivityPud |-------------------------------------------------------------------------- | - | Enable/disable recaptcha on login/registration forms. API Keys required. - | */ - 'recaptcha' => env('RECAPTCHA_ENABLED', false), - - + 'ap_inbox' => env('ACTIVITYPUB_INBOX', false), + 'ap_shared' => env('ACTIVITYPUB_SHAREDINBOX', false), + 'ap_delivery_timeout' => env('ACTIVITYPUB_DELIVERY_TIMEOUT', 2.0), + 'ap_delivery_concurrency' => env('ACTIVITYPUB_DELIVERY_CONCURRENCY', 10), + 'remote_follow_enabled' => env('REMOTE_FOLLOW', false), 'activitypub_enabled' => env('ACTIVITY_PUB', false), @@ -262,11 +262,6 @@ return [ 'enforce_account_limit' => env('LIMIT_ACCOUNT_SIZE', true), - 'ap_inbox' => env('ACTIVITYPUB_INBOX', false), - 'ap_shared' => env('ACTIVITYPUB_SHAREDINBOX', false), - 'ap_delivery_timeout' => env('ACTIVITYPUB_DELIVERY_TIMEOUT', 2.0), - 'ap_delivery_concurrency' => env('ACTIVITYPUB_DELIVERY_CONCURRENCY', 10), - 'import' => [ 'instagram' => [ 'enabled' => false, From 44b5f91713384e497de8439f3a14d40f53718fb2 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:22:59 +0800 Subject: [PATCH 05/16] Update app.php --- config/app.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/config/app.php b/config/app.php index 5bcac1d35..5aa786fbe 100644 --- a/config/app.php +++ b/config/app.php @@ -150,7 +150,6 @@ return [ /* * Package Service Providers... */ - Greggilbert\Recaptcha\RecaptchaServiceProvider::class, Jackiedo\DotenvEditor\DotenvEditorServiceProvider::class, /* @@ -211,7 +210,6 @@ return [ 'Validator' => Illuminate\Support\Facades\Validator::class, 'View' => Illuminate\Support\Facades\View::class, - 'Recaptcha' => Greggilbert\Recaptcha\Facades\Recaptcha::class, 'DotenvEditor' => Jackiedo\DotenvEditor\Facades\DotenvEditor::class, 'PrettyNumber' => App\Util\Lexer\PrettyNumber::class, 'Purify' => Stevebauman\Purify\Facades\Purify::class, From 24a1b2713f3c272e2555444a72646923de902597 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:24:36 +0800 Subject: [PATCH 06/16] Update general.blade.php --- .../views/admin/settings/config/general.blade.php | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/resources/views/admin/settings/config/general.blade.php b/resources/views/admin/settings/config/general.blade.php index 51597a015..480ec2dad 100644 --- a/resources/views/admin/settings/config/general.blade.php +++ b/resources/views/admin/settings/config/general.blade.php @@ -24,18 +24,6 @@ -
- -
-
- - -

When this option is enabled, new user registration is open.

-
-
-
@@ -100,4 +88,4 @@
- \ No newline at end of file + From d61c48c62b60fe62222e8de01b043b5a4cd44d76 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:25:02 +0800 Subject: [PATCH 07/16] Update RegisterController.php --- app/Http/Controllers/Auth/RegisterController.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/Http/Controllers/Auth/RegisterController.php b/app/Http/Controllers/Auth/RegisterController.php index 4ce5538e9..d40c855dd 100644 --- a/app/Http/Controllers/Auth/RegisterController.php +++ b/app/Http/Controllers/Auth/RegisterController.php @@ -76,10 +76,6 @@ class RegisterController extends Controller 'password' => 'required|string|min:6|confirmed', ]; - if (config('pixelfed.recaptcha')) { - $rules['g-recaptcha-response'] = 'required|recaptcha'; - } - return Validator::make($data, $rules); } From 8ad077ecfaf4c6fcd5294711de95d3f96606774c Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:25:29 +0800 Subject: [PATCH 08/16] Update sudo.blade.php --- resources/views/auth/sudo.blade.php | 6 ------ 1 file changed, 6 deletions(-) diff --git a/resources/views/auth/sudo.blade.php b/resources/views/auth/sudo.blade.php index 79f2917cb..9a253c32a 100644 --- a/resources/views/auth/sudo.blade.php +++ b/resources/views/auth/sudo.blade.php @@ -26,12 +26,6 @@ - @if(config('pixelfed.recaptcha')) -
- {!! Recaptcha::render() !!} -
- @endif -
- @if(config('pixelfed.recaptcha')) -
- {!! Recaptcha::render() !!} -
- @endif -
- @if(config('pixelfed.recaptcha')) -
- {!! Recaptcha::render() !!} -
- @endif -
- - @if(config('pixelfed.recaptcha')) -
- {!! Recaptcha::render() !!} -
- @endif
From d94539a2cb2099797dc5a2f598d11e606f473a05 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:28:10 +0800 Subject: [PATCH 12/16] Update .env.testing --- .env.testing | 1 - 1 file changed, 1 deletion(-) diff --git a/.env.testing b/.env.testing index ef7f69cf1..e28316175 100644 --- a/.env.testing +++ b/.env.testing @@ -41,7 +41,6 @@ API_BASE="/api/1/" API_SEARCH="/api/search" OPEN_REGISTRATION=false -RECAPTCHA_ENABLED=false ENFORCE_EMAIL_VERIFICATION=true MAX_PHOTO_SIZE=15000 From de8a1d47da7d08251bf85332b0e2bdf09520bb66 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:28:32 +0800 Subject: [PATCH 13/16] Update .env.example --- .env.example | 1 - 1 file changed, 1 deletion(-) diff --git a/.env.example b/.env.example index 725299e28..335af878e 100644 --- a/.env.example +++ b/.env.example @@ -42,7 +42,6 @@ API_BASE="/api/1/" API_SEARCH="/api/search" OPEN_REGISTRATION=true -RECAPTCHA_ENABLED=false ENFORCE_EMAIL_VERIFICATION=true MAX_PHOTO_SIZE=15000 From 1f3f17c51e683bb2ff888bf1e233e1be1ef09acd Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:29:02 +0800 Subject: [PATCH 14/16] Update index.blade.php --- resources/views/site/index.blade.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/resources/views/site/index.blade.php b/resources/views/site/index.blade.php index ebe13c1f2..6c2ec894e 100644 --- a/resources/views/site/index.blade.php +++ b/resources/views/site/index.blade.php @@ -140,11 +140,6 @@
- @if(config('pixelfed.recaptcha')) -
- {!! Recaptcha::render() !!} -
- @endif
- \ No newline at end of file + From 9b03c30d6fc14a327f15eb548757bccebaecadc6 Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 15:29:32 +0800 Subject: [PATCH 15/16] Update composer.json --- composer.json | 1 - 1 file changed, 1 deletion(-) diff --git a/composer.json b/composer.json index 9d942579a..0e7e1e844 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,6 @@ "beyondcode/laravel-self-diagnosis": "^1.0.2", "doctrine/dbal": "^2.7", "fideloper/proxy": "^4.0", - "greggilbert/recaptcha": "dev-master", "intervention/image": "^2.4", "jenssegers/agent": "^2.6", "laravel/framework": "5.8.*", From a50a8b1cf6c1bde611f364e1f38c1f31ef8417cb Mon Sep 17 00:00:00 2001 From: Shleeble Date: Tue, 30 Apr 2019 18:07:49 +0800 Subject: [PATCH 16/16] Update pixelfed.php --- config/pixelfed.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/pixelfed.php b/config/pixelfed.php index 2e1286536..b9156cd56 100644 --- a/config/pixelfed.php +++ b/config/pixelfed.php @@ -74,7 +74,7 @@ return [ /* |-------------------------------------------------------------------------- - | ActivityPud + | ActivityPub |-------------------------------------------------------------------------- | */