Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Mqttopia is a Ruby-based project designed to facilitate interactions with MQTT protocols. It provides a modular architecture for handling MQTT clients, subscriptions, and data serialization, making it easier to integrate MQTT into your applications.
gem 'mqttopia', '~> 0.1.0'
gem install mqttopia
You can create or update the mqttopia.rb
file using the included Rake task:
bundle exec rails generate mqttopia:install
The generated mqttopia.rb
will contain:
Mqttopia.configure do |config|
config.hosts = ["localhost"]
config.port = 1883
config.username = "user"
config.password = "xxxx"
config.ssl = true
end
client = Mqttopia::Client.instance
# Subscribe to a topic
client.subscribe('test/#') do |response|
puts "Received: #{response}"
end
# Publish a message to a topic
client.publish('test/topic', 'Hello, MQTT')
illa/{entity}/{entity_id}/{operation}/send/user/{user_id}
illa/{entity}/{entity_id}/{operation}/ask/user/{user_id}
trip_metrics
, test_debug
, ..etc.trips
user/{user_id}
is optionalInitialize Configuration File:
Creates mqttopia_initialize.rb
with default configurations.
bundle exec rake mqttopia:initialize
mqttopia/
├── lib/
│ ├── mqttopia/ # Modules for mqttopia gem
│ | ├── helpers/ # Helper Modules
│ | ├── serializers/ # Modules for payload serialization
│ | ├── subscriptions/ # MQTT Topics's events and services
│ | └── topics/ # MQTT Topic constants [name, regex, service, serializer]
│ |── tasks/ # Rake tasks
│ ├── mqttopia.rb # Main entry point for the gem
│ ├── client.rb # MQTT client implementation
│ └── logger.rb # Logging setup
└── test/ # Minitest-based test suite
git checkout -b feature-branch-name
git commit -m "Add new feature"
git push origin feature-branch-name
This project is licensed under the MIT License. See the LICENSE
file for more information.
If you have any questions or need further assistance, feel free to open an issue or contact the maintainer.
Special thanks to all contributors and users who have made this project possible.
FAQs
Unknown package
We found that mqttopia 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
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.