1-Topshiriq. OpenSSL kutubxonasidan foydalangan holda ma’lumotlarni gibrid shifrlash usulida shifrlash. (2 ball)
Har bir talaba Gibrid shifrlash usulida OpenSSL kutubxonasidan foydalangan holda shifrlash jarayonini amalga oshirish lozim (Ism va Familiya ochiq matn sifatida olinadi). (2 ball)
Ilova
openssl genrsa -out rsa.key 4096
openssl rsa -in rsa.key -pubout -out rsa_public.key
openssl rand -out keyfile 32 - //32 bitdan iborat kalit
openssl rsautl -encrypt -pubin -inkey rsa.pub -in keyfile -out keyfile_crypted
openssl aes-256-cbc -e -in plain.txt -out encrypted.txt -pass file:keyfile
openssl rsautl -decrypt -inkey rsa.key -in keyfile_crypted -out keyfile
openssl aes-256-cbc -d -in encrypted.txt -out plain_decrypted.txt -pass file:keyfile
2-Topshiriq. OpenSSL kutubxonasidan foydalangan holda RSA algoritmi asosida ERI hosil qilish.
Har bir talaba OpenSSL kutubxonasidan foydalangan holda RSA algoritmi asosida ERI hosil qiladi va ikkita foydalanuvchi tomonidan xavfsiz ma’lumot almashadi bunda shifrlash jarayonini amalga oshirish lozim (Ism va Familiya ochiq matn sifatida olinadi). (2 ball)
Ilova
openssl genpkey -algorithm RSA -pkeyopt rsa_keygen_bits:2048 -pkeyopt rsa_keygen_pubexp:3 -out yopiqkey.pem
openssl pkey -in yopiqkey.pem -out ochiqkey.pem -pubout
openssl pkeyutl -encrypt -in message.txt -pubin -inkey pubkey-B.pem -out ciphertext.bin
openssl dgst -sha1 -sign yopiqkey.pem -out imzo.bin message.txt
openssl pkeyutl -decrypt -in ciphertext.bin -inkey yopiqkey.pem -out deshifr.txt
openssl dgst -sha1 -verify ochiqkey.pem -signature signature.bin deshifr.txt
Jami 4 ball
!!!Izoh. Har bir talaba topshiriqlarni bajarilish holatini scrinshot(rasm)ga olib worl fayliga yig’ilib HEMIS tizimiga yuklanadi.
Do'stlaringiz bilan baham: |