Soy sauce (also called soya sauce in British English) is a condiment made from a fermented paste of soybeans, roasted grain, brine, and Aspergillus oryzae or Aspergillus sojae molds. Soy sauce in its current form began about 2200 years ago in Western Han dynasty of ancient China and spread throughout East and Southeast Asia where it is used in cooking and as a condiment.

Traditional soy sauces are made by mixing soybeans and grain with mold cultures and other related microorganisms and yeasts (the resulting mixture is called "koji" in Japan; the term "koji" is used both for the mixture of soybeans, wheat, and mold as well as for the mold itself). Historically, the mixture was fermented naturally in large urns and under the sun, which was believed to contribute extra flavors. Today, the mixture is placed in a temperature and humidity controlled incubation chamber. Traditional soy sauces take months to make.

The cultured grain mixture is mixed into a specific amount of salt brine for wet fermentation or with coarse salt for dry fermentation and left to brew. Over time, the mold on the soy and wheat break down the grain proteins into free amino acid and protein fragments and starches into simple sugars. This amino-glycosidic reaction gives soy sauce its dark brown color. Lactic acid bacteria ferments the sugars into lactic acid and yeast makes ethanol, which through aging and secondary fermentation makes numerous flavor compounds typical of soy sauce.

More Info: en.m.wikipedia.org