There is a fairly large variation in the types of inorganic substrates that these microorganisms can use to produce energy. Sulfur is one of many inorganic substrates that can be used in different reduced forms depending on the specific biochemical process that a lithotroph uses. The chemolithotrophs that are best documented are aerobic respirers, meaning that they use oxygen in their metabolic process.  The list of these microorganisms that employ anaerobic respiration though is growing. At the heart of this metabolic process is an electron transport system that is similar to that of chemoorganotrophs. The major difference between these two microorganisms is that chemolithotrophs directly provide electrons to the electron transport chain, while chemoorganotrophs must generate their own cellular reducing power by oxidizing reduced organic compounds. Chemolithotrophs bypass this by obtaining their reducing power directly from the inorganic substrate or by the reverse electron transport reaction. Certain specialized chemolithotrophic bacteria use different derivatives of the Sox system; a central pathway specific to sulfur oxidation. This ancient and unique pathway illustrates the power that chemolithotrophs have evolved to use from inorganic substrates, such as sulfur.
In chemolithotrophs, the compounds - the electron donors - are oxidized in the cell, and the electrons are channeled into respiratory chains, ultimately producing ATP. The electron acceptor can be oxygen (in aerobic bacteria), but a variety of other electron acceptors, organic and inorganic, are also used by various species. Aerobic bacteria such as the nitrifying bacteria, Nitrobacter, use oxygen to oxidize nitrite to nitrate. Some lithotrophs produce organic compounds from carbon dioxide in a process called chemosynthesis, much as plants do in photosynthesis.  Plants use energy from sunlight to drive carbon dioxide fixation, but chemosynthesis can take place in the absence of sunlight (e.g., around a hydrothermal vent). Ecosystems establish in and around hydrothermal vents as the abundance of inorganic substances, namely hydrogen, are constantly being supplied via magma in pockets below the sea floor.  Other lithotrophs are able to directly use inorganic substances, e.g., ferrous iron, hydrogen sulfide, elemental sulfur, thiosulfate, or ammonia, for some or all of their energy needs.
Here are a few examples of chemolithotrophic pathways, any of which may use oxygen or nitrate as electron acceptors: