

def auth_sub_string_from_body(http_body):
    "Extracts the AuthSub token from an HTTP body string.\n\n  Used to find the new session token after making a request to upgrade a\n  single use AuthSub token.\n\n  Args:\n    http_body: str The repsonse from the server which contains the AuthSub\n        key. For example, this function would find the new session token\n        from the server's response to an upgrade token request.\n\n  Returns:\n    The raw token value string to use in an AuthSubToken object.\n  "
    for response_line in http_body.splitlines():
        if response_line.startswith('Token='):
            return response_line[6:]
    return None

dataset/ETHPy150Open acil-bwh/SlicerCIP/Scripted/attic/PicasaSnap/gdata/gauth.py auth_sub_string_from_body/original