Changeset fb323ce


Ignore:
Timestamp:
Sep 22, 2016 5:06:53 PM (3 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
32e1c96
Parents:
cc179b4
Message:

SipHashInline?: Make public for external use with a supplied key (for obfs4)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • core/java/src/net/i2p/util/SipHashInline.java

    rcc179b4 rfb323ce  
    3434 * I2P mods: add off/len version
    3535 *
    36  * @since 0.9.5
     36 * @since 0.9.5, public since 0.9.27
    3737 */
    38 abstract class SipHashInline {
    39 
     38public final class SipHashInline {
     39
     40    /** @since 0.9.27 */
     41    private SipHashInline() {};
     42
     43    /**
     44     *  @param k0 the first 8 bytes of the key
     45     *  @param k1 the last 8 bytes of the key
     46     */
    4047    public static long hash24(long k0, long k1, byte[] data) {
    4148        return hash24(k0, k1, data, 0, data.length);
    4249    }
    4350
     51    /**
     52     *  @param k0 the first 8 bytes of the key
     53     *  @param k1 the last 8 bytes of the key
     54     */
    4455    public static long hash24(long k0, long k1, byte[] data, int off, int len) {
    4556        long v0 = 0x736f6d6570736575L ^ k0;
Note: See TracChangeset for help on using the changeset viewer.