Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

How do I invoke a custom .JAR from a connector?

tarung702
New Contributor III
New Contributor III

So I've got a .JAR file that creates an HMAC authz header and then packages that header into a request to retrieve a list of users (the response is a JSON like any other REST response, but the reason to do this with a .JAR is the calculated HMAC header that needs to be sent with the request). 

How do I invoke this from the accountandentimportjson for example and then trigger the import from the job control panel using a job? 

How should I structure what is in the connector for this to work to get a response and grab the records to import account data? 

9 REPLIES 9

tarung702
New Contributor III
New Contributor III

I can't find any examples of this on docs or in the forum, if it already exists I can work from being pointed in the right direction as well?

SB
Saviynt Employee
Saviynt Employee

This is currently not supported.


Regards,
Sahil

Baver
New Contributor
New Contributor

A little correction on my colleague's context. The JAR file is only getting the access token. We need it invoked from the connectionJSON. I will attach the java code here for context. The code will not work as attached as the API keys are not completed.

SB
Saviynt Employee
Saviynt Employee

Getting the access token from JAR will not work as is not supported. Is it possible to get the value from another api and then pass it along the final call.


Regards,
Sahil

tarung702
New Contributor III
New Contributor III

I COULD do that but hosting that would be the problem. Really I just need to be able to generate the HMAC header for the AuthZ request in EIC. If there is an API for that for Veracode that would be great, but I don't think there is as their postman reference details how you generate it yourself. 

Instead of how I'm doing it in the .JAR, do you know of any ways to generate the HMAC header in EIC and use that in the Authorization call?

SB
Saviynt Employee
Saviynt Employee

Unfortunately I do not think there is a way to achieve this but let me check and will update.


Regards,
Sahil

tarung702
New Contributor III
New Contributor III

TY Sahil, looking forward to hearing from you. 

SB
Saviynt Employee
Saviynt Employee

I checked this and unfortunately this is not doable.


Regards,
Sahil

tedappara
New Contributor II
New Contributor II

Hello! 

I was able to do something similar using a JAR file and the JAR connector to call it. The JAR file contained java code that pulled users (accounts) from a source system by building a custom query and calling it via the account import job.  The username/pwd/clientid was stored in the connection json field and the method from the JAR was specified in the importaccountsjson field to run with other inputs/configs in the importaccountsjson field.

The list of accounts returned were then written to Saviynt as account objects under a specified security system/endpoint.

I am triggering this from the Job control panel using an "Application Data Import" type job.

Found this documentation on JAR connector in saviynt: https://docs.saviyntcloud.com/bundle/JAR-v2022x/page/Content/About-this-Guide.htm

Not sure if this has changed with the newer versions.  Even though it might not be the exact same scenario, hope this helps generate some ideas to address your challenge!