ModernUO/Projects/UOContent/Items
Kamron Batman 4cd668ef61
feat: Moves TcpServer to another thread. Rewrites Firewall (#1660)
## Breaking Changes
* The Firewall and IP Limiter have been rewritten. Please read the notes carefully!
* `TcpServer.Instances` moved back to `NetState.Instances` - sorry - it was stupid to move it to begin with.

> [!Note]
> Sockets that fail the IP Limiter or Firewall will be immediately and forcibly disconnected.
> This means they will be stuck at "Verifying account..." if it was a real client.

### Summary
- Removes firewall wildcard support.
- Removes `AccessRestrictions`.
- Moves Firewall/IPLimiter to the core.
- Moves `TcpServer` to its own thread.
- Removes the `SocketConnect` and `SocketDisconnect` event sinks.
- Moves `Instances` back to `NetState.Instances`.
- Fixes a long standing bug with bad handling of duplicate listener addresses.

#### Firewall
The firewall has been completely rewritten. There is now an "Admin Firewall" which saves to the config file. Secondarily, there is an internal firewall used exclusively by the TcpServer while processing sockets. The Admin firewall mirrors it's additions/deletions to the internal firewall by adding requests to a queue.

> [!IMPORTANT]  
> **Wildcard firewall entries, such as `X`, `*`, `?` are not allowed.**
> **Ranges in between IP classes or sextets are not allowed.**
> **Please make sure to use one of the following:**
> * IP Address - `192.168.1.1`
> * CIDR - `192.168.1.0/24`
> * Range - `192.168.1.1-192.168.1.100`

#### IP Limiter
The IP Limiter has been completely rewritten. The available configurations are:
```json
"ipLimiter.enable": "True",
"ipLimiter.maxConnectionsPerIP": 10,
"ipLimiter.clearConnectionAttemptsDuration": "00:00:00:10",
"ipLimiter.clearThrottledDuration": "00:00:02:00",
```

The IP Limiter is set up to prevent spamming connections from the same IP. Every time an IP connects, it is added to a connection list. After 10 attempts, the IP is added to the throttle list. To keep the system fast, the connection list is entirely wiped every 10 seconds, and the throttle list is entirely wiped every 2 minutes.
2024-01-20 14:25:12 -08:00
..
Addons fix: Fixes serialization and dirty tracking conveniences (#1627) 2023-12-03 15:55:31 -08:00
Aquarium fix: Fixes serialization and dirty tracking conveniences (#1627) 2023-12-03 15:55:31 -08:00
Armor fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Body Parts feat: Adds SerializedCommandProperty (#1249) 2022-11-14 18:24:33 -08:00
Books fix: Fixes thread guard and cleans up incoming packet reader (#1641) 2023-12-19 17:04:09 -08:00
Bulletin Boards fix: Fixes thread guard and cleans up incoming packet reader (#1641) 2023-12-19 17:04:09 -08:00
Champion Artifacts fix: Fixes random bias & Adds back champion arties for UOML (#1235) 2022-11-09 16:33:27 -08:00
Clothing fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Construction fix: Removes GetObjectsInRange and fixes boat planks closing (#1579) 2023-11-03 13:45:18 -07:00
Containers fix: Updates container searches for non-generic types (#1567) 2023-11-23 09:29:45 -08:00
Decoration Artifacts fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Deeds fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Facial Formats UO Content (#201) 2020-08-27 18:30:38 -07:00
Farming fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Food fix: Fix for witch's apprentice quest - was not "beatable" (#1554) 2023-10-17 07:57:59 -07:00
Games fix: Fixes thread guard and cleans up incoming packet reader (#1641) 2023-12-19 17:04:09 -08:00
Gems fix: Codegens gems (#1059) 2022-06-13 17:38:46 -07:00
Guilds fix: Fixes serialization and dirty tracking conveniences (#1627) 2023-12-03 15:55:31 -08:00
Jewels feat: Adds IAosItem for items with AosAttributes (#1268) 2022-11-23 10:49:30 -08:00
Lights feat: Adds SerializedCommandProperty (#1249) 2022-11-14 18:24:33 -08:00
Maps fix: Fixes thread guard and cleans up incoming packet reader (#1641) 2023-12-19 17:04:09 -08:00
Minor Artifacts fix: Fixes serious stacking issue (#1225) 2022-11-02 22:18:44 -07:00
Misc fix: Use pooled ref for corpse instanced loot (#1645) 2023-12-26 10:51:58 -08:00
New Haven Quest Rewards fix: Codegen new haven quest rewards (#1269) 2022-11-23 13:00:28 -08:00
PlantsFlowers/Potted fix: Codegens potted plants (#1270) 2022-11-23 13:04:30 -08:00
Quivers fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Resources fix: Fixes scales, heritage items, and codegens holiday items (#1365) 2023-03-07 22:38:35 -08:00
Shields fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
Skill Items fix: Fixes serialization and dirty tracking conveniences (#1627) 2023-12-03 15:55:31 -08:00
Special feat: Moves TcpServer to another thread. Rewrites Firewall (#1660) 2024-01-20 14:25:12 -08:00
Suits fix: Codegens suits and adds StaffRobe to replace the others (#1468) 2023-08-23 20:25:54 -07:00
Talismans fix: Removes unused SetOldSaveFlag method (#1470) 2023-08-23 22:48:26 -07:00
Traps fix: Changes Map.Sector.Mobiles to link list & Fixes various related crash bugs (#1553) 2023-10-29 22:42:46 -07:00
TreasureChests fix: Updates serialization to use v2.0 (#998) 2022-04-17 08:02:15 -07:00
Wands fix: Changes BaseWeapon to source generator and changes crafter to string (#1519) 2023-09-29 22:45:37 -07:00
Weapons fix: Fixes Feint so it properly reduces damage (#1657) 2024-01-11 00:01:52 -08:00