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.
The oaipmh module is a Python implementation of an "Open Archives Initiative Protocol for Metadata Harvesting" (version 2) client and server.
.. image:: https://github.com/infrae/pyoai/workflows/Run%20tests/badge.svg :target: https://github.com/infrae/pyoai/actions?query=workflow%3A%22Run+tests%22
The oaipmh module is a Python implementation of an "Open Archives Initiative Protocol for Metadata Harvesting" (version 2) client and server. The protocol is described here:
http://www.openarchives.org/OAI/openarchivesprotocol.html
Below is a simple implementation of an OAIPMH client:
from oaipmh.client import Client from oaipmh.metadata import MetadataRegistry, oai_dc_reader
URL = 'http://uni.edu/ir/oaipmh'
registry = MetadataRegistry() registry.registerReader('oai_dc', oai_dc_reader) client = Client(URL, registry)
for record in client.listRecords(metadataPrefix='oai_dc'): print record
The pyoai package also contains a generic server implementation of the
OAIPMH protocol, this is used as the foundation of the MOAI Server Platform
_
.. _MOAI Server Platform: http://pypi.python.org/pypi/MOAI
2.5.2 (unreleased)
2.5.1
Added customizable client retry policy (contributed by adimascio)
Added compatibility with Python 3.8 (contributed by krenzlin)
Do not resume ListRecord requests if no result was returned (contributed by wetneb)
2.5.0 (2017-07-03)
2.4.5 (2015-12-23)
Added switch in client to force harvesting using HTTP Get method (contributed by Stefan Oderbolz).
Added unofficial GetMetadata verb in server and client. GetMetadata is identical to GetRecord, but only returns the first element below the oai:metadata element, it does not return the oai enveloppe.
2.4.4 (2010-09-30)
2.4.3 (2010-08-19)
2.4.2 (2010-05-03)
2.4.1 (2009-11-16)
2.4 (2009-05-04)
2.3.1 (2009-04-24)
2.3 (2009-04-23)
Fixed bug and added tests for handling invalid dateTime formats, the server will now respond with a BadArgument (XML) error instead of a python traceback.
Use buildout to create testrunner and environment as opposed to
test.py
script.
Install buildout by:
$ python bootstrap.py $ bin/buildout
Run the tests by doing:
$ bin/test
To get a python interpreter with the oaipmh
library importable::
$ bin/devpython
2.2.1 (2008-04-04)
2.2 (2006-11-20)
Support for BatchingServer. A BatchingServer implements the IBatchingOAI interface. This is very similar to IOAI, but methods get a ‘cursor’ and ‘batch_size’ argument. This can be used to efficiently implement batching OAI servers on top of relational databases.
Make it possible to explicitly pass None as the from or until parameters for a OAIPMH client.
an extra nsmap argument to Server and BatchingServer allows the programmer to specify either namespace prefix to namespace URI mappings that should be used in the server output.
fixed a bug where the output wasn’t encoded properly as UTF-8.
2.1.5 (2006-09-18)
2.1.4 (2006-06-16)
2.1.3
Add infrastructure to deal with non-XML compliant OAI-PMH feeds; an XMLSyntaxError is raised in that case.
added tolerant_datestamp_to_datetime which is a bit more tolerant than the normal datestamp_to_datetime when encountering bad datestamps.
Split off datestamp handling into separate datestamp module.
2.0
2.0b1
Added framework for implementing OAI-PMH compliant servers.
Changed package structure: now a oaipmh namespace package. Client functionality now in oaipmh.client.
Refactoring of oaipmh.py module to reuse code for both client and server.
Extended testing infrastructure.
Switched over from using libxml2 Python wrappers to the lxml binding.
Use generators instead of hacked up getitem. This means that the return from listRecords, listIdentifiers and listSets are now not normal lists but iterators. They can easily be turned into a normal list by using list() on them, however.
1.0.1
1.0
0.7.4
0.7
Initial public release.
FAQs
The oaipmh module is a Python implementation of an "Open Archives Initiative Protocol for Metadata Harvesting" (version 2) client and server.
We found that pyoai demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 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.