Boil the shucked corn for 5 minutes. Drain, cool under running water and then, using a sharp knife, cut the kernels from the cob into a bowl. Set aside.
Melt the butter in a heavy saucepan and gently fry the onion and garlic until starting to soften and brown. Add the corn and the chicken or lobster stock and simmer until the vegetables are tender, about 20 minutes. Add the milk. At this point, if you prefer a smoother chowder, you can blend half of the chowder and return it to the pot.
Add all the remaining ingredients except the crab and simmer for 10 minutes to allow the flavours to blend. Add the crab and simmer five more minutes. Check the seasonings and serve garnished with chopped coriander.