Aqui el codigo:
Código
#! /usr/bin/env python # -*- coding: utf-8 -*- import random import crypt print ' ______________________________________' print '| Created by: El Jorgy |' print '| |' print '| 21/6/17 18:07 |' print '| |' print '| Contact: no colocar datos personales |' print '|______________________________________|' def Cifrar_Cesar(String,Key): tmp = '' for i in String: tmp += chr(ord(i)+Key) return tmp def Descifrar_Cesar(String,Key): return Cifrar_Cesar(String,-Key) a = random.randint(0, 126) Clave = a Palabra = raw_input('Introduce la frase: ') Password = crypt.crypt(Palabra, 'He') Rencrypt = crypt.crypt(Password, '><') Reencrypt = crypt.crypt(Rencrypt, '*+') Reeencrypt = crypt.crypt(Reencrypt, '?¿') Reeeencrypt = crypt.crypt(Reeencrypt, 'Lp') Reeeeencrypt = crypt.crypt(Reeeencrypt, 'wd') Reeeeeencrypt = crypt.crypt(Reeeeencrypt, '*d') Reeeeeeencrypt = crypt.crypt(Reeeeeencrypt, 'Ñd') Reeeeeeeencrypt = crypt.crypt(Reeeeeeencrypt, 'ÑD') Reeeeeeeeencrypt = crypt.crypt(Reeeeeeeencrypt, '¨Q') Reeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeencrypt, '··') Reeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeencrypt, '($') Reeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeencrypt, '¨:') Reeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeencrypt, '*¨') Reeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeencrypt, 'que') Reeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeencrypt, '=%') Reeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeencrypt, 'Ns') Reeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeencrypt, 'Ns') Reeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeencrypt, 'wd') Reeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeencrypt, 'Ld') Reeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeencrypt, '_d') Reeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeencrypt, 'ªw') Reeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeencrypt, ';D') Reeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeencrypt, ':D') Reeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeencrypt, '_-') Reeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeencrypt, 'que') Reeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeencrypt, '@&') Reeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeencrypt, ':1') Reeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeeencrypt, 'Na') Reeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt, 'que') Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt, 'Ç}') Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt, 'nf') Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt = crypt.crypt(Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt, 'ª}') Palabras = Reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeencrypt print 'Palabra super cifrada: ' + Cifrar_Cesar(Palabras, Clave)