code: def Expandkey(key, clen):
  		
  		import sha
  		from string import join
  		from array import array
  
  		blocks = (clen + 19) / 20
  		xkey = []
  		seed = key
  		for i in xrange(blocks):
  			seed = sha.new(key + seed).digest()
  			xkey.append(seed)
  		j = join(xkey, '')
  		return array('L', j)
docs: Internal method supporting encryption and decryption functionality.