Foul odors are a common problem in well water systems. They are generally caused by hydrogen sulfide (H2S) gas, which can get into water sources in a number of ways: via sewage systems, near coal and peat deposits, in oil fields, and most commonly from iron and sulfur bacteria.
These bacteria thrive on iron and sulfur, and chemically convert sulfates to produce H2S gas, causing the odors commonly experienced in well water systems.
The two main methods used to treat strong sulfur odors are aeration and chemical injection with hydrogen peroxide or chlorine:
Self-contained sulfur filters use direct air injection to oxidize sulfur out of your water, then pass the water through a bed of filtration media specifically designed to remove odors from water.
These systems are automatically backwashing, meaning the media inside is cleaned every 1-2 nights, prolonging the life of the media and providing the air used for oxidation.
The other option is to inject hydrogen peroxide or chlorine via a metering pump, providing extra strength for oxidation of strong odors, and treating iron and manganese, which might also be fouling up your system.
This system will also disinfect your water of all common household bacterial contamination. The system works by feeding hydrogen peroxide or chlorine into a contact tank or inline mixer to ensure that the disinfectant is thoroughly mixed and has enough contact time to kill any bacteria present.
You could also install a carbon filter after the chlorinator to filter out the oxidized particulate matter and remove any lingering chlorine tastes.
Here is a diagram of a standard installation of a chlorine metering pump, contact tank, and post-treatment carbon filter: