This Mary, whose brother Lazarus now lay sick, was the same one who poured perfume on the Lord and wiped his feet with her hair.
John has not yet related the incident he refers to here and will not until the next chapter, but his audience is undoubtedly aware of Mary and what she had done for Jesus, so John identifies her for them.