Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
.. image:: https://travis-ci.org/lorehov/ognom.svg :target: https://travis-ci.org/lorehov/ognom :alt: Build Status
.. image:: https://img.shields.io/pypi/v/ognom.svg :target: https://pypi.python.org/pypi/ognom :alt: Latest Version
Documentation: #TODO
Ognom is object-to-document mapper for mongodb <https://www.mongodb.org>
. Currently ognom uses pymongo <https://api.mongodb.org/python/current/>
as default backend,
but you can easily implement your own backend based on another driver (for example asyncio-mongo <https://pypi.python.org/pypi/asyncio_mongo>
_) if needed,
as serialization and storage logic in ognom are separated.
Supports python2.7+, python3.3+, PyPy.
Documentation: #TODO
.. code-block:: python
pip install ognom
.. code-block:: python
tox
.. code-block:: python
from ognom.base import ConnectionManager, Document, Collection
from ognom.fields import StringField, IntField
ConnectionManager.connect({
'main': { # ognom use aliases for databases to make it possible to use multiple db's per project
'name': 'birzha_main',
'args': ['127.0.0.1:27017'],
'kwargs': {'socketTimeoutMS': 60000}},})
class Foo(Document):
objects = Collection(
db_name='main'
collection_name='my_foos' # collection name (by default 'foos')
indexes=[{
'index': [('bar', 1), ('baz', -1)],
'background': True}])
bar = StringField(required=True, default='baaar')
baz = IntField(choices=[10, 20, 30, 40, 50])
foo1 = Foo.objects.create({'bar': 'lalala'})
assert Foo.objects.get({'bar': 'lalala'}).id == foo1.id
foo2 = Foo(bar='lololo', baz=10)
assert foo2.id is None
foo2.save()
assert foo2.id is not None
foo2.remove()
foos = Foo.objects.find({'bar': 'lalala'}) # not list but CursorWrapper!
assert len(list(foos)) == 1
@lorehov <https://github.com/lorehov>
_@wronglink <https://github.com/wronglink>
_@sardnej <https://github.com/sardnej>
_FAQs
Neat ODM wrapper around great PyMongo driver
We found that ognom demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.