title: Can you connect to MySQL database without providing pure credentials in Python code?
body: <p>Is there a way to connect to MySQL DB with maybe RSA keys or by providing SHA-256 encrypted login and password in code? Because let's say we want to post our app publicly. Anyone who can decompile the app will see all the code including our login and password to the database. </p>
  
  <p>I was wondering (<strong>purely theoretically</strong>) because If I wanted to implement some kind of codes system (like those from gift cards or PaySafeCards) to my app so the user could have like a premium membership or different feature and I wanted to store them in my database then someone could just decompile the app, steal the login and password that were in code, access the database, steal the codes and have the membership for free so <strong>how would I prevent a situation like that from happening?</strong> </p>