def _scrub_headers(headers):
    """scrub auth info from headers"""
    headers = dict(headers)
    if 'Authorization' in headers:
        auth = headers['Authorization']
        if auth.startswith('token '):
            headers['Authorization'] = 'token [secret]'
    return headers


# log_request adapted from IPython (BSD)
dataset/ETHPy150Open jupyterhub/jupyterhub/jupyterhub/log.py/_scrub_headers/original