
Research
/Security News
9 Malicious NuGet Packages Deliver Time-Delayed Destructive Payloads
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.
exlibris-request
Advanced tools
CREBP-SRA tool to request papers, books or other materials via ExLibris (Alma, Primo etc.)
This module is part of the Bond University Centre for Research in Evidence-Based Practice Systematic Review Assistant suite of tools.
This module forms the reference request tool.
var exlibrisRequest = require('sra-exlibis-request');
new sraExlibrisRequest()
.set({
exlibris: {
apiKey: 'YOUR API KEY'
},
user: {
email: 'someone@somewhere', // User making request
},
})
.set('request.source', 'SRA') // Set some extra request fields
.set('request.note', 'SRA')
.set('validator', (ref, eref) => { // Custom validator code
if (!ref.type) return 'No reference type specified';
if (ref.type == 'book') {
if (!eref.title) return 'Missing book title';
if (!eref.journal) return 'Missing journal';
eref.pickup_location = 'MAIN',
eref.format = 'PHYSICAL';
eref.citation_type = 'BK';
}
return true;
})
.requestAll(refs, function(err, res) { // Request a bunch of references (maybe use reflib - https://github.com/hash-bang/Reflib-Node - to read in a library?)
expect(err).to.be.not.ok;
done();
})
See the testkits for more examples.
The main ExlibrisRequest class is used to setup the instance with initial settings and provide an API.
Supported Settings:
| Setting | Type | Default | Description |
|---|---|---|---|
exlibris | Object | See below | Settings passed onto the Exlibris NPM module |
exlibris.region | String | "eu" | What Exlibris region server the place the request with |
exlibris.apiKey | String | none | Your Exlibris API key |
exlibris.resourceRequestRetry | Number | 10 | How many times to retry a single request if it fails |
exlibris.resourceRequestRetryDelay | Function | See code | How to calculate how long to wait between requests. Default behaviour is to pick a random millisecond delay between 0 and 2000 |
exlibris.threads | Number | 2 | How many requests to place simultaneously |
user | Object | See below | Information about the user to place the request against |
user.email | String | none | The users email to link the request against |
request | Object | {} | Additional fields to provide in the request |
validator | Function | ()=> true | Validator function used to verify that a reference can be submitted. Should return either a boolean or a string (error message). Note, this occurs AFTER the field translation stage, so the fields are Exlibris and NOT Reflib spec. If you are mutating the object, mutate the Exlibris object (eRef) |
debug | Object | See below | Debug flags |
debug.execRequest | Boolean | false | Whether to actually place requests. User details and all other validation stages are applied except the final submission |
debug.titleMangle | String | title => title | How to mutate the citation title before submission. Override this function to specify a prefix / suffix |
cache | Object | See below | Caching details, the cache is used only on this instance and can significantly speed up requests if working in batches |
cache.enabled | Boolean | true | Whether to use caching |
cache.cacheGet | Function | See code | Uses simple memory caching |
cache.cacheSet | Function | See code | Uses simple memory caching |
Notes:
debug.execRequest flag is disabled by default. Set this to true to make the library submit requests, although you should test without this enabled firstUsed to quickly set one or more config values. See the main constructor for a list of settings.
ExlibrisRequest
.set('key1', 'value1')
.set('key2', 'value2')
.set('key3.subKey1', 'value3')
ExlibrisRequest.set({
key1: 'value1',
key2: 'value2',
key3: {
subKey1: 'value3',
},
})
Make a citation request to Exlibris.
The reference should be in the reflib format.
Options can be specified to override the defaults. Callback is optional.
Similar to request() but places requests in batch.
See the request function for details.
The ExlibrisRequest instance can also fire events.
| Event | Parameters | Description |
|---|---|---|
requestSucceed | (ref, attempt) | Fired when a request succeeded |
requestRetry | (ref, attempt, tryagainInTimeout) | Fired when a request fails but will be retried |
requestFailed | (ref, attempts) | Fired when a request failed after retrying |
requestError | (ref, err) | Fired when a request is completely rejected by the server |
FAQs
CREBP-SRA tool to request papers, books or other materials via ExLibris (Alma, Primo etc.)
We found that exlibris-request demonstrated a not healthy version release cadence and project activity because the last version was released 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
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.

Security News
Learn the essential steps every developer should take to stay secure on npm and reduce exposure to supply chain attacks.