Rewrite PBE handling read to support PKCS#5 v2.0 and update the function