- Changes an Oracle account's password.

Purpose of This Script

Command-line utility for password management for an Oracle database helpdesk ("I forgot my password, can you reset it?")

  • Enforces password rules of your choice
  • Attempts to help the user find the correct username even if the precise spelling is not known
  • Accepts AS SYSDBA/AS SYSOPER logins.


If installed with sqlWrap, the sqlWrap installer automatically puts into your Python Scripts directory: is a free-standing script, however, and may be copied independently and run from anywhere. You can copy it directly from requires that cx_Oracle be installed:


How To Use This Script

At the command prompt, run python

You will be prompted for username, password, and database name. The database name should be available in your TNSNAMES.ORA file - has not been tested with Oracle Easy Connect.

A standard set of password compliance rules is included within the script (search for ComplianceRules). To adapt them to your installation's rules, add appropriate functions to the script and append them to the ComplianceRules list.