本文整理汇总了Python中oic.oic.provider.Provider.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python Provider.__init__方法的具体用法?Python Provider.__init__怎么用?Python Provider.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类oic.oic.provider.Provider
的用法示例。
在下文中一共展示了Provider.__init__方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(
self,
name,
sdb,
cdb,
userinfo,
client_authn,
urlmap=None,
ca_certs="",
keyjar=None,
hostname="",
dist_claims_mode=None,
):
Provider.__init__(
self, name, sdb, cdb, None, userinfo, None, client_authn, "", urlmap, ca_certs, keyjar, hostname
)
if keyjar is None:
keyjar = KeyJar(ca_certs)
for cid, _dic in cdb.items():
try:
keyjar.add_symmetric(cid, _dic["client_secret"], ["sig", "ver"])
except KeyError:
pass
self.srvmethod = OICCServer(keyjar=keyjar)
self.dist_claims_mode = dist_claims_mode
self.info_store = {}
self.claims_userinfo_endpoint = ""
示例2: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(self, name, sdb, cdb, authn_broker, userinfo, authz,
client_authn, symkey, trusted_domains, verify_signer_ssl=True, **kwarg):
Provider.__init__(self, name, sdb, cdb, authn_broker, userinfo, authz,
client_authn, symkey, **kwarg)
self.trusted_domains = trusted_domains
self.verify_signer_ssl = verify_signer_ssl
示例3: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(self, name, sdb, cdb, function, userdb, urlmap=None,
debug=0, ca_certs="", jwt_keys=None):
Provider.__init__(self, name, sdb, cdb, function, userdb, urlmap,
ca_certs, jwt_keys)
self.test_mode = True
self.trace_log = {}
self.sessions = []
self.max_sessions = 100
示例4: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(self, name, sdb, cdb, function, userdb, urlmap=None,
debug=0, ca_certs="", jwt_keys=None):
Provider.__init__(self, name, sdb, cdb, function, userdb, urlmap,
ca_certs, jwt_keys)
if jwt_keys is None:
jwt_keys = []
for cid, _dic in cdb.items():
jwt_keys.append([_dic["client_secret"], "hmac", "sig", cid])
jwt_keys.append([_dic["client_secret"], "hmac", "ver", cid])
self.srvmethod = OICCServer(jwt_keys=jwt_keys)
self.keystore = self.srvmethod.keystore
self.claims_mode = "aggregate"
self.info_store = {}
self.claims_userinfo_endpoint = ""
示例5: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(self, name, sdb, cdb, authn_broker, userinfo, authz,
client_authn, symkey, urlmap=None, keyjar=None,
hostname="", configuration=None, ca_certs="",
template_lookup=None, verify_login_template=None,
base_url=""):
OIDCProvider.__init__(self, name, sdb, cdb, authn_broker, userinfo,
authz, client_authn, symkey, urlmap, ca_certs,
keyjar, hostname, template_lookup,
verify_login_template)
UmaAS.__init__(self, configuration, baseurl=base_url)
if keyjar:
self.keyjar = keyjar
else:
self.keyjar = KeyJar()
self.hostname = hostname or socket.gethostname
#self.jwks_uri = []
self.endp = UmaAS.endp[:]
self.endp.extend(OIDCProvider.endp)
示例6: __init__
# 需要导入模块: from oic.oic.provider import Provider [as 别名]
# 或者: from oic.oic.provider.Provider import __init__ [as 别名]
def __init__(self, name, sdb, cdb, function, userdb, urlmap=None,
debug=0, ca_certs="", jwt_keys=None):
Provider.__init__(self, name, sdb, cdb, function, userdb, urlmap,
ca_certs, jwt_keys)