124 lines
3.7 KiB
Java
124 lines
3.7 KiB
Java
|
package o;
|
||
|
|
||
|
import java.io.ByteArrayOutputStream;
|
||
|
import java.io.IOException;
|
||
|
import java.util.Enumeration;
|
||
|
import java.util.Vector;
|
||
|
|
||
|
/* loaded from: classes6.dex */
|
||
|
public final class gnV extends gnD {
|
||
|
gnD[] e;
|
||
|
|
||
|
/* JADX INFO: Access modifiers changed from: package-private */
|
||
|
@Override // o.AbstractC15315gnE
|
||
|
public final boolean d() {
|
||
|
return true;
|
||
|
}
|
||
|
|
||
|
private static byte[] b(gnD[] gndArr) {
|
||
|
ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();
|
||
|
for (int i = 0; i != gndArr.length; i++) {
|
||
|
try {
|
||
|
byteArrayOutputStream.write(((C15382gov) gndArr[i]).b());
|
||
|
} catch (IOException e) {
|
||
|
StringBuilder sb = new StringBuilder("exception converting octets ");
|
||
|
sb.append(e.toString());
|
||
|
throw new IllegalArgumentException(sb.toString());
|
||
|
} catch (ClassCastException unused) {
|
||
|
StringBuilder sb2 = new StringBuilder();
|
||
|
sb2.append(gndArr[i].getClass().getName());
|
||
|
sb2.append(" found in input should only contain DEROctetString");
|
||
|
throw new IllegalArgumentException(sb2.toString());
|
||
|
}
|
||
|
}
|
||
|
return byteArrayOutputStream.toByteArray();
|
||
|
}
|
||
|
|
||
|
public gnV(byte[] bArr) {
|
||
|
super(bArr);
|
||
|
}
|
||
|
|
||
|
public gnV(gnD[] gndArr) {
|
||
|
super(b(gndArr));
|
||
|
this.e = gndArr;
|
||
|
}
|
||
|
|
||
|
@Override // o.gnD
|
||
|
public final byte[] b() {
|
||
|
return this.b;
|
||
|
}
|
||
|
|
||
|
/* renamed from: o.gnV$1, reason: invalid class name */
|
||
|
/* loaded from: classes6.dex */
|
||
|
final class AnonymousClass1 implements Enumeration {
|
||
|
private int d = 0;
|
||
|
private gnV e;
|
||
|
|
||
|
/* JADX INFO: Access modifiers changed from: package-private */
|
||
|
public AnonymousClass1(gnV gnv) {
|
||
|
this.e = gnv;
|
||
|
}
|
||
|
|
||
|
@Override // java.util.Enumeration
|
||
|
public final boolean hasMoreElements() {
|
||
|
return this.d < this.e.e.length;
|
||
|
}
|
||
|
|
||
|
@Override // java.util.Enumeration
|
||
|
public final Object nextElement() {
|
||
|
gnD[] gndArr = this.e.e;
|
||
|
int i = this.d;
|
||
|
this.d = i + 1;
|
||
|
return gndArr[i];
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* JADX INFO: Access modifiers changed from: package-private */
|
||
|
public final Vector g() {
|
||
|
Vector vector = new Vector();
|
||
|
int i = 0;
|
||
|
while (i < this.b.length) {
|
||
|
int i2 = i + 1000;
|
||
|
int length = (i2 > this.b.length ? this.b.length : i2) - i;
|
||
|
byte[] bArr = new byte[length];
|
||
|
System.arraycopy(this.b, i, bArr, 0, length);
|
||
|
vector.addElement(new C15382gov(bArr));
|
||
|
i = i2;
|
||
|
}
|
||
|
return vector;
|
||
|
}
|
||
|
|
||
|
/* JADX INFO: Access modifiers changed from: package-private */
|
||
|
@Override // o.AbstractC15315gnE
|
||
|
public final int c() throws IOException {
|
||
|
Enumeration anonymousClass1;
|
||
|
if (this.e == null) {
|
||
|
anonymousClass1 = g().elements();
|
||
|
} else {
|
||
|
anonymousClass1 = new AnonymousClass1(this);
|
||
|
}
|
||
|
int i = 0;
|
||
|
while (anonymousClass1.hasMoreElements()) {
|
||
|
i += ((InterfaceC15342gnr) anonymousClass1.nextElement()).i().c();
|
||
|
}
|
||
|
return i + 4;
|
||
|
}
|
||
|
|
||
|
@Override // o.gnD, o.AbstractC15315gnE
|
||
|
public final void c(gnG gng) throws IOException {
|
||
|
Enumeration anonymousClass1;
|
||
|
gng.a(36);
|
||
|
gng.a(128);
|
||
|
if (this.e == null) {
|
||
|
anonymousClass1 = g().elements();
|
||
|
} else {
|
||
|
anonymousClass1 = new AnonymousClass1(this);
|
||
|
}
|
||
|
while (anonymousClass1.hasMoreElements()) {
|
||
|
gng.d((InterfaceC15342gnr) anonymousClass1.nextElement());
|
||
|
}
|
||
|
gng.a(0);
|
||
|
gng.a(0);
|
||
|
}
|
||
|
}
|