gog / recaptcha-firewall
Installs: 5 255
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 11
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- google/recaptcha: ^1.1
- symfony/config: ~2.3
- symfony/dependency-injection: ~2.3
- symfony/event-dispatcher: ~2.3
- symfony/http-kernel: ~2.3
- symfony/yaml: ~2.3
This package is not auto-updated.
Last update: 2018-05-15 00:51:09 UTC
README
Simple component for securing routes by adding ReCaptcha validation to it.
Installation
Install with composer:
$ composer require gog/recaptcha-firewall
Then register the bundle in the AppKernel.php
file:
public function registerBundles() { $bundles = array( // ... new GOG\Security\RecaptchaFirewall\Bundle\GOGSecurityRecaptchaFirewallBundle(), // ... ); return $bundles; }
Configuration
Simply configure bundle by adding below lines to your config.yml
.
gog_security_recaptcha_firewall: secret: your_secret site_key: your_site_key routes: - route_name1 - route_name2
How it works?
Every route added to configuration tree will be checked for valid g-recaptcha-response
token.
If validation fails, you will receive a 403 JSON response on checked route.