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.
@cfanoulis/workers-slack
Advanced tools
private fork for testing, please use the original (@sagi.io/workers-slack)
@sagi.io/workers-slack
allows
you to use Slack's Web API within Cloudflare Workers.
⭐ We use it at OpenSay to access Slack's REST API through Cloudflare Workers.
Here is a blog post that explains why I built it.
$ npm i @sagi.io/workers-slack
Initialize SlackREST
:
// Without token:
const SlackREST = require('@sagi.io/workers-slack')
const SlackAPI = new SlackREST()
// With token:
const botAccessToken = process.env.SLACK_BOT_ACCESS_TOKEN;
const SlackREST = require('@sagi.io/workers-slack')
const SlackAPI = new SlackREST({ botAccessToken })
You can then use supported Slack methods.
For instance, here's how to use the chat.postMessage
method:
// SlackREST was initialized with a token
const formData = { channel: 'general', text: 'hello world'}
// SlackREST wasn't initialized with a token
const botAccessToken = process.env.SLACK_BOT_ACCESS_TOKEN;
const formData = { token: botAcccessToken, channel: 'general', text: 'hello world' }
const result = await SlackREST.chat.postMessage(formData)
More information here.
The SlackREST.helpers.verifyRequestSignature
method returns true
when a signature from Slack is verified. Otherwise it throws an error.
const SlackREST = require('@sagi.io/workers-slack')
const SlackAPI = new SlackREST()
const signingSecret = process.env.SLACK_SIGNING_SECRET
const isVerifiedRequest = await SlackAPI.helpers.verifyRequestSignature(request, signingSecret)
FAQs
private fork for testing, please use the original (@sagi.io/workers-slack)
The npm package @cfanoulis/workers-slack receives a total of 0 weekly downloads. As such, @cfanoulis/workers-slack popularity was classified as not popular.
We found that @cfanoulis/workers-slack 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.