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.
rss-to-twitter
Advanced tools
This is the module that you need to send rss news to a twitter account.
This is the module that you need to send rss news to a twitter account.
support for:
npm i rss-to-twitter
get your twitter api keys https://developer.twitter.com/en/portal/dashboard
const rssToTwitter = require("rss-to-twitter");
const {
TWITTER_CONSUMER_KEY: consumerKey,
TWITTER_CONSUMER_SECRET: consumerSecret,
TWITTER_ACCESS_TOKEN: accessToken,
TWITTER_ACCESS_TOKEN_SECRET: accessTokenSecret,
} = process.env;
rssToTwitter({
consumerKey,
consumerSecret,
accessToken,
accessTokenSecret,
cron: "0 0 6 * * *", // publish every day at 6:00 AM , cron sintaxis
timezone: "America/Havana", // your defined timezone
// rss source
// can be an async function or and array of objects
source: "https://feed.informer.com/digests/ZO8A5LZCGA/feeder.rss",
// source: async () => {
// return db.get({ limit: 10 }); // your custom source of items,(db)
// },
// source: [{colo:"red"}],
// add new fields to show in the message
// define you own message template
template: "Color is {{color}},{{title}}\n{{link}}",
preprocess: async (item) => {
item.color = "green";
item.short = await bitly.short(item.link);
return item;
},
// filter news of the day, use this function to filter already published posts
filter: async ({ date }) => {
const d = new Date();
return (
date.getDate() === d.getDate() &&
date.getMonth() === d.getMonth() &&
date.getFullYear() === d.getFullYear()
);
},
// add extra common fields to all items,
extraFields: { colo: "red", line: "stroke" }, // add line field to all items and overwrite color field
});
# ┌────────────── second (optional)
# │ ┌──────────── minute
# │ │ ┌────────── hour
# │ │ │ ┌──────── day of month
# │ │ │ │ ┌────── month
# │ │ │ │ │ ┌──── day of week
# │ │ │ │ │ │
# │ │ │ │ │ │
# * * * * * *
0 */5 * * * *
0 */15 * * * *
0 30 * * * *
0 0,5,10 * * * *
0 */30 * * * *
More example https://crontab.guru/examples.html
https://github.com/moment/moment-timezone/blob/develop/data/packed/latest.json
use the preprocess function to add fields, then modify the template to show the new fields in the message
rssToTwitter({
...
preprocess: async (item) => {
item.color = "green";
return item;
},
template: 'Color is {{color}}, Link is {{link}}, Title is {{title}} \n @{{channel}}',
...
})
Donate Bitcoin:
bitcoin:3GqQcxFk5y7onUyoTKqZHwoWXvLusqJSVG
3GqQcxFk5y7onUyoTKqZHwoWXvLusqJSVG
Contact: fabiel.leon.oliva@gmail.com
FAQs
This is the module that you need to send rss news to a twitter account.
The npm package rss-to-twitter receives a total of 0 weekly downloads. As such, rss-to-twitter popularity was classified as not popular.
We found that rss-to-twitter 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.