Mercurial > 510Connectbot
comparison app/src/main/java/ch/ethz/ssh2/crypto/digest/SHA512.java @ 510:7953570e5210
update to ganymed-ssh2 tag 263 and fix hmac-sha2-512
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Wed, 01 Feb 2023 17:55:29 -0700 |
parents | d29cce60f393 |
children |
comparison
equal
deleted
inserted
replaced
509:2eb4fa13b9ef | 510:7953570e5210 |
---|---|
31 public final void reset() { | 31 public final void reset() { |
32 md.reset(); | 32 md.reset(); |
33 } | 33 } |
34 | 34 |
35 public final void update(byte b[]) { | 35 public final void update(byte b[]) { |
36 md.update(b); | 36 this.update(b, 0, b.length); |
37 } | 37 } |
38 | 38 |
39 public final void update(byte b[], int off, int len) { | 39 public final void update(byte b[], int off, int len) { |
40 md.update(b, off, len); | 40 md.update(b, off, len); |
41 } | 41 } |
42 | 42 |
43 public final void update(byte b) { | 43 public final void update(byte b) { |
44 md.update(b); | 44 md.update(b); |
45 } | 45 } |
46 | 46 |
47 public final void digest(byte[] out) { | 47 public final void digest(byte[] out) throws DigestException { |
48 md.digest(out); | 48 this.digest(out, 0); |
49 } | 49 } |
50 | 50 |
51 public final void digest(byte[] out, int off) throws DigestException { | 51 public final void digest(byte[] out, int off) throws DigestException { |
52 md.digest(out, off, out.length); | 52 md.digest(out, off, out.length - off); |
53 } | 53 } |
54 } | 54 } |