def _clean_data_struct(orig_data):
    '''
    walk a complex data structure, and use _clean_data() to
    remove any template tags that may exist
    '''
    if isinstance(orig_data, dict):
        data = orig_data.copy()
        for key in data:
            new_key = _clean_data_struct(key)
            new_val = _clean_data_struct(data[key])
            if key != new_key:
                del data[key]
            data[new_key] = new_val
    elif isinstance(orig_data, list):
        data = orig_data[:]
        for i in range(0, len(data)):
            data[i] = _clean_data_struct(data[i])
    elif isinstance(orig_data, basestring):
        data = _clean_data(orig_data)
    else:
        data = orig_data
    return data
The product receives input or data, but it does
        not validate or incorrectly validates that the input has the
        properties that are required to process the data safely and
        correctly.