
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
Rubydium is a framework for building Telegram bots. Built on top of telegram-bot-ruby API wrapper, it aims to provide tools for building your bots with minimum boilerplate.
It's far from being done, but all the code in the examples directory is functional and mostly covered with specs.
CLI tool for creating and setting up new projects is planned. For now:
mkdir example_bot && cd example_bot
bundle init && echo 'gem "rubydium"' >> Gemfile
bundle install
gem install rubydium
touch example_bot.rb
There's two main ways to write your config. With a block:
ExampleBot.configure do |config|
config.token = "1234567890:long_alphanumeric_string_goes_here"
config.bot_username = "ends_with_bot"
config.owner_username = "thats_you"
config.privileged_usernames = %w[
your_friend your_chat_moderator
]
end
Or with a hash:
ExampleBot.config = {
token: "1234567890:long_alphanumeric_string_goes_here",
bot_username: "ends_with_bot",
owner_username: "thats_you",
privileged_usernames: %w[
your_friend your_chat_moderator
]
}
The hash variant also means you can pass in any valid Ruby hash, regardless of where it comes from. For example, you can set the same values, if you parse
example_bot/config.json
:
{
"token": "1234567890:long_alphanumeric_string_goes_here",
"bot_username": "ends_with_bot",
"owner_username": "thats_you",
"privileged_usernames": [
"your_friend",
"your_chat_moderator"
]
}
example_bot/example_bot.rb
:
require "json"
ExampleBot.config = JSON.load_file("./config.json")
example_bot/config.yaml
token: 1234567890:long_alphanumeric_string_goes_here
bot_username: ends_with_bot
owner_username: thats_you
privileged_usernames:
- your_friend
- your_chat_moderator
example_bot/example_bot.rb
:
require "yaml"
ExampleBot.config = YAML.load_file("./config.yaml")
FAQs
Unknown package
We found that rubydium demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.