def open(self):
        univention.admin.handlers.simpleLdap.open(self)
        self.oldinfo['a'] = []
        self.info['a'] = []
        if 'aRecord' in self.oldattr:
            self.oldinfo['a'].extend(self.oldattr['aRecord'])
            self.info['a'].extend(self.oldattr['aRecord'])
        if 'aAAARecord' in self.oldattr:
            self.oldinfo['a'].extend(
                map(lambda x: ipaddr.IPv6Address(x).exploded,
                    self.oldattr['aAAARecord']))
            self.info['a'].extend(
                map(lambda x: ipaddr.IPv6Address(x).exploded,
                    self.oldattr['aAAARecord']))

        soa = self.oldattr.get('sOARecord', [''])[0].split(' ')
        if len(soa) > 6:
            self['contact'] = unescapeSOAemail(soa[1])
            self['serial'] = soa[2]
            self['refresh'] = univention.admin.mapping.unmapUNIX_TimeInterval(
                soa[3])
            self['retry'] = univention.admin.mapping.unmapUNIX_TimeInterval(
                soa[4])
            self['expire'] = univention.admin.mapping.unmapUNIX_TimeInterval(
                soa[5])
            self['ttl'] = univention.admin.mapping.unmapUNIX_TimeInterval(
                soa[6])

        self.save()
예제 #2
0
	def open(self):
		univention.admin.handlers.simpleLdap.open(self)

		soa = self.oldattr.get('sOARecord', [b''])[0].split(b' ')
		if len(soa) > 6:
			self['contact'] = unescapeSOAemail(soa[1].decode('UTF-8'))
			self['serial'] = soa[2].decode('UTF-8')
			self['refresh'] = univention.admin.mapping.unmapUNIX_TimeInterval(soa[3])
			self['retry'] = univention.admin.mapping.unmapUNIX_TimeInterval(soa[4])
			self['expire'] = univention.admin.mapping.unmapUNIX_TimeInterval(soa[5])
			self['ttl'] = univention.admin.mapping.unmapUNIX_TimeInterval(soa[6])

		self.save()
예제 #3
0
	def open(self):
		univention.admin.handlers.simpleLdap.open(self)

		soa=self.oldattr.get('sOARecord',[''])[0].split(' ')
		if len(soa) > 6:
			self['contact'] = unescapeSOAemail(soa[1])
			self['serial'] = soa[2]
			self['refresh'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[3] )
			self['retry'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[4] )
			self['expire'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[5] )
			self['ttl'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[6] )

		self.save()
예제 #4
0
	def open(self):
		univention.admin.handlers.simpleLdap.open(self)
		self.oldinfo['a'] = []
		self.info['a'] = []
		if 'aRecord' in self.oldattr:
			self.oldinfo['a'].extend(self.oldattr['aRecord'])
			self.info['a'].extend(   self.oldattr['aRecord'])
		if 'aAAARecord' in self.oldattr:
			self.oldinfo['a'].extend(map(lambda x: ipaddr.IPv6Address(x).exploded, self.oldattr['aAAARecord']))
			self.info['a'].extend(   map(lambda x: ipaddr.IPv6Address(x).exploded, self.oldattr['aAAARecord']))

		soa=self.oldattr.get('sOARecord',[''])[0].split(' ')
		if len(soa) > 6:
			self['contact'] = unescapeSOAemail(soa[1])
			self['serial']=soa[2]
			self['refresh'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[3] )
			self['retry'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[4] )
			self['expire'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[5] )
			self['ttl'] = univention.admin.mapping.unmapUNIX_TimeInterval( soa[6] )

		self.save()