diff options
author | Christian Cleberg <hello@cleberg.net> | 2025-05-06 21:31:46 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-05-06 21:31:46 -0500 |
commit | 95bf612c338dec8235e89ca6a1d9e5e8cad3f997 (patch) | |
tree | 82cfd62fb145b7b686d4ae825ab2c2436343e590 /databases/administrators/mongo/admins.py | |
parent | d62f25007470fe546e0f9d2e38a26e84146f72c5 (diff) | |
download | audit-tools-95bf612c338dec8235e89ca6a1d9e5e8cad3f997.tar.gz audit-tools-95bf612c338dec8235e89ca6a1d9e5e8cad3f997.tar.bz2 audit-tools-95bf612c338dec8235e89ca6a1d9e5e8cad3f997.zip |
reorganize db dir (#6)
Diffstat (limited to 'databases/administrators/mongo/admins.py')
-rw-r--r-- | databases/administrators/mongo/admins.py | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/databases/administrators/mongo/admins.py b/databases/administrators/mongo/admins.py deleted file mode 100644 index e844cbc..0000000 --- a/databases/administrators/mongo/admins.py +++ /dev/null @@ -1,16 +0,0 @@ -from pymongo import MongoClient
-
-# Connect to the MongoDB server
-client = MongoClient("mongodb://localhost:27017/")
-
-# Select the 'admin' database
-db = client.admin
-
-# Query the 'system.users' collection
-users = db.system.users.find(
- {}, {"user": 1, "db": 1, "roles": 1, "credentials": 1, "userSource": 1}
-)
-
-# Print the results in a pretty format
-for user in users:
- print(user)
|