質問するログイン新規登録

質問編集履歴

1

コードを修正

2021/05/19 15:03

投稿

noko123
noko123

スコア28

title CHANGED
File without changes
body CHANGED
@@ -11,7 +11,7 @@
11
11
  val cipherText:ByteArray=cipher.doFinal(plaintext)
12
12
       val iv: ByteArray = cipher.iv
13
13
 
14
- encryptedText.text=cipher.toString()
14
+ encryptedText.text=cipherText.toString()
15
15
  }
16
16
  ```
17
17
  として暗号化したテキストを表示しました。次に、この暗号化した文章を元に戻そうとして、
@@ -26,7 +26,7 @@
26
26
  val cipherText:ByteArray=cipher.doFinal(encryptedtext)
27
27
  val iv:ByteArray=cipher.iv
28
28
 
29
- decryptedText.text=iv.toString()
29
+ decryptedText.text=cipherText.toString()
30
30
  }
31
31
  ```
32
32