Remove the stems of the chilies. Wash them well and then immerse them in a bowl of hot water for 2 hours.
Peel and finely chop the garlic cloves and onion.
Once the chilies are rehydrated, place them in a mixer jar or food processor, and process to get a smooth puree, adding some of the soaking water if required.
In a deep, heavy bottomed pan, heat the oil. When the oil is slightly hot, add the finely chopped garlic and onion. Keep stirring it for 2-3 minutes. Don't let the garlic and onion get brown.
At this point, add the pureed red chilies and stir on medium heat. The mixture will splutter a bit, which is why preparing this in a pan with high sides will work better.
After stirring this for 2-3 minutes, add the vinegar, sugar, soya sauce and salt. Add upto 1/2 cup water (you can use this water to clean up any chili residue in the mixer / food processor). Stir well and allow to simmer for another 8-10 minutes until oil starts oozing out.
Check for salt, and add a pinch more if required. This may be needed if the chillies you use are spicier.
Remove into an airtight container and refrigerate until ready to use. This will stay for 10 days or so in the refrigerator. Use a clean dry spoon to remove required quantities of sauce for any dish.