Layer 7 API Management

Expand all | Collapse all

Examples of custom assertions

Jump to Best Answer
  • 1.  Examples of custom assertions

    Posted 11-13-2015 10:00 AM

    We want to create some custom assertions with input and output parameters for the api gateway. Does anybody want to share some samples of custom assertions? With some examples we could kickstart our own custom assertions.



  • 2.  Re: Examples of custom assertions
    Best Answer

    Posted 11-18-2015 07:33 AM

    Hello, Edward. You may find the attached Custom Assertion project plugin for Eclipse useful.

     

    Note: This plugin is not a supported CA product. It was developed by the community. Use at your own risk, and post questions here, and don't contact CA support for questions or issues related to the use of this plugin.

     

    Use this plugin by adding it to your Eclipse dropins folder. This can be easier to find on some platforms than on others. On Mac, you'll find it in your Eclipse.app directory:

     

     

    Start (or restart, if already running) Eclipse, and create a new project:

     

     

    Under the CA API Management category, select CA API Management Custom Assertion Project, and click Next:

     

     

    Make changes to fields in the form to accelerate creation of a unique custom assertion and/or click the Finish button:

     

     

    This will result in a custom assertion project that is ready to be built with Ant, and that demonstrates taking two strings as input, converting both to upper case and concatenating them together, and returning the result in an output context variable:

     

     

    The project will use your workspace's default JRE:

     

     

    For custom assertions that will be run on v8.4 or above gateways, you must use a Java 8 (a.k.a. 1.8) version. For custom assertions that will be run on v8.0 to v8.3, you must use a Java 7 (a.k.a. 1.7) version of Java. This change can be made to in your project's Java Build Path settings. For earlier version of the gateway, you should use an earlier version of the plugin (not attached, but can attach upon request).

     

    Build your project by selecting the build.xml file in the project's root directory, right click to open its context menu, select Run As, and Ant Build:

     

    This will result in a corresponding .jar file in a build folder in the project's root directory:

    Deploy the .jar file to your gateway's /opt/SecureSpan/Gateway/runtime/modules/lib file and change its ownership to layer7:layer7, then restart your gateway. Your custom assertion should now be available in the policy assertion pallet.



  • 3.  Re: Examples of custom assertions

    Posted 11-18-2015 07:39 AM

    BTW, I should add that though it's great to see your interest in extending the gateway's capabilities using custom assertions, in almost all cases, it's possible and possibly better to use policy (and possibly policy backed encapsulated assertions in later versions of the gateway). In the many years I've been with Layer 7 and now CA, I can probably count on two hands the times that a custom assertion was needed to solve a problem, and for most of those cases, we now have out-of-the-box policy assertions that can solve the same problem without a custom assertion.



  • 4.  Re: Examples of custom assertions

    Posted 07-12-2018 05:03 AM

    My colleague Lucas has recently developed a Custom Assertion for us. He wrote a nice how to: Implementation of a CA API Gateway Custom Assertion. If you are interested in starting to develop a Custom Assertion you might like to consider this tutorial.



  • 5.  RE: Re: Examples of custom assertions

    Posted 07-16-2019 11:36 AM
    The attachment to your message can't be found anymore : where can I found the Custom Assertion project plugin for Eclipse now ?

    Thanks in advance.



  • 6.  RE: Re: Examples of custom assertions

    Posted 07-17-2019 08:37 AM
    It seems to be gone with the migration to Broadcom.
    See attached the jar File from the original post.


  • 7.  RE: Re: Examples of custom assertions

    Posted 07-17-2019 09:04 AM
    Edited by Nicolas Mayoraz 07-17-2019 09:06 AM
    Hi Waldemar,

    Actually there is no attachment with the original post either:



    And nothing is attached to your reply.

    Could you add the file as attachment to a new message ?

    Thanks.




  • 8.  RE: Re: Examples of custom assertions

    Posted 11-07-2019 10:18 PM
    Could you please provide me the latest the plug-in jar that supports?
    There is no attachment.



  • 9.  RE: Re: Examples of custom assertions

    Posted 11-08-2019 05:02 AM
    I will sent you a PM. It is not possible anymore to attach a jar file.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 10.  RE: Re: Examples of custom assertions

    Posted 11-11-2019 01:52 PM
    Hello,
    Can you also send me the plugin? Thank you very much


  • 11.  RE: Re: Examples of custom assertions

    Posted 11-12-2019 03:14 AM
    Sure, just sended you a PM.

    @Broadcom: Could it be possible, that you can provide the jar file again in this forum?


    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 12.  RE: Re: Examples of custom assertions

    Posted 11-20-2019 02:29 AM
    Hi Waldemar,

    we cant find the plugin for custom assertion on provided link, can you please share it as an attachment.

    It really needed for us, while im using the provided link it just return back to the same community broadcom page so can you please help on this

    thanks in advance


  • 13.  RE: Re: Examples of custom assertions

    Posted 11-20-2019 05:35 AM

    Hi Jagan,
    Unfortunately it is not possible to share it as an attachment. The forum software don't allow jar files.
    I can sent it to you as PM.



    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 14.  RE: Re: Examples of custom assertions

    Posted 11-20-2019 07:21 AM
    Yeah, Waldemar

    but the link u have provided https://apiida.com/aagm?lang=en doesn't contain the plugin. can you share it via email?


  • 15.  RE: Re: Examples of custom assertions

    Posted 11-20-2019 07:25 AM
    This is just the link form the automated signature. Please check your inbox from this forum.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 16.  Re: Examples of custom assertions

    Posted 12-10-2015 10:00 AM

    Hello. Was Ben's response adequate to addressing your question? If so then please take a moment to mark it as the best answer. Thanks!



  • 17.  Re: Examples of custom assertions

    Posted 01-25-2019 03:47 PM

    Could you please provide me the latest the plug-in jar that supports ca-apigateway 9.3 version ?



  • 18.  RE: Re: Examples of custom assertions

    Posted 11-19-2019 08:20 AM
    Hi,
    Is it also possible to get hands on this plugin ?
    Does ti support all gateway versions, considering we're using 9.4CR03 ?
    Thanks.


  • 19.  RE: Re: Examples of custom assertions

    Posted 11-19-2019 09:57 AM
    As far as I know, this plugin works with Gateway 9.4. We have developed ourself some custom assertions (for APIIDA API Gateway Manager), which are working fine with all 9.x Gateways.
    But since this is an unofficial plugin, you won't get any support from Broadcom.

    I can send you the file via PM. I hope a Broadcom member can do this in the future.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 20.  RE: Re: Examples of custom assertions

    Posted 11-19-2019 10:06 AM
    Thanks.


  • 21.  RE: Re: Examples of custom assertions

    Posted 01-06-2020 01:46 AM
    Could you please provide me the latest the plug-in jar that supports ca-apigateway 9.3 version ?

    ------------------------------
    Chief Manager,
    ICICI Bank
    Hyderabad
    ------------------------------



  • 22.  RE: Re: Examples of custom assertions

    Posted 01-07-2020 03:16 AM
    Hi Parag,
    There is no other version, then the one from 2015. This version still works, but there is no specific 9.3 version.
    It would really help, if someone from the Broadcom Team could confirm this.
    Besides that, I will send you a PM with the plugin.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 23.  RE: Re: Examples of custom assertions

    Posted 01-21-2020 09:20 AM
    Hi Waldemar,

    Is there a possibility I could get this plug-in as well. It seems its no longer in the forums and support has not been able to locate it as well. It would be greatly appreciated!

    Thanks!


  • 24.  RE: Re: Examples of custom assertions

    Posted 01-22-2020 03:00 AM
    Hi Paul,
    Just send you a PM with a download link.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 25.  RE: Re: Examples of custom assertions

    Posted 01-22-2020 10:57 AM
    Hi Waldemar,

    Would you be able to send me a copy of the plug in as well please?

    Kind regards,
    Andrew


  • 26.  RE: Re: Examples of custom assertions

    Posted 01-23-2020 03:31 AM
    Sure, just send you a PM

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 27.  RE: Re: Examples of custom assertions

    Posted 24 days ago
    Hi Waldemar,

    Could you send me an eclipse plugin as well please?


  • 28.  RE: Re: Examples of custom assertions

    Posted 24 days ago
    Sure! Just send you a PM.

    ------------------------------
    Product Manager - APIIDA API Gateway Manager
    APIIDA AG
    https://apiida.com/aagm?lang=en
    ------------------------------



  • 29.  RE: Re: Examples of custom assertions

    Posted 21 days ago

    Hi Waldemar. 

    Could you send me the eclipse plugin as well ?

    You might want to put it on a Github or some sort to avoid to send PM to everyone ! :)

    Thanks in advance