This Repository is a collection of different ethical hacking tools and malware's for penetration testing and research purpose written in python, ruby, rust, c++, go and c.
JavaScript algorithmsartificial-intelligencebugbountycryptographycyber-threat-intelligencecybersecurity-projectsethical-hackinghacking-toolsmalwarenessusnetwork-monitoringnetwork-securitynmapportscannerpythonpythonprojectsthreat-intelligencevirus-scanning
Update get_tables_database.py
Abdul Wahab Junaid7fe30cf7f424
diff --git a/Python Tools/sqlite/get_tables_database.py b/Python Tools/sqlite/get_tables_database.pyindex 8b13789..9baa95f 100644--- a/Python Tools/sqlite/get_tables_database.py+++ b/Python Tools/sqlite/get_tables_database.py@@ -1 +1,27 @@+#!/usr/bin/env python3+import sqlite3++connection = sqlite3.connect('database.sqlite')++def tables_in_sqlite_database(connection):+ cursor = connection.execute("SELECT name FROM sqlite_master WHERE type='table';")+ tables = [+ v[0] for v in cursor.fetchall()+ if v[0] != "sqlite_sequence"+ ]+ cursor.close()+ return tables++tables = tables_in_sqlite_database(connection)+tables.remove('Order')++cursor = connection.cursor()++for table in tables:+ sql="select * from {}".format(table)+ cursor.execute(sql)+ records = cursor.fetchall()+ print(sql+" "+ str(len(records))+" elements")++connection.close()