The present specification for putInt() uses Java's default byte order (big endian) for turning an int into bytes but the Javadocs for java.nio.ByteBuffer state that while the byte order is big endian by default, it can be set to little endian using order(ByteOrder).