vishavsingla / Anti-Corrupto

This project leverages cutting-edge technologies like blockchain and machine learning to build trust and combat corruption in government systems. Secure Land Registry: Eliminates fraud with tamper-proof land ownership records. Automated Traffic & Challan System (using edge computing): Ensures transparency in traffic enforcement and reduces bribery
4 stars 6 forks source link

Some Suggestions in the ChallanManagement Contract. #48

Open BaibhavTiwari opened 2 months ago

BaibhavTiwari commented 2 months ago

While going through the code, I noticed that we are using block.timestamp and msg.sender for challanId generation.

Which can potentially lead to collisions if multiple transactions happen within the same block from the same address, we can Use a counter or a more unique method for generating challan IDs.