Solutionunvalidated

If you don't care about the bytes read and just want the digest. Outcome: byte[] buffer = new byte[2048]; while (digestInputStream.read(buffer) >= 0);.

f509728f-0c4d-4cc9-8aeb-50570c3acf3a

If you don't care about the bytes read and just want the digest. Outcome: byte[] buffer = new byte[2048]; while (digestInputStream.read(buffer) >= 0);.