Verily, verily, I say unto you, He that entereth not by the door into the sheepfold, but climbeth up some other way, the same is a thief and a robber. But he that entereth in by the door is the shepherd of the sheep. To him the porter openeth; and the sheep hear his voice: and he calleth his own sheep by name, and leadeth them out. And when he putteth forth his own sheep, he goeth before them, and the sheep follow him: for they know his voice. And a stranger will they not follow, but will flee from him: for they know not the voice of strangers. (John 10:1-5)
"The door" is the Holy Scriptures, the Bible. Blessed Theophylact, following the interpretation of St. John Chrysostom, explains this to us.
Jesus Christ Himself, the Son and Word of God, is also "the door", as He tells us a few verses later. It is only by Him that we can enter and be saved.
He is also the Good Shepherd, who enters by "the door" of the Holy Scriptures, since they testify to Him. Indeed, the whole Bible is about Jesus Christ. Everybody else speaks of himself, and twists the Scriptures to fit his ideas.
So how is it that we can be saved, and "go in and out, and find pasture"? Through Jesus Christ.
And how is it that we will recognize Him? Because He will "call us by name," and if we will "know His voice".
And how will we know His voice? Because we will have, throughout our lives, accustomed ourselves to hear and love His voice.
And how do we accustom ourselves to hear and love His voice? By reading the Holy Scriptures, by praying in the words of the saints, by attentively praying in the services of the Church, by frequently receiving the Holy Mysteries, and by striving to follow His directions about how to live, knowing that He will not lead us astray but will rather guide us into the good pasture.