Toggle navigation
Home
Latest pastes
FAQ
Random
BitBin is shutting down!
Register
Login
teste_della_porta.py
SUBMITTED BY:
siriarah
DATE:
Nov. 19, 2019, 9:30 p.m.
FORMAT:
Python 3
SIZE:
447 Bytes
Raw
Download
Tweet
HITS:
617
Go to comments
Report
from
della_porta
import
DellaPorta
import
sys
versao
=
sys
.
version_info
[
0
]
if
versao
==
2
:
leitura
=
raw_input
elif
versao
==
3
:
leitura
=
input
txt_in
=
leitura
(
'Texto a ser cifrado: '
)
txt_key
=
leitura
(
'Chave: '
)
dporta
=
DellaPorta
()
txt_cifrado
=
dporta
.
encrypt
(
txt_in
,
txt_key
)
print
(
''
)
print
(
'Texto cifrado:
{0}
'
.
format
(
txt_cifrado
))
print
(
' Texto plano:
{0}
'
.
format
(
dporta
.
decrypt
(
txt_cifrado
,
txt_key
)))
Please enable JavaScript to view the
comments powered by Disqus.
comments powered by
Disqus