If the user-provided slice doesn't actually match the expected alignment, undefined behavior will ensue.
FWIW, many of these buffer-wranging APIs actually want to receive an *mut [u8], because they are often meant to manipulate uninitialized memory and that concept doesn't exist at the Rust reference layer.