
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
$ npm install ors-cp --save
If you have mocha installed globally, e.g. npm install -g mocha
$ mocha
Or
$ node node_modules/mocha/bin/mocha
First, import the module via require
const OnlineRegistration = require('ors-cp');
Instantiate the instance of the class and pass in the assumed classData object
const classData = {
"enrollmentCapacity": 8,
"reservations": [
{
"reservationCapacity": 4,
"sequenceId": "1",
"effectiveStartDate": "2017-12-01"
},
....
],
"currentEnrollment": {
"effectiveDate": "2017-12-06",
"reservedSeatsEnrolled": 1,
"openSeatsEnrolled": 1
}
}
//Instantiate instance of OnlineRegistration
//Since os is a native Node module, I use ors for the naming convention
//e.g. OnlineRegistrationSystem
const ors = new OnlineRegistration(classData);
Most of the API usage is calling various getters. Optional parameters are available as per the method signature stated below.
ors.showCourseEnrollment();
Returns an Object containing keys reservedSeatsAvailable, openSeatsAvailable
ors.getOpenSeatsAvailable();
Returns a Number containing the sum of all open seats available for students to enroll in for a course
ors.getTotalOpenSeats();
Returns a Number containing the sum of all open seats assigned to a course
ors.getReservedSeatsAvailable();
Returns a Number the sum of reserved seats available for a student to enroll (given their correct enrollment critier etc)
ors.getEnabledReservedSeats()
Returns a Number containing the sum of all reserved seats enabled in a course e.g. the reserved seats who's effective start date is less than the date of the request.
ors.getTotalReservedSeats(optionalReservationsArray);
Returns a Number containing the sum of all reserved seats assigned to a course
regardless of the date of request/effective start date for each reservation object.
FAQs
A tool for calculating available course enrollment
We found that ors-cp 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.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.