LeakedIn Logo
Stories About Data Leaks and Related Stuff

Potential leak of data: Python Database Connection

0 votedvote

Detected 2 occurrence(s) of ‘(mdb|pyodbc)\.connect\(‘:

= cxn.cursor()
    csr.execute(use)
    fetch = csr.fetchall()
	
Sqls = (Sql,Sql_2,Sql_3)
	
Sqls = ('Sql','Sql_2','Sql_3')
	
SQl = """Select something"""
SQl_2 = """Select something"""
SQl_3 = """Select something"""

Sqls = (Sql, Sql_2, Sql_3)
cxn = pyodbc.connect('DSN=MySQL;PWD=xxx') 
csr = cxn.cursor()

for x in Sqls:
    print x
    use = Sql_2  
    # use = x    
    csr.execute(use)
    fetch = csr.fetchall()

Source: http://pastebin.com/raw.php?i=aqmWvWny

Tags: ,

Comments are closed.