Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Restful with mongodb + koa :heart:
Pdta: ECHO (Elian Chancay Olivo is my Son :baby: It's funny because I do not like php )
Developing ... :runner:
import koa from 'koa';
import mongoose from 'mongoose';
import echoApi from 'echo-crud';
const app = koa();
const mongoUrl = 'mongodb://localhost/yourDatabase';
mongoose.connect(mongoUrl);
let schema = new mongoose.Schema({
name: String,
age : Number
}, {versionKey: false});
const model = app.model = mongoose.model('user', schema);
const user = echoApi(app, model,['GET','POST','PUT','DELETE']);
app.use(user.routes());
app.listen(3000);
Use header X-Requested-With : XMLHttpRequest
test in your browser. http://localhost:3000/users
-- | Params | query | body |
---|---|---|---|
GET | limit - skip - sort | --- | |
GET | id | limit - skip - sort | --- |
POST | --- | --- | Json data |
DELETE | id* | --- | --- |
PUT | id* | --- | Json data |
FAQs
Restful with mongo and koa
The npm package echo-crud receives a total of 1 weekly downloads. As such, echo-crud popularity was classified as not popular.
We found that echo-crud 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 a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.