Rank | Bot | Approximate Server Count | Library |
---|---|---|---|
1 | MEE6 | 21,300,000 | Custom Python |
2 | Rythm 🪦 | 15,200,000 | JDA |
3 | carl-bot |
10,900,000 | Pycord |
4 | Groovy 🪦 | 10,100,000 | JDA, Discord4J |
5 | Dyno |
Discord bots, just like web servers, deal with untrusted data. Most of those bots implement interactive commands, which makes the attack surface significantly larger. This guide is to improve security of Discord bots.
Security is usually represented by the three elements of CIA (not related to the agency) - Confidentiality, Integrity, and Availability.
- Confidentiality: Protecting your secrets (and others' secrets) from attackers. "Secrets" include your bot token, message contents and other PII, files stored on your computer and other private data.
- Integrity: Protecting your data from manipulation by attackers. "Manipulation" can vary from compromising the host computer to improper permissions/roles assignment or data spoofing/tampering (e.g. cheating in a chess game to obtain points).
- Availability: Protecting your bot from crashes or similar situations. Examples include infinite loop, blocking codes and error handling issues.
Here are some tips to im
Discord timestamps can be useful for specifying a date/time across multiple users time zones. They work with the Unix Timestamp format and can be posted by regular users as well as bots and applications.
The Epoch Unix Time Stamp Converter is a good way to quickly generate a timestamp. For the examples below I will be using the Time Stamp of 1543392060
, which represents November 28th, 2018
at 09:01:00
hours for my local time zone (GMT+0100 Central European Standard Time).
Style | Input | Output (12-hour clock) | Output (24-hour clock) |
---|---|---|---|
Default | <t:1543392060> |
November 28, 2018 9:01 AM | 28 November 2018 09:01 |
#!/bin/python3 | |
from PIL import Image | |
import math, base64 | |
i = Image.open("lcch.png") | |
pixels = i.load() | |
width, height = i.size |
This gist intends on clearing up some of the misinformation surrounding signed chat/the reporting feature Mojang has added to Minecraft 1.19.1. Here you can find both technical information as well as a general explanation of how these work.
After joining a server, clients now send a profile key used for verifying a message's authenticity. This key and thus the whole signing process is optional, but by default, servers enforce secure profiles for clients to send chat messages. Whenever the player sends a chat message and has a key associated, the message will be signed using their own private key, which the server then verifies using the public key sent after join. Assuming signature, timestamp, and message contents line up, the message goes through.
On the other end, clients can also require all broadcasted player messages to be signed, disregarding the ones without sender verified signatures.
[ | |
"928350122843193385", | |
"1185047194261274665", | |
"956202276408688650", | |
"956104664821157918", | |
"1185047092478095443", | |
"1185046791826178099", | |
"1185047045413797898", | |
"928483283698851901", | |
"1185047444619284641", |