Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

Storing ECM password options for Saviynt API invocation

IAM_99
Regular Contributor II
Regular Contributor II

Hi ,

we have to use Saviynt REST api (Invoke Jar etc)  for custom functionalities,  for connecting to Saviynt Instance we use username and password, any inputs best place to store the password ?since this is initial connection we have to store somewhere ,please let me know how you are managing this ?

 

7 REPLIES 7

prasannta
Saviynt Employee
Saviynt Employee

You can create a customProperties file to store the URL, username, password etc. The password can be encrypted before storing the value in the properties file.

IAM_99
Regular Contributor II
Regular Contributor II

We tried it was not loading  .properties , did it worked for you ?

prasannta
Saviynt Employee
Saviynt Employee

From 2020.x version onwards, the customproperties file should be in csv format. Use below code to load the properties file and refer the url, host and password defined in properties file in your code.

FileReader reader;
try {
reader = new FileReader("src/resources/customProperties.csv");
properties.load(reader);
} catch (Exception e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}

Please try using the above code.

DixshantValecha
Saviynt Employee
Saviynt Employee

Thank you for contacting the Saviynt forums.

#There are various possible approaches that can be considered for addressing this.

1.)One approach is to utilize Basic authentication, which utilizes your email address and password to authenticate the API request. This method of authentication eliminates the need for a separate API to obtain the authorization token. To generate the authorization header, combine your email address and password in a Base-64 encoded string using a website such as https://www.base64decode.org/, and click ENCODE.

DixshantValecha_0-1678192633157.png

> In order to authenticate using this method, you must populate the encoded value of your username and password in the Headers tab of Postman in the following format: Authorization: Basic Username:password.The string that follows "Authorization: Basic" is "dmVkYW50aC5iaOBzYXZpeW50LmNvbTpTYXZpeW." This is the base64-encoded version of the username and password.

DixshantValecha_1-1678192734363.png

> The {access_token} binding variable in the JSON is automatically populated with this value.Moreover, to enable the functionality, it may be necessary to configure the ConnectionJSON with this variable.

2.)Another potential approach is to store both the username and password in  file called externalConfig.properties or customProperties . Before storing the password value, it is recommended to encrypt it using a secure encryption algorithm. One way to achieve this is by encoding the password using Base-64, for instance, with the aid of a reliable web page such as https://www.base64decode.org/. Once the password is encoded, it can be securely stored in the external configuration file.

DixshantValecha_0-1678189022222.png

Afterward, the next step would be to configure the Jar files to decrypt the encrypted values when necessary.

Please validate and let us know if further information is needed on this.

IAM_99
Regular Contributor II
Regular Contributor II

Custom CSV or externalConfig.properties  - Did it worked  ? 

We are trying to load  from   /opt/saviynt/Conf/externalConfig.properties  in Java program it was not printing.

 

DixshantValecha
Saviynt Employee
Saviynt Employee

We are currently checking on this internally and will provide you with the required details.

prasannta
Saviynt Employee
Saviynt Employee

Have you tried using the customproperties.csv to load the properties file with username and password as suggested above. Please let us know if that approach is working.