Answered by Shaykh Hamza Karamali, SunniPath Academy Teacher
Whey is a by-product of the cheese-making process. A coagulating agent is added to milk to produce cheese. The liquid that separates contains whey. Further processing of this liquid isolates the whey in a pure form.
In the Name of Allah, Most Merciful and Compassionate
Yes, if the coagulating agent is filth, then the resulting whey would be filthy and unlawful to consume according to the Shafi`i school. This is because adding the agent to the milk will render the entire mixture filthy. Any liquid that is then derived from this mixture will also be filthy. Rennet from un-slaughtered animals, as you correctly note, is considered filth in our school.
And Allah knows best.