Getting Started
This is a crisp and precise integration guide that will facilitate the integration of ShieldSquare - Real-time Bot Management Solution for Web Apps, Mobile & APIs at the application level using our Ruby on Rails SDK. Please login and download the connectors from here
Info |
---|
PrerequisitesRuby version >=2.0andRails>=3 |
Integrating ShieldSquare in Monitor Mode
...
Parameter | Description | Type | Required |
---|---|---|---|
_sid | This holds the subscriber id of the user, and can be obtained by clicking on the Subscriber id details link on the dashboard. Choose Sandbox Id as you are integrating for the very first time Important Note: Sandbox ID is meant for only testing and verification purposes and requests sent using this ID will not be persisted by ShieldSquare Service. | Alphanumeric | Yes |
_mode | Sets the mode of the operation depending on the mode of activation. Set value to ‘Monitor’ in this case. | String | Yes |
_async_http_post | This Boolean parameter is used to post the data asynchronously. In the Monitor mode, this has to be set as ‘true’. | Boolean | Yes |
_timeout_value | This parameter indicates the time limit after which an API call has to be timed out. No synchronous API call would block for more than the value specified to this parameter. | A numeric value (measured in milliseconds) | Yes |
_ipaddress | This is set to the HTTP header which indicates the IP address of the user. The default value is “auto”. | String | Yes |
_js_url | Set the _js_url to relative URL at which the “getData” file has been placed on the site. This file will collect the JavaScript data send it to the ShieldSquare site. You can find the getData file in the downloaded connector folder. Quick Tip:Relative path of “www.example.com/ShieldSquare/getData” is “/ShieldSquare/getData”. The simplest solution to work around this complexity is to place all the connector files in the root folder and set the _js_url parameter to “/getData”. Important Note:This parameter is only used for backward compatibility. Kindly ignore. | String | Yes |
_ss2_domain | Select the ShieldSquare server closest to the website’s server and assign it to the _ss2_domain property. Available options are:
| String | Yes |
_domain_cache_file | This parameter is the path to a cache file which stores the resolved IP of the _ss2_domain. The default path is "/tmp/" | String | No |
_domain_ttl | This parameter indicates the time after which _domain_cache_file is reloaded. The default time is 3600 seconds | Numeric value (measured in seconds) | No |
_deployment_number | Identifier denoting different families of configuration settings in your servers | String | Yes |
...
Go to 'Download Connectors' page and switch to 'JS Tag' tab to find your customized JS.
Integrate the JS in the starting of head section of web pages protected by ShieldSquare to ensure JS Tag executes immediately after the page loads. This will facilitate ShieldSquare to catch sophisticated bots.
Info |
---|
NoteBoth the aforementioned code snippets (API & JS) need to be executed from the every page of the website. It is therefore mandatory to include both the snippets in the common header file. |
...