George Armstrong Custer, sometime during the Civil War, wearing his temporary (brevet) Major General uniform. He reverted to Captain for a time after the war, before rising again in rank.
General Joseph Reid Anderson, whose Tredegar Iron Company was at the industrial heart of the Confederate States of America. Anderson resigned his army commission on July 19, 1862, so this photo was almost certainly taken before then, unless he donned it again just for the portrait.