NAME
WebService::CastleIO - Castle.io API client
VERSION
Version 1.03
SYNOPSIS
Castle detects and mitigates account takeover in web and mobile apps. This is a third party API client built for the Castle.io API.
CONFIGURATION
use WebService::CastleIO;
my $castle = WebService::CastleIO->new(
api_secret => 'sRq3Zmzpxwu6eDXiYCFB3xyfi4ZnVjnn',
cookie_id => 'abcd',
ip_address => '24.61.128.172',
headers => JSON->new->allow_nonref->utf8->encode({'User-Agent' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:54.0) Gecko/20100101 Firefox/54.0'}),
source => 'backend',
debug => 1
);
SUBROUTINES/METHODS
track
Track lets you record security-related actions your users perform. Events are processed asynchronously to return as quickly as possible.
my $event_result = $castle->track(
data => {user_id => 'dummy', name => '$login.succeeded', properties => {threat => 'Large', whatever => 'made up'}}
);
authenticate
Authenticate is processed synchronous and returns returns an action of the types approve, challenge or deny.
my $auth_result = $castle->authenticate(
data => {user_id => 'dummywriter', name => '$login.succeeded'},
);
identify
User updates are processed asynchronously to return as quickly as possible.
my $identify_result = $castle->identify(
data => {user_id => 'dummywriter', traits => {'foo' => 'bar'}},
);
review
Reviews lets you fetch the context for a user to review anomalous account activity.
my $reviews_result = $castle->review(review_id => 12356789);
_call
Private method that makes call to API web service.
_client_user_agent
Private method to return user agent.
_json_to_object
Private method that converts JSON result to object
AUTHOR
Dino Simone, <dino at simone.is>
BUGS
Please report any bugs or feature requests to bug-webservice-castleio at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WebService-CastleIO. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc WebService::CastleIO
You can also look for information at:
RT: CPAN's request tracker (report bugs here)
http://rt.cpan.org/NoAuth/Bugs.html?Dist=WebService-CastleIO
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
LICENSE AND COPYRIGHT
Copyright 2017 Dino Simone - dinosimone.com
This program is distributed under the MIT (X11) License: http://www.opensource.org/licenses/mit-license.php
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.