'Get an association for the endpoint\'s server_url.
First try seeing if we have a good association in the
store. If we do not, then attempt to negotiate an association
with the server.
If we negotiate a good association, it will get stored.
@returns: A valid association for the endpoint\'s server_url or None
@rtype: openid.association.Association or NoneType'

def _getAssociation(self, endpoint):

    assoc = self.store.getAssociation(endpoint.server_url)
    if ((assoc is None) or (assoc.expiresIn <= 0)):
        assoc = self._negotiateAssociation(endpoint)
        if (assoc is not None):
            self.store.storeAssociation(endpoint.server_url, assoc)
    return assoc
