How do I protect my members from stolen tokens and malicious code?

SecurityOriusBotGuardCode
Security centre — inside the OriusBot admin panel.
Security centre — inside the OriusBot admin panel.

Code scanning looks at the code blocks your members post and spots what should never be public: bot tokens, webhook addresses, malicious code. It is provided by OriusBotGuard.

Turn it on

  1. Open the Security page Left menu, Protection section, then Security.
  2. Find the “Code scanning” line
  3. Turn the switch on
  4. (Optional) Turn on the “extended sources” line just below, which adds scanning engines. Greyed out = not included in your plan.

If you want to turn it off

A “Disable Code scanning?” window opens. It explains that your members would then be exposed to token theft (token grabbers) and to malicious code hidden in files and text. Click Cancel to keep the protection, or Disable anyway.

Set the threat threshold

The threat threshold is a danger score from 10 to 100. From that score on, a file or code is blocked.

  • Lower = stricter, but more wrong blocks (false positives).
  • Higher = fewer wrong blocks, but more dubious code gets through.
  • Default value: 50.
  1. Look for the “Module status” card The setting is at the very bottom, named Threat threshold (OriusBotGuard).
  2. Type a number between 10 and 100 The field is on the right. It saves by itself.
Greyed-out field? This setting carries a Pro badge (“Code scan threshold”). Without the subscription, it stays at 50 and cannot be changed.

Frequently asked questions

A member posted a code example and it was blocked

The threshold may be too low. Raise it in steps of 10 and test again.

A bot token was published by mistake

Even if the message is deleted, consider the token compromised: regenerate it immediately in Discord’s developer portal.

Still stuck?

Contact support with the title of this article, the step where you are stuck and what you see on screen.

Contact support More articles: Protection

Last checked: 13 November 2026.