Resource Collection System Security Improvements
- Bonus System Integration: After calculating the basic cargo capacity of a player's fleets, an additional bonus is applied if the "Depot Expert" officer is present.
- Security Vulnerabilities Closed
- Race Condition Prevention: Errors that could occur due to simultaneous operations are now prevented.
- Data Locking: Planet data is locked during processing using FOR UPDATE.
- Protection Against Timing Manipulations: A maximum time limit has been set.
- Negative Resource Control: Resources will no longer drop to negative values.
- Transaction Order Improved
- Correct Transaction Order: Resources are now deducted before the fleet is sent.
- Safe Resource Calculation: Transfers exceeding capacity are now prevented.
- System Resilience Increased
- Error Management: try/catch blocks have been added.
- Column Control: A flexible mechanism has been developed for the last_request_time column.
- New Features Added
- Detailed Logging: Suspicious transactions can now be detected.
- Anti-Flood Protection: A 3-second wait time has been defined.
- Database Improvements Made
- Index Usage: Performance has been improved in the log table.
Simultaneous transaction errors have been prevented.
Protection against time manipulations has been provided.
Suspicious transactions can now be detected through log entries.