When a car slams on its brakes what provides friction that helps the car stop? What kind of energy is produced?

i believe it's kinetic energy, once the car stops it may transfer that energy to the ground or even a rock causing it to move; therefore, producing movement.