Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
pymgclient is a Memgraph database adapter for Python programming language compliant with the DB-API 2.0 specification described by PEP 249.
mgclient module is the current implementation of the adapter. It is implemented in C as a wrapper around mgclient, the official Memgraph client library. As a C extension, it is only compatible with the CPython implementation of the Python programming language.
pymgclient only works with Python 3.
Check out the documentation if you need help with installation or if you want to build pymgclient for yourself!
Online documentation can be found on GitHub pages.
You can also build a local version of the documentation by running make
from
the docs
directory. You will need Sphinx
installed in order to do that.
Here is an example of an interactive session showing some of the basic commands:
>>> import mgclient
# Make a connection to the database
>>> conn = mgclient.connect(host='127.0.0.1', port=7687)
# Create a cursor for query execution
>>> cursor = conn.cursor()
# Execute a query
>>> cursor.execute("""
CREATE (n:Person {name: 'John'})-[e:KNOWS]->
(m:Person {name: 'Steve'})
RETURN n, e, m
""")
# Fetch one row of query results
>>> row = cursor.fetchone()
>>> print(row[0])
(:Person {'name': 'John'})
>>> print(row[1])
[:KNOWS]
>>> print(row[2])
(:Person {'name': 'Steve'})
# Make database changes persistent
>>> conn.commit()
FAQs
Memgraph database adapter for Python language
We found that pymgclient demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.