Posts

Showing posts from November, 2024

Creating Custom Apps - Part 2

Image
   In this video series we will discuss about the ServiceNow App Engine module and its features. Special thanks to my friend Kleber for participating in this series. Thank you.

Generating Passwords

Image
Searching for an OOB* feature to generate User passwords, I have found the example below. var username = 'itil' ; var password = SNC . PasswordPolicyEvaluator . generateUserPassword ( username ) ; gs . info ( password ); // to view the password If we try to access the SNC API in a Scoped Application it will not work because it is designed for System Administrators. They can run scripts within the Global scope.  Last month while participating as a Hacktoberfest maintainer I had the chance to evaluate a contribution regarding password generation: var PasswordGenerator = Class .create(); PasswordGenerator .prototype = { initialize: function () {}, // // Input: Minimum password length that is required // Returns a random password for the min length specified // generate: function (givenPasswordLength) { var specials = '!@#$%&*()_+<>[].~' ; var lowercase = 'abcdefghijklmnopqrstuvwxyz' ; var upperc...