This notice applies to you if one or more of your scripts use the SuiteScript 1.0 nlapiEncrypt(s, algorithm, key) API, or the SuiteScript 2.x record.getValue(options) or currentRecord.getValue(options)methods, to check the values of custom password fields. As of NetSuite 2021.2, this usage of nlapiEncrypt will no longer be supported and this usage of record.getValue and currentRecord.getValue will no longer be recommended.
NetSuite 2021.1 will introduce the following new APIs that you should use instead to check custom password field values:
- SuiteScript 1.0: nlapiCheckPasswordField(type, id, value, field, sublist, line) API
- SuiteScript 2.x: checkPasswordField(options) method in the N/crypto Module
After your account is upgraded to 2021.1 and before it is upgraded to 2021.2, you should update your scripts to use these new APIs.
These new APIs include new validation capabilities that improve product security and do not require users to know or identify specific information about cryptography.
Note: You have to make changes to scripts that use nlapiEncrypt only if they check password fields and have a value set to sha1 or void.
What is Changing?
As of NetSuite 2021.2, the use of the nlapiEncrypt API to check correct values of custom password fields will be prohibited.
In addition, NetSuite 2021.2 will include the following changes to return values:
- Calling the SuiteScript 1.0 nlapiEncrypt API with a void (empty) algorithm parameter will return NULL.
- Calling the SuiteScript 1.0 nlapiEncrypt API with the algorithm parameter set to sha1 will return NULL.
- Calling the SuiteScript 1.0 nlapiGetFieldValue(fldname) API specifying a custom password field will no longer return a hashed value.
- Calling the SuiteScript 2.x record.getValue(options) or currentRecord.getValue(options) methods specifying a custom password field will no longer return a hashed value.
- Getting the value of an encrypted custom password field will no longer return a hashed value. Instead the returned value will be obfuscated. This change will apply to encrypted custom password field values obtained through a variety of methods, including saved searches, SuiteAnalytics workbooks and datasets, SuiteAnalytics Connect integrations, SOAP web services integrations, REST web services integrations, and CSV export integrations.
Recommended Actions
To ensure your scripts continue to run as expected after your account is upgraded to 2021.2, you should make the following changes as soon as possible after your account is upgraded to 2021.1:
- Update your SuiteScript 1.0 scripts that call nlapiEncrypt to use nlapiCheckPasswordField
- Update your SuiteScript 2.x scripts that call getValue(options) or currentRecord.getValue(options) on a custom password field to instead use the checkPasswordField(options) method in the N/crypto module.
Identify any logic dependencies on encrypted field values and update them before the 2021.2 upgrade.
For more information about these upcoming changes, including recommended actions details and code examples, see Upcoming Changes to Supported APIs for Checking Custom Password Fields (SuiteAnswer ID 97620).
If you require assistance or more information, please contact NetSuite Customer Support.