# This file was automatically generated by SWIG (https://www.swig.org). # Version 4.1.1 # # Do not make changes to this file unless you know what you are doing - modify # the SWIG interface file instead. from sys import version_info as _swig_python_version_info # Import the low-level C/C++ module if __package__ or "." in __name__: from . import _credential else: from arc import _credential try: import builtins as __builtin__ except ImportError: import __builtin__ def _swig_repr(self): try: strthis = "proxy of " + self.this.__repr__() except __builtin__.Exception: strthis = "" return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) def _swig_setattr_nondynamic_instance_variable(set): def set_instance_attr(self, name, value): if name == "this": set(self, name, value) elif name == "thisown": self.this.own(value) elif hasattr(self, name) and isinstance(getattr(type(self), name), property): set(self, name, value) else: raise AttributeError("You cannot add instance attributes to %s" % self) return set_instance_attr def _swig_setattr_nondynamic_class_variable(set): def set_class_attr(cls, name, value): if hasattr(cls, name) and not isinstance(getattr(cls, name), property): set(cls, name, value) else: raise AttributeError("You cannot add class attributes to %s" % cls) return set_class_attr def _swig_add_metaclass(metaclass): """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass""" def wrapper(cls): return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy()) return wrapper class _SwigNonDynamicMeta(type): """Meta class to enforce nondynamic attributes (no new attributes) for a class""" __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__) class SwigPyIterator(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") def __init__(self, *args, **kwargs): raise AttributeError("No constructor defined - class is abstract") __repr__ = _swig_repr __swig_destroy__ = _credential.delete_SwigPyIterator def value(self): return _credential.SwigPyIterator_value(self) def incr(self, n=1): return _credential.SwigPyIterator_incr(self, n) def decr(self, n=1): return _credential.SwigPyIterator_decr(self, n) def distance(self, x): return _credential.SwigPyIterator_distance(self, x) def equal(self, x): return _credential.SwigPyIterator_equal(self, x) def copy(self): return _credential.SwigPyIterator_copy(self) def next(self): return _credential.SwigPyIterator_next(self) def __next__(self): return _credential.SwigPyIterator___next__(self) def previous(self): return _credential.SwigPyIterator_previous(self) def advance(self, n): return _credential.SwigPyIterator_advance(self, n) def __eq__(self, x): return _credential.SwigPyIterator___eq__(self, x) def __ne__(self, x): return _credential.SwigPyIterator___ne__(self, x) def __iadd__(self, n): return _credential.SwigPyIterator___iadd__(self, n) def __isub__(self, n): return _credential.SwigPyIterator___isub__(self, n) def __add__(self, n): return _credential.SwigPyIterator___add__(self, n) def __sub__(self, *args): return _credential.SwigPyIterator___sub__(self, *args) def __iter__(self): return self # Register SwigPyIterator in _credential: _credential.SwigPyIterator_swigregister(SwigPyIterator) import warnings def deprecated(method): """This decorator is used to mark python methods as deprecated, _not_ functions. It will result in a warning being emmitted when the method is used.""" def newMethod(*args, **kwargs): warnings.warn("Call to deprecated method 'arc.%s.%s'." % (args[0].__class__.__name__, method.__name__), category = DeprecationWarning, stacklevel = 2) return method(*args, **kwargs) newMethod.__name__ = method.__name__ newMethod.__doc__ = method.__doc__ newMethod.__dict__.update(method.__dict__) return newMethod class StaticPropertyWrapper(object): def __init__(self, wrapped_class): object.__setattr__(self, "wrapped_class", wrapped_class) def __getattr__(self, name): orig_attr = getattr(self.wrapped_class, name) if isinstance(orig_attr, property): return orig_attr.fget() else: return orig_attr def __setattr__(self, name, value): orig_attr = getattr(self.wrapped_class, name) if isinstance(orig_attr, property): orig_attr.fset(value) else: setattr(self.wrapped_class, name, value) from arc import common def OpenSSLInit(): return _credential.OpenSSLInit() def HandleOpenSSLError(*args): return _credential.HandleOpenSSLError(*args) def OpenSSLAppDataIndex(id): return _credential.OpenSSLAppDataIndex(id) class PasswordSource(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") def __init__(self, *args, **kwargs): raise AttributeError("No constructor defined - class is abstract") __repr__ = _swig_repr NO_PASSWORD = _credential.PasswordSource_NO_PASSWORD PASSWORD = _credential.PasswordSource_PASSWORD CANCEL = _credential.PasswordSource_CANCEL def Get(self, password, minsize, maxsize): return _credential.PasswordSource_Get(self, password, minsize, maxsize) __swig_destroy__ = _credential.delete_PasswordSource # Register PasswordSource in _credential: _credential.PasswordSource_swigregister(PasswordSource) class PasswordSourceNone(PasswordSource): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def Get(self, password, minsize, maxsize): return _credential.PasswordSourceNone_Get(self, password, minsize, maxsize) def __init__(self): _credential.PasswordSourceNone_swiginit(self, _credential.new_PasswordSourceNone()) __swig_destroy__ = _credential.delete_PasswordSourceNone # Register PasswordSourceNone in _credential: _credential.PasswordSourceNone_swigregister(PasswordSourceNone) class PasswordSourceString(PasswordSource): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, password): _credential.PasswordSourceString_swiginit(self, _credential.new_PasswordSourceString(password)) def Get(self, password, minsize, maxsize): return _credential.PasswordSourceString_Get(self, password, minsize, maxsize) __swig_destroy__ = _credential.delete_PasswordSourceString # Register PasswordSourceString in _credential: _credential.PasswordSourceString_swigregister(PasswordSourceString) class PasswordSourceStream(PasswordSource): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, password): _credential.PasswordSourceStream_swiginit(self, _credential.new_PasswordSourceStream(password)) def Get(self, password, minsize, maxsize): return _credential.PasswordSourceStream_Get(self, password, minsize, maxsize) __swig_destroy__ = _credential.delete_PasswordSourceStream # Register PasswordSourceStream in _credential: _credential.PasswordSourceStream_swigregister(PasswordSourceStream) class PasswordSourceInteractive(PasswordSource): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, prompt, verify): _credential.PasswordSourceInteractive_swiginit(self, _credential.new_PasswordSourceInteractive(prompt, verify)) def Get(self, password, minsize, maxsize): return _credential.PasswordSourceInteractive_Get(self, password, minsize, maxsize) __swig_destroy__ = _credential.delete_PasswordSourceInteractive # Register PasswordSourceInteractive in _credential: _credential.PasswordSourceInteractive_swigregister(PasswordSourceInteractive) class CredentialError(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, *args): _credential.CredentialError_swiginit(self, _credential.new_CredentialError(*args)) __swig_destroy__ = _credential.delete_CredentialError # Register CredentialError in _credential: _credential.CredentialError_swigregister(CredentialError) CRED_PEM = _credential.CRED_PEM CRED_DER = _credential.CRED_DER CRED_PKCS = _credential.CRED_PKCS CRED_UNKNOWN = _credential.CRED_UNKNOWN SIGN_DEFAULT = _credential.SIGN_DEFAULT SIGN_SHA1 = _credential.SIGN_SHA1 SIGN_SHA224 = _credential.SIGN_SHA224 SIGN_SHA256 = _credential.SIGN_SHA256 SIGN_SHA384 = _credential.SIGN_SHA384 SIGN_SHA512 = _credential.SIGN_SHA512 class Credential(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr __swig_destroy__ = _credential.delete_Credential def __init__(self, *args): _credential.Credential_swiginit(self, _credential.new_Credential(*args)) @staticmethod def InitProxyCertInfo(): return _credential.Credential_InitProxyCertInfo() @staticmethod def IsCredentialsValid(usercfg): return _credential.Credential_IsCredentialsValid(usercfg) @staticmethod def AddCertExtObj(sn, oid): return _credential.Credential_AddCertExtObj(sn, oid) def SetSigningAlgorithm(self, *args): return _credential.Credential_SetSigningAlgorithm(self, *args) def SetKeybits(self, keybits=0): return _credential.Credential_SetKeybits(self, keybits) @staticmethod def NoPassword(): return _credential.Credential_NoPassword() def LogError(self): return _credential.Credential_LogError(self) def GetVerification(self): return _credential.Credential_GetVerification(self) def GetPrivKey(self): return _credential.Credential_GetPrivKey(self) def GetPubKey(self): return _credential.Credential_GetPubKey(self) def GetCert(self): return _credential.Credential_GetCert(self) def GetCertReq(self): return _credential.Credential_GetCertReq(self) def GetCertChain(self): return _credential.Credential_GetCertChain(self) def GetCertNumofChain(self): return _credential.Credential_GetCertNumofChain(self) def getFormat_BIO(self, _in, is_file=True): return _credential.Credential_getFormat_BIO(self, _in, is_file) def getFormat_str(self, source): return _credential.Credential_getFormat_str(self, source) def GetDN(self): return _credential.Credential_GetDN(self) def GetIdentityName(self): return _credential.Credential_GetIdentityName(self) def GetType(self): return _credential.Credential_GetType(self) def GetIssuerName(self): return _credential.Credential_GetIssuerName(self) def GetCAName(self): return _credential.Credential_GetCAName(self) def GetSigningAlgorithm(self): return _credential.Credential_GetSigningAlgorithm(self) def GetKeybits(self): return _credential.Credential_GetKeybits(self) def GetProxyPolicy(self): return _credential.Credential_GetProxyPolicy(self) def SetProxyPolicy(self, proxyversion, policylang, policy, pathlength): return _credential.Credential_SetProxyPolicy(self, proxyversion, policylang, policy, pathlength) def OutputPrivatekey(self, *args): return _credential.Credential_OutputPrivatekey(self, *args) def OutputPublickey(self, content): return _credential.Credential_OutputPublickey(self, content) def OutputCertificate(self, content, is_der=False): return _credential.Credential_OutputCertificate(self, content, is_der) def OutputCertificateChain(self, content, is_der=False): return _credential.Credential_OutputCertificateChain(self, content, is_der) def GetLifeTime(self): return _credential.Credential_GetLifeTime(self) def GetStartTime(self): return _credential.Credential_GetStartTime(self) def GetEndTime(self): return _credential.Credential_GetEndTime(self) def SetLifeTime(self, period): return _credential.Credential_SetLifeTime(self, period) def SetStartTime(self, start_time): return _credential.Credential_SetStartTime(self, start_time) def IsValid(self): return _credential.Credential_IsValid(self) def AddExtension(self, *args): return _credential.Credential_AddExtension(self, *args) def GetExtension(self, name): return _credential.Credential_GetExtension(self, name) def GenerateEECRequest(self, *args): return _credential.Credential_GenerateEECRequest(self, *args) def GenerateRequest(self, *args): return _credential.Credential_GenerateRequest(self, *args) def InquireRequest(self, *args): return _credential.Credential_InquireRequest(self, *args) def SignRequest(self, *args): return _credential.Credential_SignRequest(self, *args) def SelfSignEECRequest(self, dn, extfile, extsect, certfile): return _credential.Credential_SelfSignEECRequest(self, dn, extfile, extsect, certfile) def SignEECRequest(self, *args): return _credential.Credential_SignEECRequest(self, *args) # Register Credential in _credential: _credential.Credential_swigregister(Credential) cvar = _credential.cvar CredentialLogger = cvar.CredentialLogger class RegularExpression(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, *args): _credential.RegularExpression_swiginit(self, _credential.new_RegularExpression(*args)) __swig_destroy__ = _credential.delete_RegularExpression def isOk(self): return _credential.RegularExpression_isOk(self) def hasPattern(self, str): return _credential.RegularExpression_hasPattern(self, str) def match(self, *args): return _credential.RegularExpression_match(self, *args) def getPattern(self): return _credential.RegularExpression_getPattern(self) # Register RegularExpression in _credential: _credential.RegularExpression_swigregister(RegularExpression) class VOMSACInfo(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr Success = _credential.VOMSACInfo_Success CAUnknown = _credential.VOMSACInfo_CAUnknown CertRevoked = _credential.VOMSACInfo_CertRevoked LSCFailed = _credential.VOMSACInfo_LSCFailed TrustFailed = _credential.VOMSACInfo_TrustFailed X509ParsingFailed = _credential.VOMSACInfo_X509ParsingFailed ACParsingFailed = _credential.VOMSACInfo_ACParsingFailed InternalParsingFailed = _credential.VOMSACInfo_InternalParsingFailed TimeValidFailed = _credential.VOMSACInfo_TimeValidFailed IsCritical = _credential.VOMSACInfo_IsCritical ParsingError = _credential.VOMSACInfo_ParsingError ValidationError = _credential.VOMSACInfo_ValidationError Error = _credential.VOMSACInfo_Error voname = property(_credential.VOMSACInfo_voname_get, _credential.VOMSACInfo_voname_set) holder = property(_credential.VOMSACInfo_holder_get, _credential.VOMSACInfo_holder_set) issuer = property(_credential.VOMSACInfo_issuer_get, _credential.VOMSACInfo_issuer_set) target = property(_credential.VOMSACInfo_target_get, _credential.VOMSACInfo_target_set) attributes = property(_credential.VOMSACInfo_attributes_get, _credential.VOMSACInfo_attributes_set) _from = property(_credential.VOMSACInfo__from_get, _credential.VOMSACInfo__from_set) till = property(_credential.VOMSACInfo_till_get, _credential.VOMSACInfo_till_set) status = property(_credential.VOMSACInfo_status_get, _credential.VOMSACInfo_status_set) def __init__(self): _credential.VOMSACInfo_swiginit(self, _credential.new_VOMSACInfo()) __swig_destroy__ = _credential.delete_VOMSACInfo # Register VOMSACInfo in _credential: _credential.VOMSACInfo_swigregister(VOMSACInfo) class VOMSTrustList(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, *args): _credential.VOMSTrustList_swiginit(self, _credential.new_VOMSTrustList(*args)) __swig_destroy__ = _credential.delete_VOMSTrustList def AddChain(self, *args): return _credential.VOMSTrustList_AddChain(self, *args) def AddElement(self, encoded_list): return _credential.VOMSTrustList_AddElement(self, encoded_list) def AddRegex(self, reg): return _credential.VOMSTrustList_AddRegex(self, reg) def SizeChains(self): return _credential.VOMSTrustList_SizeChains(self) def SizeRegexs(self): return _credential.VOMSTrustList_SizeRegexs(self) def GetChain(self, num): return _credential.VOMSTrustList_GetChain(self, num) def GetRegex(self, num): return _credential.VOMSTrustList_GetRegex(self, num) # Register VOMSTrustList in _credential: _credential.VOMSTrustList_swigregister(VOMSTrustList) def InitVOMSAttribute(): return _credential.InitVOMSAttribute() def createVOMSAC(codedac, issuer_cred, holder_cred, fqan, targets, attributes, voname, uri, lifetime): return _credential.createVOMSAC(codedac, issuer_cred, holder_cred, fqan, targets, attributes, voname, uri, lifetime) def addVOMSAC(aclist, acorder, decodedac): return _credential.addVOMSAC(aclist, acorder, decodedac) def parseVOMSAC(*args): return _credential.parseVOMSAC(*args) def VOMSDecode(data, size, j): return _credential.VOMSDecode(data, size, j) def VOMSEncode(data, size, j): return _credential.VOMSEncode(data, size, j) def getCredentialProperty(*args): return _credential.getCredentialProperty(*args) def VOMSFQANToFull(vo, fqan): return _credential.VOMSFQANToFull(vo, fqan) def VOMSFQANFromFull(attribute): return _credential.VOMSFQANFromFull(attribute) def VOMSACSeqEncode(*args): return _credential.VOMSACSeqEncode(*args) class VOMSACInfoVector(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def iterator(self): return _credential.VOMSACInfoVector_iterator(self) def __iter__(self): return self.iterator() def __nonzero__(self): return _credential.VOMSACInfoVector___nonzero__(self) def __bool__(self): return _credential.VOMSACInfoVector___bool__(self) def __len__(self): return _credential.VOMSACInfoVector___len__(self) def __getslice__(self, i, j): return _credential.VOMSACInfoVector___getslice__(self, i, j) def __setslice__(self, *args): return _credential.VOMSACInfoVector___setslice__(self, *args) def __delslice__(self, i, j): return _credential.VOMSACInfoVector___delslice__(self, i, j) def __delitem__(self, *args): return _credential.VOMSACInfoVector___delitem__(self, *args) def __getitem__(self, *args): return _credential.VOMSACInfoVector___getitem__(self, *args) def __setitem__(self, *args): return _credential.VOMSACInfoVector___setitem__(self, *args) def pop(self): return _credential.VOMSACInfoVector_pop(self) def append(self, x): return _credential.VOMSACInfoVector_append(self, x) def empty(self): return _credential.VOMSACInfoVector_empty(self) def size(self): return _credential.VOMSACInfoVector_size(self) def swap(self, v): return _credential.VOMSACInfoVector_swap(self, v) def begin(self): return _credential.VOMSACInfoVector_begin(self) def end(self): return _credential.VOMSACInfoVector_end(self) def rbegin(self): return _credential.VOMSACInfoVector_rbegin(self) def rend(self): return _credential.VOMSACInfoVector_rend(self) def clear(self): return _credential.VOMSACInfoVector_clear(self) def get_allocator(self): return _credential.VOMSACInfoVector_get_allocator(self) def pop_back(self): return _credential.VOMSACInfoVector_pop_back(self) def erase(self, *args): return _credential.VOMSACInfoVector_erase(self, *args) def __init__(self, *args): _credential.VOMSACInfoVector_swiginit(self, _credential.new_VOMSACInfoVector(*args)) def push_back(self, x): return _credential.VOMSACInfoVector_push_back(self, x) def front(self): return _credential.VOMSACInfoVector_front(self) def back(self): return _credential.VOMSACInfoVector_back(self) def assign(self, n, x): return _credential.VOMSACInfoVector_assign(self, n, x) def resize(self, *args): return _credential.VOMSACInfoVector_resize(self, *args) def insert(self, *args): return _credential.VOMSACInfoVector_insert(self, *args) def reserve(self, n): return _credential.VOMSACInfoVector_reserve(self, n) def capacity(self): return _credential.VOMSACInfoVector_capacity(self) __swig_destroy__ = _credential.delete_VOMSACInfoVector # Register VOMSACInfoVector in _credential: _credential.VOMSACInfoVector_swigregister(VOMSACInfoVector) class StringVectorVector(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def iterator(self): return _credential.StringVectorVector_iterator(self) def __iter__(self): return self.iterator() def __nonzero__(self): return _credential.StringVectorVector___nonzero__(self) def __bool__(self): return _credential.StringVectorVector___bool__(self) def __len__(self): return _credential.StringVectorVector___len__(self) def __getslice__(self, i, j): return _credential.StringVectorVector___getslice__(self, i, j) def __setslice__(self, *args): return _credential.StringVectorVector___setslice__(self, *args) def __delslice__(self, i, j): return _credential.StringVectorVector___delslice__(self, i, j) def __delitem__(self, *args): return _credential.StringVectorVector___delitem__(self, *args) def __getitem__(self, *args): return _credential.StringVectorVector___getitem__(self, *args) def __setitem__(self, *args): return _credential.StringVectorVector___setitem__(self, *args) def pop(self): return _credential.StringVectorVector_pop(self) def append(self, x): return _credential.StringVectorVector_append(self, x) def empty(self): return _credential.StringVectorVector_empty(self) def size(self): return _credential.StringVectorVector_size(self) def swap(self, v): return _credential.StringVectorVector_swap(self, v) def begin(self): return _credential.StringVectorVector_begin(self) def end(self): return _credential.StringVectorVector_end(self) def rbegin(self): return _credential.StringVectorVector_rbegin(self) def rend(self): return _credential.StringVectorVector_rend(self) def clear(self): return _credential.StringVectorVector_clear(self) def get_allocator(self): return _credential.StringVectorVector_get_allocator(self) def pop_back(self): return _credential.StringVectorVector_pop_back(self) def erase(self, *args): return _credential.StringVectorVector_erase(self, *args) def __init__(self, *args): _credential.StringVectorVector_swiginit(self, _credential.new_StringVectorVector(*args)) def push_back(self, x): return _credential.StringVectorVector_push_back(self, x) def front(self): return _credential.StringVectorVector_front(self) def back(self): return _credential.StringVectorVector_back(self) def assign(self, n, x): return _credential.StringVectorVector_assign(self, n, x) def resize(self, *args): return _credential.StringVectorVector_resize(self, *args) def insert(self, *args): return _credential.StringVectorVector_insert(self, *args) def reserve(self, n): return _credential.StringVectorVector_reserve(self, n) def capacity(self): return _credential.StringVectorVector_capacity(self) __swig_destroy__ = _credential.delete_StringVectorVector # Register StringVectorVector in _credential: _credential.StringVectorVector_swigregister(StringVectorVector) class CredentialStore(object): thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr def __init__(self, *args): _credential.CredentialStore_swiginit(self, _credential.new_CredentialStore(*args)) __swig_destroy__ = _credential.delete_CredentialStore def __nonzero__(self): return _credential.CredentialStore___nonzero__(self) __bool__ = __nonzero__ def Store(self, *args): return _credential.CredentialStore_Store(self, *args) def Retrieve(self, options, cred, if_delegate=True): return _credential.CredentialStore_Retrieve(self, options, cred, if_delegate) def Info(self, options, respinfo): return _credential.CredentialStore_Info(self, options, respinfo) def Destroy(self, options): return _credential.CredentialStore_Destroy(self, options) def ChangePassword(self, options): return _credential.CredentialStore_ChangePassword(self, options) # Register CredentialStore in _credential: _credential.CredentialStore_swigregister(CredentialStore)