Lines Matching defs:peekLength
54 private int peekLength = -1;
106 return peekLength <= in.available();
225 peekLength = (readByte & 0x7F);
226 if (peekLength != readByte)
228 lengthBytesNeeded = peekLength;
235 peekLength = 0x00;
257 peekLength = (peekLength << 8) | (readByte & 0xFF);
264 if ((maxElementSize > 0) && (peekLength > maxElementSize))
267 peekLength, maxElementSize);
313 peekLength = (peekLength << 8) | (readByte & 0xFF);
319 if ((maxElementSize > 0) && (peekLength > maxElementSize))
322 peekLength, maxElementSize);
354 public int peekLength() throws ASN1Exception
370 return peekLength;
386 peekLength();
388 if (peekLength != 1)
391 ERR_ASN1_BOOLEAN_INVALID_LENGTH.get(peekLength);
400 Message message = ERR_ASN1_BOOLEAN_TRUNCATED_VALUE.get(peekLength);
408 peekType, peekLength, String.valueOf(readByte != 0x00)));
428 peekLength();
430 if ((peekLength < 1) || (peekLength > 4))
432 Message message = ERR_ASN1_INTEGER_INVALID_LENGTH.get(peekLength);
447 peekLength();
449 if ((peekLength < 1) || (peekLength > 8))
452 ERR_ASN1_INTEGER_INVALID_LENGTH.get(peekLength);
458 if(peekLength > 4)
461 for (int i=0; i < peekLength; i++)
467 ERR_ASN1_INTEGER_TRUNCATED_VALUE.get(peekLength);
483 for (int i=0; i < peekLength; i++)
489 ERR_ASN1_INTEGER_TRUNCATED_VALUE.get(peekLength);
503 "value=%d)", peekType, peekLength, intValue));
524 peekLength();
527 if (peekLength != 0)
530 ERR_ASN1_NULL_INVALID_LENGTH.get(peekLength);
538 peekType, peekLength));
549 peekLength();
551 if(peekLength == 0)
560 byte[] value = new byte[peekLength];
561 int bytesNeeded = peekLength;
565 bytesRead = in.read(value, peekLength - bytesNeeded, bytesNeeded);
569 ERR_ASN1_OCTET_STRING_TRUNCATED_VALUE.get(peekLength);
580 peekType, peekLength));
610 peekLength();
612 if(peekLength == 0)
619 if(peekLength > buffer.length)
621 buffer = new byte[peekLength];
626 int bytesNeeded = peekLength;
630 bytesRead = in.read(buffer, peekLength - bytesNeeded, bytesNeeded);
634 ERR_ASN1_OCTET_STRING_TRUNCATED_VALUE.get(peekLength);
652 str = new String(buffer, 0, peekLength, charSet);
661 str = new String(buffer, 0, peekLength);
668 "value=%s)", peekType, peekLength, str));
680 peekLength();
682 if(peekLength == 0)
691 int bytesNeeded = peekLength;
699 ERR_ASN1_OCTET_STRING_TRUNCATED_VALUE.get(peekLength);
709 peekType, peekLength));
728 peekLength();
731 new SizeLimitInputStream(in, peekLength);
737 peekType, peekLength));
832 peekLength();
836 long bytesSkipped = in.skip(peekLength);
837 if(bytesSkipped != peekLength)
840 ERR_ASN1_SKIP_TRUNCATED_VALUE.get(peekLength);