Put the ham in a large container of cold water. Soak it for at least a day, preferably longer, changing the water several times.
When you are ready to cook, scrub the ham and put it into a container large enough to hold it and enough water to cover it. Add all the ingredients except the cloves and brown sugar. Bring to a boil, reduce the heat, and simmer for 5 hours, adding more water if needed. Turn off the heat and let the ham cool overnight in the liquid.