How to Check an EA for Malware or Backdoors

Quick Answer

To check an EA for malware or backdoors, source it only from a reputable channel, verify the publisher's identity and track record independently, and inspect the exact permissions it asks for before you ever enable live trading. In MetaTrader 4 and MetaTrader 5, that means checking whether the EA requests "Allow DLL imports" (a major red flag from unknown sources) and reviewing which external URLs it wants whitelisted under WebRequest. Run the EA on a demo account first and watch the Journal and Experts tabs for connections or actions that don't match the product description. Cross-check any performance claim against an independently verifiable record rather than a screenshot, and never install a cracked or "free" copy of a paid EA, since pirated files are one of the most common backdoor delivery methods in retail trading communities. None of this takes more than 20-30 minutes, and skipping it is how traders hand control of their MT4/MT5 terminal to a stranger.

Automated trading has made it easier than ever to run a rules-based strategy around the clock, but that convenience comes with a real exposure: an Expert Advisor is a program with the same level of access to your trading terminal as you have yourself. A malicious or compromised EA can place trades you never authorized, leak your account credentials, or quietly funnel a copy of every order to someone else's server. Most traders never think to audit an EA the way they would any other software they install, and that gap is exactly what scammers rely on. This guide walks through a practical, repeatable process for vetting any EA - free or paid, MT4 or MT5 - before you let it anywhere near a funded account.

Why EA Security Is a Real Concern, Not Paranoia

An Expert Advisor is compiled code that runs inside your MetaTrader terminal with permission to read market data, manage orders, and, if you allow it, reach outside the platform entirely. When you enable "Allow DLL imports" for an EA, you are giving it the same system-level access as any other Windows executable - it can, in theory, read files, write to disk, or communicate with a remote server outside of MetaTrader's own network controls. That is a legitimate feature used by some professional tools for chart automation or data logging, but it is also the exact door a badly-intentioned developer would want open. The MetaTrader 5 terminal documentation explains these permission settings in detail, and it is worth reading once so you know what each toggle actually does before you click "OK" on an installation prompt.

This is not a hypothetical risk. US regulators have repeatedly warned retail traders about automated "trading system" products sold with fabricated results or hidden functionality. The CFTC's advisory on trading system fraud flags software sold with unverifiable performance claims, and the FTC's guidance on investment scams lists "too good to be true" automated returns as a classic warning sign. Reading both before you buy any EA takes about ten minutes and changes how you evaluate every listing afterward.

Where You Get the EA Determines Most of Your Risk

The single biggest predictor of whether an EA is safe is not the code itself - it's the channel you got it from. A developer selling through a controlled marketplace has accountability and technical restrictions working in your favor; a file downloaded from an anonymous Telegram channel or a "free EA" torrent has none of that. Before you evaluate anything else, be honest with yourself about where the .ex4 or .ex5 file actually came from.

SourceTypical Risk LevelHow You Verify It
MQL5 Market listingLower - sandboxed execution, no DLL calls, no arbitrary file accessCheck publisher profile age, review count, and whether source or only compiled code is offered
Developer's own site with a public, independently verified track recordModerate - depends entirely on the seller's transparencyConfirm the Myfxbook or MQL5 signal link is broker-verified, not just a screenshot
Telegram group, Discord server, or forum "free download"High - no accountability, files often modified from the originalCannot be reliably verified; treat as untrusted by default
Cracked or "cost-free" copy of a paid EAHighest - frequently re-packaged with injected codeNo verification possible; the license check itself may have been replaced with malicious code

The MQL5 Market deserves a specific mention because its technical restrictions do real security work: EAs distributed through it run in a sandbox that blocks DLL imports and restricts file-system access to a dedicated common folder, and any external network call must be explicitly declared and approved by you at installation. That does not make every listing trustworthy - a bad strategy can still lose your money - but it closes off the most dangerous backdoor mechanisms by design. The MQL5 documentation covers these sandbox restrictions if you want the technical detail. If an EA is being distributed anywhere else and specifically avoiding the Market, ask yourself why a legitimate developer would skip the one channel with built-in safeguards.

Step 1: Verify the Publisher and Track Record Independently

Before you install anything, spend five minutes confirming that the entity selling the EA is who they claim to be and that their results are real. A results screenshot proves nothing - it can be edited in seconds. A verified account link, on the other hand, is tied to a specific broker login and cannot be faked without the broker's cooperation. Look specifically for a Myfxbook account carrying the "verified" badge, which confirms the statement was pulled directly from a live broker feed rather than uploaded manually; the process is explained in Myfxbook's verification knowledge base. An MQL5 signal works the same way, pulling trade history straight from the account rather than a user-submitted export.

Worked example: a seller shows you a screenshot claiming $48,000 in profit over six months on a $10,000 account - a 480% return with no visible equity curve, no drawdown figure, and no way to confirm the trades happened in that order. Compare that to a verified account link, where you can independently check the trade log, the maximum drawdown, and the exact dates - the claim is either backed up or falls apart in front of you. If the seller resists linking a verified account "for privacy reasons," that alone is reason enough to walk away.

Step 2: Check What Permissions the EA Is Actually Requesting

This is the step most traders skip, and it's the most important one from a pure security standpoint. In MetaTrader, open Tools > Options > Expert Advisors before you attach any new EA. Two settings matter most:

  • Allow DLL imports - if checked for an untrusted EA, the program can execute native Windows code outside MetaTrader's own restrictions. Legitimate reasons for this exist (certain VPS monitoring tools, some advanced charting utilities), but a gold-trading strategy EA generally has no reason to need it.
  • Allow WebRequest for listed URL - this is a whitelist you control. Any domain the EA wants to contact for updates, licensing checks, or remote signals must be added here manually by you. If an EA's installation instructions ask you to whitelist an unfamiliar domain, look that domain up before you approve it - not after.

Worked example: you install an EA and its setup guide tells you to whitelist update-license-check.example-domain.net. A legitimate publisher's licensing domain usually matches their own product site. A domain that looks randomly generated, uses a free dynamic-DNS suffix, or has no relationship to the seller's brand is a signal that the "license check" traffic could actually be data exfiltration - account numbers, balance figures, or terminal identifiers sent somewhere you never intended. The MetaTrader 5 automated trading overview explains how WebRequest permissions are meant to function, which is worth comparing against what any specific EA is asking you to approve.

Step 3: Read the Code When Source Is Available

If a developer provides the .mq4 or .mq5 source file rather than only a compiled .ex4/.ex5, you have a real opportunity to check for suspicious behavior even without being a professional programmer. You don't need to understand the whole strategy - you need to search the file for a handful of specific function calls: WebRequest, FileWrite, FileOpen, SendMail, and any #import statement pulling in an external DLL. Every one of these is documented in the official MQL5 language reference, so you can look up exactly what each function is capable of and judge whether its presence makes sense for a gold-trading strategy.

If you find a hard-coded IP address, an unexplained email-sending routine, or a function that writes account information to a file with no obvious purpose in the strategy logic, stop and ask the developer directly what it does before proceeding. A legitimate developer will give you a straight technical answer. Evasive answers, or a developer who refuses to share source code at all while charging a premium price, should push you toward a compiled EA from a channel with independent sandbox restrictions instead - such as the MQL5 Market, which strips out DLL access regardless of what the source contains.

Step 4: Run It on a Demo Account and Watch the Logs

Never send a new EA straight to a live, funded account, no matter how convincing the sales page is. Attach it to a demo account first and let it run for at least a week of live market conditions, keeping the MT4/MT5 Journal and Experts tabs open the entire time. These logs record every action the EA takes, every WebRequest call it makes, and every error MetaTrader itself throws in response to something unusual.

Worked example: your risk setting is configured for a conservative 0.5 lots on a $10,000 demo balance, consistent with standard risk management principles. If the Experts log shows the EA opening a 5.0 lot position instead - ten times larger than the parameter you set - that's either a serious bug or evidence the EA is ignoring your input settings entirely, the same practical outcome as a hidden backdoor even if unintentional. That single log entry is reason enough to stop testing and uninstall it. Pairing this observation with a proper backtest on MT5 beforehand gives you a baseline of expected behavior to compare the live demo run against.

Step 5: Match Actual Behavior Against the Published Description

Every honestly built EA should behave the way its documentation says it will, and any gap between the two deserves an explanation. Read through how EA settings actually work before you tune anything, so you know what a normal parameter range looks like for the strategy type you bought. If the product page describes a selective strategy trading once a day at most, and your demo log shows dozens of trades firing in a single session, something does not match the description - either the settings weren't applied correctly, or the live version of the EA differs from what was advertised.

Worked example: a seller advertises three risk presets - Conservative, Normal, and Aggressive - each tied to a stated percentage of account risk per trade. Run all three on the same demo account with the same starting balance and record the actual position sizes generated over ten trades. If "Conservative" consistently produces position sizes closer to what you'd expect from "Aggressive," the risk-sizing logic doesn't match the labeling, which is either poor quality control or intentional misrepresentation - and you have no way to know which from outside the code. Compare the resulting equity swings against the concept of drawdown and our own breakdown of how drawdown actually works to judge whether the risk you're seeing matches what was promised.

Red Flags Checklist Before You Ever Attach an EA

Red FlagWhy It MattersWhat To Do
Only a compiled .ex4/.ex5 file, no source, from an unfamiliar sellerYou cannot inspect what the code actually doesPrefer sandboxed MQL5 Market listings or request source code
Requires "Allow DLL imports" with no stated technical reasonGrants system-level access outside MetaTrader's own controlsAsk the developer to justify it in writing; decline if unclear
Asks you to whitelist an unfamiliar or randomly named domainCould be exfiltrating account data disguised as a license checkLook up the domain independently before approving WebRequest
Performance shown only as a screenshot, never a verified linkScreenshots can be edited or entirely fabricatedRequire a Myfxbook-verified or MQL5 signal link
Distributed only through Telegram/Discord "free download" groupsNo accountability, frequent history of re-packaged filesTreat as untrusted; source from an accountable channel instead
Guarantees profits or claims "zero risk" tradingA hallmark warning sign flagged directly by US regulatorsReview the CFTC's forex fraud guidance and walk away
Live behavior on demo doesn't match the advertised strategy logicSettings may be ignored, or the live build differs from the demoStop testing, uninstall, and do not fund a live account

What a Transparent, Well-Built EA Should Look Like

It helps to know what "good" looks like, not just what "bad" looks like. A transparently run EA publishes a broker-verified track record rather than asking you to trust a claim, documents its risk settings clearly enough that you can predict how a given mode will behave before you test it, and doesn't ask for permissions beyond what its stated strategy requires. It describes its approach honestly - for example, as a rules-based gold strategy using trend and momentum confirmation on a defined timeframe - without dressing up marginal statistics as guaranteed returns. Our review of proven forex trading systems and the checklist in choosing a broker for a gold EA both walk through the same due-diligence habits, worth cross-referencing before you commit capital.

The Golden Viper EA team, for instance, publishes its live results on a broker-verified Myfxbook account and as an MQL5 signal rather than relying on screenshots, and the EA does not request DLL access or unexplained network permissions to run its XAUUSD strategy. That's the standard you should hold any EA to, regardless of who built it - verifiable results, minimal and explainable permissions, and documentation that matches observed behavior.

Backdoors Aren't Always About Stealing Funds Directly

A common misconception is that a "backdoor" in an EA means someone can reach into your broker account and withdraw your money. In practice, brokers require separate authentication for withdrawals, so an EA generally cannot move funds out of your account on its own. The real risks are different and, in some ways, more insidious:

Backdoor TechniqueWhat It Actually DoesHow You'd Spot It
Credential or account-info exfiltrationSends terminal ID, account number, or balance data to a remote server via WebRequestUnfamiliar domain in the WebRequest whitelist prompt
Hidden trade copyingMirrors your trades to a third party's account without disclosureUnexplained outbound connections logged in the Experts tab
Position-size manipulationOpens lots far larger than your configured risk setting, accelerating lossesCompare logged lot sizes against your input parameters directly
License-check malware injectionA cracked EA's license validation is replaced with malicious code entirelyAny deviation in behavior between the "cracked" and original versions

Notice that most of these techniques rely on you never checking the logs or the permission prompts in the first place. That's why Steps 2 and 4 above - reviewing WebRequest/DLL settings and watching the Journal on a demo account - catch the overwhelming majority of real-world cases, even without any coding background.

Running EAs Safely on a VPS Adds Another Layer to Check

If you run your EA on a VPS for uptime reasons, you introduce a second machine that needs the same scrutiny. Confirm your VPS provider is reputable, and follow a proper VPS setup process rather than accepting a pre-configured image from an unknown source, since a compromised image can plant malware before you've installed any trading software. The same permission checks apply once the EA is running remotely - open Tools > Options > Expert Advisors on the VPS terminal exactly as you would locally, and don't assume a "trusted" VPS provider has already vetted the software you're about to install, because that isn't their job.

What To Do If You Suspect an EA Is Compromised

If anything from the steps above raises a real concern, act immediately rather than waiting to "see what happens":

  1. Right-click the chart and disable Algo Trading, or use the toolbar toggle, to stop the EA from taking any further action.
  2. Remove the EA from the chart and delete the file from your terminal's Experts folder.
  3. Change your broker account password and, if you use a VPS, your VPS credentials as well, since a DLL-enabled EA could theoretically have accessed more than just MetaTrader.
  4. Run a full antivirus/anti-malware scan on the machine or VPS the EA was installed on.
  5. Review our common EA problems and fixes guide to rule out an innocent bug before assuming malicious intent - not every anomaly is a backdoor.
  6. If you paid for the EA and believe you were defrauded, file a complaint through the FTC's investment scam reporting process so the pattern gets tracked, even if you don't expect a personal refund.

Risk Disclosure

Trading gold, forex, and other leveraged instruments carries a real risk of loss, and no verification process - including everything described in this guide - eliminates that risk. Past performance, including any verified track record, does not guarantee future results. Only trade with capital you can genuinely afford to lose, and treat any product that claims otherwise as a red flag in itself. Vetting an EA for malware or backdoors protects your terminal and your data; it does not protect you from ordinary market risk, which is a separate and permanent part of trading.

Frequently Asked Questions

Can an EA actually steal money directly from my broker account?

Not directly in most cases. Brokers require separate authentication for withdrawals, so an EA running inside MetaTrader generally cannot move funds out on its own. The real risk is indirect: an EA can open oversized or excessive trades that lose your money through bad execution, or exfiltrate account data that could be used elsewhere.

Is it safe to buy an EA from the MQL5 Market?

The MQL5 Market runs EAs in a sandbox that blocks DLL imports and restricts file access, which closes off the most dangerous backdoor mechanisms by design. It doesn't guarantee the trading strategy itself is profitable, but it substantially reduces the malware and data-exfiltration risk compared to an unverified download.

What does "Allow DLL imports" actually let an EA do?

Enabling DLL imports lets the EA call external Windows library functions outside MetaTrader's normal sandbox, effectively giving it the same system access as any other program you install. It's a legitimate feature for a small number of specialized tools, but it is unnecessary for the vast majority of trading strategy EAs and should be treated with caution when requested by an unfamiliar publisher.

How do I know if a performance track record is real?

Look for a broker-verified link, such as a verified Myfxbook account or an MQL5 signal, both of which pull trade history directly from a live broker feed rather than a manually uploaded file. A results screenshot alone proves nothing, since it can be edited or fabricated in minutes.

Should I ever run an EA that only comes as a compiled file with no source code?

You can, but only from a channel with independent technical safeguards, such as the sandboxed MQL5 Market, or from a publisher with a long, independently verifiable track record. A compiled-only file from an anonymous forum post or Telegram channel, with no sandbox and no accountability, is the highest-risk combination there is.

What should I watch for in the MetaTrader Journal and Experts logs?

Watch for WebRequest calls to domains you didn't approve, position sizes that don't match your configured risk parameters, and any error message referencing DLL calls or file operations you weren't expecting. Consistent, explainable log entries over a full demo test are a good sign; anything unexplained deserves a direct question to the developer before you proceed further.

Are free EAs more likely to contain malware than paid ones?

Not automatically, but a specific category of "free" EA is high risk: a cracked or pirated copy of a paid product. These are frequently re-packaged with the original license-check code replaced by something else entirely, since the pirate has already demonstrated they're willing to modify the file. A genuinely free EA from an accountable, identifiable developer carries different risk than a cracked version of someone else's paid product.

Can antivirus software detect a malicious EA?

Sometimes, but not reliably. Standard antivirus tools are built to detect known malware signatures, and a targeted backdoor written specifically for trading terminals may not match any existing signature. Running a scan is a reasonable extra step, but it should never replace the manual permission and log checks described in this guide.

Does a demo account fully protect me while testing a new EA?

It protects your trading capital, since no real money is at risk from bad trades, but it does not fully protect your machine if the EA has DLL access and malicious intent, since that access works the same way on a demo account as a live one. Review the DLL and WebRequest permissions before attaching the EA to any account, demo included.

What's the fastest way to sanity-check an EA before spending real money?

Check the permission requests under Tools > Options > Expert Advisors, confirm the seller has a broker-verified track record rather than screenshots, and run it on a demo account for at least several trading days while watching the logs. Those three checks together, done consistently, catch the overwhelming majority of malicious or misrepresented EAs before they ever touch a funded account.

Myfxbook Verified

Automate Your Tutorials Edge

+€1,485Net · 6-mo (verified)
56%Win Rate (51/91)
24/5Automated
Starting at $199 one-time
Get Lifetime Access →
✓ Instant download✓ Full feature access✓ MT4 & MT5 compatible
SR

Sofia Reyes

Sofia Reyes writes about MetaTrader 4/5, Expert Advisors, and automated XAUUSD gold trading for Golden Viper EA.

Myfxbook VerifiedLive since Jan 2026Public track record

Let Golden Viper EA trade gold for you

Automated XAUUSD trading for MT4 & MT5, verified live on Myfxbook. One-time $199, lifetime access.

Get Lifetime Access — $199