Rinse, drain and coarsely chop black beans.
In a small bowl, combine ShaoHsing wine, soy sauce, sugar and salt. Set aside.
In a wok or saucepan, heat vegetable oil on medium heat. Add crushed red pepper flakes, if using and turn heat down to medium low. Cook for a minute.
Add shallots and black beans. Stir fry until the oil is released after being absorbed by the black beans. This will take approximately 5-7 minutes.
Add sauce and let simmer for about 2-3 minutes, stirring occasionally until shallots are tender.
Add garlic and ginger. Stir constantly for 1-2 minutes. Cook until oil rises to the top.
Transfer the sauce to a large bowl. Let cool completely. Store in an airtight jar or container for up to 1 month.
Use 2-3 tablespoons per pound of meat to marinate or add 2-3 tablespoons to your stir-frys.