# Harmony Protocol Bug Report ( Hard Fork v2024.1.0 )

**URL:** <https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761>\
**Category:** Protocol\
**Created:** [June 17, 2024, 3:43pm UTC](https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761 "2024-06-17T15:43:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Casey](https://yyz1.discourse-cdn.com/flex035/user_avatar/talk.harmony.one/casey/32/15241_2.png) [@Casey](https://talk.harmony.one/u/Casey)\
**Post date:** [June 17, 2024, 3:43pm UTC](https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761/1 "2024-06-17T15:43:38Z")

</div>

## Harmony Protocol Technical Report

### Date: June 17, 2024

* * *

### Overview

This report provides a comprehensive account of the recent updates, actions taken, and future plans regarding implementing a hard fork in the Harmony Protocol. The hard fork addresses a critical validator max rate issue and aims to ensure the network’s security and integrity. The update has been launched as of this date, and we are awaiting the forking date.

* * *

### Key Actions and Updates

#### 1. Pull Request Merges and Node Upgrades

Merged Pull Requests (PRs): All five critical PRs essential for the hard fork implementation have been successfully merged. These PRs address the validator max rate issue and ensure the proper functioning of the network.

- PR #4687: Essential for the hard fork activation.
- PR #4689 (main\_hotfix): Configures the hard fork activation epoch to 1976.
- PR #4690: Aligns the MaxRateEpoch to epoch 1733 for mainnet.
- PR #4691: Replicates the hard fork activation epoch to the dev branch.
- PR #4692: Corrects the chain configuration order for different networks.

**Node Upgrades:**

- Devnet/Testnet Upgrades: Nodes have been upgraded to release v8369-v2024.0.0-31-gef745011b.
- Mainnet Upgrade: Successfully completed on June 15, 2024.

* * *

### 2. Hard Fork Details

**Activation Epoch:** 1976  
**Activation Time:** June 20, 2024, at 00:06:49 UTC  
**Objective:** The hard fork enforces a uniform validator rate check, ensuring the network’s integrity and the security of user funds. This update addresses discrepancies in the chain configuration and the activation of specific epochs across different network environments.

* * *

### 3. Snapshot Feature Review

**Identified Issue:** The snapshot feature was enabled by default in the main\_hotfix branch, potentially leading to unnecessary complications post-deployment.

Resolution:

- PR #4693: Adjusted the default SnapshotLimit to 0 in the main\_hotfix branch. This PR has been reviewed and approved.
- PR #4694: Adjusted the default SnapshotLimit to 0 in the dev branch. This PR was determined to be redundant and subsequently closed.

* * *

### PR Review and Status

PR #4687:

- Successfully merged; critical for hard fork activation.

PR #4689 (main\_hotfix):

- Configured the hard fork activation epoch to 1976, effective June 20, 2024.

PR #4690:

- Aligned MaxRateEpoch to epoch 1733 for mainnet, ensuring consistency with the v2023.4.2 release.

PR #4691:

- Replicated the hard fork activation epoch to the dev branch, maintaining uniformity across network environments.

PR #4692:

- Corrected the chain configuration order for different networks to prevent future discrepancies.

PR #4693:

- Set SnapshotLimit to 0 in main\_hotfix, preventing unnecessary snapshot creation. Approved and merged.

PR #4694:

- Closed as redundant following a thorough review.

* * *

### Next Steps

1. Observation Period:

- Continue monitoring the upgraded nodes for stability and absence of issues, ensuring network reliability.

1. Validator Community Communication:

- Provide detailed updates and instructions to the validator community regarding the hard fork and related changes.

1. External Node Configuration:

- Ensure all external nodes are updated with the correct snapshot configuration to avoid post-deployment complications.

* * *

### Additional Notes

**Testing and Validation:**

- Comprehensive testing has been conducted in localnet and testnet environments to validate the fixes and ensure the network’s stability and security.

**Coordination and Communication:**

- Maintain clear communication with team members and external partners to facilitate smooth execution of the hard fork and related updates.

**Acknowledgments:** We thank the validator “Colossus” for reporting the initial issue. Their diligence and prompt reporting have been invaluable in addressing this critical concern and improving the network’s security.

* * *

### Conclusion

The Harmony Protocol team has taken decisive actions to address the validator max rate issue, ensuring the security and integrity of the network. Through diligent coordination and thorough testing, we have successfully merged the necessary PRs, upgraded the nodes, and prepared for the upcoming hard fork. We remain committed to maintaining a secure and reliable blockchain environment for all users.

We thank the validator “Colossus” for their crucial role in identifying the issue and enabling us to implement these vital updates. We look forward to a seamless hard fork activation and continued network stability.

---

<div class="post-metadata">

**Author:** ![WhitePeach](https://avatars.discourse-cdn.com/v4/letter/w/aca169/32.png) [@WhitePeach](https://talk.harmony.one/u/WhitePeach)\
**Post date:** [June 18, 2024, 2:40pm UTC](https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761/2 "2024-06-18T14:40:07Z")

</div>

The date on the title should be June 17, 2024?

---

<div class="post-metadata">

**Author:** ![Casey](https://yyz1.discourse-cdn.com/flex035/user_avatar/talk.harmony.one/casey/32/15241_2.png) [@Casey](https://talk.harmony.one/u/Casey)\
**Post date:** [June 18, 2024, 6:23pm UTC](https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761/3 "2024-06-18T18:23:44Z")

</div>

Fixed the date. Thanks for the heads up.

---

<div class="post-metadata">

**Author:** ![Casey](https://yyz1.discourse-cdn.com/flex035/user_avatar/talk.harmony.one/casey/32/15241_2.png) [@Casey](https://talk.harmony.one/u/Casey)\
**Post date:** [July 26, 2024, 1:09pm UTC](https://talk.harmony.one/t/harmony-protocol-bug-report-hard-fork-v2024-1-0/24761/4 "2024-07-26T13:09:19Z")

</div>

### Harmony Protocol Technical Report on MaxRate Bug Fix

#### Date: July 26, 2024

#### Author: Casey Gardiner, Senior Protocol Lead, Harmony Protocol

* * *

### Overview

This report provides an update on successfully implementing a critical hard fork to address the validator max rate issue, including the final resolutions and additional actions taken post-fork.

* * *

### Key Actions and Updates Since the Last Report

#### 1. Bug Fix Implementation and Mainnet Update

**Mainnet Fix:**  
The validator max rate bug has been fixed on the mainnet. This update enforces the max-rate cap to ensure it does not exceed 100%, preventing future issues related to the bug.

#### 2. Bug Bounty Award

**Bug Bounty:**  
In recognition of their critical role in identifying the bug, we are awarding the validator “Colossus” with 1 million ONE tokens.

#### 3. Impact Analysis Script

**Script Summary:**  
A script was developed to calculate the impact of the bug. The script:

- Connects to the Harmony RPC endpoint.
- Identifies validators with high max rates.
- Tracks pending undelegations and identifies malicious activities.
- Generates detailed reports and summaries of the affected validators and delegators.

**Script Location:**  
The full script can be found at [maxrate-bug script](https://github.com/harmony-one/harmony-ops/tree/master/devops/maxrate-bug).

#### 4. Summary of Impact Analysis Results

**Results:**  
The script identified several validators with max rates exceeding the threshold and tracked their pending undelegations. The analysis highlighted:

- Validators with high max rates and their associated delegators.
- Instances of undelegations flagged as potentially malicious based on transaction patterns.

**Detailed Results:**  
For detailed results, refer to [impact analysis results](https://github.com/harmony-one/harmony-ops/tree/master/devops/maxrate-bug/results).

* * *

### Additional Notes

#### Testing and Validation

Comprehensive testing and validation have been conducted in localnet and testnet environments to ensure the stability and security of the network.

#### Coordination and Communication

Maintaining clear communication with team members and external partners has been crucial in facilitating the smooth execution of the hard fork and subsequent updates.

* * *

### Conclusion

The Harmony Protocol team has effectively addressed the validator max rate issue, ensuring network security and integrity. The hard fork was successfully implemented, and the mainnet has been updated. The diligent efforts of Konstantin and Gheis were instrumental in this process. We thank “Colossus” for their valuable contribution in identifying the bug.

If you need any further assistance or have any questions, don’t hesitate to contact the protocol team or me.
