
Research
Malicious fezbox npm Package Steals Browser Passwords from Cookies via Innovative QR Code Steganographic Technique
A malicious package uses a QR code as steganography in an innovative technique.
Official Metrafin API Client for Node.js
GitHub | NPM | Official API Documentation
npm i metrafin
const App = require('metrafin')
Create an application with its private token.
const myApp = new App('VLeIjSNigss5eqLcNf5Snv2kh_d-HWOv1-ojr952gpW0CyKt')
// in async context
const userInfoA = await myApp.resolveUser('username', 'ethan')
// => { error: null, userId: 'd2ed3320-af45-4136-bc51-bb48a62da7dc', username: 'ethan' }
// or...
const userInfoB = await myApp.resolveUser('userId', '9175009b-b215-4be8-a3a8-88322757804d')
// => { error: null, userId: 'd2ed3320-af45-4136-bc51-bb48a62da7dc', username: 'ethan' }
authorization_code
)Create an auth instance using an authorization_code
. You may access the accessToken as a property of the created authorization if all is successful.
It is recommended that you check that all of the OAuth scopes you expect are present in the auth instance's scopes
array.
const auth = await myApp.auth('rmxQPAll1kEhsc8u-IPwBkwyNdixJCSf', 'authorizationCode')
console.log('Auth accessToken: ' + auth.accessToken)
console.log('Auth userId: ' + auth.userId)
console.log('Auth scopes: ' + auth.scopes)
console.log('Auth expires: ' + auth.expires)
Create an auth instance using an access token
.
const auth = await myApp.auth('rmxQPAll1kEhsc8u-IPwBkwyNdixJCSf', 'accessToken')
console.log('Auth accessToken: ' + auth.accessToken)
console.log('Auth userId: ' + auth.userId)
console.log('Auth scopes: ' + auth.scopes)
console.log('Auth expires: ' + auth.expires)
See profile information documentation for details about the profile response.
await auth.getProfile()
See permissions documentation for details about the permissions response.
await auth.getPermissions()
See HonorScore documentation for details about the HonorScore response.
await auth.getHonorScore()
See reputation event documentation for details about reputation events.
await auth.createReputationEvent({
'context': 'public_comment',
'tag': 'spam',
'type': 'negative',
'description': 'Excessive commenting on a video'
})
// => {"error": null, "eventId": "0f6ca352-480a-468d-a99f-43580ccf4aff"}
await auth.getReputationEvents()
// => {"error": null, "reputationEvents": [ ... ]}
await auth.setReputationEventActive('ef8c4ce3-2f02-4647-ab5e-727387184e15', false)
// This will deactivate the reputation event with ID ef8c4ce3-2f02-4647-ab5e-727387184e15.
If you have questions or feedback about the package, feel free to let us know in GitHub issues.
Feel free to contribute through PRs as well. :)
FAQs
Official Metrafin API Client for Node.js
We found that metrafin 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
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.
Application Security
/Research
/Security News
Socket detected multiple compromised CrowdStrike npm packages, continuing the "Shai-Hulud" supply chain attack that has now impacted nearly 500 packages.