Shock absorbers are basically oil pumps. A piston is attached to the end of the piston rod and works against hydraulic fluid or gas in the pressure tube. As the suspension travels up and down, the hydraulic fluid is forced through tiny holes, called orifices, inside the piston. However, these orifices let only a small amount of fluid through the piston. This slows down the piston, which in turn slows down spring and suspension movement.
The amount of resistance a shock absorber develops depends on the speed of the suspension and the number and size of the orifices in the piston. Because of this feature, shock absorbers adjust to road conditions.