import math


def pad_message(message, blocklength):
    """Pad a message so its length is a multiple of blocklength."""
    message_padded_length = (
        int(math.ceil(len(message) / blocklength)) * blocklength)
    padded_message = message.ljust(message_padded_length)
    return padded_message