Dear MetaQuotes Development and Technical Support Team,
We are conducting a technical forensic investigation of MetaTrader 5 Strategy Tester behavior, specifically concerning Expert Advisor (EX5) binary transfer, loading, storage, and runtime identity verification.
During several independent native Strategy Tester runs, we observed a recurring discrepancy between the physical sizes of archived EX5 reference artifacts associated with our project records and the sizes reported in MetaTester Agent and Strategy Tester journal messages.
We would appreciate an authoritative technical explanation of this behavior and guidance on how to verify the exact binary executed by a local testing agent.
1. Observed Size Discrepancies
The following discrepancies have been documented:
Expert / Version
Physical size of archived reference artifact
Journal-reported size
Difference
STEP8 StateFixture v1.0
29,168 bytes
29,239 bytes
+71
Recovery v1.4.0
160,200 bytes
160,293 bytes
+93
STEP8 StateFixture v2.0.3
40,282 bytes
40,376 bytes
+94
PBQ-01 Telemetry v1.2.1
137,048 bytes
137,148 bytes
+100
The differences are consistently positive, although their magnitudes are not constant.
Important clarification: The physical files listed above are archived reference artifacts associated with the respective project records. Their identity with the exact binaries loaded by the MetaTester agents has not been independently established.
PBQ-01 v1.2.1 — Detailed Evidence
For our most recent case:
Archived and installed EX5 reference size: 137,048 bytes.
The actual EX5 binary received and executed by the Agent was not captured as a physical file.
The corresponding MQ5 source, compilation records, archived EX5 copies, and SHA256 manifests are available.
The Agent and Tester logs contain matching Expert paths, symbol, timeframe, date range, and run identifier. However, we cannot establish whether their identical size messages represent independent measurements or the same reported event.
2. Meaning of the "Bytes Loaded" Journal Message
The MetaTrader 5 Strategy Tester journal contains messages in the following form:
"expert file added: ... N bytes loaded"
We would appreciate clarification on the exact technical meaning of this value.
Specifically:
Does N represent the exact raw byte size of the original EX5 file on disk?
Is this value measured before or after any internal processing, packaging, synchronization, or transfer operation?
Can the reported number legitimately differ from the physical size of the original EX5 file without the executable code itself being different?
Are there documented circumstances in which the reported size is larger than the original EX5 file size?
Is the value affected by the MetaTrader terminal build, MetaTester Agent build, or communication protocol?
When the same size is reported in both the Agent and Tester/Core journals, are these independent measurements, or can one journal message be forwarded or reproduced from the other?
We are particularly interested in understanding whether the four observed differences could have a common technical explanation.
3. EX5 Storage and Local Agent Architecture
We have reviewed the following official MetaQuotes documentation:
We noticed descriptions that appear to differ regarding the storage of Expert Advisor files on testing agents.
The Testing Features documentation states that agents do not save EX5 files received from the platform to their hard disks for security reasons.
However, the Files and Folders documentation describes an MQL5 directory under a local testing agent where the Expert Advisor used in the last test may be stored.
Could you clarify the exact behavior for current MetaTrader 5 local testing agents?
In particular:
Is the received EX5 physically materialized in the local Agent directory?
If the binary is not stored on disk, how is it transferred to and made available to the execution process?
Does the storage behavior differ between local, remote, and cloud agents?
Does it depend on the MetaTrader 5 or MetaTester Agent build?
Is there a supported method to inspect or preserve the exact received binary during or immediately after loading?
4. Binary Fingerprints and Runtime Identity Verification
The official Testing Features documentation mentions MD5 fingerprints associated with data blocks transferred between the platform and testing agents.
We would like to understand their exact scope.
Does the MD5 fingerprint cover the raw EX5 binary itself?
Does it cover a combined data block containing the Expert Advisor and its input parameters?
Does it include other transferred resources or metadata?
Can the fingerprint be accessed through an official diagnostic interface or journal?
Is there an officially supported method to obtain the SHA256 hash, MD5 fingerprint, or another cryptographic identity of the exact EX5 binary received and executed by a local Agent?
If the Agent does not persist the EX5 file on disk, what is the recommended way to independently verify that the binary executed by the Agent is identical to the approved compiled artifact selected in the terminal?
We do not intend to decompile or modify the EX5 binary. Our objective is solely to establish reliable binary provenance and execution identity.
5. Can a Size Difference Exist Without an Executable Difference?
This is our most important practical question.
In the PBQ-01 v1.2.1 case, the archived physical EX5 artifact is 137,048 bytes, whereas both the Agent and Tester journals report 137,148 bytes.
Could this difference represent an internal representation, transfer-related size, or another legitimate measurement that does not imply a difference in the actual executable content?
Alternatively, should this discrepancy be treated as evidence that a different EX5 binary was loaded?
Is there a supported method to compare the executable payload independently of any additional data or internal representation?
We would particularly appreciate guidance on how to determine whether two differently sized representations contain the same executable payload.
6. MetaTrader Environment
Our environment is:
Operating system: Windows.
Platform: MetaTrader 5 Desktop.
Testing component: MetaTrader 5 Strategy Tester.
Testing mode: Every tick based on real ticks.
Agent type: Local MetaTester Agent.
Agent endpoint: 127.0.0.1:3000.
MetaEditor build used for the PBQ-01 v1.2.1 compilation: Build 6331.
MetaTrader 5 Terminal build: Not yet independently verified.
MetaTester Agent build: Not yet independently verified.
We can provide sanitized Agent and Tester journal excerpts, archived EX5 reference artifacts, SHA256 manifests, and additional evidence if required.
7. Requested Technical Clarification
We would be grateful if the development team could address the following points explicitly:
The precise meaning of the journal-reported "bytes loaded" value.
The reason why it can differ from the physical EX5 artifact size, if such a difference is legitimate.
The relationship between Agent and Tester journal messages.
The exact storage and transfer behavior of EX5 files in local MetaTester agents.
An officially supported procedure for verifying the cryptographic identity of the actual binary executed by the Agent.
Our goal is to establish a reproducible and technically reliable source-to-compile-to-runtime verification process for Expert Advisors tested through MetaTrader 5.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Dear MetaQuotes Development and Technical Support Team,
We are conducting a technical forensic investigation of MetaTrader 5 Strategy Tester behavior, specifically concerning Expert Advisor (EX5) binary transfer, loading, storage, and runtime identity verification.
During several independent native Strategy Tester runs, we observed a recurring discrepancy between the physical sizes of archived EX5 reference artifacts associated with our project records and the sizes reported in MetaTester Agent and Strategy Tester journal messages.
We would appreciate an authoritative technical explanation of this behavior and guidance on how to verify the exact binary executed by a local testing agent.
1. Observed Size Discrepancies
The following discrepancies have been documented:
The differences are consistently positive, although their magnitudes are not constant.
Important clarification: The physical files listed above are archived reference artifacts associated with the respective project records. Their identity with the exact binaries loaded by the MetaTester agents has not been independently established.
PBQ-01 v1.2.1 — Detailed Evidence
For our most recent case:
Archived and installed EX5 reference size: 137,048 bytes.
SHA256: 6BD0C7398E0D20FFFEADCF7A641FB85B4E43761EAF06F9B993F51EEF2D95A282
Agent journal-reported size: 137,148 bytes.
Tester/Core journal-reported size: 137,148 bytes.
The actual EX5 binary received and executed by the Agent was not captured as a physical file.
The corresponding MQ5 source, compilation records, archived EX5 copies, and SHA256 manifests are available.
The Agent and Tester logs contain matching Expert paths, symbol, timeframe, date range, and run identifier. However, we cannot establish whether their identical size messages represent independent measurements or the same reported event.
2. Meaning of the "Bytes Loaded" Journal Message
The MetaTrader 5 Strategy Tester journal contains messages in the following form:
"expert file added: ... N bytes loaded"
We would appreciate clarification on the exact technical meaning of this value.
Specifically:
Does N represent the exact raw byte size of the original EX5 file on disk?
Is this value measured before or after any internal processing, packaging, synchronization, or transfer operation?
Can the reported number legitimately differ from the physical size of the original EX5 file without the executable code itself being different?
Are there documented circumstances in which the reported size is larger than the original EX5 file size?
Is the value affected by the MetaTrader terminal build, MetaTester Agent build, or communication protocol?
When the same size is reported in both the Agent and Tester/Core journals, are these independent measurements, or can one journal message be forwarded or reproduced from the other?
We are particularly interested in understanding whether the four observed differences could have a common technical explanation.
3. EX5 Storage and Local Agent Architecture
We have reviewed the following official MetaQuotes documentation:
Testing Features:
https://www.metatrader5.com/en/terminal/help/algotrading/testing_features
Files and Folders:
https://www.metatrader5.com/en/terminal/help/start_advanced/structure
We noticed descriptions that appear to differ regarding the storage of Expert Advisor files on testing agents.
The Testing Features documentation states that agents do not save EX5 files received from the platform to their hard disks for security reasons.
However, the Files and Folders documentation describes an MQL5 directory under a local testing agent where the Expert Advisor used in the last test may be stored.
Could you clarify the exact behavior for current MetaTrader 5 local testing agents?
In particular:
Is the received EX5 physically materialized in the local Agent directory?
If the binary is not stored on disk, how is it transferred to and made available to the execution process?
Does the storage behavior differ between local, remote, and cloud agents?
Does it depend on the MetaTrader 5 or MetaTester Agent build?
Is there a supported method to inspect or preserve the exact received binary during or immediately after loading?
4. Binary Fingerprints and Runtime Identity Verification
The official Testing Features documentation mentions MD5 fingerprints associated with data blocks transferred between the platform and testing agents.
We would like to understand their exact scope.
Does the MD5 fingerprint cover the raw EX5 binary itself?
Does it cover a combined data block containing the Expert Advisor and its input parameters?
Does it include other transferred resources or metadata?
Can the fingerprint be accessed through an official diagnostic interface or journal?
Is there an officially supported method to obtain the SHA256 hash, MD5 fingerprint, or another cryptographic identity of the exact EX5 binary received and executed by a local Agent?
If the Agent does not persist the EX5 file on disk, what is the recommended way to independently verify that the binary executed by the Agent is identical to the approved compiled artifact selected in the terminal?
We do not intend to decompile or modify the EX5 binary. Our objective is solely to establish reliable binary provenance and execution identity.
5. Can a Size Difference Exist Without an Executable Difference?
This is our most important practical question.
In the PBQ-01 v1.2.1 case, the archived physical EX5 artifact is 137,048 bytes, whereas both the Agent and Tester journals report 137,148 bytes.
Could this difference represent an internal representation, transfer-related size, or another legitimate measurement that does not imply a difference in the actual executable content?
Alternatively, should this discrepancy be treated as evidence that a different EX5 binary was loaded?
Is there a supported method to compare the executable payload independently of any additional data or internal representation?
We would particularly appreciate guidance on how to determine whether two differently sized representations contain the same executable payload.
6. MetaTrader Environment
Our environment is:
Operating system: Windows.
Platform: MetaTrader 5 Desktop.
Testing component: MetaTrader 5 Strategy Tester.
Testing mode: Every tick based on real ticks.
Agent type: Local MetaTester Agent.
Agent endpoint: 127.0.0.1:3000.
MetaEditor build used for the PBQ-01 v1.2.1 compilation: Build 6331.
MetaTrader 5 Terminal build: Not yet independently verified.
MetaTester Agent build: Not yet independently verified.
We can provide sanitized Agent and Tester journal excerpts, archived EX5 reference artifacts, SHA256 manifests, and additional evidence if required.
7. Requested Technical Clarification
We would be grateful if the development team could address the following points explicitly:
The precise meaning of the journal-reported "bytes loaded" value.
The reason why it can differ from the physical EX5 artifact size, if such a difference is legitimate.
The relationship between Agent and Tester journal messages.
The exact storage and transfer behavior of EX5 files in local MetaTester agents.
An officially supported procedure for verifying the cryptographic identity of the actual binary executed by the Agent.
Our goal is to establish a reproducible and technically reliable source-to-compile-to-runtime verification process for Expert Advisors tested through MetaTrader 5.
Thank you for your time and technical assistance.
Best regards,
EdgeLab EL201 Research Project