I was learning about ACTIVE and PASSIVE sentences and came across this particular example. I know a sentence is said to be Active when the subject of the particular sentence performs the action. For example, "The hunter killed an antelope." In the Passive form it will be "An antelope was killed by the hunter." A sentence becomes Passive when the action is acted upon the subject, and the subject becomes the receiver of the action like the second example I gave.
The book also said that the passive voice is use to express an action in which the actor is unknown, and gave this example "The food had been eaten before we came." What I'm confused about here is that, passive voice contains the preposition "by" which is preceded by the subject, but in this case, there was nothing like that, and I want to know if it's a valid one.