Python Forum
Encrypting Oracle Passwords / Python Library for That?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Encrypting Oracle Passwords / Python Library for That?
#1
I have numerous Python scripts that have been written over the past several years. Many of those interact with several Oracle databases in our office. Currently, all of those Python scripts have the Oracle DB usernames & passwords hard-coded directly in them.

I need to get away from that and, at minimum, have have the Oracle database username stored in the Python script, and make a call to some encrypted password stored Python library to pass-in the username and have the encrypted Oracle DB password returned back from that call.

I've researched this a bit and have seen that a library called Keyring is popular for this, and there looks to be a related library called keyrings.cryptfile (https://pypi.org/project/keyrings.cryptfile/) that deals specifically with encrypting whatever is stored in the library.

Any other suggestions, libraries, practical examples anyone can share as far as what's worked for them for this sort of privacy scenario to get away from having hard-coded passwords in your Python scripts?

Thanks!
Reply
#2
There is a good user management package available here: https://pypi.org/project/Flask-User/
it uses Flask, but may be appropriate for storing your users.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  python to read the data from oracle melinda 3 1,583 Aug-18-2025, 10:24 AM
Last Post: Larz60+
  Conversion of Oracle PL/SQL(packages, functions, procedures) to python modules. DivyaKumar 3 9,611 Oct-01-2024, 03:32 PM
Last Post: Alex_Kirpichny
  best way to embed passwords into scripts mikey6785 3 6,137 Aug-31-2022, 08:22 AM
Last Post: DeaD_EyE
  Help with passwords program Vasilis 1 2,577 Jan-06-2021, 10:55 AM
Last Post: Larz60+
  Calling Oracle REST SQL from Python johnjacob 2 3,351 Nov-05-2020, 04:19 AM
Last Post: johnjacob
  Python to Oracle Conn Issue chvsnarayana 2 55,551 Sep-06-2020, 04:33 PM
Last Post: Larz60+
  Load table from Oracle to MYSQL using python himupant94 0 2,489 May-12-2020, 04:50 PM
Last Post: himupant94
  how to set echo ON in Python call to Oracle SQL nmrt 4 5,698 Sep-21-2019, 05:40 AM
Last Post: nmrt
  Long command with characters not working in Python on Oracle Linux 7 iaas_infra 10 9,305 Jul-19-2019, 04:53 PM
Last Post: ichabod801
  I need help using Python to generate usernames and passwords with excel documents Jannejannesson 3 6,330 May-08-2019, 02:30 PM
Last Post: Jannejannesson

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020
This forum uses Lukasz Tkacz MyBB addons.
Forum use Krzysztof "Supryk" Supryczynski addons.