Until recently, with its rejection of Latter Day Saints' baptism (see here and here), the Catholic Church has always accepted "Protestant" baptism as valid.
The question of whether the baptism of heretics and schismatics is valid or not, arose centuries ago about 250 CE between Pope Stephen and Bishops Cyprian and Firmillian.
Cyprian et al argued this way in short. (emphasis mine in the quotations)
and holding it for certain that no one can be baptized abroad outside the Church, since there is one baptism appointed in the holy Church. And it is written in the words of the Lord, “They have forsaken me, the fountain of living waters, and hewed them out broken cisterns, which can hold no water.”2812 And again, sacred Scripture warns, and says, “Keep thee from the strange water, and drink not from a fountain of strange water.”2813 It is required, then, that the water should first be cleansed and sanctified by the priest,2814 that it may wash away by its baptism the sins of the man who is baptized; because the Lord says by Ezekiel the prophet: “Then will I sprinkle clean water upon you, and ye shall be cleansed from all your filthiness; and from all your idols will I cleanse you: a new heart also will I give you, and a new spirit will I put within you.”2815 But how can he cleanse and sanctify the water who is himself unclean, and in whom the Holy Spirit is not? since the Lord says in the book of Numbers, “And whatsoever the unclean person toucheth shall be unclean.”2816 Or how can he who baptizes give to another remission of sins who himself, being outside the Church, cannot put away his own sins? Epistle LXIX of Cyprian
If you are outside the Church, your baptism is invalid. The Catholic Church at the time argued heretics and schismatic baptisms were valid, even though the object (Trinity) was not the same in each instance (inside or outside the Church).
Cyprian, by the way, was very keen on the priestly line, requiring a valid priest to cleanse the water first. The heretics and schismatics do not have that "valid priest" he believed. Oddly Pope Stephen does not agree.
Cyprian sharpens the difference in another letter.
For the Lord after His resurrection, sending His disciples, instructed and taught them in what manner they ought to baptize, saying, “All power is given unto me in heaven and in earth. Go ye, therefore, and teach all nations, baptizing them in the name of the Father, and of the Son, and of the Holy Ghost.”2854 He suggests the Trinity, in whose sacrament the nations were to be baptized. Does Marcion then maintain the Trinity? Does he then assert the same Father, the Creator, as we do? Does he know the same Son, Christ born of the Virgin Mary, who as the Word was made flesh, who bare our sins, who conquered death by dying, who by Himself first of all originated the resurrection of the flesh, and showed to His disciples that He had risen in the same flesh? Widely different is the faith with Marcion, and, moreover, with the other heretics; nay, with them there is nothing but perfidy, and blasphemy, and contention, which is hostile to holiness and truth. How then can one who is baptized among them seem to have obtained remission of sins, and the grace of the divine mercy, by his faith, when he has not the truth of the faith itself? For if, as some suppose, one could receive anything abroad out of the Church according to his faith, certainly he has received what he believed; but if he believes what is false, he could not receive what is true; but rather he has received things adulterous and profane, according to what he believed. Epistle LXXII
Lastly, Firmillian replies to Stephen this way.
And as Stephen and those who agree with him contend that putting away of sins and second birth may result from the baptism of heretics, among whom they themselves confess that the Holy Spirit is not; let them consider and understand that spiritual birth cannot be without the Spirit; in conformity with which also the blessed Apostle Paul baptized anew with a spiritual baptism those who had already been baptized by John before the Holy Spirit had been sent by the Lord, and so laid hands on them that they might receive the Holy Ghost. Epistle LXXIV
This sharp distinction shows Church accepts only Trinity baptism, but not that of heretics and schismatics who do not believe the Trinity.
For the Catholic Church, however, heretics and schismatics baptisms' at that time were all valid. As already mentioned, only within the last century has the question of the sameness of belief in the Trinity entered its differences.
So, to answer the OP, the earliest reference to the Catholic Church recognizing the validity of heretical or schismatic (ie Protestant) baptism is circa 250 CE.
As to the question of salvation, whether a valid baptism, is all that is necessary, it seems to be a different question.
catholiccontrove00sain
, and followed by additional URL segment indicating the page number. The archive.org book reader automatically updates the full URL as you navigate the book.