I’m not sure of a formal definition. However having worked in the field... I would say that Permanent way is everything above the formation*, ie rail, sleepers, fastenings, ballast, and any sand / geotextile membrane that separates the ballast from the formation.
Track is rail, sleepers and fastenings only.
The one part of ambiguity is track drainage. Definitely not part of the track, but could be part of the permanent way.
*formation being the subgrade, and everything beneath it, ie the basic civils. This is the responsibility of the
Civil Engineer, not the Permanent Way** Engineer.
** unhelpfully, most permanent way engineers are now known as track engineers. But they look after the whole permanent way, and their professional body is the Permanent Way Institution.