Put garlic, onions and ginger in blender and blend with 1 cup of water until fine.
Marinate chicken legs in this paste for about 1/2 hour.
Put marinated chicken legs in a sauce pot and pour thin coconut milk over it.
Add cardamom and cloves and cook over medium heat until chicken is partly cooked, about 15 minutes.
Then pinch in a little bit of salt and sugar.
Take the chicken out of the pot, reserving the sauce in the pot. Then place the chicken on baking tray and cook under the oven grill (broiler) at medium heat for 8 minutes.
Take the sauce that was left in the pot and discard the cardamom and cloves. Then add tamarind juice, chilli paste, thick coconut milk and glutinous rice flour in and stir.
Again season with salt, pepper and sugar and cook until it thickens. Stir continuously.
When the sauce thickens, ladle the sauce over the chicken and return to grill.
Cook until the sauce begins to dry up a little then turn the chicken and ladle sauce over and cook again.
Repeat this process of coating the chicken with the sauce about four times until chicken is cooked well.