def init_app(self, app):
        """
        Do setup that requires a Flask app.
        """
        # register callback route and cookie-setting decorator
        app.route('/oidc_callback')(self.oidc_callback)
        app.after_request(self.after_request)

        # load client_secrets.json
        self.flow = flow_from_clientsecrets(
            app.config['OIDC_CLIENT_SECRETS'],
            scope=['openid', 'email'])
        assert isinstance(self.flow, OAuth2WebServerFlow)

        # create a cookie signer using the Flask secret key
        self.cookie_serializer = TimedJSONWebSignatureSerializer(
            app.config['SECRET_KEY'])

        try:
            self.google_apps_domain = app.config['OIDC_GOOGLE_APPS_DOMAIN']
        except KeyError:
            pass

        try:
            self.id_token_cookie_name = app.config['OIDC_ID_TOKEN_COOKIE_NAME']
        except KeyError:
            pass

        try:
            self.id_token_cookie_ttl = app.config['OIDC_ID_TOKEN_COOKIE_TTL']
        except KeyError:
            pass

        try:
            self.id_token_cookie_secure =\
                app.config['OIDC_ID_TOKEN_COOKIE_SECURE']
        except KeyError:
            pass

        try:
            self.credentials_store = app.config['OIDC_CREDENTIALS_STORE']
        except __HOLE__:
            pass
dataset/ETHPy150Open SteelPangolin/flask-oidc/flask_oidc/__init__.py/OpenIDConnect.init_app