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.
facebook-signed-request
Advanced tools
node.js port of facebook-signeded-request. It implements the signed request sent by facebook to applications.
clone this repository and then
var SignedRequest = require(PATH_TO_LIB + '/lib/facebook-signed-request');
SignedRequest.secret = "your facebook application secret";
var request = yourRequestObjectParamsHash['signed_request'];
var signedRequest = new SignedRequest( request );
signedRequest.parse(function(errors, request){
// check if request was valid
console.log(request.isValid());
// access errors
console.log(errors);
// this is your data object
console.log(request.data);
});
You can also sign requests to be used in your tests
SignedRequest.secret = "897z956a2z7zzzzz5783z458zz3z7556";
SignedRequest.encodeAndSign({ user_id : '111111'})
which will output something in the format of
gI7hojzSUZyrEP6/kh7TRCI6PZ6VucX0bvbcKxj10HY.eyJ1c2VyX2lkIjoiMTExMTExMSJ9
Here is an example
{
algorithm: 'HMAC-SHA256',
expires: 1308988800,
issued_at: 1308985018,
oauth_token: '111111111111111|2.AQBAttRlLVnwqNPZ.3600.1111111111.1-111111111111111|T49w3BqoZUegypru51Gra70hED8',
user: { country: 'de', locale: 'en_US', age: { min: 21 } },
user_id: '111111111111111'
}
npm install jasmine-node
jasmine-node spec
FAQs
Facebook Signed Request de- and encoder for node.js
The npm package facebook-signed-request receives a total of 134 weekly downloads. As such, facebook-signed-request popularity was classified as not popular.
We found that facebook-signed-request 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.