{"action":"opened","issue":{"url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/175","labels_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/175/labels{/name}","comments_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/175/comments","events_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/175/events","html_url":"https://github.com/OfflineIMAP/offlineimap/issues/175","id":62526864,"number":175,"title":"password from mysql database","user":{"login":"naveensharmayoung","id":8940514,"avatar_url":"https://avatars.githubusercontent.com/u/8940514?v=3","gravatar_id":"","url":"https://api.github.com/users/naveensharmayoung","html_url":"https://github.com/naveensharmayoung","followers_url":"https://api.github.com/users/naveensharmayoung/followers","following_url":"https://api.github.com/users/naveensharmayoung/following{/other_user}","gists_url":"https://api.github.com/users/naveensharmayoung/gists{/gist_id}","starred_url":"https://api.github.com/users/naveensharmayoung/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/naveensharmayoung/subscriptions","organizations_url":"https://api.github.com/users/naveensharmayoung/orgs","repos_url":"https://api.github.com/users/naveensharmayoung/repos","events_url":"https://api.github.com/users/naveensharmayoung/events{/privacy}","received_events_url":"https://api.github.com/users/naveensharmayoung/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-17T21:54:29Z","updated_at":"2015-03-17T21:54:29Z","closed_at":null,"body":"i am using mysql database to store password of gmail and getting it via function\r\npython file \r\ndef username():\r\n   db = MySQLdb.connect(host=\"localhost\", # your host, usually localhost\r\n                     user=\"root\", # your username\r\n                      passwd=\"1555511\", # your password\r\n                      db=\"database\") # name of the data base\r\n\r\n# you must create a Cursor object. It will let\r\n#  you execute all the queries you need\r\n   cur = db.cursor()\r\n\r\n# Use all the SQL you like\r\n   cur.execute(\"select password from database)\r\n   data = cur.fetchall()\r\n   for row in data:\r\n       fname = row[0]\r\n# print all the first cell of all the rows\r\n       return fname \r\nand my offlineimaprc files is \r\n[Repository Remote2]\r\ntype = IMAP\r\nremotehost = imap.gmail.com\r\nremoteuser = nk86@gmail.com\r\nremotepasseval = username()\r\nssl = yes\r\nsslcacertfile = /etc/ssl/certs/ca-certificates.crt\r\nmaxconnections = 3\r\n\r\nrealdelete = no\r\nbut error in authentication how to correct this error"}}