There is a slightly different version of the Hakuin story in "Shame and Conscience", in ZEN ANTICS translated and edited by Tom Cleary, (p 19-20) though he does not give the original Japanese source. Elihu Smith