So they gave Jacob all the foreign gods which were in their hands, and the earrings which were in their ears; and Jacob hid them under the terebinth tree which was by Shechem. Genesis 35:4 (NKJV)
A plain reading of Genesis 35:4 makes it appear that the hands and the ears mentioned in the verse belong to the people. Regarding the hands, there is no ambiguity - the hands can't belong to anyone else. The "they" in this verse is tied directly to "his household" mentioned in verse 2.
However, the ears are actually ambiguous. The ears might belong to this same household group, in which case we can assume that they donned the earrings after looting Shechem's people in the previous chapter. But there is another interpretation of the text that Chizkuni entertains.
אשר באזניהם, “which were in the ears of those idols.” Chizkuni on Genesis 35:4
Why would this interpretation exist? It has to do with the assumption of intentional writing: Torah doesn't leave room for meaningless repetition or omission. So the "in their..." is the repeated phrase the text did not need. And therefore, it should be examined.
The "foreign gods in their hands... the earrings in their ears" forces a question: why were the earrings buried? Surely, the plunder of Shechem did not only involve earrings. You'd expect other jewelry and items to be included, but the earrings are singled out. From this, it seems possible that the earrings in question were in the ears of the idols and were somehow associated with the worship of those idols.
This also feels related:
And Aaron said to them, “Break off the golden earrings which are in the ears of your wives, your sons, and your daughters, and bring them to me.” So all the people broke off the golden earrings which were in their ears, and brought them to Aaron. And he received the gold from their hand, and he fashioned it with an engraving tool, and made a molded calf.
Then they said, “This is your god, O Israel, that brought you out of the land of Egypt!” Exodus 32:2-4 (NKJV)