I would prefer if my significant other was not 100% honest with me.
Is there a certain reason you feel this way?  Did he say something that you wouldn't have wanted to know?
He thinks that if I knew everything about him , I might not like him.
I think it is okay to not know everything about each other. It is fine to have specific standards when dating.
I think he is scared of being vulnerable and he doesn't want to feel judged.
Well if your boyfriend feels this way, and as long as you don't think that whatever he is keeping secret is dangerous or threatening, then I think it's fine for you to respect his privacy.  I do, however, think it would be a good idea for you to ask him out right if whatever he is hiding is truly in the past.