def createAssociation(self, dumb=True, assoc_type='HMAC-SHA1'):
        secret = cryptutil.getBytes(getSecretSize(assoc_type))
        uniq = oidutil.toBase64(cryptutil.getBytes(4))
        handle = '{%s}{%x}{%s}' % (assoc_type, int(time.time()), uniq)

        assoc = Association.fromExpiresIn(
            self.SECRET_LIFETIME, handle, secret, assoc_type)

        if dumb:
            key = self._dumb_key
        else:
            key = self._normal_key
        self.store.storeAssociation(key, assoc)
        return assoc
Handle a request.
dataset/ETHPy150Open CollabQ/CollabQ/openid/server/server.py/Signatory.createAssociation--crossover with--dataset/ETHPy150Open CollabQ/CollabQ/openid/server/server.py/Server.handleRequest