protected void doPadding(byte[] output, int outputOffset)
	{
		/*
		 * This is slightly ugly... we need to get the still
		 * buffered data, but the only way to get it from
		 * DigestEngine is to input some more bytes and wait
		 * for the processBlock() call. We set a variable
		 * with the count of actual data bytes, so that
		 * processBlock() knows what to do.
		 */
		onlyThis = flush();
		if (onlyThis > 0)
			update(zeroPad, 0, 64 - onlyThis);

		int olen = tmpOut.length;
		dig.digest(tmpOut, 0, olen);
		dig.update(kopad);
		dig.update(tmpOut);
		dig.digest(tmpOut, 0, olen);
		if (outputLength >= 0)
			olen = outputLength;
		System.arraycopy(tmpOut, 0, output, outputOffset, olen);
	}