if (cipherSpi == null) { if (inputLength > output.length - outputOffset) { throw new ShortBufferException(); } System.arraycopy(input, inputOffset, output, outputOffset, inputLength); return inputLength; } if (state != ENCRYPT_MODE && state != DECRYPT_MODE) { throw new IllegalStateException( "cipher is not for encrypting or decrypting"); } return cipherSpi.engineUpdate(input, inputOffset, inputLength, output, outputOffset);
return update(input, 0, input.length);
  public final int update(byte[] input, int inputOffset, int inputLength,                          byte[] output, int outputOffset)    throws IllegalStateException, ShortBufferException  {    if (cipherSpi == null)      {        if (inputLength > output.length - outputOffset)          {            throw new ShortBufferException();          }        System.arraycopy(input, inputOffset, output, outputOffset, inputLength);        return inputLength;      }    if (state != ENCRYPT_MODE && state != DECRYPT_MODE)      {        throw new IllegalStateException(          "cipher is not for encrypting or decrypting");      }    return cipherSpi.engineUpdate(input, inputOffset, inputLength,                                  output, outputOffset);  }