CrackMe.apk
Download file
package com.google.android.exoplayer2.upstream.crypto;
import android.net.Uri;
import com.google.android.exoplayer2.upstream.DataSource;
import com.google.android.exoplayer2.upstream.DataSpec;
import com.google.android.exoplayer2.upstream.TransferListener;
import com.google.android.exoplayer2.util.Assertions;
import com.google.android.exoplayer2.util.Util;
import java.io.IOException;
import java.util.List;
import java.util.Map;
public final class AesCipherDataSource implements DataSource {
private AesFlushingCipher cipher;
private final byte[] secretKey;
private final DataSource upstream;
public AesCipherDataSource(byte[] bArr, DataSource dataSource) {
this.upstream = dataSource;
this.secretKey = bArr;
}
public void addTransferListener(TransferListener transferListener) {
Assertions.checkNotNull(transferListener);
this.upstream.addTransferListener(transferListener);
}
public long open(DataSpec dataSpec) throws IOException {
long open = this.upstream.open(dataSpec);
this.cipher = new AesFlushingCipher(2, this.secretKey, dataSpec.key, dataSpec.position + dataSpec.uriPositionOffset);
return open;
}
public int read(byte[] bArr, int i, int i2) throws IOException {
if (i2 == 0) {
return 0;
}
int read = this.upstream.read(bArr, i, i2);
if (read == -1) {
return -1;
}
((AesFlushingCipher) Util.castNonNull(this.cipher)).updateInPlace(bArr, i, read);
return read;
}
public Uri getUri() {
return this.upstream.getUri();
}
public Map<String, List<String>> getResponseHeaders() {
return this.upstream.getResponseHeaders();
}
public void close() throws IOException {
this.cipher = null;
this.upstream.close();
}
}
Download file