Fixes a Uint8Array to the specified length. If the array is longer than the specified length, it is truncated. If the array is shorter than the specified length, it is padded with zeroes.