Using bouncyCastle, full java