public static int searchFor(byte[] buffer, byte[] searchFor, int iStartBufferOffset) {
		int iWrk = iStartBufferOffset;
		int iX;

		if (buffer == null)
			throw new NullPointerException("buffer is null");
		if (searchFor == null)
			throw new NullPointerException("searchFor is null");
		if (iStartBufferOffset < 0)
			throw new IllegalArgumentException("iStartBufferOffset < 0");
		if (iStartBufferOffset > buffer.length)
			throw new IllegalArgumentException("iStartBufferOffset > buffer.length");

		while (iWrk < buffer.length - searchFor.length +1) {
			iX = -1;
			boolean testRemaining = iX < searchFor.length - 1;
			boolean sofarCorrect = true;

			while (testRemaining && sofarCorrect) {
				iX++;
				sofarCorrect = (buffer[iWrk + iX] == searchFor[iX]);
				testRemaining = iX < searchFor.length - 1;
			}
			if (testRemaining == false && sofarCorrect) {
				return iWrk + iX + 1;
			}
			iWrk++;
		}
		return -1;
	}