def buiild_canonicalized_headers(headers, prefix):
    """
    aliyun的header里的canonicalized属性排序和计算
    :param headers:
    :param prefix:
    :return:
    """
    canonicalized_headers = ''
    if len(headers) > 0:
        x_header_list = headers.keys()
        sorted(x_header_list)
        for k in x_header_list:
            if k.startswith(prefix):
                canonicalized_headers += k + ':' + headers[k] + '\n'
    return canonicalized_headers
