Closed PSTDylan closed 1 year ago
Hello @tanveery! Could you please watch this PR and merge it? It is very necessary and relevant. Thanks!
55 and #54 are related. I see the other solution for this was closed, but this PR allows either source.
Yes, it would be great to solve this problem.
With these changes, one may optionally add RecaptchaApiSource to Web.config to override the default url used to fetch google's reCAPTCHA resources:
By using the above, the package will use https://www.recaptcha.net/recaptcha/api.js and https://www.recaptcha.net/recaptcha/api/siteverify rather than https://www.google.com/recaptcha/api.js and https://www.google.com/recaptcha/api/siteverify
If RecaptchaApiSource is not specified, the default is www.google.com/recaptcha.
These changes are required to allow access to users who are unable to request resources from google.com domains, as is the case for many users in China. By editing one's host file ("C:\Windows\System32\drivers\etc\hosts") to include the following, it can be tested that the reCAPTCHA widget with RecaptchaApiSource overridden works without access to google.com:
127.0.0.1 google.com www.google.com