Gospel of Thomas, Lambdin translation:
(1) And he said, "Whoever finds the interpretation of these sayings will not experience death."
John 3:15-17 KJV
15 That whosoever believeth in him should not perish, but have eternal life.
16 For God so loved the world, that he gave his only begotten Son, that whosoever believeth in him should not perish, but have everlasting life.
17 For God sent not his Son into the world to condemn the world; but that the world through him might be saved.
The invitation of Jesus for salvation by faith doesn't teach salvation by gnosis (mental gymnastics).