Flashing is a important part to a roof system, it keeps water from entering the interior of a structure by diverting the water away from the walls and protrusions connected to the roof (chimneys and skylights etc). It is usually done using a combination of metal and sealant. Over time, the sealant on the flashing wears out, also over time the metal can rust. It is recommended to get new flashing with a new roof or if a roof has been done recently, and the flashing did not get replaced.