Yeah, this is exactly what he wanted to happen.
He finds the book from the evil dude. Immediately gives it to the knight without even opening it. The knight gives it to his commander (like he said he would) and can verify that he didn't read it.
So he should be completely avoiding any suspicion.
In addition, he gave it to the knight for "safe keeping". So if it's okay for him to have it then they'll eventually return it. If it's not okay, then he's avoided getting into trouble.