<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def verify_client(endpoint_context, request, authorization_info):
 """ Initiated Guessing ! :param endpoint_context: SrvInfo instance :param request: The request :param authorization_info: Client authentication information :return: dictionary containing client id, client authentication method and possibly access token. """


    if not authorization_info:
        if 'client_id' in request and 'client_secret' in request:
            auth_info = ClientSecretPost(endpoint_context).verify(request)
            auth_info['method'] = 'client_secret_post'
        elif 'client_assertion' in request:
            auth_info = JWSAuthnMethod(endpoint_context).verify(request)
            #  If symmetric key was used
            # auth_method = 'client_secret_jwt'
            #  If asymmetric key was used
            auth_info['method'] = 'private_key_jwt'
        elif 'access_token' in request:
            auth_info = BearerBody(endpoint_context).verify(request)
            auth_info['method'] = 'bearer_body'
        else:
            raise UnknownOrNoAuthnMethod()
    else:
        if authorization_info.startswith('Basic '):
            auth_info = ClientSecretBasic(endpoint_context).verify(
                request, authorization_info)
            auth_info['method'] = 'client_secret_basic'
        elif authorization_info.startswith('Bearer '):
            auth_info = BearerHeader(endpoint_context).verify(
                request, authorization_info)
            auth_info['method'] = 'bearer_header'
        else:
            raise UnknownOrNoAuthnMethod(authorization_info)

    try:
        client_id = auth_info['client_id']
    except KeyError:
        client_id = ''
        try:
            _token = auth_info['token']
        except KeyError:
            logger.warning('Unknown client ID')
        else:
            sinfo = endpoint_context.sdb[_token]
            auth_info['client_id'] = sinfo['authn_req']['client_id']
    else:
        try:
            _cinfo = endpoint_context.cdb[client_id]
        except KeyError:
            raise ValueError('Unknown Client ID')
        else:
            if isinstance(_cinfo,str):
                try:
                    _cinfo = endpoint_context.cdb[_cinfo]
                except KeyError:
                    raise ValueError('Unknown Client ID')

            try:
                valid_client_info(_cinfo)
            except KeyError:
                logger.warning('Client registration has timed out')
                raise ValueError('Not valid client')
            else:
                # check that the expected authz method was used
                try:
                    endpoint_context.cdb[client_id]['auth_method'][
                        request.__class__.__name__] = auth_info['method']
                except KeyError:
                    try:
                        endpoint_context.cdb[client_id]['auth_method'] = {
                            request.__class__.__name__: auth_info['method']}
                    except KeyError:
                        pass

    return auth_info