A cassock (also known as a soutane) is not technically a liturgical vestment, but simply the daily clothing of a priest.
The close fitting, ankle-length robe worn by Roman Catholic clergy as their official garb originated in the classical dress of antiquity. When newer, shorter garments became the style, the clergy continued the older way of dressing.
Laymen participating in a worship service sometimes wear cassocks for the occasion.
In most western countries, the cassock has been virtually replaced by the clerical suit of a more contemporary design and a plain linen alb is worn in the sanctuary.
Cassock Styles
Cassocks come in different styles. A Roman cassock has 33 buttons down the front; a French cassock has fewer front buttons, but buttons sewn to the sleeves after the manner of a suit, and a broader skirt.
A Jesuit cassock has a fly fastened with hooks. An Anglican cassock is double breasted and fastens at the shoulders on the opposing side of the breast.
Cassock Colors
Black is the usual color for the cassocks of priests, although white is favored in the tropics.
The color for bishops and other prelates is purple, for cardinals red, and white for the pope.
Cardinals, bishops and other prelates also have what is called a "house cassock," which is black with red or purple piping, buttons, buttonholes, and sash-loops; this is usually worn with a sash.
The complete ecclesiastical habit of a priest differs from the house cassock of a prelate only in the color of the piping, buttons and other trim, which must be black.
References
Victor Schultze, "Vestments." New Schaff-Herzog Encyclopedia of Religious Knowledge (Baker Book House, 1950).