Untitled

                Never    
Java
       
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package kr.co.grizzly.masq.synchronization.anonymity;

import java.io.IOException;
import java.util.ArrayList;
import java.util.Iterator;
import org.apache.commons.codec.EncoderException;

public class StreamMatcher {
    private ArrayList<ArrayList<a>> a;
    private long b;
    private long c;
    private d d;
    public static int e;
    private static final String f;

    public StreamMatcher(String var1, long var2, double var4) throws Exception {
        int var10000 = e;
        kr.co.grizzly.masq.synchronization.anonymity.b.a();
        int var6 = var10000;
        this.d = new d(var2, var4);

        ArrayList var7;
        try {
            var7 = kr.co.grizzly.masq.synchronization.anonymity.b.b(var1, this.d.getAnoKeyLen());
        } catch (IOException var15) {
            System.out.println(f);
            throw var15;
        }

        long var8 = ((a)var7.get(0)).a;
        long var10 = ((a)var7.get(0)).b;
        Iterator var12 = var7.iterator();

        while(var12.hasNext()) {
            a var13 = (a)var12.next();

            long var18;
            label54: {
                try {
                    if (var8 > var13.a) {
                        var18 = var13.a;
                        break label54;
                    }
                } catch (IOException var17) {
                    throw var17;
                }

                var18 = var8;
            }

            var8 = var18;

            label46: {
                try {
                    if (var10 < var13.b) {
                        var18 = var13.b;
                        break label46;
                    }
                } catch (IOException var16) {
                    throw var16;
                }

                var18 = var10;
            }

            var10 = var18;
            if (var6 != 0) {
                break;
            }
        }

        try {
            this.a = new ArrayList();
            kr.co.grizzly.masq.synchronization.anonymity.b.a(this.a, this.d.g());
            this.b = (var10 - var8) / (long)this.d.g();
            this.c = var8;
            kr.co.grizzly.masq.synchronization.anonymity.b.a(var7, this.c, this.b, this.d.g(), this.a);
            if (EncoderException.b) {
                ++var6;
                e = var6;
            }

        } catch (IOException var14) {
            throw var14;
        }
    }

    public String match(String var1) {
        long[] var3 = kr.co.grizzly.masq.synchronization.anonymity.b.a(var1, this.d.getAnoKeyLen());
        long var4 = var3[0];
        int var2 = e;
        long var6 = var3[1];
        int var8 = (int)((var4 - this.c) / this.b);
        int var9 = (int)((var6 - this.c) / this.b);
        if (var9 >= 0 && var8 < this.d.g()) {
            var8 = var8 < 0 ? 0 : var8;
            var9 = var9 >= this.d.g() ? this.d.g() - 1 : var9;
            a var10 = new a(var4, var6, "");
            double var11 = -1.0D;
            a var13 = null;
            int var14 = var8;

            while(var14 <= var9) {
                if (this.a.get(var14) != null || var2 != 0) {
                    Iterator var15 = ((ArrayList)this.a.get(var14)).iterator();

                    label49:
                    do {
                        a var16;
                        double var17;
                        do {
                            if (!var15.hasNext()) {
                                break label49;
                            }

                            var16 = (a)var15.next();
                            var17 = kr.co.grizzly.masq.synchronization.anonymity.b.a(var10, var16);
                        } while(var17 < this.d.h() && var2 == 0);

                        if (var17 > var11) {
                            var11 = var17;
                            var13 = var16;
                        }
                    } while(var2 == 0);
                }

                ++var14;
                if (var2 != 0) {
                    break;
                }
            }

            return var11 < 0.0D ? null : var13.c;
        } else {
            return null;
        }
    }

    static {
        char[] var10001 = "xp\u001cn\u007f((ot\"`_!7#T\u0000sD;d".toCharArray();
        int var10003 = var10001.length;
        int var0 = 0;
        char[] var10002 = var10001;
        int var2 = var10003;
        String var1;
        char[] var4;
        int var10004;
        boolean var5;
        if (var10003 <= 1) {
            var4 = var10001;
            var10004 = var0;
        } else {
            var10002 = var10001;
            var2 = var10003;
            if (var10003 <= var0) {
                var1 = (new String(var10001)).intern();
                var5 = true;
                f = var1;
                return;
            }

            var4 = var10001;
            var10004 = var0;
        }

        while(true) {
            char var10005 = var4[var10004];
            byte var10006;
            switch(var0 % 7) {
            case 0:
                var10006 = 3;
                break;
            case 1:
                var10006 = 17;
                break;
            case 2:
                var10006 = 114;
                break;
            case 3:
                var10006 = 1;
                break;
            case 4:
                var10006 = 43;
                break;
            case 5:
                var10006 = 73;
                break;
            default:
                var10006 = 74;
            }

            var4[var10004] = (char)(var10005 ^ var10006);
            ++var0;
            if (var2 == 0) {
                var10004 = var2;
                var4 = var10002;
            } else {
                if (var2 <= var0) {
                    var1 = (new String(var10002)).intern();
                    var5 = true;
                    f = var1;
                    return;
                }

                var4 = var10002;
                var10004 = var0;
            }
        }
    }
}