Closed flowbru closed 3 years ago
That usually means your secret is not set correctly.
Please check that you are passing the full key in the right format as retrieved from https://www.google.com/recaptcha/admin#list
That error occurs, according to https://developers.google.com/recaptcha/docs/verify
The secret parameter is invalid or malformed.
If you are sure that secret is correct, then try to run php artisan config:clear
and php artisan cache:clear
to cleanup caches, sometimes env data might get cached so no secret is provided.
Can you check above things? if not, i will take a further investigation.
Hi Ryan! Thanks for your fast response! It seems that the problem was the config cache... So thanks alot that solved my problem. And sorry for that,,,
Hi there,
I'm trying to use the vue component in my register from.
I have added my keys to .env file
RECAPTCHA_V3_SECRET_KEY=XXX RECAPTCHA_V3_SITE_KEY=XX
I have published the vue component as described in the installation docu.
I have added the rule to my RegisterUserRequest.php ` use TimeHunter\LaravelGoogleReCaptchaV3\Validations\GoogleReCaptchaV3ValidationRule; ...
public function rules() { return [ 'name' => 'required|string|max:255', 'email' => 'required|string|email|max:255|unique:users', 'password' => 'required|string|min:8|confirmed', 'gRecaptchaResponse' => ['required', new GoogleReCaptchaV3ValidationRule('sign_up')] ]; } `
I have imported and added the component to my form. ` <google-re-captcha-v3 v-model="registerForm.gRecaptchaResponse" ref="captcha" site-key="XXX" id="sign_up_id" inline action="sign_up"
And I have double checked if the sitekey and secret keys are correct.
The badge gets displayed correctly. the v-model gRecaptchaResponse has a pretty long string inside. But when I submit the form I get an error response with the message gRecaptchaResponse: ["invalid-input-secret"].
What could be the cause of that problem?