ah.smali

.class public Lcom/appsflyer/internal/ah;
.super Ljava/io/FilterInputStream;
.source ""


# instance fields
.field private ı:[B

.field private Ɩ:I

.field private ǃ:[B

.field private ɩ:[B

.field private ɹ:[I

.field private Ι:Lcom/appsflyer/internal/ak;

.field private final ι:I

.field private І:I

.field private і:I

.field private Ӏ:I


# direct methods
.method public constructor <init>(Ljava/io/InputStream;[I[BIZI)V
    .registers 8
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    invoke-direct {p0, p1}, Ljava/io/FilterInputStream;-><init>(Ljava/io/InputStream;)V

    const p1, 0x7fffffff

    .line 2
    iput p1, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    const/4 p1, 0x3

    .line 3
    invoke-static {p4, p1}, Ljava/lang/Math;->max(II)I

    move-result p1

    const/16 p4, 0x10

    invoke-static {p1, p4}, Ljava/lang/Math;->min(II)I

    move-result p1

    iput p1, p0, Lcom/appsflyer/internal/ah;->ι:I

    const/16 p1, 0x8

    .line 4
    new-array p4, p1, [B

    iput-object p4, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    .line 5
    new-array p4, p1, [B

    iput-object p4, p0, Lcom/appsflyer/internal/ah;->ı:[B

    .line 6
    new-array p4, p1, [B

    iput-object p4, p0, Lcom/appsflyer/internal/ah;->ǃ:[B

    const/4 p4, 0x2

    .line 7
    new-array v0, p4, [I

    iput-object v0, p0, Lcom/appsflyer/internal/ah;->ɹ:[I

    .line 8
    iput p1, p0, Lcom/appsflyer/internal/ah;->і:I

    .line 9
    iput p1, p0, Lcom/appsflyer/internal/ah;->І:I

    .line 10
    iput p6, p0, Lcom/appsflyer/internal/ah;->Ɩ:I

    if-ne p6, p4, :cond_36

    .line 11
    iget-object p4, p0, Lcom/appsflyer/internal/ah;->ı:[B

    const/4 p6, 0x0

    invoke-static {p3, p6, p4, p6, p1}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V

    .line 12
    :cond_36
    new-instance p1, Lcom/appsflyer/internal/ak;

    iget p3, p0, Lcom/appsflyer/internal/ah;->ι:I

    const/4 p4, 0x1

    invoke-direct {p1, p2, p3, p4, p5}, Lcom/appsflyer/internal/ak;-><init>([IIZZ)V

    iput-object p1, p0, Lcom/appsflyer/internal/ah;->Ι:Lcom/appsflyer/internal/ak;

    return-void
.end method

.method private ı()V
    .registers 20

    move-object/from16 v0, p0

    .line 1
    iget v1, v0, Lcom/appsflyer/internal/ah;->Ɩ:I

    const/4 v2, 0x2

    const/4 v3, 0x0

    if-ne v1, v2, :cond_10

    .line 2
    iget-object v1, v0, Lcom/appsflyer/internal/ah;->ɩ:[B

    iget-object v4, v0, Lcom/appsflyer/internal/ah;->ǃ:[B

    array-length v5, v1

    invoke-static {v1, v3, v4, v3, v5}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V

    .line 3
    :cond_10
    iget-object v1, v0, Lcom/appsflyer/internal/ah;->ɩ:[B

    aget-byte v4, v1, v3

    shl-int/lit8 v4, v4, 0x18

    const/high16 v5, -0x1000000

    and-int/2addr v4, v5

    const/4 v6, 0x1

    aget-byte v7, v1, v6

    shl-int/lit8 v7, v7, 0x10

    const/high16 v8, 0xff0000

    and-int/2addr v7, v8

    add-int/2addr v4, v7

    aget-byte v7, v1, v2

    const/16 v9, 0x8

    shl-int/2addr v7, v9

    const v10, 0xff00

    and-int/2addr v7, v10

    add-int/2addr v4, v7

    const/4 v7, 0x3

    aget-byte v11, v1, v7

    and-int/lit16 v11, v11, 0xff

    add-int v12, v4, v11

    const/4 v4, 0x4

    .line 4
    aget-byte v11, v1, v4

    shl-int/lit8 v11, v11, 0x18

    and-int/2addr v5, v11

    const/4 v11, 0x5

    aget-byte v13, v1, v11

    shl-int/lit8 v13, v13, 0x10

    and-int/2addr v8, v13

    add-int/2addr v5, v8

    const/4 v8, 0x6

    aget-byte v13, v1, v8

    shl-int/2addr v13, v9

    and-int/2addr v10, v13

    add-int/2addr v5, v10

    const/4 v10, 0x7

    aget-byte v1, v1, v10

    and-int/lit16 v1, v1, 0xff

    add-int v13, v5, v1

    const/4 v14, 0x0

    .line 5
    iget v15, v0, Lcom/appsflyer/internal/ah;->ι:I

    iget-object v1, v0, Lcom/appsflyer/internal/ah;->Ι:Lcom/appsflyer/internal/ak;

    iget-object v5, v1, Lcom/appsflyer/internal/ak;->ι:[I

    iget-object v1, v1, Lcom/appsflyer/internal/ak;->ǃ:[[I

    iget-object v9, v0, Lcom/appsflyer/internal/ah;->ɹ:[I

    move-object/from16 v16, v5

    move-object/from16 v17, v1

    move-object/from16 v18, v9

    invoke-static/range {v12 .. v18}, Lcom/appsflyer/internal/ag;->ι(IIZI[I[[I[I)V

    .line 6
    iget-object v1, v0, Lcom/appsflyer/internal/ah;->ɹ:[I

    aget v5, v1, v3

    .line 7
    aget v1, v1, v6

    .line 8
    iget-object v9, v0, Lcom/appsflyer/internal/ah;->ɩ:[B

    shr-int/lit8 v12, v5, 0x18

    int-to-byte v12, v12

    aput-byte v12, v9, v3

    shr-int/lit8 v12, v5, 0x10

    int-to-byte v12, v12

    .line 9
    aput-byte v12, v9, v6

    shr-int/lit8 v6, v5, 0x8

    int-to-byte v6, v6

    .line 10
    aput-byte v6, v9, v2

    int-to-byte v5, v5

    .line 11
    aput-byte v5, v9, v7

    shr-int/lit8 v5, v1, 0x18

    int-to-byte v5, v5

    .line 12
    aput-byte v5, v9, v4

    shr-int/lit8 v4, v1, 0x10

    int-to-byte v4, v4

    .line 13
    aput-byte v4, v9, v11

    shr-int/lit8 v4, v1, 0x8

    int-to-byte v4, v4

    .line 14
    aput-byte v4, v9, v8

    int-to-byte v1, v1

    .line 15
    aput-byte v1, v9, v10

    .line 16
    iget v1, v0, Lcom/appsflyer/internal/ah;->Ɩ:I

    if-ne v1, v2, :cond_ad

    const/4 v1, 0x0

    const/16 v2, 0x8

    :goto_94
    if-ge v1, v2, :cond_a5

    .line 17
    iget-object v4, v0, Lcom/appsflyer/internal/ah;->ɩ:[B

    aget-byte v5, v4, v1

    iget-object v6, v0, Lcom/appsflyer/internal/ah;->ı:[B

    aget-byte v6, v6, v1

    xor-int/2addr v5, v6

    int-to-byte v5, v5

    aput-byte v5, v4, v1

    add-int/lit8 v1, v1, 0x1

    goto :goto_94

    .line 18
    :cond_a5
    iget-object v1, v0, Lcom/appsflyer/internal/ah;->ǃ:[B

    iget-object v2, v0, Lcom/appsflyer/internal/ah;->ı:[B

    array-length v4, v1

    invoke-static {v1, v3, v2, v3, v4}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V

    :cond_ad
    return-void
.end method

.method private Ι()I
    .registers 8
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    iget v0, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    const v1, 0x7fffffff

    if-ne v0, v1, :cond_f

    .line 2
    iget-object v0, p0, Ljava/io/FilterInputStream;->in:Ljava/io/InputStream;

    invoke-virtual {v0}, Ljava/io/InputStream;->read()I

    move-result v0

    iput v0, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    .line 3
    :cond_f
    iget v0, p0, Lcom/appsflyer/internal/ah;->і:I

    const/16 v1, 0x8

    if-ne v0, v1, :cond_5b

    .line 4
    iget-object v0, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    iget v2, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    int-to-byte v3, v2

    const/4 v4, 0x0

    aput-byte v3, v0, v4

    const-string v0, "unexpected block size"

    if-ltz v2, :cond_55

    const/4 v2, 0x1

    .line 5
    :cond_22
    iget-object v3, p0, Ljava/io/FilterInputStream;->in:Ljava/io/InputStream;

    iget-object v5, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    rsub-int/lit8 v6, v2, 0x8

    invoke-virtual {v3, v5, v2, v6}, Ljava/io/InputStream;->read([BII)I

    move-result v3

    if-lez v3, :cond_31

    add-int/2addr v2, v3

    if-lt v2, v1, :cond_22

    :cond_31
    if-lt v2, v1, :cond_4f

    .line 6
    invoke-direct {p0}, Lcom/appsflyer/internal/ah;->ı()V

    .line 7
    iget-object v0, p0, Ljava/io/FilterInputStream;->in:Ljava/io/InputStream;

    invoke-virtual {v0}, Ljava/io/InputStream;->read()I

    move-result v0

    iput v0, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    .line 8
    iput v4, p0, Lcom/appsflyer/internal/ah;->і:I

    .line 9
    iget v0, p0, Lcom/appsflyer/internal/ah;->Ӏ:I

    if-gez v0, :cond_4c

    iget-object v0, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    const/4 v2, 0x7

    aget-byte v0, v0, v2

    and-int/lit16 v0, v0, 0xff

    sub-int/2addr v1, v0

    :cond_4c
    iput v1, p0, Lcom/appsflyer/internal/ah;->І:I

    goto :goto_5b

    .line 10
    :cond_4f
    new-instance v1, Ljava/lang/IllegalStateException;

    invoke-direct {v1, v0}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V

    throw v1

    .line 11
    :cond_55
    new-instance v1, Ljava/lang/IllegalStateException;

    invoke-direct {v1, v0}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V

    throw v1

    .line 12
    :cond_5b
    :goto_5b
    iget v0, p0, Lcom/appsflyer/internal/ah;->І:I

    return v0
.end method


# virtual methods
.method public available()I
    .registers 3
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    invoke-direct {p0}, Lcom/appsflyer/internal/ah;->Ι()I

    .line 2
    iget v0, p0, Lcom/appsflyer/internal/ah;->І:I

    iget v1, p0, Lcom/appsflyer/internal/ah;->і:I

    sub-int/2addr v0, v1

    return v0
.end method

.method public markSupported()Z
    .registers 2

    const/4 v0, 0x0

    return v0
.end method

.method public read()I
    .registers 4
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    invoke-direct {p0}, Lcom/appsflyer/internal/ah;->Ι()I

    .line 2
    iget v0, p0, Lcom/appsflyer/internal/ah;->і:I

    iget v1, p0, Lcom/appsflyer/internal/ah;->І:I

    if-lt v0, v1, :cond_b

    const/4 v0, -0x1

    return v0

    .line 3
    :cond_b
    iget-object v1, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    add-int/lit8 v2, v0, 0x1

    iput v2, p0, Lcom/appsflyer/internal/ah;->і:I

    aget-byte v0, v1, v0

    and-int/lit16 v0, v0, 0xff

    return v0
.end method

.method public read([BII)I
    .registers 10
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    add-int v0, p2, p3

    move v1, p2

    :goto_3
    if-ge v1, v0, :cond_23

    .line 4
    invoke-direct {p0}, Lcom/appsflyer/internal/ah;->Ι()I

    .line 5
    iget v2, p0, Lcom/appsflyer/internal/ah;->і:I

    iget v3, p0, Lcom/appsflyer/internal/ah;->І:I

    if-lt v2, v3, :cond_15

    if-ne v1, p2, :cond_12

    const/4 p1, -0x1

    return p1

    :cond_12
    sub-int/2addr v0, v1

    sub-int/2addr p3, v0

    return p3

    :cond_15
    add-int/lit8 v3, v1, 0x1

    .line 6
    iget-object v4, p0, Lcom/appsflyer/internal/ah;->ɩ:[B

    add-int/lit8 v5, v2, 0x1

    iput v5, p0, Lcom/appsflyer/internal/ah;->і:I

    aget-byte v2, v4, v2

    aput-byte v2, p1, v1

    move v1, v3

    goto :goto_3

    :cond_23
    return p3
.end method

.method public skip(J)J
    .registers 7
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    const-wide/16 v0, 0x0

    :goto_2
    cmp-long v2, v0, p1

    if-gez v2, :cond_11

    .line 1
    invoke-virtual {p0}, Lcom/appsflyer/internal/ah;->read()I

    move-result v2

    const/4 v3, -0x1

    if-eq v2, v3, :cond_11

    const-wide/16 v2, 0x1

    add-long/2addr v0, v2

    goto :goto_2

    :cond_11
    return-wide v0
.end method