import base64
import hashlib


def compute_md5_for_string(string):
    """Compute MD5 digest over some string payload"""
    return base64.b64encode(hashlib.md5(
            string.encode('utf-8')).digest()).decode('utf-8')