Symantec Access Management

  • 1.  How to create a custom SMS Provider for CA Strong Authentication?

    Posted Jan 02, 2018 11:02 AM

    Hi,

    I'm trying to send  OTP over SMS using our enterprise SMS gateway.  I cant find clear instructions how to replace the existing Clickatell SMS Provider used by AFM. The documentation says to implement com.arcot.integrations.frontend.SMSService, but where is Java Docs for this interface, how to deploy a new provider, how to pass custom parameters there?

     

    Thanks,

    Vlad



  • 2.  Re: How to create a custom SMS Provider for CA Strong Authentication?

    Posted Jan 05, 2018 02:29 AM

    Clickatell SMS Provider used by AFM leverages Clickatell's HTTP interface. This may work for those providers who has HTTP interface and accepts same parameters. I would recommend to write your own implementation class and replace it with the existing one.



  • 3.  Re: How to create a custom SMS Provider for CA Strong Authentication?
    Best Answer

    Posted Jan 08, 2018 01:15 AM

    Hi,

     

    Please find details below.

    To use custom SMS provider you would need to implement interface : com.arcot.integrations.frontend.SMSService

     

    Methods in the interface:

     

    1. public void init(Map<String, String> initParams) throws Adapter Exception:
    Explanation: This method is called after creating an instance of User specific Class.In this method, user can provide any validation before sending SMS.
    For eg: We can provide a check to validate various configuration details provided in the property file like SMS-URL, APP-ID and others.

    2. public boolean validatePhoneNumber(String phone Number):
    Explanation: This method is used to validate phone number. User can provide his own validations like how many digits phone number should have and any other he want. Return true if we don’t want to validate the number.

    3. public void sendSMS(SMS smsData) throws AdapterException:
    Explanation: This method is used to send the SMS to the end user.
    In this method,User will encode all the details like username,textmessage and other details(details specific to service provider) and send that to the output-stream of the POST-URL/API.In order to validate,we can read the response again from the POST-URL/API and check whether message is sent successfully or not.

    Note:
    For throwing any exception create an object of AceNoticeCode inside the class and throw the exception.
    For eg: Following Code Snippet is used to throw an exception if POSTURL is null.
    public final static AceNoticeCode SMS_MISSING_POST_URL
    = new AceNoticeCode (Code, Message);
    If (postUrl == null) {
    throw new AdapterException (
    SMS_MISSING_POST_URL, ErrorMessage);
    }

     

    Instructions for configuring SMS Service in the properties file:

    1. Open arcotafm.properties present in <ARCOT_HOME>/conf/afm.
    2. Under SMS Service Gateway Configuration present in arcotafm.properties, provide the following details for SMS Class:
    sms.service.impl=com.arcot.integrations.frontend. MySMSService
    3. Provide the configuration details related to your Service Provider:
    For eg: sms.service.url=SMS_POST_URL
    sms.service.api.id=SMS_APP_ID
    Note: We can add and remove these parameters depending upon SMS Service Provider.
    4. Restart the APP_SERVER.

     

    Regards,

    Ujwol



  • 4.  Re: How to create a custom SMS Provider for CA Strong Authentication?

    Posted Jan 11, 2018 10:46 AM

    Hi Ujwol,

    A great answer. I was able to implement my own OTP over SMS Provider. It also required me to do some reverse engineering of CA code to understand what each class in dependency is doing. I believe this part of customization  should be documented in an SDK and corresponding Java docs.

    Another thing I discovered, every time AFM wizard is used it rewrites providers implementation classes in arcotafm.properties file back to default ones.

     

    Regards,

    Vlad



  • 5.  Re: How to create a custom SMS Provider for CA Strong Authentication?

    Posted Oct 30, 2018 06:49 AM

    HI

     

    How do you log using the standard afm log from this implementation ?

     

    Thanks

     

    Paolo



  • 6.  Re: How to create a custom SMS Provider for CA Strong Authentication?

    Posted Oct 30, 2018 09:34 AM

    I'm just using log4j, for example

    private static Logger log = Logger.getLogger("class_name");

    log.debug((new StringBuilder()).append("To Phonenumber: ").append(smsData.getPhoneNumber()).toString());

     

    Add a line into AFM  arcotafm-log4j.properties file:

    log4j.logger.your.classname.with.package=debug

    or whatever level of log you need

    It writes to the same arcotafm.log  as the rest of AFM.

    Thanks,

    Vlad

     



  • 7.  Re: How to create a custom SMS Provider for CA Strong Authentication?

    Posted Nov 06, 2018 03:42 AM

    Works, thank a lot !

     

    Cheers,

             Paolo