Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
grpc-client-promise-wrapper
Advanced tools
Wrap the function of the grpc client, don't use callback anymore
Use async/await for @grpc/grpc-js package
$ npm install grpc-client-promise-wrapper
const promiseWrapper = require('grpc-client-promise-wrapper');
import * as promiseWrapper from 'grpc-client-promise-wrapper';
syntax = "proto3";
package test;
service TestService {
rpc GetTestFn (inputParam) returns (returnValue);
}
message InputParam {
string inputParam = 1;
}
message ReturnValue {
string returnValue = 1;
}
const grpc = require('@grpc/grpc-js');
const protoLoader = require('@grpc/proto-loader');
const promiseWrapper = require('grpc-client-promise-wrapper');
const testStub = () => {
const packageDefinition = protoLoader.loadSync(path.join(__dirname, './test.proto'));
const testService = grpc.loadPackageDefinition(packageDefinition).test;
return promiseWrapper(new testService.TestService('localhost:3001', grpc.credentials.createInsecure()));
};
const getTestFn = async (params) => {
return testStub().getTestFn(params);
};
FAQs
Wrap the function of the grpc client, don't use callback anymore
We found that grpc-client-promise-wrapper 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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.