
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
signature-module
Advanced tools
This JavaScript module provides tools to make the process of signing a request between servers easier. It consist on two services:
SignatureMiddleware: Node.js Express middleware in charge of checking whether a signed request is valid.
SignedRequest: Service to send signed http requests. It appends the necessary parameters to it.
1-
npm install signature-module --save
2- Include it once in your project with the sequelize instance (It is used for creating the necessary migrations)
const signature = require('signature-module')({
appId: 'appId',
signatureKey: 'signatureKey'
});
3- Initialize the service desired
const signatureMiddleware = signature.signatureMiddleware();
const signedRequest = signature.signedRequest('targetSecretKey');
Use the signatureMiddleware with your Express server to validate any incomming request.
server.use(signatureMiddleware());
Use the signed request module like you would do with the request-promise module: https://github.com/request/request-promise. The module will append the necessary values to the request (signature, appId, timestamp)
GET:
signedRequest.get({
baseUrl: 'https://some.url.com',
uri: `/some/uri`,
json: true,
qs: {
param: 'value'
}
})
.then(data => {})
.catch(error => {})
POST:
signedRequest.post({
baseUrl: 'https://some.url.com',
uri: `/some/uri`,
json: true,
qs: {
param: 'value'
},
body: {
param1: 'value',
param2: 'value'
}
})
.then(data => {})
.catch(error => {})
Service A AppId: 'ServiceA'; IncomingSignatureKey: 'IncomingSignatureA';
Service B AppId: 'ServiceB'; IncomingSignatureKey: 'IncomingSignatureB';
To make a request from A to B Service A needs to add three extra query parameters to the request:
signedRequest.post('ServiceB', {
appId: 'ServiceA',
signature: 'SignatureHashedWithServiceBSignatureKey'
});
For Service B to validate a request coming from service A:
const signature = require('signature-module')({
validOffset: {
amount: 20,
time: 'minutes'
}
});
FAQs
Signature Module
The npm package signature-module receives a total of 24 weekly downloads. As such, signature-module popularity was classified as not popular.
We found that signature-module 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.