
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
A RESTful database request server. It listens for seven types of REST requests and responds with JSON API formatted resources.
npm install -g quarry
Currently, Quarry is built exclusively for PostgreSQL databases. Support for other database options will be added in the future, prior to the 1.0 release.
For now, you'll need PostgreSQL installed and started before running Quarry.
Create a JSON config file for Quarry (default quarry.json
) with the following "global" options:
Each database will need its own JavaScript file in order to outline its tables, fixtures, and permissions. This "database script" file will simply export an object with the following allowed nested parameters:
For convenience, and certainly not for security, you can simply set allow to true, in order to allow all the actions to be permitted on the table. This is definitely not recommended for stable or production projects, but is intended as an easy way to get up and running quickly.
The RESTful "actions" are a friendly way to refer to REST requests, and each represents a combination of an HTTP method and a URI format:
{
"connection": {
"host": "localhost",
"port": 5432,
"user": "quarry_user",
"password": null
},
"databaseScripts": [
"databases/example.js"
],
"host": "db.example.com",
"port": 54321
}
module.exports = {
tables: {
colors: {
columns: {
id : 'serial',
name : 'text',
hexCode : 'text'
},
fixtures: [
{ name: 'Red', hexCode: 'FF0000' },
{ name: 'Green', hexCode: '00FF00' },
{ name: 'Blue', hexCode: '0000FF' }
],
allow: {
findAll: true,
update: function ( request ) {
return !!request.params.userId;
}
}
}
}
}
The above two configurations would result in two valid endpoints:
FAQs
A RESTful database server app
The npm package quarry receives a total of 1 weekly downloads. As such, quarry popularity was classified as not popular.
We found that quarry 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 uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.