public static byte[] toArray(long l, int numBytes) {
		ByteBuffer buffy = ByteBuffer.allocate(Long.BYTES);
		buffy.putLong(l);
		byte[] checksumArray = new byte[numBytes];
		int n = Math.min(Long.BYTES, numBytes);
		System.arraycopy(buffy.array(), Long.BYTES - n, checksumArray, numBytes - n, n);
		ArrayUtils.reverse(checksumArray);
		return checksumArray;
	}
Converts a long to a little-endian array.

@param l The long to convert.
@param numBytes The desired size of the resulting array.  Result is truncated or padded if 
                numBytes is smaller or larger than size of long.
@return The little-endian array.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/checksums/ChecksumAlgorithm.java