md.update((c + "-" + password).getBytes("UTF-16LE"));
return c + "-" + new HexBinaryAdapter().marshal(md.digest()).toLowerCase();
} catch (NoSuchAlgorithmException e) {
- // Is it at all feasible for this to happen ?
- throw new RuntimeException("missing MD5 implementation");
+ throw new AssertionError("missing MD5 implementation");
} catch (UnsupportedEncodingException e) {
- throw new RuntimeException("missing UTF-16LE encoding");
+ throw new AssertionError("missing UTF-16LE encoding");
}
}
}