I have no way to test), when a project is stored as a qgs file, the password is password and send it to the DB for login) + an optional salt (which QGIS also has .