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.
marshmallow-mongoengine
Advanced tools
Mongoengine integration with the marshmallow (de)serialization library
.. image:: https://travis-ci.org/MongoEngine/marshmallow-mongoengine.svg?branch=master :target: https://travis-ci.org/MongoEngine/marshmallow-mongoengine :alt: Travis-CI
.. image:: https://readthedocs.org/projects/marshmallow-mongoengine/badge/?version=latest :target: http://marshmallow-mongoengine.readthedocs.org/en/latest/?badge=latest :alt: Documentation Status
.. image:: https://coveralls.io/repos/github/MongoEngine/marshmallow-mongoengine/badge.svg?branch=master :target: https://coveralls.io/github/MongoEngine/marshmallow-mongoengine?branch=master :alt: Code Coverage
Mongoengine <http://mongoengine.org>
_ integration with the marshmallow <https://marshmallow.readthedocs.org/en/latest/>
_ (de)serialization library.
See documentation at http://marshmallow-mongoengine.rtfd.org/
.. code-block:: python
import mongoengine as me
class Author(me.Document):
id = me.IntField(primary_key=True, default=1)
name = me.StringField()
books = me.ListField(me.ReferenceField('Book'))
def __repr__(self):
return '<Author(name={self.name!r})>'.format(self=self)
class Book(me.Document):
title = me.StringField()
.. code-block:: python
from marshmallow_mongoengine import ModelSchema
class AuthorSchema(ModelSchema):
class Meta:
model = Author
class BookSchema(ModelSchema):
class Meta:
model = Book
author_schema = AuthorSchema()
.. code-block:: python
author = Author(name='Chuck Paluhniuk').save()
book = Book(title='Fight Club', author=author).save()
dump_data = author_schema.dump(author).data
# {'id': 1, 'name': 'Chuck Paluhniuk', 'books': ['5578726b7a58012298a5a7e2']}
author_schema.load(dump_data).data
# <Author(name='Chuck Paluhniuk')>
::
pip install -U marshmallow-mongoengine
MIT licensed. See the bundled LICENSE <https://github.com/touilleMan/marshmallow-mongoengine/blob/master/LICENSE>
_ file for more details.
FAQs
Mongoengine integration with the marshmallow (de)serialization library
We found that marshmallow-mongoengine 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.