Skip to main content

Reporting via our API

(0 comments)

Reporting is a fact of life. And to be honest, good reporting is good for security. In this post, we will take a look at the reports you can generate via the wAuth API to help monitor and manage your two-factor authentication installation.

The first report is the user report:

<%

    if (request.getParameter("action") != null && request.getParameter("action").equalsIgnoreCase("Get User Report")) {
        ReportDataTransaction.Separator separator;
        if("comma".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.COMMA;
        } else if("tab".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.TAB;
        } else {
            separator = ReportDataTransaction.Separator.XML;
        }
        status = wc.getUserReport(separator,request.getParameter("includeDisabledUsers")!=null, request.getParameter("includeTokenData")!=null);
    }

%>

The XML looks like (note that the XML needs to be on one line, it is edited for presentation):

<transaction>
<type>12</type>
<data dataType="USER" separator=",">
<options>
<includeDisabledUsers>true</includeDisabledUsers>
<includeTokenData>true</includeTokenData>
<groupUserData>false</groupUserData>
<includeDisabledDevices>false</includeDisabledDevices>
<includeUnregistered>false</includeUnregistered>
</options>
</data>
</transaction>

The report is available in comma delimited, tab delimited and XML.

username,badPasscodes,userCreation,userStatus,tokenDeviceID,tokenStatus,badPINs,tokenExpiration,tokenCreation,domainCode,domainName,deviceDomainName 

This report will show you users that are perhaps in danger of getting disabled for bad passcode attempts (ie, bad logins) or bad PIN attempts.

If you run multiple domains, you may want a report based on domains:

<%

    if (request.getParameter("action") != null && request.getParameter("action").equalsIgnoreCase("Get Domain Report")) {
        ReportDataTransaction.Separator separator;
        if("comma".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.COMMA;
        } else if("tab".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.TAB;
        } else {
            separator = ReportDataTransaction.Separator.XML;
        }
        status = wc.getDomainReport(separator, request.getParameter("groupUserData") != null);
    }

%>

This report shows the following information:

 domainName,domainCode,deviceDomainName,userName,tokenDeviceID 

Each user can have more than one token/device. You can generate a report of your two-factor authentication users based on their tokens:

<%

    if (request.getParameter("action") != null && request.getParameter("action").equalsIgnoreCase("Get Device Report")) {
        ReportDataTransaction.Separator separator;
        if("comma".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.COMMA;
        } else if("tab".equals(request.getParameter("separator"))){
            separator = ReportDataTransaction.Separator.TAB;
        } else {
            separator = ReportDataTransaction.Separator.XML;
        }
        status = wc.getDeviceReport(separator, request.getParameter("includeDisabledDevices") != null, request.getParameter("includeUnregistered") != null);
    }

%>

The output:

deviceid,username,badPINs,tokenStatus,tokenExpiration,tokenCreation,domainCodedomainName,deviceDomainName 

If you have any additional reporting needs, please let us know!

Currently unrated

Comments

There are currently no comments

New Comment

required

required (not published)

optional

Recent Posts

Archive

2018
2017
2016
2015
2014
2013
2012
2011
2010
2009
2008

Categories

Tags

Authors

Feeds

RSS / Atom